更新商户入驻
This commit is contained in:
parent
36f3e5fc78
commit
0e1a09f20b
@ -67,28 +67,28 @@ class MerchantIntention extends BaseController
|
||||
'id' => $intention->mer_intention_id
|
||||
]
|
||||
]);
|
||||
// $areaInfo = Db::name('geo_area')->where('area_code', $data['area_id'] ?? '')->find();
|
||||
// $cityId = Db::name('geo_city')->where('city_code', $areaInfo['city_code'] ?? '')->value('city_id', 0);
|
||||
// $streetId = Db::name('geo_street')->where('street_code', $data['street_id'] ?? '')->value('street_id', 0);
|
||||
// $sendData = [
|
||||
// 'company_name' => $data['mer_name'],
|
||||
// 'organization_code' => $data['social_credit_code'] ?? '',
|
||||
// 'master_name' => $data['name'],
|
||||
// 'master_phone' => $data['phone'],
|
||||
// 'city' => $cityId,
|
||||
// 'area' => $areaInfo['area_id'] ?? 0,
|
||||
// 'street' => $streetId,
|
||||
// 'mer_intention_id' => $intention->mer_intention_id
|
||||
// ];
|
||||
// $res = $this->sendMerIntentionApply($sendData);
|
||||
// if (!$res) {
|
||||
// Db::name('merchant_intention')->where('mer_intention_id', $intention->mer_intention_id)->delete();
|
||||
// throw new ValidateException('申请商户入驻任务失败,请联系平台');
|
||||
// }
|
||||
$cdata['status'] = 1;
|
||||
$cdata['create_mer'] = -1;
|
||||
$cdata['fail_msg'] ='自动审核通过';
|
||||
$this->repository->updateStatus($intention->mer_intention_id, $cdata);
|
||||
$areaInfo = Db::name('geo_area')->where('area_code', $data['area_id'] ?? '')->find();
|
||||
$cityId = Db::name('geo_city')->where('city_code', $areaInfo['city_code'] ?? '')->value('city_id', 0);
|
||||
$streetId = Db::name('geo_street')->where('street_code', $data['street_id'] ?? '')->value('street_id', 0);
|
||||
$sendData = [
|
||||
'company_name' => $data['mer_name'],
|
||||
'organization_code' => $data['social_credit_code'] ?? '',
|
||||
'master_name' => $data['name'],
|
||||
'master_phone' => $data['phone'],
|
||||
'city' => $cityId,
|
||||
'area' => $areaInfo['area_id'] ?? 0,
|
||||
'street' => $streetId,
|
||||
'mer_intention_id' => $intention->mer_intention_id
|
||||
];
|
||||
$res = $this->sendMerIntentionApply($sendData);
|
||||
if (!$res) {
|
||||
Db::name('merchant_intention')->where('mer_intention_id', $intention->mer_intention_id)->delete();
|
||||
throw new ValidateException('申请商户入驻任务失败,请联系平台');
|
||||
}
|
||||
// $cdata['status'] = 1;
|
||||
// $cdata['create_mer'] = -1;
|
||||
// $cdata['fail_msg'] ='自动审核通过';
|
||||
// $this->repository->updateStatus($intention->mer_intention_id, $cdata);
|
||||
return app('json')->success('提交成功');
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user