Commit 4e61fb66 by jack

更新

parent 0131e863
...@@ -298,7 +298,7 @@ public function pay(Request $request) ...@@ -298,7 +298,7 @@ public function pay(Request $request)
try { try {
$res = ''; $res = '';
$order = OrderInfoModel::find($order_id); $order = OrderInfoModel::find($order_id);
if ($order->pay_cs > 0) { if ($order->pay_cs > 0 && $order->pay_cs < 20) {
$order_record = $order->order_record ?? $order->order_sn; $order_record = $order->order_record ?? $order->order_sn;
$order->order_sn = $this->getOrderSn(); $order->order_sn = $this->getOrderSn();
$order->order_record = $order_record . "|" . $order->order_sn; $order->order_record = $order_record . "|" . $order->order_sn;
...@@ -306,6 +306,7 @@ public function pay(Request $request) ...@@ -306,6 +306,7 @@ public function pay(Request $request)
} }
$orderGoodsObj = OrderGoods::where("order_id", $order_id)->first(); $orderGoodsObj = OrderGoods::where("order_id", $order_id)->first();
$order_title = $orderGoodsObj ? $orderGoodsObj->goods_name : ''; $order_title = $orderGoodsObj ? $orderGoodsObj->goods_name : '';
Log::add('--支付订单号ID--', ['order_id' => $order_id, 'order_sn' => $order->order_sn]);
$res = (new Adapay())->pay($order_title, $order->order_sn, $order->order_amount, $openid); $res = (new Adapay())->pay($order_title, $order->order_sn, $order->order_amount, $openid);
$order->pay_cs += 1; $order->pay_cs += 1;
$order->save(); $order->save();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment