Commit to merge latest code
This commit is contained in:
parent
f57d917297
commit
465db26f7e
20
admin_archive.go
Normal file
20
admin_archive.go
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
package main
|
||||||
|
|
||||||
|
import (
|
||||||
|
"net/http"
|
||||||
|
|
||||||
|
"github.com/gorilla/mux"
|
||||||
|
)
|
||||||
|
|
||||||
|
func handleAdminArchive(w http.ResponseWriter, req *http.Request, page *pageData) {
|
||||||
|
vars := mux.Vars(req)
|
||||||
|
page.SubTitle = "GameJam Archive"
|
||||||
|
id := vars["id"]
|
||||||
|
if id == "" {
|
||||||
|
// Archive List
|
||||||
|
type archivePageData struct {
|
||||||
|
Gamejams []Gamejam
|
||||||
|
}
|
||||||
|
apd := new(archivePageData)
|
||||||
|
}
|
||||||
|
}
|
@ -47,6 +47,8 @@ func handleAdmin(w http.ResponseWriter, req *http.Request) {
|
|||||||
handleAdminSetMode(w, req, page)
|
handleAdminSetMode(w, req, page)
|
||||||
case "authmode":
|
case "authmode":
|
||||||
handleAdminSetAuthMode(w, req, page)
|
handleAdminSetAuthMode(w, req, page)
|
||||||
|
case "archive":
|
||||||
|
handleAdminArchive(w, req, page)
|
||||||
default:
|
default:
|
||||||
page.TemplateData = getCondorcetResult()
|
page.TemplateData = getCondorcetResult()
|
||||||
page.show("admin-main.html", w)
|
page.show("admin-main.html", w)
|
||||||
|
1
main.go
1
main.go
@ -273,6 +273,7 @@ func InitPageData(w http.ResponseWriter, req *http.Request) *pageData {
|
|||||||
p.Menu = append(p.Menu, menuItem{"Teams", "/admin/teams", "fa-users"})
|
p.Menu = append(p.Menu, menuItem{"Teams", "/admin/teams", "fa-users"})
|
||||||
p.Menu = append(p.Menu, menuItem{"Games", "/admin/games", "fa-gamepad"})
|
p.Menu = append(p.Menu, menuItem{"Games", "/admin/games", "fa-gamepad"})
|
||||||
p.Menu = append(p.Menu, menuItem{"Votes", "/admin/votes", "fa-sticky-note"})
|
p.Menu = append(p.Menu, menuItem{"Votes", "/admin/votes", "fa-sticky-note"})
|
||||||
|
p.Menu = append(p.Menu, menuItem{"Archive", "/admin/archive", "fa-archive"})
|
||||||
p.Menu = append(p.Menu, menuItem{"Clients", "/admin/clients", "fa-desktop"})
|
p.Menu = append(p.Menu, menuItem{"Clients", "/admin/clients", "fa-desktop"})
|
||||||
|
|
||||||
p.BottomMenu = append(p.BottomMenu, menuItem{"Users", "/admin/users", "fa-user"})
|
p.BottomMenu = append(p.BottomMenu, menuItem{"Users", "/admin/users", "fa-user"})
|
||||||
|
@ -6,6 +6,7 @@ import (
|
|||||||
"github.com/br0xen/boltease"
|
"github.com/br0xen/boltease"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
// Gamejam is specifically for an archived game jam
|
||||||
type Gamejam struct {
|
type Gamejam struct {
|
||||||
UUID string
|
UUID string
|
||||||
Name string
|
Name string
|
||||||
|
Loading…
Reference in New Issue
Block a user