20 lines
404 B
Go
20 lines
404 B
Go
|
package gmodel
|
||
|
|
||
|
import (
|
||
|
"gorm.io/gorm"
|
||
|
)
|
||
|
|
||
|
// ldap_user_roles 用户角色表
|
||
|
type LdapUserRoles struct {
|
||
|
RoleId *int64 `gorm:"default:0;" json:"role_id"` //
|
||
|
UserId *int64 `gorm:"default:0;" json:"user_id"` //
|
||
|
}
|
||
|
type LdapUserRolesModel struct {
|
||
|
db *gorm.DB
|
||
|
name string
|
||
|
}
|
||
|
|
||
|
func NewLdapUserRolesModel(db *gorm.DB) *LdapUserRolesModel {
|
||
|
return &LdapUserRolesModel{db: db, name: "ldap_user_roles"}
|
||
|
}
|