mc-client-updater-server/pkg/dao/entity/token.go

12 lines
366 B
Go
Raw Normal View History

2022-10-04 00:36:01 +08:00
package entity
import "gorm.io/gorm"
// Token Token是授权给用户的给予用户登录权限
type Token struct {
gorm.Model `json:"model"`
Token string `gorm:"unique;not null" json:"token,omitempty"`
GrantTo string `gorm:"index;not null;default:''" json:"grant_to,omitempty"`
TTL int `gorm:"not null;default:0" json:"ttl,omitempty"`
}