|
@ -6,6 +6,51 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<select id="queryPageList" resultType="org.dromara.business.domain.vo.BusinessLayerVo"> |
|
|
<select id="queryPageList" resultType="org.dromara.business.domain.vo.BusinessLayerVo"> |
|
|
|
|
|
SELECT |
|
|
|
|
|
t.id, |
|
|
|
|
|
t.layer_name as layerName, |
|
|
|
|
|
t.enable, |
|
|
|
|
|
t.remark, |
|
|
|
|
|
t.layer_type as layerType, |
|
|
|
|
|
t.dept_id as deptId, |
|
|
|
|
|
t.dept_name AS deptName, |
|
|
|
|
|
t.tenant_id as tenantId, |
|
|
|
|
|
t.create_time AS createTime, |
|
|
|
|
|
t.sort, |
|
|
|
|
|
t.parent_id AS parentId |
|
|
|
|
|
FROM |
|
|
|
|
|
business_layer t |
|
|
|
|
|
<where> |
|
|
|
|
|
<if test="bo.parentId != null and bo.parentId != ''"> |
|
|
|
|
|
and t.parent_id = #{bo.parentId} |
|
|
|
|
|
</if> |
|
|
|
|
|
<if test="bo.layerType != null and bo.layerType != ''"> |
|
|
|
|
|
and t.layer_type = #{bo.layerType} |
|
|
|
|
|
</if> |
|
|
|
|
|
<if test="bo.deptId != null and bo.deptId != ''"> |
|
|
|
|
|
and t.dept_id = #{bo.deptId} |
|
|
|
|
|
</if> |
|
|
|
|
|
<if test="bo.enable != null and bo.enable != ''"> |
|
|
|
|
|
and t.enable = #{bo.enable} |
|
|
|
|
|
</if> |
|
|
|
|
|
<if test="bo.layerName != null and bo.layerName != ''"> |
|
|
|
|
|
and t.layer_name like CONCAT(#{bo.layerName}, '%') |
|
|
|
|
|
</if> |
|
|
|
|
|
<if test="bo.deptName != null and bo.deptName != ''"> |
|
|
|
|
|
and t.dept_name like CONCAT(#{bo.deptName}, '%') |
|
|
|
|
|
</if> |
|
|
|
|
|
<choose> |
|
|
|
|
|
<when test="bo.startTime != null and bo.endTime != null"> |
|
|
|
|
|
and t.create_time between #{bo.startTime} and #{bo.endTime} |
|
|
|
|
|
</when> |
|
|
|
|
|
<when test="bo.startTime != null"> |
|
|
|
|
|
and t.create_time >= #{bo.startTime} |
|
|
|
|
|
</when> |
|
|
|
|
|
<when test="bo.endTime != null"> |
|
|
|
|
|
and t.create_time <= #{bo.endTime} |
|
|
|
|
|
</when> |
|
|
|
|
|
</choose> |
|
|
|
|
|
</where> |
|
|
|
|
|
order by t.parentId , t.sort |
|
|
</select> |
|
|
</select> |
|
|
</mapper> |
|
|
</mapper> |
|
|