31 lines
816 B
Go
31 lines
816 B
Go
package model
|
|
|
|
const (
|
|
AuthBindStatusNormal = 1
|
|
AuthBindStatusDisabled = 2
|
|
)
|
|
|
|
type AuthBind struct {
|
|
ModelIDCULD
|
|
|
|
UserID string `orm:"size(48);column(user_id)" json:"userID"`
|
|
Type string `orm:"size(16)" json:"type"`
|
|
Status int8 `json:"status"`
|
|
|
|
AuthID string `orm:"size(48);column(auth_id);index" json:"authID"`
|
|
AuthID2 string `orm:"size(48);column(auth_id2);index" json:"authID2"`
|
|
AuthSecret string `orm:"size(48)" json:"authSecret"`
|
|
AuthSecret2 string `orm:"size(48)" json:"authSecret2"`
|
|
Remark string `orm:"size(255)" json:"remark"`
|
|
DetailData string `orm:"type(text)" json:"-"`
|
|
|
|
UserData interface{} `orm:"-" json:"-"`
|
|
}
|
|
|
|
func (*AuthBind) TableUnique() [][]string {
|
|
return [][]string{
|
|
[]string{"UserID", "Type", "DeletedAt"},
|
|
[]string{"AuthID", "Type", "DeletedAt"},
|
|
}
|
|
}
|