Merge branch 'feat_agree' into dev

This commit is contained in:
yaooo 2023-09-23 14:37:05 +08:00
commit 97bfb2a9aa

View File

@ -68,15 +68,13 @@ class Auth extends BaseController
$param = [
"status" => 0,
"is_del" => 0,
"mer_id" => 5,
"type" => 10,
"meal_id" => 10,
"mer_id" => 1,
"pay_type" => 1,
"attach" => "meal",
"order_info" => '{"type_id":10,"is_margin":1,"margin":"0.01"}',
"pay_price" => "0.01",
"attach" => "margin",
"order_info" => '{"is_margin":1,"margin":"0.01"}',
"pay_price" => 0.01,
"order_sn" => "bzj" . date('YmdHis') . uniqid(),
"body" => uniqid(),
"body" =>'哈哈哈',
];
$payType = 'weixinApp';
$service = new PayService($payType, $param);
@ -278,7 +276,7 @@ class Auth extends BaseController
public function doMargin()
{
$user = $this->request->userInfo();
$merchant = Db::name('merchant')->where('uid', $user['uid'])->where('status', 1)->find();
$merchant = Db::name('merchant')->where('uid', $user['uid'])->where('status', 1)->where('is_margin', 1)->find();
if (!$merchant) {
return app('json')->fail('用户店铺异常');
}
@ -288,7 +286,7 @@ class Auth extends BaseController
"is_del" => 0,
"mer_id" => $merchant['mer_id'],
"pay_type" => 1,
"attach" => "meal",
"attach" => "margin",
"order_info" => '{"is_margin":1,"margin":"' . $merchant['margin'] . '"}',
"pay_price" => $merchant['margin'],
"order_sn" => "bzj" . date('YmdHis') . uniqid(),