feat : refund

This commit is contained in:
2025-03-27 10:58:00 +08:00
parent 7f4d6ca0d0
commit c4bc83f9e2
5 changed files with 16 additions and 12 deletions

View File

@@ -127,6 +127,7 @@ abstract class BaseRefundOrderService
if ($orderGoodList->isEmpty()) throw new Exception('该订单没有这些商品信息:'.json_encode(['order_id' => $this->orderId,'order_type' => $this->type,'goods_list' => $this->orderGoodIds]));
$this->orderGoodList = $orderGoodList->toArray();
unset($orderGoodList);
//todo 优惠券信息没有看
foreach ($this->orderGoodList as $orderGood) {
if (!in_array($orderGood['status'],OrderCode::CAN_REFUND_STATUS)) throw new Exception('商品状态不能退款:'.json_encode(['order_info' => $this->orderInfo->toArray(),'order_good' => $orderGood,'goods_list' => $this->orderGoodIds]));