This commit is contained in:
邹宗楠
2022-05-18 15:27:30 +08:00
parent 837168d0fb
commit a1775edf9c
2 changed files with 6 additions and 2 deletions

View File

@@ -159,7 +159,8 @@ func init() {
func RegisterUserWithMobile(ctx *jxcontext.Context, user *model.User, mobileVerifyCode string, inAuthInfo, manTokenInfo *auth2.AuthInfo) (outAuthInfo *auth2.AuthInfo, err error) { func RegisterUserWithMobile(ctx *jxcontext.Context, user *model.User, mobileVerifyCode string, inAuthInfo, manTokenInfo *auth2.AuthInfo) (outAuthInfo *auth2.AuthInfo, err error) {
var mobileAuth *auth2.AuthInfo var mobileAuth *auth2.AuthInfo
fakeMobile := false fakeMobile := false
user.Type = model.UserTypeConsumer | model.UserTypeStoreBoss // 先不区分商户与消息者 //user.Type = model.UserTypeConsumer | model.UserTypeStoreBoss // 先不区分商户与消息者
user.Type = model.UserTypeConsumer // 先不区分商户与消息者
createName := ctx.GetRealRemoteIP() createName := ctx.GetRealRemoteIP()
authType := auth2.AuthTypeMobile authType := auth2.AuthTypeMobile
if manTokenInfo != nil && mobileVerifyCode == "" { if manTokenInfo != nil && mobileVerifyCode == "" {
@@ -210,7 +211,7 @@ func RegisterUserWithMobile(ctx *jxcontext.Context, user *model.User, mobileVeri
user.Type |= model.UserTypeOperator user.Type |= model.UserTypeOperator
user.Type |= model.UserTypeRole user.Type |= model.UserTypeRole
} else if user.Mobile != nil { } else if user.Mobile != nil {
user.Type |= model.UserTypeStoreBoss //user.Type |= model.UserTypeStoreBoss
} }
createName += "," + inAuthInfo.GetAuthID() createName += "," + inAuthInfo.GetAuthID()
authType = inAuthInfo.GetAuthType() authType = inAuthInfo.GetAuthType()

View File

@@ -37,4 +37,7 @@ func TestCancelWaybill(t *testing.T) {
} }
func Test11(t *testing.T) { func Test11(t *testing.T) {
type1 := 3
type1 |=2
fmt.Println(type1)
} }