|
|
|
@ -33,12 +33,21 @@ class Merchant extends Controller |
|
|
|
|
public function userinfo(): Json |
|
|
|
|
{ |
|
|
|
|
$model = new StoreUserModel; |
|
|
|
|
$list = $model->getList($this->request->param()); |
|
|
|
|
print_r($list);die; |
|
|
|
|
$list = $model->getList($this->request->param())->toArray(); |
|
|
|
|
$res = []; |
|
|
|
|
foreach ($list['data'] as $l) { |
|
|
|
|
if (!empty($l['user_name'])) { |
|
|
|
|
array_push($res, $l['user_name']); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
$model2 = new MerchantModel; |
|
|
|
|
$list = $model2->getList($this->request->param()); |
|
|
|
|
return $this->renderSuccess(['storeInfo' => $model2]); |
|
|
|
|
$list2 = $model2->getList($this->request->param())->toArray(); |
|
|
|
|
$userIds = array_column($list2['data'], "user_name"); |
|
|
|
|
|
|
|
|
|
$res = array_diff($res, $userIds); |
|
|
|
|
|
|
|
|
|
return $this->renderSuccess(compact('res')); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|