From 3a67f108a009ddfdd5b5de6f62d76a424316e767 Mon Sep 17 00:00:00 2001 From: fhx <308050795@qq.com> Date: 星期二, 06 二月 2024 16:03:42 +0800 Subject: [PATCH] 1.修改查询 --- phi_platform_user/src/main/java/com/hx/phip/controller/promotion/PromotionController.java | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/phi_platform_user/src/main/java/com/hx/phip/controller/promotion/PromotionController.java b/phi_platform_user/src/main/java/com/hx/phip/controller/promotion/PromotionController.java index 64cda14..f4b4ae7 100644 --- a/phi_platform_user/src/main/java/com/hx/phip/controller/promotion/PromotionController.java +++ b/phi_platform_user/src/main/java/com/hx/phip/controller/promotion/PromotionController.java @@ -59,7 +59,7 @@ sql.append(" LEFT JOIN shop AS s ON s.id = p.shopId"); sql.append(" WHERE p.isDel = #{m.isDel} AND p.isUp = #{m.isUp}"); if (!StringUtils.isEmpty(promotionDto.getKeyWord())) { - sql.append(" AND p.name LIKE #{m.keyWord}"); + sql.append(" AND ( p.name LIKE #{m.keyWord} or p.code LIKE #{m.keyWord} ) "); sqlMap.put("keyWord", "%" + promotionDto.getKeyWord() + "%"); } sql.append(" ORDER BY p.createTime DESC "); -- Gitblit v1.8.0