2557eb935b
Renamed the *Store methods. Added more functionality to some of the DataStores. Added DataCache interfaces in addition to the DataStores to help curb their unrelenting growth and confusing APIs. Fixed a crash bug in the ForumStore getters. Fixed three tests. Added more tests. Temporary Group permissions should now be applied properly. Improved the Tempra Conflux theme. Moved the topic deletion logic into the TopicStore. Tweaked the permission checks on the member routes to make them more sensible.
28 lines
799 B
Go
28 lines
799 B
Go
package main
|
|
|
|
var blankGroup = Group{ID: 0, Name: ""}
|
|
|
|
type GroupAdmin struct {
|
|
ID int
|
|
Name string
|
|
Rank string
|
|
RankClass string
|
|
CanEdit bool
|
|
CanDelete bool
|
|
}
|
|
|
|
type Group struct {
|
|
ID int
|
|
Name string
|
|
IsMod bool
|
|
IsAdmin bool
|
|
IsBanned bool
|
|
Tag string
|
|
Perms Perms
|
|
PermissionsText []byte
|
|
PluginPerms map[string]bool // Custom permissions defined by plugins. What if two plugins declare the same permission, but they handle them in incompatible ways? Very unlikely, we probably don't need to worry about this, the plugin authors should be aware of each other to some extent
|
|
PluginPermsText []byte
|
|
Forums []ForumPerms
|
|
CanSee []int // The IDs of the forums this group can see
|
|
}
|