diff --git a/business/model/user.go b/business/model/user.go index d36f004c4..e806aa4c1 100644 --- a/business/model/user.go +++ b/business/model/user.go @@ -61,12 +61,17 @@ type User struct { UnionId string `json:"union_id" db:"union_id"` // 微信用户Id } -func (*User) TableUnique() [][]string { +func (user *User) TableUnique() [][]string { return [][]string{ - []string{"UserID"}, []string{"Mobile", "DeletedAt"}, - []string{"Email", "DeletedAt"}, - // []string{"IDCardNo", "DeletedAt"}, + } +} + +func (user *User) TableIndex() [][]string { + return [][]string{ + []string{"Mobile"}, + []string{"OpenId"}, + []string{"UserID"}, } }