Fontend handling of account role to hide user actions and links that the user does not have access to

This commit is contained in:
Torkel Ödegaard
2015-01-28 11:33:50 +01:00
parent aa261bbe23
commit 1cff564483
5 changed files with 23 additions and 22 deletions
+8 -7
View File
@@ -15,13 +15,14 @@ type LoginCommand struct {
}
type CurrentUser struct {
Login string `json:"login"`
Email string `json:"email"`
Role m.RoleType `json:"role"`
Name string `json:"name"`
UsingAccountName string `json:"usingAccountName"`
IsGrafanaAdmin bool `json:"isGrafanaAdmin"`
GravatarUrl string `json:"gravatarUrl"`
IsSignedIn bool `json:"isSignedIn"`
Login string `json:"login"`
Email string `json:"email"`
Name string `json:"name"`
AccountRole m.RoleType `json:"accountRole"`
AccountName string `json:"acountName"`
IsGrafanaAdmin bool `json:"isGrafanaAdmin"`
GravatarUrl string `json:"gravatarUrl"`
}
type DataSource struct {