diff --git a/application/common/Model/Member.php b/application/common/Model/Member.php index 8e3e682..e3547c6 100755 --- a/application/common/Model/Member.php +++ b/application/common/Model/Member.php @@ -30,13 +30,13 @@ class Member extends CommonModel $configModel = new SystemConfig(); $config = $configModel->info(); if ($config['single_mode'] && $config['single_org_code']) { - $list = MemberAccount::where(['member_code' => $member['code'], 'organization_code' => $config['single_org_code']])->order('id asc')->select()->toArray(); + $list = MemberAccount::where(['member_code' => $member['code'], 'organization_code' => $config['single_org_code']])->where('authorize','<>','')->order('id asc')->select()->toArray(); if (!$list) { MemberAccount::inviteMember($member['code'], $config['single_org_code']); - $list = MemberAccount::where(['member_code' => $member['code'], 'organization_code' => $config['single_org_code']])->order('id asc')->select()->toArray(); + $list = MemberAccount::where(['member_code' => $member['code'], 'organization_code' => $config['single_org_code']])->where('authorize','<>','')->order('id asc')->select()->toArray(); } } else { - $list = MemberAccount::where(['member_code' => $member['code']])->order('id asc')->select()->toArray(); + $list = MemberAccount::where(['member_code' => $member['code']])->where('authorize','<>','')->order('id asc')->select()->toArray(); } $organizationList = self::getOrgList($member['code'], true); @@ -95,7 +95,7 @@ class Member extends CommonModel return $organizationList; } } - $list = MemberAccount::where(['member_code' => $memberCode])->where('authorize','<>','')->order('id asc')->select()->toArray(); + $list = MemberAccount::where(['member_code' => $memberCode])->order('id asc')->select()->toArray(); if ($list) { $configModel = new SystemConfig(); $config = $configModel->info();