From 387f61d55a8e20bc772b026cba4f8c34dfce5665 Mon Sep 17 00:00:00 2001 From: puzhibing <393733352@qq.com> Date: 星期三, 07 二月 2024 11:20:28 +0800 Subject: [PATCH] 更新代码 --- UserIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/PhoneMapper.xml | 24 ++++++++++-------------- 1 files changed, 10 insertions(+), 14 deletions(-) diff --git a/UserIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/PhoneMapper.xml b/UserIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/PhoneMapper.xml index 213317e..90270d6 100644 --- a/UserIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/PhoneMapper.xml +++ b/UserIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/PhoneMapper.xml @@ -22,14 +22,12 @@ companyId as companyId from t_phone where companyId in ( select companyId from t_company_city where state = 1 - <if test="null != province"> - and provinceCode = #{province} - </if> <if test="null != city"> - and cityCode = #{city} - </if> - <if test="null != code"> - and areaCode = #{code} + and cityId in (select id from t_city where englishName in + <foreach collection="city" item="item" index="index" separator="," open="(" close=")"> + #{item} + </foreach> + ) </if> ) </select> @@ -52,14 +50,12 @@ <if test="platform != 1"> and companyId in ( select companyId from t_company_city where state = 1 - <if test="null != province"> - and provinceCode = #{province} - </if> <if test="null != city"> - and cityCode = #{city} - </if> - <if test="null != code"> - and areaCode = #{code} + and cityId in (select id from t_city where englishName in + <foreach collection="city" item="item" index="index" separator="," open="(" close=")"> + #{item} + </foreach> + ) </if> ) </if> -- Gitblit v1.7.1