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;