11
This commit is contained in:
parent
acf5c32434
commit
d22e298f59
@ -150,6 +150,7 @@ class IndexController extends BaseApiController
|
|||||||
$party_b_company = Company::field('user_id,master_name,master_phone')->where('id',$contract['company_b_id'])->find();
|
$party_b_company = Company::field('user_id,master_name,master_phone')->where('id',$contract['company_b_id'])->find();
|
||||||
//通知物流系统添加车辆使用人
|
//通知物流系统添加车辆使用人
|
||||||
curl_post('http://logistics.lihaink.cn/api/createRentCarUser',[],[
|
curl_post('http://logistics.lihaink.cn/api/createRentCarUser',[],[
|
||||||
|
'company_id' => $contract['company_b_id'],
|
||||||
'car_id' => $car[0]['id'],
|
'car_id' => $car[0]['id'],
|
||||||
'user_id' => $party_b_company['user_id'],
|
'user_id' => $party_b_company['user_id'],
|
||||||
'user_name' => $party_b_company['master_name'],
|
'user_name' => $party_b_company['master_name'],
|
||||||
@ -157,6 +158,20 @@ class IndexController extends BaseApiController
|
|||||||
]);
|
]);
|
||||||
}else{
|
}else{
|
||||||
//自有车辆
|
//自有车辆
|
||||||
|
$company_b = Company::where('id',$contract['company_b_id'])->find();
|
||||||
|
$res = curl_post('http://logistics.lihaink.cn/api/addSelfCar',[],[
|
||||||
|
'license' => $car[0]['license'],
|
||||||
|
'company_id' => $contract['company_a_id'],
|
||||||
|
'company_name' => $contract['company_a_name'],
|
||||||
|
'company_user' => $contract['company_a_user'],
|
||||||
|
'company_phone' => $contract['company_a_phone'],
|
||||||
|
'user_id' => $company_b['user_id'],
|
||||||
|
'user_name' => $contract['company_b_user'],
|
||||||
|
'user_phone' => $contract['company_b_phone']
|
||||||
|
]);
|
||||||
|
if($res && $res['code'] == 1){
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return json(['success' => true, 'msg' => '成功']);
|
return json(['success' => true, 'msg' => '成功']);
|
||||||
|
@ -121,7 +121,7 @@ class VehicleController extends BaseApiController
|
|||||||
}
|
}
|
||||||
//判断是否申请过
|
//判断是否申请过
|
||||||
$apply = VehicleVillageApply::where('village_company_id',$this->userInfo['company_id'])->where('status','<>',2)->find();
|
$apply = VehicleVillageApply::where('village_company_id',$this->userInfo['company_id'])->where('status','<>',2)->find();
|
||||||
if(!$apply->isEmpty()){
|
if($apply){
|
||||||
return $this->fail('已申请了,请勿重复申请');
|
return $this->fail('已申请了,请勿重复申请');
|
||||||
}
|
}
|
||||||
//设置数据
|
//设置数据
|
||||||
|
Loading…
x
Reference in New Issue
Block a user