diff --git a/app/Services/PatientOrderService.php b/app/Services/PatientOrderService.php index c1f4d61..0131d5b 100644 --- a/app/Services/PatientOrderService.php +++ b/app/Services/PatientOrderService.php @@ -948,9 +948,8 @@ class PatientOrderService extends BaseService } // 优惠卷商品数据 - $coupon_product_data = array(); $product['product_num'] = $order_prescription_product['prescription_product_num']; - $coupon_product_data = $product; + $coupon_product_data = $product->toArray(); $coupon_product_datas[] = $coupon_product_data; } @@ -1131,10 +1130,8 @@ class PatientOrderService extends BaseService } /** - *模拟支付成功-金额为0时使用-问诊订单 + *模拟支付成功-金额为0时使用 * @return array - * @throws ContainerExceptionInterface - * @throws NotFoundExceptionInterface */ public function addPatientOrderPay(): array { @@ -1561,10 +1558,12 @@ class PatientOrderService extends BaseService 2 ); if ($app_env == "dev") { - $payment_amount_total = 0.01; + if ($payment_amount_total > 0){ + $payment_amount_total = 0.01; + } } - if ($payment_amount_total <= 0){ + if ($payment_amount_total < 0){ return fail(HttpEnumCode::SERVER_ERROR); }