曾超新 5 years ago
parent 111e8be031
commit 132e157e9e
  1. 4
      frontend/controllers/CarController.php

@ -553,6 +553,7 @@ class CarController extends BaseController
]); ]);
if($res->getStatusCode() == 200) { if($res->getStatusCode() == 200) {
$obj = json_decode($res->getBody()); $obj = json_decode($res->getBody());
if($obj->code == 200) {
if($obj->data && $obj->data->UserInfo && $obj->data->UserInfo->CarUsedType != '') { if($obj->data && $obj->data->UserInfo && $obj->data->UserInfo->CarUsedType != '') {
$car_user_info = CarUseT::find()->where(['name'=>$obj->data->UserInfo->CarUsedType])->one(); $car_user_info = CarUseT::find()->where(['name'=>$obj->data->UserInfo->CarUsedType])->one();
if($car_user_info) { if($car_user_info) {
@ -560,6 +561,9 @@ class CarController extends BaseController
} }
} }
return MyLib::ok3($obj->data); return MyLib::ok3($obj->data);
} else {
return MyLib::error3($obj->msg);
}
} }
return MyLib::error3($res->getBody()); return MyLib::error3($res->getBody());
} }

Loading…
Cancel
Save