Browse Source

Merge branch 'hotfix/pcManageBug'

# Conflicts:
#	esua-epdc/epdc-admin/epdc-admin-server/src/main/java/com/elink/esua/epdc/service/impl/SysRoleServiceImpl.java
feature/dangjian
李鹏飞 5 years ago
parent
commit
b28a9431bd
  1. 18
      esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/mapper/user/UserAnalysisDao.xml

18
esua-epdc/epdc-module/epdc-analysis/epdc-analysis-server/src/main/resources/mapper/user/UserAnalysisDao.xml

@ -234,11 +234,15 @@
<select id="selectListCommunityCount" resultType="com.elink.esua.epdc.dto.user.result.GridOpeningResultDTO"> <select id="selectListCommunityCount" resultType="com.elink.esua.epdc.dto.user.result.GridOpeningResultDTO">
SELECT SELECT
epgr.GRID_ID gridId, epgr.GRID_ID gridId,
COUNT( DISTINCT epgr.ID ) communityCount, COUNT( DISTINCT epgrCount.ID ) communityCount,
COUNT( DISTINCT ug.user_id ) communityMemberCount, COUNT( DISTINCT ug.user_id ) communityMemberCount,
COUNT( DISTINCT ut.ID ) communityTopicCount COUNT( DISTINCT ut.ID ) communityTopicCount
FROM FROM
esua_epdc_group.epdc_group epgr esua_epdc_group.epdc_group epgr
left join esua_epdc_group.epdc_group epgrCount on epgr.id = epgrCount,id
<if test="startTime != null and endTime != null and endTime != ''">
AND DATE_FORMAT(epgrCount.CREATED_TIME,'%Y-%m-%d') BETWEEN #{startTime} AND #{endTime}
</if>
LEFT JOIN esua_epdc_group.epdc_user_group ug ON epgr.id = ug.group_id AND ug.DEL_FLAG = '0' LEFT JOIN esua_epdc_group.epdc_user_group ug ON epgr.id = ug.group_id AND ug.DEL_FLAG = '0'
<if test="startTime != null and endTime != null and endTime != ''"> <if test="startTime != null and endTime != null and endTime != ''">
AND DATE_FORMAT(ug.CREATED_TIME,'%Y-%m-%d') BETWEEN #{startTime} AND #{endTime} AND DATE_FORMAT(ug.CREATED_TIME,'%Y-%m-%d') BETWEEN #{startTime} AND #{endTime}
@ -252,9 +256,7 @@
<if test="gridIdList != null and gridIdList.size() > 0"> <if test="gridIdList != null and gridIdList.size() > 0">
AND epgr.GRID_ID in <include refid="foreachGridIdList"></include> AND epgr.GRID_ID in <include refid="foreachGridIdList"></include>
</if> </if>
<if test="startTime != null and endTime != null and endTime != ''">
AND DATE_FORMAT(epgr.CREATED_TIME,'%Y-%m-%d') BETWEEN #{startTime} AND #{endTime}
</if>
GROUP BY epgr.GRID_ID GROUP BY epgr.GRID_ID
</select> </select>
@ -986,13 +988,7 @@
LEFT JOIN esua_epdc_group.epdc_group epgr ON find_in_set(t0.id, epgr.ALL_DEPT_IDS) LEFT JOIN esua_epdc_group.epdc_group epgr ON find_in_set(t0.id, epgr.ALL_DEPT_IDS)
AND epgr.DEL_FLAG = '0' AND epgr.DEL_FLAG = '0'
AND ( AND (
epgr.STATE = '10' epgr.STATE = '10'
<if test="operationStartTime != null and operationEndTime != null 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') &lt;=#{endTime}
</if>
OR epgr.STATE = '15' OR epgr.STATE = '15'
) )
<if test="deptIdList != null and deptIdList.size() > 0"> <if test="deptIdList != null and deptIdList.size() > 0">

Loading…
Cancel
Save