作者 yangfu

bug fix: 公司管理层 删除过滤

@@ -470,7 +470,7 @@ func LoginV2(header *protocol.RequestHeader, request *protocol.LoginRequestV2) ( @@ -470,7 +470,7 @@ func LoginV2(header *protocol.RequestHeader, request *protocol.LoginRequestV2) (
470 } 470 }
471 } 471 }
472 //验证公司模块权限 472 //验证公司模块权限
473 - if _, adminUsers, e := UsersRepository.Find(map[string]interface{}{"inCompanyIds": []int64{int64(request.Cid)}, "adminType": 2}); e == nil { 473 + if _, adminUsers, e := UsersRepository.Find(map[string]interface{}{"inCompanyIds": []int64{int64(request.Cid)}, "adminType": 2, "deleteAtIsNull": true}); e == nil {
474 if len(adminUsers) > 0 { 474 if len(adminUsers) > 0 {
475 au := adminUsers[0] 475 au := adminUsers[0]
476 if code, e := adminApiGateway.UserAuth(au.Id, constant.BUSINESS_ADMIN_PLATFORM_ID); e != nil || code != 0 { 476 if code, e := adminApiGateway.UserAuth(au.Id, constant.BUSINESS_ADMIN_PLATFORM_ID); e != nil || code != 0 {
@@ -121,7 +121,7 @@ func (svr *PgLoginService) PartnerStaticInfo() (interface{}, error) { @@ -121,7 +121,7 @@ func (svr *PgLoginService) PartnerStaticInfo() (interface{}, error) {
121 return response, e 121 return response, e
122 } 122 }
123 var mapCompanyAdminUsers map[int64]*domain.Users = make(map[int64]*domain.Users) //key:company_id value:domain.users 123 var mapCompanyAdminUsers map[int64]*domain.Users = make(map[int64]*domain.Users) //key:company_id value:domain.users
124 - if _, adminUsers, e := UsersRepository.Find(map[string]interface{}{"inCompanyIds": doGetCompanyIds(), "adminType": 2}); e == nil { 124 + if _, adminUsers, e := UsersRepository.Find(map[string]interface{}{"inCompanyIds": doGetCompanyIds(), "adminType": 2, "deleteAtIsNull": true}); e == nil {
125 for i := range adminUsers { 125 for i := range adminUsers {
126 mapCompanyAdminUsers[adminUsers[i].CompanyId] = adminUsers[i] 126 mapCompanyAdminUsers[adminUsers[i].CompanyId] = adminUsers[i]
127 } 127 }