From e1b6d608feb861b2d2df9d8c5e2ea775d177a8a5 Mon Sep 17 00:00:00 2001 From: evoxwht <442384644@qq.com> Date: Wed, 29 Mar 2023 17:23:46 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E5=90=8E=E5=8F=B0=E6=8B=BC=E5=9B=A2?= =?UTF-8?q?=E6=8B=BC=E5=9B=A2=E8=AE=A2=E5=8D=95=E8=AF=A6=E6=83=85=E9=87=91?= =?UTF-8?q?=E9=A2=9D=E5=B1=95=E7=A4=BA=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../admin/src/pages/marketing/storeCombination/combinaList.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/template/admin/src/pages/marketing/storeCombination/combinaList.vue b/template/admin/src/pages/marketing/storeCombination/combinaList.vue index ba22b23fd..c72384b70 100644 --- a/template/admin/src/pages/marketing/storeCombination/combinaList.vue +++ b/template/admin/src/pages/marketing/storeCombination/combinaList.vue @@ -249,7 +249,7 @@ export default { }, { title: '金额', - key: 'price', + key: 'total_price', }, { title: '订单状态', From 397ec0c48fc006d9f5b98f0be1881e3b902292a4 Mon Sep 17 00:00:00 2001 From: evoxwht <442384644@qq.com> Date: Wed, 29 Mar 2023 17:24:17 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E4=BC=98=E5=8C=96=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../app/api/controller/v1/admin/StoreOrderController.php | 2 +- crmeb/app/dao/activity/combination/StorePinkDao.php | 1 + crmeb/app/dao/order/StoreOrderDao.php | 9 ++++++--- .../services/activity/combination/StorePinkServices.php | 8 +++++++- template/uni-app/pages/goods/goods_return/index.vue | 2 +- 5 files changed, 16 insertions(+), 6 deletions(-) diff --git a/crmeb/app/api/controller/v1/admin/StoreOrderController.php b/crmeb/app/api/controller/v1/admin/StoreOrderController.php index 2bdcd8f91..f966fd6c4 100644 --- a/crmeb/app/api/controller/v1/admin/StoreOrderController.php +++ b/crmeb/app/api/controller/v1/admin/StoreOrderController.php @@ -113,7 +113,7 @@ class StoreOrderController public function detail(Request $request, StoreOrderServices $services, UserServices $userServices, $orderId) { $economizeServices = app()->make(StoreOrderEconomizeServices::class); - $orderData = $services->getUserOrderByKey($economizeServices, $orderId, (int)$request->uid()); + $orderData = $services->getUserOrderByKey($economizeServices, $orderId, 0); $orderData['nickname'] = $userServices->value(['uid' => $orderData['uid']], 'nickname'); return app('json')->success($orderData); } diff --git a/crmeb/app/dao/activity/combination/StorePinkDao.php b/crmeb/app/dao/activity/combination/StorePinkDao.php index d6b18ffca..042272623 100644 --- a/crmeb/app/dao/activity/combination/StorePinkDao.php +++ b/crmeb/app/dao/activity/combination/StorePinkDao.php @@ -138,6 +138,7 @@ class StorePinkDao extends BaseDao /** * 获取拼团完成的个数 * @return float + * @throws \ReflectionException */ public function getPinkOkSumTotalNum() { diff --git a/crmeb/app/dao/order/StoreOrderDao.php b/crmeb/app/dao/order/StoreOrderDao.php index cb9c12c51..166e5a6df 100644 --- a/crmeb/app/dao/order/StoreOrderDao.php +++ b/crmeb/app/dao/order/StoreOrderDao.php @@ -446,8 +446,9 @@ class StoreOrderDao extends BaseDao /** * 获取订单详情 - * @param $uid - * @param $key + * @param string $key + * @param int $uid + * @param array $with * @return array|\think\Model|null * @throws \think\db\exception\DataNotFoundException * @throws \think\db\exception\DbException @@ -455,7 +456,9 @@ class StoreOrderDao extends BaseDao */ public function getUserOrderDetail(string $key, int $uid, $with = []) { - return $this->getOne(['order_id|unique' => $key, 'uid' => $uid, 'is_del' => 0], '*', $with); + $where = ['order_id|unique' => $key, 'is_del' => 0]; + if ($uid > 0) $where = $where + ['uid' => $uid]; + return $this->getOne($where, '*', $with); } /** diff --git a/crmeb/app/services/activity/combination/StorePinkServices.php b/crmeb/app/services/activity/combination/StorePinkServices.php index 3033ddbeb..535ab831b 100644 --- a/crmeb/app/services/activity/combination/StorePinkServices.php +++ b/crmeb/app/services/activity/combination/StorePinkServices.php @@ -88,6 +88,9 @@ class StorePinkServices extends BaseServices * 参团人员 * @param int $id * @return array + * @throws \think\db\exception\DataNotFoundException + * @throws \think\db\exception\DbException + * @throws \think\db\exception\ModelNotFoundException */ public function getPinkMember(int $id) { @@ -96,8 +99,11 @@ class StorePinkServices extends BaseServices /** * 拼团退款 - * @param $id + * @param $order * @return bool + * @throws \think\db\exception\DataNotFoundException + * @throws \think\db\exception\DbException + * @throws \think\db\exception\ModelNotFoundException */ public function setRefundPink($order) { diff --git a/template/uni-app/pages/goods/goods_return/index.vue b/template/uni-app/pages/goods/goods_return/index.vue index c1984e250..9062265cd 100644 --- a/template/uni-app/pages/goods/goods_return/index.vue +++ b/template/uni-app/pages/goods/goods_return/index.vue @@ -10,7 +10,7 @@ {{item.productInfo.store_name}} - {{$t(`¥`)}}{{(parseFloat(item.truePrice)+parseFloat(item.postage_price)).toFixed(2)}} + {{$t(`¥`)}}{{(parseFloat(item.truePrice)+parseFloat(item.postage_price/item.cart_num)).toFixed(2)}} x{{item.cart_num}}