...
|
...
|
@@ -136,13 +136,13 @@ func GetUserNameByIds(ids []int64) ([]User, error) { |
|
|
|
|
|
func ExistUserByPhone(phone string) bool {
|
|
|
o := orm.NewOrm()
|
|
|
ok := o.QueryTable(&User{}).Filter("phone", phone).Exist()
|
|
|
ok := o.QueryTable(&User{}).Filter("phone", phone).Filter("delete_at", 0).Exist()
|
|
|
return ok
|
|
|
}
|
|
|
|
|
|
func GetUserByUCenter(ucenterId int64) (v *User, err error) {
|
|
|
v = &User{}
|
|
|
o := orm.NewOrm()
|
|
|
err = o.QueryTable(&User{}).Filter("user_center_id", ucenterId).One(v)
|
|
|
err = o.QueryTable(&User{}).Filter("user_center_id", ucenterId).Filter("delete_at", 0).One(v)
|
|
|
return
|
|
|
} |
...
|
...
|
|