|
@@ -99,9 +99,9 @@ class Supplier extends Base
|
|
|
$res->updater=$param['uname'];
|
|
|
$res->updaterid=$param['uid'];
|
|
|
$resup=Headquarters::createInfo($res,3);
|
|
|
- if($resup)throw new \Exception('供应商信息失败');
|
|
|
+ if(!$resup)throw new \Exception('供应商信息失败');
|
|
|
$acc= AccountCompany::create(["account_id"=>$param['uid'],"companyCode"=>$bussinesCode,"companyName"=>$data['company'],'company_type' => 2]);
|
|
|
- if($acc)throw new \Exception('业务公司账户关联失败');
|
|
|
+ if($acc->isEmpty())throw new \Exception('业务公司账户关联失败');
|
|
|
return $res->save();
|
|
|
}
|
|
|
|