diff options
author | Steve Manuel <nilslice@gmail.com> | 2016-10-22 01:39:19 -0700 |
---|---|---|
committer | Steve Manuel <nilslice@gmail.com> | 2016-10-22 01:39:19 -0700 |
commit | 735f99addd98f232ae126cac11d93a9dbbcc3c79 (patch) | |
tree | f8d3804f326fda466ac9ac91782228909ef05fd6 /system/admin/handlers.go | |
parent | 936b8aef13b164ce74f9ec11bf1385275d282df8 (diff) |
adding initial support to edit and add admin users
Diffstat (limited to 'system/admin/handlers.go')
-rw-r--r-- | system/admin/handlers.go | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/system/admin/handlers.go b/system/admin/handlers.go index 497dec6..045d7b3 100644 --- a/system/admin/handlers.go +++ b/system/admin/handlers.go @@ -182,6 +182,32 @@ func configUsersHandler(res http.ResponseWriter, req *http.Request) { } } +func configUsersEditHandler(res http.ResponseWriter, req *http.Request) { + switch req.Method { + case http.MethodGet: + // list all users and delete buttons + + case http.MethodPost: + // create new user + + default: + res.WriteHeader(http.StatusMethodNotAllowed) + } +} + +func configUsersDeleteHandler(res http.ResponseWriter, req *http.Request) { + switch req.Method { + case http.MethodGet: + // list all users and delete buttons + + case http.MethodPost: + // create new user + + default: + res.WriteHeader(http.StatusMethodNotAllowed) + } +} + func loginHandler(res http.ResponseWriter, req *http.Request) { if !db.SystemInitComplete() { redir := req.URL.Scheme + req.URL.Host + "/admin/init" |