|
@ -613,6 +613,14 @@ |
|
|
<if test="endTime != null and endTime != ''"> |
|
|
<if test="endTime != null and endTime != ''"> |
|
|
and DATE_FORMAT(un.CREATED_TIME,'%Y-%m-%d') <=#{endTime} |
|
|
and DATE_FORMAT(un.CREATED_TIME,'%Y-%m-%d') <=#{endTime} |
|
|
</if> |
|
|
</if> |
|
|
|
|
|
where |
|
|
|
|
|
1=1 |
|
|
|
|
|
<if test="deptIdList != null and deptIdList.size() > 0"> |
|
|
|
|
|
AND un.DEPT_ID in |
|
|
|
|
|
<foreach collection="deptIdList" open="(" separator="," close=")" item="deptId"> |
|
|
|
|
|
#{deptId} |
|
|
|
|
|
</foreach> |
|
|
|
|
|
</if> |
|
|
GROUP BY |
|
|
GROUP BY |
|
|
t0.id |
|
|
t0.id |
|
|
ORDER BY |
|
|
ORDER BY |
|
@ -640,10 +648,10 @@ |
|
|
where sd.del_flag='0')epen ON find_in_set(t0.id, epen.ALL_DEPT_IDS) |
|
|
where sd.del_flag='0')epen ON find_in_set(t0.id, epen.ALL_DEPT_IDS) |
|
|
AND epen.DEL_FLAG = '0' |
|
|
AND epen.DEL_FLAG = '0' |
|
|
<if test="operationStartTime != null and operationEndTime != null and operationEndTime != ''"> |
|
|
<if test="operationStartTime != null and operationEndTime != null and operationEndTime != ''"> |
|
|
AND epen.CREATED_TIME BETWEEN #{operationStartTime} AND #{operationEndTime} |
|
|
AND DATE_FORMAT(epen.CREATED_TIME,'%Y-%m-%d') BETWEEN #{operationStartTime} AND #{operationEndTime} |
|
|
</if> |
|
|
</if> |
|
|
<if test="endTime != null and endTime != ''"> |
|
|
<if test="endTime != null and endTime != ''"> |
|
|
and epen.CREATED_TIME <=#{endTime} |
|
|
and DATE_FORMAT(epen.CREATED_TIME,'%Y-%m-%d') <=#{endTime} |
|
|
</if> |
|
|
</if> |
|
|
GROUP BY |
|
|
GROUP BY |
|
|
t0.id |
|
|
t0.id |
|
@ -705,10 +713,27 @@ |
|
|
OR epgr.STATE = '15' |
|
|
OR epgr.STATE = '15' |
|
|
) |
|
|
) |
|
|
<if test="operationStartTime != null and operationEndTime != null and operationEndTime != ''"> |
|
|
<if test="operationStartTime != null and operationEndTime != null and operationEndTime != ''"> |
|
|
AND epgr.CREATED_TIME BETWEEN #{operationStartTime} AND #{operationEndTime} |
|
|
AND DATE_FORMAT(epgr.CREATED_TIME,'%Y-%m-%d') BETWEEN #{operationStartTime} AND #{operationEndTime} |
|
|
|
|
|
</if> |
|
|
|
|
|
<if test="endTime != null and endTime != ''"> |
|
|
|
|
|
and DATE_FORMAT(epgr.CREATED_TIME,'%Y-%m-%d') <=#{endTime} |
|
|
|
|
|
</if> |
|
|
|
|
|
LEFT JOIN esua_epdc_group.epdc_user_group ugp ON ugp.GROUP_ID = epgr.ID |
|
|
|
|
|
AND ugp.DEL_FLAG = '0' |
|
|
|
|
|
AND ugp.LORD_FLAG = '1' |
|
|
|
|
|
<if test="operationStartTime != null and operationEndTime != null and operationEndTime != ''"> |
|
|
|
|
|
AND DATE_FORMAT(ugp.CREATED_TIME,'%Y-%m-%d') BETWEEN #{operationStartTime} AND #{operationEndTime} |
|
|
</if> |
|
|
</if> |
|
|
<if test="endTime != null and endTime != ''"> |
|
|
<if test="endTime != null and endTime != ''"> |
|
|
and epgr.CREATED_TIME <=#{endTime} |
|
|
and DATE_FORMAT(ugp.CREATED_TIME,'%Y-%m-%d') <=#{endTime} |
|
|
|
|
|
</if> |
|
|
|
|
|
where |
|
|
|
|
|
1=1 |
|
|
|
|
|
<if test="deptIdList != null and deptIdList.size() > 0"> |
|
|
|
|
|
AND epgr.GRID_ID in |
|
|
|
|
|
<foreach collection="deptIdList" open="(" separator="," close=")" item="deptId"> |
|
|
|
|
|
#{deptId} |
|
|
|
|
|
</foreach> |
|
|
</if> |
|
|
</if> |
|
|
GROUP BY |
|
|
GROUP BY |
|
|
t0.id |
|
|
t0.id |
|
@ -758,6 +783,14 @@ |
|
|
<if test="endTime != null and endTime != ''"> |
|
|
<if test="endTime != null and endTime != ''"> |
|
|
and DATE_FORMAT(ug.CREATED_TIME,'%Y-%m-%d') <=#{endTime} |
|
|
and DATE_FORMAT(ug.CREATED_TIME,'%Y-%m-%d') <=#{endTime} |
|
|
</if> |
|
|
</if> |
|
|
|
|
|
where |
|
|
|
|
|
1=1 |
|
|
|
|
|
<if test="deptIdList != null and deptIdList.size() > 0"> |
|
|
|
|
|
AND epgr.GRID_ID in |
|
|
|
|
|
<foreach collection="deptIdList" open="(" separator="," close=")" item="deptId"> |
|
|
|
|
|
#{deptId} |
|
|
|
|
|
</foreach> |
|
|
|
|
|
</if> |
|
|
GROUP BY |
|
|
GROUP BY |
|
|
epgr.GRID_ID, |
|
|
epgr.GRID_ID, |
|
|
t0.id |
|
|
t0.id |
|
@ -790,20 +823,28 @@ |
|
|
AND ( |
|
|
AND ( |
|
|
epgr.STATE = '10' |
|
|
epgr.STATE = '10' |
|
|
<if test="operationStartTime != null and operationEndTime != null and operationEndTime != ''"> |
|
|
<if test="operationStartTime != null and operationEndTime != null and operationEndTime != ''"> |
|
|
AND epgr.CREATED_TIME BETWEEN #{operationStartTime} AND #{operationEndTime} |
|
|
AND DATE_FORMAT(epgr.CREATED_TIME,'%Y-%m-%d') BETWEEN #{operationStartTime} AND #{operationEndTime} |
|
|
</if> |
|
|
</if> |
|
|
<if test="endTime != null and endTime != ''"> |
|
|
<if test="endTime != null and endTime != ''"> |
|
|
and epgr.CREATED_TIME <=#{endTime} |
|
|
and DATE_FORMAT(epgr.CREATED_TIME,'%Y-%m-%d') <=#{endTime} |
|
|
</if> |
|
|
</if> |
|
|
OR epgr.STATE = '15' |
|
|
OR epgr.STATE = '15' |
|
|
) |
|
|
) |
|
|
LEFT JOIN esua_epdc_group.epdc_topic ug ON epgr.id = ug.group_id |
|
|
LEFT JOIN esua_epdc_group.epdc_topic ug ON epgr.id = ug.group_id |
|
|
AND ug.DEL_FLAG = '0' |
|
|
AND ug.DEL_FLAG = '0' |
|
|
<if test="operationStartTime != null and operationEndTime != null and operationEndTime != ''"> |
|
|
<if test="operationStartTime != null and operationEndTime != null and operationEndTime != ''"> |
|
|
AND ug.CREATED_TIME BETWEEN #{operationStartTime} AND #{operationEndTime} |
|
|
AND DATE_FORMAT(ug.CREATED_TIME,'%Y-%m-%d') BETWEEN #{operationStartTime} AND #{operationEndTime} |
|
|
</if> |
|
|
</if> |
|
|
<if test="endTime != null and endTime != ''"> |
|
|
<if test="endTime != null and endTime != ''"> |
|
|
and ug.CREATED_TIME <=#{endTime} |
|
|
and DATE_FORMAT(ug.CREATED_TIME,'%Y-%m-%d') <=#{endTime} |
|
|
|
|
|
</if> |
|
|
|
|
|
where |
|
|
|
|
|
1=1 |
|
|
|
|
|
<if test="deptIdList != null and deptIdList.size() > 0"> |
|
|
|
|
|
AND epgr.GRID_ID in |
|
|
|
|
|
<foreach collection="deptIdList" open="(" separator="," close=")" item="deptId"> |
|
|
|
|
|
#{deptId} |
|
|
|
|
|
</foreach> |
|
|
</if> |
|
|
</if> |
|
|
GROUP BY |
|
|
GROUP BY |
|
|
t0.id |
|
|
t0.id |
|
|