feat: 完善合同上传
parent
95fe7bd981
commit
4346bc718c
|
@ -27,10 +27,25 @@ class Order extends Api
|
||||||
return JsonServer::success('下单成功!', ['path' => $path, 'domain' => request()->domain()]);
|
return JsonServer::success('下单成功!', ['path' => $path, 'domain' => request()->domain()]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 合同上传
|
||||||
public function contractUpload()
|
public function contractUpload()
|
||||||
{
|
{
|
||||||
|
$orderId = input('order_id/d');
|
||||||
|
$path = input('path/s');
|
||||||
|
|
||||||
return JsonServer::success('上传成功!');
|
if (empty($orderId) || empty($path)) {
|
||||||
|
return JsonServer::error('参数错误!');
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!$order = \app\common\model\order\Order::where('id', $orderId)->find()) {
|
||||||
|
return JsonServer::error('订单不存在!');
|
||||||
|
}
|
||||||
|
|
||||||
|
$order->save([
|
||||||
|
'frontend_info' => $path
|
||||||
|
]);
|
||||||
|
|
||||||
|
return JsonServer::success('操作成功!');
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue