feat: 下单接口:订单前置相关

master
yin5th 2023-08-16 10:54:33 +08:00
parent 0225c18ba8
commit a7ef54db77
1 changed files with 9 additions and 0 deletions

View File

@ -923,6 +923,15 @@ class OrderLogic extends Logic
$order_data['coupon_list_id'] = $coupon_list_id;
$order_data['create_time'] = time();
// 前置订单
$order_data['is_frontend'] = 0;
if (!empty($post['is_frontend'])) {
$order_data['is_frontend'] = 1;
$order_data['pay_status'] = OrderEnum::PAY_STATUS_PAID;
$order_data['pay_way'] = OrderEnum::PAY_WAY_OFFLINE;
$order_data['pay_time'] = time();
}
$order_create = $Order->create($order_data);
if (false === $order_create) {