Merge pull request '新增商户合同管理模块接口' (#33) from zhangwei into dev
Reviewed-on: #33
This commit is contained in:
commit
75c18b93dd
|
@ -17,4 +17,88 @@
|
|||
}
|
||||
return json($result);
|
||||
}
|
||||
|
||||
//商户合同详情
|
||||
public function detail(): Json
|
||||
{
|
||||
$params = $this->request->get(['id']);
|
||||
if(empty($params['id'])){
|
||||
return $this->fail('缺少必要参数');
|
||||
}
|
||||
$result = curl_post(env('project.worker_domain').'/middleapi/ShopContract/detail',$params,$this->reqHeader);
|
||||
if($result['code'] == 0){
|
||||
return $this->fail($result['msg']);
|
||||
}
|
||||
return json($result);
|
||||
}
|
||||
|
||||
//商户合同审核
|
||||
public function check(): Json
|
||||
{
|
||||
$params = $this->request->post(['id','file']);
|
||||
if(empty($params['id']) || empty($params['file'])){
|
||||
return $this->fail('缺少必要参数');
|
||||
}
|
||||
$result = curl_post(env('project.worker_domain').'/middleapi/ShopContract/check',$params,$this->reqHeader);
|
||||
if($result['code'] == 0){
|
||||
return $this->fail($result['msg']);
|
||||
}
|
||||
return json($result);
|
||||
}
|
||||
|
||||
//商户合同备注
|
||||
public function note(): Json
|
||||
{
|
||||
$params = $this->request->post(['id','notes']);
|
||||
if(empty($params['id']) || empty($params['notes'])){
|
||||
return $this->fail('缺少必要参数');
|
||||
}
|
||||
$result = curl_post(env('project.worker_domain').'/middleapi/ShopContract/note',$params,$this->reqHeader);
|
||||
if($result['code'] == 0){
|
||||
return $this->fail($result['msg']);
|
||||
}
|
||||
return json($result);
|
||||
}
|
||||
|
||||
//发送商户合同
|
||||
public function draftContract(): Json
|
||||
{
|
||||
$params = $this->request->post(['id']);
|
||||
if(empty($params['id'])){
|
||||
return $this->fail('缺少必要参数');
|
||||
}
|
||||
$result = curl_post(env('project.worker_domain').'/middleapi/ShopContract/draftContract',$params,$this->reqHeader);
|
||||
if($result['code'] == 0){
|
||||
return $this->fail($result['msg']);
|
||||
}
|
||||
return json($result);
|
||||
}
|
||||
|
||||
//发送短信
|
||||
public function sendSms(): Json
|
||||
{
|
||||
$params = $this->request->post(['id']);
|
||||
if(empty($params['id'])){
|
||||
return $this->fail('缺少必要参数');
|
||||
}
|
||||
$result = curl_post(env('project.worker_domain').'/middleapi/ShopContract/sendSms',$params,$this->reqHeader);
|
||||
if($result['code'] == 0){
|
||||
return $this->fail($result['msg']);
|
||||
}
|
||||
return json($result);
|
||||
}
|
||||
|
||||
//下载证据包
|
||||
public function evidence(): Json
|
||||
{
|
||||
$params = $this->request->get(['id']);
|
||||
if(empty($params['id'])){
|
||||
return $this->fail('缺少必要参数');
|
||||
}
|
||||
$result = curl_post(env('project.worker_domain').'/middleapi/ShopContract/evidence',$params,$this->reqHeader);
|
||||
if($result['code'] == 0){
|
||||
return $this->fail($result['msg']);
|
||||
}
|
||||
return json($result);
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue