订单支付为0时处理

This commit is contained in:
liu 2024-06-13 17:05:43 +08:00
parent 7c35d4e504
commit f2d777d5e3
2 changed files with 9 additions and 1 deletions

View File

@ -185,6 +185,9 @@ class OrderController extends BaseApiController
$user=User::where('id',$this->userId)->find();
$order = OrderLogic::createOrder($cartId, $addressId, $user, $params);
if($order['pay_price'] <= 0){
$pay_type = 3;
}
if ($order != false) {
switch ($pay_type) {
case PayEnum::BALANCE_PAY:

View File

@ -28,12 +28,16 @@ class OrderEnum
const SUPPLIER_ORDER_OBTAINS = 6;
const PLATFORM_ORDER_PAY = 7;
const SYSTEM_SET = 8;
const CASHIER_ORDER_PAY = 9;
const CASHIER_ORDER_PAY = 9;//微信条码
const CASHIER_CASH_ORDER_PAY = 10;
const ORDER_MARGIN = 11;
const ORDER_COMMITION = 12;
const CASHIER_ORDER_ALI_PAY = 13;//支付宝条码
const CASHIER_FACE_PAY = 17;//现金收银
/**
* 收入支出类型
@ -87,6 +91,7 @@ class OrderEnum
/**小程序下单**/
const ONLINE = [1,2];
const OFFLINE = [3];
/**
* 账户类型
* @USER 用户