|
|
@@ -172,34 +172,42 @@
|
|
|
</select>
|
|
|
<select id="selectPageData1" resultType="com.xunmei.common.core.domain.drill.vo.CoreDrillDictionaryPageVo">
|
|
|
select * from core_drill_dictionary d inner join sys_dict_data dd on d.drill_type=dd.dict_value and
|
|
|
- dd.dict_type='core_drill_type' WHERE deleted=0
|
|
|
+ dd.dict_type='core_drill_type' inner join sys_org o on d.org_id=o.id
|
|
|
+ WHERE d.deleted=0 and o.deleted=0
|
|
|
<include refid="pageSql"/>
|
|
|
and d.org_id=#{request.orgId}
|
|
|
+ order by ifnull(o.sort,0)
|
|
|
</select>
|
|
|
<select id="selectPageData2" resultType="com.xunmei.common.core.domain.drill.vo.CoreDrillDictionaryPageVo">
|
|
|
select * from core_drill_dictionary d inner join sys_dict_data dd on d.drill_type=dd.dict_value and
|
|
|
- dd.dict_type='core_drill_type' WHERE deleted=0
|
|
|
+ dd.dict_type='core_drill_type' inner join sys_org o on d.org_id=o.id
|
|
|
+ WHERE d.deleted=0 and o.deleted=0
|
|
|
<include refid="pageSql"/>
|
|
|
and d.org_path like concat(#{request.orgPath},'%')
|
|
|
+ order by ifnull(o.sort,0)
|
|
|
</select>
|
|
|
<select id="selectPageData3" resultType="com.xunmei.common.core.domain.drill.vo.CoreDrillDictionaryPageVo">
|
|
|
select * from core_drill_dictionary d inner join sys_dict_data dd on d.drill_type=dd.dict_value and
|
|
|
- dd.dict_type='core_drill_type' WHERE deleted=0
|
|
|
+ dd.dict_type='core_drill_type' inner join sys_org o on d.org_id=o.id
|
|
|
+ WHERE d.deleted=0 and o.deleted=0
|
|
|
<include refid="pageSql"/>
|
|
|
and d.org_id in
|
|
|
<foreach item="item" collection="request.orgIdList" open="(" separator="," close=")">
|
|
|
#{item}
|
|
|
</foreach>
|
|
|
+ order by ifnull(o.sort,0)
|
|
|
</select>
|
|
|
<select id="selectPageData4" resultType="com.xunmei.common.core.domain.drill.vo.CoreDrillDictionaryPageVo">
|
|
|
select * from core_drill_dictionary d inner join sys_dict_data dd on d.drill_type=dd.dict_value and
|
|
|
- dd.dict_type='core_drill_type' WHERE deleted=0
|
|
|
+ dd.dict_type='core_drill_type' inner join sys_org o on d.org_id=o.id
|
|
|
+ WHERE d.deleted=0 and o.deleted=0
|
|
|
<include refid="pageSql"/>
|
|
|
and (d.org_id in
|
|
|
<foreach item="item" collection="request.orgIdList" open="(" separator="," close=")">
|
|
|
#{item}
|
|
|
</foreach>
|
|
|
or d.org_path like concat(#{request.orgPath},'%'))
|
|
|
+ order by ifnull(o.sort,0)
|
|
|
</select>
|
|
|
|
|
|
|