From 52a38c9fa942d7d7d628dd2d097cb797c8787da4 Mon Sep 17 00:00:00 2001 From: dy-hu Date: Tue, 9 Jul 2024 14:49:03 +0800 Subject: [PATCH] =?UTF-8?q?=E5=B9=B3=E5=8F=B0=E7=AB=AF=E3=80=81=E5=95=86?= =?UTF-8?q?=E5=AE=B6=E7=AB=AF=E3=80=81=E5=95=86=E5=9F=8E=E7=AB=AF=E6=B6=89?= =?UTF-8?q?=E5=8F=8A=E4=BC=9A=E5=91=98=E8=A1=A8=E5=85=B3=E8=81=94=E6=9F=A5?= =?UTF-8?q?=E8=AF=A2=E4=B8=9A=E5=8A=A1=E5=A4=84=E7=90=86=E6=89=80=E5=B1=9E?= =?UTF-8?q?=E5=95=86=E5=AE=B6=E8=BF=87=E6=BB=A4=E7=AD=9B=E9=80=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../resources/mybatis/mapper/admin/CereActivitySignDAO.xml | 2 +- .../resources/mybatis/mapper/buyer/CereBuyerWithdrawalDAO.xml | 2 +- .../resources/mybatis/mapper/credit/CereCreditRecordDAO.xml | 1 + .../main/resources/mybatis/mapper/order/CereShopOrderDAO.xml | 6 +++--- .../main/resources/mybatis/mapper/risk/CereRiskBlackDAO.xml | 2 +- .../main/resources/mybatis/mapper/shop/CereShopCommentDAO.xml | 2 +- .../app/controller/distributor/DistributorController.java | 1 + .../com/shop/cereshop/business/dao/buyer/CereBuyerUserDAO.java | 2 +- .../business/dao/distributor/CereShopDistributorDAO.java | 2 +- .../business/service/buyer/impl/CereBuyerUserServiceImpl.java | 3 ++- .../distributor/impl/CereShopDistributorServiceImpl.java | 4 ++-- .../main/resources/mybatis/mapper/buyer/CereBuyerUserDAO.xml | 2 +- .../mybatis/mapper/distributor/CereShopDistributorDAO.xml | 2 +- .../resources/mybatis/mapper/shop/CereShopRelationshipDAO.xml | 2 +- .../main/resources/mybatis/mapper/tool/CereShopOperateDAO.xml | 10 +++++----- .../com/shop/cereshop/commons/domain/scene/CereShopScene.java | 2 +- 16 files changed, 24 insertions(+), 21 deletions(-) diff --git a/cereshop-admin/src/main/resources/mybatis/mapper/admin/CereActivitySignDAO.xml b/cereshop-admin/src/main/resources/mybatis/mapper/admin/CereActivitySignDAO.xml index 0bf2255..2479ea7 100644 --- a/cereshop-admin/src/main/resources/mybatis/mapper/admin/CereActivitySignDAO.xml +++ b/cereshop-admin/src/main/resources/mybatis/mapper/admin/CereActivitySignDAO.xml @@ -5,7 +5,7 @@ diff --git a/cereshop-admin/src/main/resources/mybatis/mapper/buyer/CereBuyerWithdrawalDAO.xml b/cereshop-admin/src/main/resources/mybatis/mapper/buyer/CereBuyerWithdrawalDAO.xml index d251580..8fc916b 100644 --- a/cereshop-admin/src/main/resources/mybatis/mapper/buyer/CereBuyerWithdrawalDAO.xml +++ b/cereshop-admin/src/main/resources/mybatis/mapper/buyer/CereBuyerWithdrawalDAO.xml @@ -117,7 +117,7 @@ SELECT a.withdrawal_id,a.withdrawal_money,a.state, IF(b.wechat_name IS NULL,b.`name`,b.wechat_name) `name`,b.phone from cere_buyer_withdrawal a LEFT JOIN cere_buyer_user b ON a.buyer_user_id=b.buyer_user_id - where 1=1 + where b.project = 0 and IF(b.wechat_name IS NULL,b.`name`,b.wechat_name) like concat('%',#{name},'%') diff --git a/cereshop-admin/src/main/resources/mybatis/mapper/credit/CereCreditRecordDAO.xml b/cereshop-admin/src/main/resources/mybatis/mapper/credit/CereCreditRecordDAO.xml index ea587f3..ebc7ceb 100644 --- a/cereshop-admin/src/main/resources/mybatis/mapper/credit/CereCreditRecordDAO.xml +++ b/cereshop-admin/src/main/resources/mybatis/mapper/credit/CereCreditRecordDAO.xml @@ -29,6 +29,7 @@ and (a.buyer_user_id = #{search} or b.name like concat('%', #{search}, '%')) + where b.project = 0 diff --git a/cereshop-admin/src/main/resources/mybatis/mapper/order/CereShopOrderDAO.xml b/cereshop-admin/src/main/resources/mybatis/mapper/order/CereShopOrderDAO.xml index d58faa7..90c4f55 100644 --- a/cereshop-admin/src/main/resources/mybatis/mapper/order/CereShopOrderDAO.xml +++ b/cereshop-admin/src/main/resources/mybatis/mapper/order/CereShopOrderDAO.xml @@ -570,19 +570,19 @@ diff --git a/cereshop-business/src/main/resources/mybatis/mapper/shop/CereShopRelationshipDAO.xml b/cereshop-business/src/main/resources/mybatis/mapper/shop/CereShopRelationshipDAO.xml index 8d4ff83..cfa0834 100644 --- a/cereshop-business/src/main/resources/mybatis/mapper/shop/CereShopRelationshipDAO.xml +++ b/cereshop-business/src/main/resources/mybatis/mapper/shop/CereShopRelationshipDAO.xml @@ -91,7 +91,7 @@ b.if_bind,b.update_time,b.distributor_id FROM cere_buyer_user a LEFT JOIN cere_distributor_buyer b ON a.buyer_user_id=b.buyer_user_id and b.shop_id=#{shopId} LEFT JOIN cere_shop_distributor c ON b.distributor_id=c.distributor_id - where 1=1 + where a.project = #{shopId} and (a.wechat_name like concat('%',#{name},'%') OR a.`name` like concat('%',#{name},'%')) diff --git a/cereshop-business/src/main/resources/mybatis/mapper/tool/CereShopOperateDAO.xml b/cereshop-business/src/main/resources/mybatis/mapper/tool/CereShopOperateDAO.xml index 099d9a7..82a5daf 100644 --- a/cereshop-business/src/main/resources/mybatis/mapper/tool/CereShopOperateDAO.xml +++ b/cereshop-business/src/main/resources/mybatis/mapper/tool/CereShopOperateDAO.xml @@ -237,10 +237,10 @@ SELECT a.buyer_user_id from cere_buyer_user a - LEFT JOIN (SELECT COUNT(*) count,buyer_user_id,shop_id from cere_shop_order where DATE_SUB(CURDATE(), INTERVAL + LEFT JOIN (SELECT COUNT(*) count,buyer_user_id,shop_id,project from cere_shop_order where DATE_SUB(CURDATE(), INTERVAL #{number} DAY) <= date(create_time) GROUP BY buyer_user_id) b ON a.buyer_user_id=b.buyer_user_id - where b.shop_id=#{shopId} and b.count=0 + where b.project=#{shopId} and b.count=0 and a.project=#{shopId} and a.buyer_user_id in ( @@ -272,7 +272,7 @@ LEFT JOIN (SELECT COUNT(*) count,buyer_user_id from cere_shop_visit where DATE_SUB(CURDATE(), INTERVAL #{number} DAY) <= date(visit_time) GROUP BY buyer_user_id) b ON a.buyer_user_id=b.buyer_user_id - where b.count=0 + where a.project=#{shopId} and b.count=0 and a.buyer_user_id in ( diff --git a/cereshop-commons/src/main/java/com/shop/cereshop/commons/domain/scene/CereShopScene.java b/cereshop-commons/src/main/java/com/shop/cereshop/commons/domain/scene/CereShopScene.java index 51b7477..907a7d7 100644 --- a/cereshop-commons/src/main/java/com/shop/cereshop/commons/domain/scene/CereShopScene.java +++ b/cereshop-commons/src/main/java/com/shop/cereshop/commons/domain/scene/CereShopScene.java @@ -24,7 +24,7 @@ public class CereShopScene implements Serializable { private Long sceneId; /** - * 店铺id + * 店铺id(存的是商家id) */ private Long shopId;