Put the Update and Packages pages on one Updates page

Router software and packages are two parts of one page, with one overlay,
one confirmation banner and both logs. /upgrade redirects to it; the
actions keep their addresses.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-24 22:55:54 +01:00
co-authored by Claude Sonnet 5.5
parent 4aef47a350
commit 9cb2d28ea1
11 changed files with 231 additions and 192 deletions
+1 -10
View File
@@ -294,17 +294,8 @@ func (a *app) upgradeData() upgradeData {
return d
}
func (a *app) upgradePage(w http.ResponseWriter, r *http.Request, sess session) {
d := a.upgradeData()
p := page{Title: "Packages", CSRF: sess.csrf, LoggedIn: true, Data: d, Flash: r.URL.Query().Get("msg")}
if d.Run.Running {
p.Live = 3
}
a.render(w, "upgrade", p)
}
func (a *app) upgradeBack(w http.ResponseWriter, r *http.Request, msg string) {
http.Redirect(w, r, "/upgrade?msg="+url.QueryEscape(msg), http.StatusSeeOther)
http.Redirect(w, r, "/update?msg="+url.QueryEscape(msg)+"#packages", http.StatusSeeOther)
}
func (a *app) upgradeChannel(w http.ResponseWriter, r *http.Request, _ session) {