From ea719b0443b8ccbc6d17349796936664ff3261d0 Mon Sep 17 00:00:00 2001 From: puzhibing <393733352@qq.com> Date: 星期六, 11 二月 2023 19:04:43 +0800 Subject: [PATCH] 修改bug --- UserIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/CompanyMapper.xml | 15 ++++++--------- 1 files changed, 6 insertions(+), 9 deletions(-) diff --git a/UserIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/CompanyMapper.xml b/UserIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/CompanyMapper.xml index 21887b3..87c218c 100644 --- a/UserIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/CompanyMapper.xml +++ b/UserIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/dao/mapping/CompanyMapper.xml @@ -107,16 +107,13 @@ insertTime as insertTime from t_company where flag != 3 and state = 0 and id in ( select companyId from t_company_city where state = 1 - <if test="null != province and null != city and null != code"> - and provinceCode = #{province} and cityCode = #{city} and areaCode = #{code} + <if test="null != cityIds"> + and cityId in + <foreach collection="cityIds" item="item" index="index" open="(" separator="," close=")"> + #{item} + </foreach> </if> - <if test="null != province and null != city and null == code"> - and provinceCode = #{province} and cityCode = #{city} and (areaCode = '' or areaCode is null) - </if> - <if test="null != province and null == city and null == code"> - and provinceCode = #{province} and (cityCode = '' or cityCode is null) and (areaCode = '' or areaCode is null) - </if> - ) + ) order by `type` desc limit 0, 1 </select> -- Gitblit v1.7.1