Merge pull request 'update' (#118) from zhangwei into dev
Reviewed-on: #118
This commit is contained in:
commit
074cad1ca4
@ -279,13 +279,14 @@ class VehicleContractController extends BaseAdminController
|
||||
if($data['type'] == 1){
|
||||
if(empty($v['id'])){
|
||||
$cars[$k]['type'] = 1;
|
||||
}else{
|
||||
$rentInfo = VehicleRent::where('car_id',$v['id'])->findOrEmpty();
|
||||
if($rentInfo->isEmpty()){
|
||||
$cars[$k]['type'] = 0;
|
||||
}else{
|
||||
$cars[$k]['type'] = $rentInfo['type'];
|
||||
}
|
||||
}
|
||||
$rentInfo = VehicleRent::where('car_id',$v['id'])->findOrEmpty();
|
||||
if($rentInfo->isEmpty()){
|
||||
$cars[$k]['type'] = 0;
|
||||
}else{
|
||||
$cars[$k]['type'] = $rentInfo['type'];
|
||||
}
|
||||
}
|
||||
if($data['type'] == 2){
|
||||
$rentInfo = VehicleRent::where('car_id',$v['id'])->findOrEmpty();
|
||||
|
Loading…
x
Reference in New Issue
Block a user