修改了admin里面的发起合同接口

This commit is contained in:
unknown 2023-08-23 15:25:55 +08:00
parent cf08afdb88
commit 73e2a61e01
3 changed files with 8 additions and 5 deletions

View File

@ -142,8 +142,8 @@ class CompanyController extends BaseAdminController
$params['party_b'] = $params['id'];
unset($params['id']);
$result = ContractLogic::initiate_contract($params);
if ($result == true) {
return $this->success('发起成功,等待平台风控部上传合同', [], 1, 1);
if ($result['code']==1) {
return $this->success($result['msg'], $result['data']);
}
return $this->fail(ContractLogic::getError());
}

View File

@ -203,7 +203,12 @@ class ContractLogic extends BaseLogic
$model->check_status = 1;
$model->update_time = time();
$model->setAttrs($data);
return $model->save($data);
$res = $model->save($data);
if($res){
return ['code'=>1,'msg'=>'发起成功,等待平台风控部上传合同','data'=>['id'=>$model->id]];
}else{
return ['code'=>0,'msg'=>'发起失败,请稍后重试',];
}
}
// /**发送合同 */

2
runtime/.gitignore vendored
View File

@ -1,2 +0,0 @@
*
!.gitignore