Some checks failed
CI / init (push) Has been cancelled
CI / Frontend node 18.16.0 (push) Has been cancelled
CI / Backend go (1.22) (push) Has been cancelled
CI / devops-test (1.22, 18.16.0) (push) Has been cancelled
CI / release-pr (push) Has been cancelled
CI / release-please (push) Has been cancelled
CI / devops-prod (1.22, 18.x) (push) Has been cancelled
CI / docker (push) Has been cancelled
18 lines
633 B
Go
18 lines
633 B
Go
package system
|
|
|
|
import (
|
|
"github.com/flipped-aurora/gin-vue-admin/server/global"
|
|
"time"
|
|
)
|
|
|
|
type SysApiToken struct {
|
|
global.GVA_MODEL
|
|
UserID uint `json:"userId" gorm:"comment:用户ID"`
|
|
User SysUser `json:"user" gorm:"foreignKey:UserID;"`
|
|
AuthorityID uint `json:"authorityId" gorm:"comment:角色ID"`
|
|
Token string `json:"token" gorm:"type:text;comment:Token"`
|
|
Status bool `json:"status" gorm:"default:true;comment:状态"` // true有效 false无效
|
|
ExpiresAt time.Time `json:"expiresAt" gorm:"comment:过期时间"`
|
|
Remark string `json:"remark" gorm:"comment:备注"`
|
|
}
|