Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // Permissions has the types of permissions that can be assigned Permissions = permissionTypes{ Create: "create:%s", Read: "read:%s", Update: "update:%s", Delete: "delete:%s", List: "list:%s", Assign: "assign:%s", Upload: "upload:%s", } // EntityNames the names of the tables in the server EntityNames = entitynames{ Users: "Users", Roles: "Roles", Permissions: "Permissions", RoleParents: "RoleParents", RolePermissions: "RolePermissions", UserPermissions: "UserPermissions", UserProfiles: "UserProfiles", UserRoles: "UserRoles", } // Dialects are definition of databases Dialects = dialects{ PostgresSQL: "postgres", MySQL: "mysql", } // Roles that are part of the systme Roles = []role{ { Name: "admin", Description: "Administrator of the app", }, { Name: "user", Description: "Normal user of the app", }, } )
Functions ¶
func FormatPermissionDesc ¶
FormatPermissionDesc returns a string with the description of the action:entity permission
func FormatPermissionTag ¶
FormatPermissionTag returns a string formatted action:entity permission
func GetTableName ¶
GetTableName gets the db normalized tablename
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.