Saving home dashboard id in table

This commit is contained in:
utkarshcmu
2016-03-16 23:22:27 -07:00
parent a88176e060
commit 749fd618a9
4 changed files with 30 additions and 6 deletions

View File

@ -160,7 +160,12 @@ func Register(r *macaron.Macaron) {
r.Delete("/:id", wrap(DeleteApiKey))
}, reqOrgAdmin)
r.Combo("/preferences").Get(GetPreferences).Put(bind(m.SavePreferencesCommand{}), wrap(SavePreferences))
// Preferences
r.Group("/preferences", func() {
r.Get("/", wrap(GetPreferences))
r.Put("/", bind(m.SavePreferencesCommand{}), wrap(SavePreferences))
r.Post("/set-home-dash", bind(m.SavePreferencesCommand{}), wrap(SetHomeDashboard))
})
// Data sources
r.Group("/datasources", func() {