From ec0c753e8386d0dabe6c65ffb9d26484fa361eb0 Mon Sep 17 00:00:00 2001 From: Steve Manuel Date: Sat, 29 Oct 2016 14:02:15 -0700 Subject: initial set up for external/internal toggle view --- system/admin/handlers.go | 8 ++++++-- system/admin/server.go | 1 + 2 files changed, 7 insertions(+), 2 deletions(-) (limited to 'system') diff --git a/system/admin/handlers.go b/system/admin/handlers.go index 9f0b81e..b511339 100644 --- a/system/admin/handlers.go +++ b/system/admin/handlers.go @@ -638,7 +638,7 @@ func postsHandler(res http.ResponseWriter, req *http.Request) { switch created { case "internal": - html += `
+ html += `
Created by: Internal  |  @@ -646,7 +646,7 @@ func postsHandler(res http.ResponseWriter, req *http.Request) {
` case "external": - html += `
+ html += `
Created by: Internal  |  @@ -753,6 +753,10 @@ func adminPostListItem(p editor.Editable, t string) []byte { return []byte(post) } +func approvePostHandler(res http.ResponseWriter, req *http.Request) { + +} + func editHandler(res http.ResponseWriter, req *http.Request) { switch req.Method { case http.MethodGet: diff --git a/system/admin/server.go b/system/admin/server.go index c22c278..161220e 100644 --- a/system/admin/server.go +++ b/system/admin/server.go @@ -24,6 +24,7 @@ func Run() { http.HandleFunc("/admin/configure/users/delete", user.Auth(configUsersDeleteHandler)) http.HandleFunc("/admin/posts", user.Auth(postsHandler)) + http.HandleFunc("/admin/posts/approve", user.Auth(approvePostHandler)) http.HandleFunc("/admin/posts/search", user.Auth(searchHandler)) http.HandleFunc("/admin/edit", user.Auth(editHandler)) -- cgit v1.2.3