|
@@ -886,6 +886,7 @@ func (m *Front) Sess(ostr string) error {
|
|
|
ok = true
|
|
|
} else {
|
|
|
var identity *pb.Identity
|
|
|
+
|
|
|
if str[1] == "userId" || str[1] == "entUserId" || str[1] == "positionId" {
|
|
|
if str[1] == "userId" {
|
|
|
identity = config.Middleground.UserCenter.IdentityByUserId(util.Int64All(userFlag))
|
|
@@ -905,7 +906,11 @@ func (m *Front) Sess(ostr string) error {
|
|
|
if m.GetSession("positionId") != nil {
|
|
|
hasIdentity = true
|
|
|
}
|
|
|
- ok, _, _ = FindUserAndCreateSess(userFlag, m.Session(), "wx", false, !hasIdentity)
|
|
|
+ if userFlag == "" && m.GetSession("positionId") != nil {
|
|
|
+ ok = true
|
|
|
+ } else if userFlag != "" {
|
|
|
+ ok, _, _ = FindUserAndCreateSess(userFlag, m.Session(), "wx", false, !hasIdentity)
|
|
|
+ }
|
|
|
}
|
|
|
if !hasIdentity {
|
|
|
identity = config.Middleground.UserCenter.IdentityByUserId(util.Int64All(m.GetSession("base_user_id")))
|