...
|
...
|
@@ -601,7 +601,6 @@ class Order extends Api |
|
|
$model = new \app\api\model\Order();
|
|
|
$order = $model::get($order_id);
|
|
|
if (!$order) $this->error('订单不存在');
|
|
|
// $third = Third::get(['user_id'=>$this->auth->id]);
|
|
|
$third = Third::alias('a')
|
|
|
->join('user b','b.id = a.user_id')
|
|
|
->where('a.user_id',$order['user_id'])
|
...
|
...
|
@@ -629,16 +628,14 @@ class Order extends Api |
|
|
'type' => 'wechat',
|
|
|
'orderid' => $order['order_no'],
|
|
|
'title' => '订单号-'.$order['order_no'],
|
|
|
// 'amount' => $order['pay_price'],
|
|
|
'amount' => 0.01,
|
|
|
'amount' => $order['pay_price'],
|
|
|
// 'amount' => 0.01,
|
|
|
'method' => 'miniapp',
|
|
|
'openid' => $openid,
|
|
|
'notifyurl' => $this->request->domain().'/api/notify/orderNotify/type/wechat',
|
|
|
'returnurl' => '',
|
|
|
];
|
|
|
$result = Service::submitOrder($params);
|
|
|
// $order->pay_user_id = $this->auth->id;
|
|
|
// $order->isUpdate()->save();
|
|
|
$this->success('支付信息',$result);
|
|
|
}
|
|
|
|
...
|
...
|
@@ -759,10 +756,10 @@ class Order extends Api |
|
|
$wechat = Pay::wechat($config);
|
|
|
$refund_no = 'LQ-'.time().mt_rand(10000,99999);
|
|
|
$param = [
|
|
|
// 'total_fee' => $order['pay_price'],
|
|
|
// 'refund_fee' => $order['pay_price'],
|
|
|
'total_fee' => 1,
|
|
|
'refund_fee' => 1,
|
|
|
'total_fee' => $order['pay_price'],
|
|
|
'refund_fee' => $order['pay_price'],
|
|
|
// 'total_fee' => 1,
|
|
|
// 'refund_fee' => 1,
|
|
|
'out_trade_no' => $order['order_no'],
|
|
|
'out_refund_no' => $refund_no
|
|
|
];
|
...
|
...
|
|