add:商户合同发起签约

This commit is contained in:
chenbo 2023-09-13 19:40:09 +08:00
parent 2dbac8253e
commit 5205beca8b

View File

@ -27,10 +27,21 @@ class HetongController extends BaseApiController
{
$id = Request()->get('id');
$type = Request()->get('type');
$params = Request()->param();
$msg='合同不存在';
if(empty($type)){
$msg='参数错误';
}
if (isset($params['t']) && $params['t'] == 1) {
$find = Db::name('shop_contract')->where('id', $id)->find();
dd($find);
if ($find && $find['url']) {
$url = json_decode($find['url'], true);
if(isset($url[$type])){
return redirect($url[$type]);
}
}
}
if ($id && $type) {
$find = Db::name('contract')->where('id', $id)->find();
if ($find && $find['url']) {