Add the moderator role

This commit is contained in:
Las Zenow 2016-10-16 20:05:45 -04:00
parent baf2b5a6a9
commit dcc2d3b9dc
9 changed files with 28 additions and 16 deletions

View file

@ -21,7 +21,7 @@ type Status struct {
Title string
Search string
User string
IsAdmin bool
Role string
Notif []Notification
Updated string
Home bool
@ -39,7 +39,7 @@ func GetStatus(h handler) Status {
s.FullURL = s.BaseURL + h.r.RequestURI
s.Title = "Imperial Library of Trantor"
s.User = h.sess.User
s.IsAdmin = h.sess.IsAdmin()
s.Role = h.sess.Role
s.Notif = h.sess.GetNotif()
s.Updated = time.Now().UTC().Format("2006-01-02T15:04:05Z")
h.sess.Save(h.w, h.r)