...
|
...
|
@@ -227,6 +227,11 @@ class OrderController extends HomeBaseController |
|
|
Db::name('order_info')->update(['id' => $oid, 'payment' => $payment]);
|
|
|
if ($payment == 0) {
|
|
|
$model = new OrderModel;
|
|
|
$balance = Db::name('user')->where(['id'=>session('user.id')])->value('balance');
|
|
|
if($balance < $order_amount) {
|
|
|
echo json_encode(['msg' => '您的余额不足', 'code' => 40000]);
|
|
|
exit();
|
|
|
}
|
|
|
if ($model->orderCallBack($oid, $order_amount)) {
|
|
|
//如果是有定金订单,则需要更新order_log
|
|
|
if ($info['order_type'] == 1) {
|
...
|
...
|
|