mirror of
https://gitee.com/dromara/mayfly-go
synced 2025-11-03 16:00:25 +08:00
20 lines
312 B
Go
20 lines
312 B
Go
|
|
package models
|
||
|
|
|
||
|
|
import (
|
||
|
|
"github.com/astaxie/beego/orm"
|
||
|
|
"mayfly-go/base"
|
||
|
|
)
|
||
|
|
|
||
|
|
type Role struct {
|
||
|
|
base.Model
|
||
|
|
|
||
|
|
Name string `orm:"column(name)" json:"username"`
|
||
|
|
//AccountId int64 `orm:"column(account_id)`
|
||
|
|
|
||
|
|
Account *Account `orm:"rel(fk);index"`
|
||
|
|
}
|
||
|
|
|
||
|
|
func init() {
|
||
|
|
orm.RegisterModelWithPrefix("t_", new(Role))
|
||
|
|
}
|