fix region_path like concat("%/",#{regionPath},"/%")
This commit is contained in:
@@ -186,7 +186,7 @@
|
||||
deleted as deleted
|
||||
from region_${enterpriseId}
|
||||
where deleted = 0
|
||||
and region_path like concat(#{regionPath},'%')
|
||||
and region_path like concat("%/",#{regionPath},"/%")
|
||||
</select>
|
||||
|
||||
<select id="getRegionPathByIds" resultType="com.cool.store.entity.RegionDO">
|
||||
@@ -271,7 +271,7 @@
|
||||
where
|
||||
deleted = 0
|
||||
and
|
||||
<foreach collection="regionPaths" separator=" or " open="(" close=")" item="region" > region_path like concat(#{region}, "%")</foreach>
|
||||
<foreach collection="regionPaths" separator=" or " open="(" close=")" item="region" > region_path like concat("%/",#{regionPath},"/%")</foreach>
|
||||
</select>
|
||||
|
||||
<select id="getSubRegionIdsByRegionIds" resultType="string">
|
||||
@@ -305,7 +305,7 @@
|
||||
deleted = 0
|
||||
and region_type = 'path'
|
||||
and
|
||||
<foreach collection="regionPaths" separator=" or " open="(" close=")" item="region" > region_path like concat('%',#{region}, "%")</foreach>
|
||||
<foreach collection="regionPaths" separator=" or " open="(" close=")" item="region" > region_path like concat("%/",#{regionPath},"/%")</foreach>
|
||||
</select>
|
||||
|
||||
<select id="getRegionPathByRegionIds" resultType="string">
|
||||
|
||||
Reference in New Issue
Block a user