| | |
| | | <select id="institutionalPartyMemberServiceAnalysis" |
| | | resultType="com.panzhihua.common.model.vos.neighbor.PartyMemberAnalysisVO"> |
| | | SELECT count(caa.sponsor_id) as serviceTimes,sum(caa.duration) as serviceTime,caa.check_unit_id as unitId |
| | | ,caa.community_id as communityId,cpm.id as memberId,cpm.name as memberName,cpcu.name as belongUnit,ca.name as belongCommunity,cpcu.belong_to |
| | | ,caa.community_id as communityId,caa.sponsor_id as memberId,su.name as memberName,cpcu.name as belongUnit,ca.name as belongCommunity,cpcu.belong_to |
| | | FROM `com_act_activity` as caa |
| | | left join com_act_act_sign as caas on caa.id=caas.activity_id |
| | | left join sys_user as su on caa.sponsor_id=su.user_id |
| | | left join com_pb_check_unit as cpcu on cpm.check_unit_id=cpcu.id |
| | | left join com_act as ca on cpm.community_id=ca.community_id |
| | | left join com_act as ca on su.community_id=ca.community_id |
| | | left join com_pb_check_unit as cpcu on ca.community_id=cpcu.community_id |
| | | where caa.sponsor_id<>'' |
| | | and caa.type=3 |
| | | <if test="beginTime != null"> |