Documentation ¶
Index ¶
- Constants
- Variables
- func CreatePermission(permission models.Permission) (models.Permission, error)
- func CreateRole(role models.Role) (models.Role, error)
- func CreateUser(user models.User) (models.User, error)
- func DeletePermissionById(id int) (permission models.Permission, err error)
- func DeleteRoleById(id int) (role models.Role, err error)
- func DeleteUserById(id int) (user models.User, err error)
- func FindAllPermissions() ([]models.Permission, error)
- func FindAllRoles() ([]models.Role, error)
- func FindAllUsers() ([]models.User, error)
- func GenerateNewJWT(claims jwt.Claims) (tokenString string)
- func GetPermissionById(id int) (permission models.Permission, err error)
- func GetRoleById(id int) (role models.Role, err error)
- func GetRoleWithPermissions(id int) (role models.Role, err error)
- func GetRolesWithPermissions() (roles []models.Role, err error)
- func GetUserByAccount(username string, pass string) (user models.User, err error)
- func GetUserById(id int) (user models.User, err error)
- func UpdatePermission(permission models.Permission) (models.Permission, error)
- func UpdateRole(role models.Role) (models.Role, error)
- func UpdateUser(user models.User) (models.User, error)
- func ValidateUser(c *gin.Context, username, password string) bool
Constants ¶
View Source
const PersistenceUnit = "testing"
Variables ¶
View Source
var Keystore *rsastore.RsaKeystore
Functions ¶
func CreatePermission ¶
func CreatePermission(permission models.Permission) (models.Permission, error)
func DeletePermissionById ¶
func DeletePermissionById(id int) (permission models.Permission, err error)
func FindAllPermissions ¶
func FindAllPermissions() ([]models.Permission, error)
func FindAllRoles ¶
func FindAllUsers ¶
func GenerateNewJWT ¶
func GetPermissionById ¶
func GetPermissionById(id int) (permission models.Permission, err error)
func GetRolesWithPermissions ¶
func GetUserByAccount ¶
func UpdatePermission ¶
func UpdatePermission(permission models.Permission) (models.Permission, error)
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.