From 7030c900d93498b71986bf0f6a75371fa0413baa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=82=B9=E6=99=AF=E7=AB=8B?= Date: Wed, 24 Mar 2021 17:41:47 +0800 Subject: [PATCH] Update RebateService.php --- app/data/service/RebateService.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app/data/service/RebateService.php b/app/data/service/RebateService.php index 9adda4292..f0a0024e3 100644 --- a/app/data/service/RebateService.php +++ b/app/data/service/RebateService.php @@ -99,6 +99,9 @@ class RebateService extends Service $map = ['order_no' => $orderNo, 'payment_status' => 1]; $this->order = $this->app->db->name('ShopOrder')->where($map)->find(); if (empty($this->order)) throw new Exception('订单不存在'); + if ($this->order['payment_type'] === 'balance') { + throw new Exception('余额支付不反利'); + } // 检查订单参与返利 if ($this->order['amount_total'] <= 0) throw new Exception('订单金额为零'); if ($this->order['rebate_amount'] <= 0) throw new Exception('订单返利为零');