| | |
| | | import javax.annotation.Resource; |
| | | |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.community.ComActVO; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.data.redis.core.StringRedisTemplate; |
| | | import org.springframework.data.redis.core.ValueOperations; |
| | |
| | | LoginUserInfoVO loginUser = (LoginUserInfoVO)authentication.getPrincipal(); |
| | | String token = JWTTokenUtil.generateToken(loginUser); |
| | | String refeshToken = JWTTokenUtil.generateRefeshToken(loginUser); |
| | | ComActVO comActVO = loginUser.getComActVO(); |
| | | LoginReturnVO loginReturnVO = new LoginReturnVO(); |
| | | loginReturnVO.setToken(token); |
| | | loginReturnVO.setRefreshToken(refeshToken); |
| | | loginReturnVO.setCommunityId(loginUser.getCommunityId()); |
| | | loginReturnVO.setLat(comActVO.getLat()); |
| | | loginReturnVO.setLng(comActVO.getLng()); |
| | | return loginReturnVO; |
| | | } |
| | | |
| | |
| | | package com.panzhihua.common.model.vos; |
| | | |
| | | import com.panzhihua.common.validated.AddGroup; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import javax.validation.constraints.NotBlank; |
| | | |
| | | /** |
| | | * @program: springcloud_k8s_panzhihuazhihuishequ |
| | |
| | | private Long communityId; |
| | | @ApiModelProperty("openId") |
| | | private String openId; |
| | | @ApiModelProperty("社区经度") |
| | | private String lng; |
| | | @ApiModelProperty("社区维度") |
| | | private String lat; |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.vos.community.bigscreen; |
| | | |
| | | import java.util.List; |
| | | |
| | | import com.panzhihua.common.model.vos.community.StatisticsCommVO; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @title: BigScreenAlarmStatisticsInfo |
| | | * @projectName: 成都呐喊信息技术有限公司-智慧社区项目 |
| | | * @description: 杨家坪定制-居家养老大屏统计数据 |
| | | * @author: hans |
| | | * @date: 2022/02/28 17:23 |
| | | */ |
| | | @Data |
| | | @ApiModel("杨家坪定制-居家养老大屏统计数据") |
| | | public class BigScreenAlarmStatisticsInfo { |
| | | |
| | | @ApiModelProperty(value = "监测设备数量") |
| | | private Integer abnormalAlarmTotal; |
| | | |
| | | @ApiModelProperty("服务设备数量") |
| | | private Integer oneKeyAlarmTotal; |
| | | |
| | | @ApiModelProperty("异常总次数") |
| | | private Integer abnormalTotal; |
| | | |
| | | @ApiModelProperty("服务总次数") |
| | | private Integer oneKeyTotal; |
| | | |
| | | @ApiModelProperty("待处理异常总数") |
| | | private Integer pendingAbnormalTotal; |
| | | |
| | | @ApiModelProperty("已处理异常总数") |
| | | private Integer completeAbnormalTotal; |
| | | |
| | | @ApiModelProperty("待服务总数") |
| | | private Integer pendingServiceTotal; |
| | | |
| | | @ApiModelProperty("已服务总数") |
| | | private Integer completeServiceTotal; |
| | | |
| | | @ApiModelProperty(value = "异常新增折线数据") |
| | | private List<StatisticsCommVO> abnormalAddPolylineData; |
| | | |
| | | @ApiModelProperty(value = "异常累计折线数据") |
| | | private List<StatisticsCommVO> abnormalTotalPolylineData; |
| | | |
| | | @ApiModelProperty(value = "服务新增折线数据") |
| | | private List<StatisticsCommVO> serviceAddPolylineData; |
| | | |
| | | @ApiModelProperty(value = "服务累计折线数据") |
| | | private List<StatisticsCommVO> serviceTotalPolylineData; |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.vos.community.bigscreen; |
| | | |
| | | import java.util.List; |
| | | |
| | | import com.panzhihua.common.model.vos.community.StatisticsCommVO; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @title: BigScreenFmsStatisticsInfo |
| | | * @projectName: 成都呐喊信息技术有限公司-智慧社区项目 |
| | | * @description: 杨家坪定制-五微服务大屏统计数据 |
| | | * @author: hans |
| | | * @date: 2022/02/26 14:57 |
| | | */ |
| | | @Data |
| | | @ApiModel("杨家坪定制-五微服务大屏统计数据") |
| | | public class BigScreenFmsStatisticsInfo { |
| | | |
| | | @ApiModelProperty(value = "团队/微团队总数") |
| | | private Integer teamTotal; |
| | | |
| | | @ApiModelProperty("成员总数") |
| | | private Integer memberTotal; |
| | | |
| | | @ApiModelProperty("服务/微服务总数") |
| | | private Integer serviceTotal; |
| | | |
| | | @ApiModelProperty("已服务总数") |
| | | private Integer completeServiceTotal; |
| | | |
| | | @ApiModelProperty("微讲堂/开课总数") |
| | | private Integer classroomTotal; |
| | | |
| | | @ApiModelProperty("微调节") |
| | | private Integer adjustTotal; |
| | | |
| | | @ApiModelProperty("微防控") |
| | | private Integer controlTotal; |
| | | |
| | | @ApiModelProperty("参与学习人数") |
| | | private Integer learnTotal; |
| | | |
| | | @ApiModelProperty("发现隐患数") |
| | | private Integer fxyhTotal; |
| | | |
| | | @ApiModelProperty("解决隐患数") |
| | | private Integer jjyhTotal; |
| | | |
| | | @ApiModelProperty(value = "团队类型占比圆形图数据") |
| | | private List<StatisticsCommVO> teamTypeCircleData; |
| | | |
| | | @ApiModelProperty(value = "微服务新增折线数据") |
| | | private List<StatisticsCommVO> serviceAddPolylineData; |
| | | |
| | | @ApiModelProperty(value = "微服务累计折线数据") |
| | | private List<StatisticsCommVO> serviceTotalPolylineData; |
| | | |
| | | @ApiModelProperty(value = "微调节矛盾类型占比圆形图数据") |
| | | private List<StatisticsCommVO> adjustCircleData; |
| | | |
| | | @ApiModelProperty(value = "新增解决矛盾折线数据") |
| | | private List<StatisticsCommVO> adjustAddPolylineData; |
| | | |
| | | @ApiModelProperty(value = "累计解决矛盾折线数据") |
| | | private List<StatisticsCommVO> adjustTotalPolylineData; |
| | | |
| | | @ApiModelProperty(value = "微防控防控类型占比圆形图数据") |
| | | private List<StatisticsCommVO> controlCircleData; |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.vos.community.bigscreen; |
| | | |
| | | import java.util.List; |
| | | |
| | | import com.panzhihua.common.model.vos.community.ComActFourMemberVO; |
| | | import com.panzhihua.common.model.vos.community.StatisticsCommVO; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @title: BigScreenPartyBuildIngStatisticsInfo |
| | | * @projectName: 成都呐喊信息技术有限公司-智慧社区项目 |
| | | * @description: 金沙定制-四长四员大屏统计数据 |
| | | * @author: hans |
| | | * @date: 2022/02/21 16:22 |
| | | */ |
| | | @Data |
| | | @ApiModel("金沙定制-四长四员大屏统计数据") |
| | | public class BigScreenFourMemberStatisticsInfo { |
| | | |
| | | @ApiModelProperty(value = "四长四员总数/群众线总数") |
| | | private Integer szsyTotal; |
| | | |
| | | @ApiModelProperty("居民小组长") |
| | | private Integer jmxzzTotal; |
| | | |
| | | @ApiModelProperty("妇女小组长") |
| | | private Integer fnxzzTotal; |
| | | |
| | | @ApiModelProperty("楼栋党小组长") |
| | | private Integer dxzzTotal; |
| | | |
| | | @ApiModelProperty("楼栋长") |
| | | private Integer ldzTotal; |
| | | |
| | | @ApiModelProperty("调解员") |
| | | private Integer tjyTotal; |
| | | |
| | | @ApiModelProperty("安全员") |
| | | private Integer aqyTotal; |
| | | |
| | | @ApiModelProperty("宣传员") |
| | | private Integer xcyTotal; |
| | | |
| | | @ApiModelProperty("监督员") |
| | | private Integer jdyTotal; |
| | | |
| | | @ApiModelProperty("解决问题数") |
| | | private Integer jjwtTotal; |
| | | |
| | | @ApiModelProperty("院落议事数") |
| | | private Integer ylysTotal; |
| | | |
| | | @ApiModelProperty(value = "解决问题新增折线数据") |
| | | private List<StatisticsCommVO> jjwtAddPolylineData; |
| | | |
| | | @ApiModelProperty(value = "解决问题累计折线数据") |
| | | private List<StatisticsCommVO> jjwtTotalPolylineData; |
| | | |
| | | @ApiModelProperty(value = "院落议事新增折线数据") |
| | | private List<StatisticsCommVO> ylysAddPolylineData; |
| | | |
| | | @ApiModelProperty(value = "院落议事累计折线数据") |
| | | private List<StatisticsCommVO> ylysTotalPolylineData; |
| | | |
| | | @ApiModelProperty("四长四员组织列表") |
| | | private List<FourMemberOrgRelationVO> fourMemberOrgList; |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.vos.community.bigscreen; |
| | | |
| | | import java.util.List; |
| | | |
| | | import com.panzhihua.common.model.vos.community.ComActDynVO; |
| | | import com.panzhihua.common.model.vos.community.ComActEasyPhotoVO; |
| | | import com.panzhihua.common.model.vos.community.ComSwPatrolRecordVO; |
| | | import com.panzhihua.common.model.vos.community.StatisticsCommVO; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @title: BigScreenPartyBuildIngStatisticsInfo |
| | | * @projectName: 成都呐喊信息技术有限公司-智慧社区项目 |
| | | * @description: 金沙定制-党建引领大屏统计数据 |
| | | * @author: hans |
| | | * @date: 2022/02/21 16:22 |
| | | */ |
| | | @Data |
| | | @ApiModel("金沙定制-党建引领大屏统计数据") |
| | | public class BigScreenPartyBuildIngStatisticsInfo { |
| | | |
| | | @ApiModelProperty("党建动态数") |
| | | private Integer djdtTotal; |
| | | |
| | | @ApiModelProperty("党建活动数") |
| | | private Integer djhdTotal; |
| | | |
| | | @ApiModelProperty(value = "议事投票总数/议事线总数") |
| | | private Integer ystpTotal; |
| | | |
| | | @ApiModelProperty(value = "议事投票总参与人数") |
| | | private Integer ystpcyTotal; |
| | | |
| | | @ApiModelProperty(value = "议事总数") |
| | | private Integer ysTotal; |
| | | |
| | | @ApiModelProperty(value = "投票总数") |
| | | private Integer tpTotal; |
| | | |
| | | @ApiModelProperty(value = "院落议事总数") |
| | | private Integer ylysTotal = 0; |
| | | |
| | | @ApiModelProperty(value = "社区议事总数") |
| | | private Integer sqysTotal = 0; |
| | | |
| | | @ApiModelProperty(value = "党员线总数") |
| | | private Integer dyTotal; |
| | | |
| | | @ApiModelProperty(value = "志愿线总数") |
| | | private Integer zyfwTotal; |
| | | |
| | | @ApiModelProperty(value = "四长四员总数/群众线总数") |
| | | private Integer szsyTotal; |
| | | |
| | | @ApiModelProperty(value = "安全线总数") |
| | | private Integer aqxTotal; |
| | | |
| | | @ApiModelProperty("居民小组长") |
| | | private Integer jmxzzTotal; |
| | | |
| | | @ApiModelProperty("妇女小组长") |
| | | private Integer fnxzzTotal; |
| | | |
| | | @ApiModelProperty("楼栋党小组长") |
| | | private Integer dxzzTotal; |
| | | |
| | | @ApiModelProperty("楼栋长") |
| | | private Integer ldzTotal; |
| | | |
| | | @ApiModelProperty("调解员") |
| | | private Integer tjyTotal; |
| | | |
| | | @ApiModelProperty("安全员") |
| | | private Integer aqyTotal; |
| | | |
| | | @ApiModelProperty("宣传员") |
| | | private Integer xcyTotal; |
| | | |
| | | @ApiModelProperty("监督员") |
| | | private Integer jdyTotal; |
| | | |
| | | @ApiModelProperty("志愿线总服务次数") |
| | | private Integer zyxServiceTotal; |
| | | |
| | | @ApiModelProperty("志愿线帮助群众次数") |
| | | private Integer zyxHelpTotal; |
| | | |
| | | @ApiModelProperty("居民宣传次数") |
| | | private Integer jmxcTotal; |
| | | |
| | | @ApiModelProperty("商户监督次数") |
| | | private Integer shjdTotal = 0; |
| | | |
| | | @ApiModelProperty("辖区巡查次数") |
| | | private Integer xqxcTotal; |
| | | |
| | | @ApiModelProperty("群众满意度分数") |
| | | private Double qzmydStar; |
| | | |
| | | @ApiModelProperty("随手拍治安防控记录列表") |
| | | private List<ComActEasyPhotoVO> zafkList; |
| | | |
| | | @ApiModelProperty("居民宣传记录列表") |
| | | private List<ComActDynVO> jmxcList; |
| | | |
| | | @ApiModelProperty("商户监督记录列表") |
| | | private List shjdList; |
| | | |
| | | @ApiModelProperty("辖区巡查记录列表") |
| | | private List<ComSwPatrolRecordVO> xqxcList; |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.vos.community.bigscreen; |
| | | |
| | | import java.util.List; |
| | | |
| | | import com.panzhihua.common.model.vos.community.StatisticsCommVO; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @title: BigScreenVolunteerStatisticsInfo |
| | | * @projectName: 成都呐喊信息技术有限公司-智慧社区项目 |
| | | * @description: 杨家坪定制-志愿服务大屏统计数据 |
| | | * @author: hans |
| | | * @date: 2022/03/02 15:25 |
| | | */ |
| | | @Data |
| | | @ApiModel("杨家坪定制-志愿服务大屏统计数据") |
| | | public class BigScreenVolunteerStatisticsInfo extends BigScreenVolunteerActStatisticsInfo { |
| | | |
| | | @ApiModelProperty("志愿者人数") |
| | | private Integer volunteerNum = 0; |
| | | |
| | | @ApiModelProperty("志愿者组织") |
| | | private Integer volunteerOrgNum = 0; |
| | | |
| | | @ApiModelProperty("志愿者队伍") |
| | | private Integer volunteerTeamNum = 0; |
| | | |
| | | @ApiModelProperty(value = "志愿者统计-组织人数直方图") |
| | | private List<StatisticsCommVO> volunteerOrgHistogram; |
| | | |
| | | @ApiModelProperty(value = "志愿者服务类型占比圆形图") |
| | | private List<StatisticsCommVO> volunteerServiceTypeCircleData; |
| | | |
| | | @ApiModelProperty(value = "志愿者年龄段占比圆形图") |
| | | private List<StatisticsCommVO> volunteerAgeCircleData; |
| | | |
| | | @ApiModelProperty(value = "志愿者技能占比圆形图") |
| | | private List<StatisticsCommVO> volunteerSkillCircleData; |
| | | |
| | | @ApiModelProperty(value = "志愿者组织关系") |
| | | private List<VolunteerOrgRelationVO> volunteerOrgRelationList; |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.vos.community.bigscreen; |
| | | |
| | | import java.util.List; |
| | | |
| | | import com.panzhihua.common.model.vos.community.ComActFourMemberVO; |
| | | |
| | | import com.panzhihua.common.model.vos.property.ComPropertyEquipmentVO; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @title: EquipmentPointMapDataVO |
| | | * @projectName: 成都呐喊信息技术有限公司-智慧社区项目 |
| | | * @description: 设备点位图数据 |
| | | * @author: hans |
| | | * @date: 2022/03/02 11:21 |
| | | */ |
| | | @Data |
| | | public class EquipmentPointMapDataVO { |
| | | |
| | | @ApiModelProperty("经纬度位置") |
| | | private String position; |
| | | |
| | | @ApiModelProperty("设备数") |
| | | private Integer equipmentNum; |
| | | |
| | | @ApiModelProperty("点位展示颜色(1.红色 2.黄色 3.绿色)") |
| | | private Integer pointColor; |
| | | |
| | | @ApiModelProperty("设备") |
| | | List<ComPropertyEquipmentVO> equipments; |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.vos.community.bigscreen; |
| | | |
| | | import java.util.List; |
| | | |
| | | import com.panzhihua.common.model.vos.community.ComActFourMemberVO; |
| | | |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @title: FourMemberOrgRelationVO |
| | | * @projectName: 成都呐喊信息技术有限公司-智慧社区项目 |
| | | * @description: 四长四员组织关系 |
| | | * @author: hans |
| | | * @date: 2022/02/25 16:57 |
| | | */ |
| | | @Data |
| | | public class FourMemberOrgRelationVO { |
| | | |
| | | @ApiModelProperty("关系") |
| | | private String relation; |
| | | |
| | | @ApiModelProperty("成员") |
| | | List<ComActFourMemberVO> members; |
| | | } |
New file |
| | |
| | | package com.panzhihua.common.model.vos.community.bigscreen; |
| | | |
| | | import java.util.List; |
| | | |
| | | import com.panzhihua.common.model.vos.community.ComMngVolunteerMngVO; |
| | | |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * @title: VolunteerOrgRelationVO |
| | | * @projectName: 成都呐喊信息技术有限公司-智慧社区项目 |
| | | * @description: 志愿者组织关系 |
| | | * @author: hans |
| | | * @date: 2022/03/03 13:30 |
| | | */ |
| | | @Data |
| | | public class VolunteerOrgRelationVO { |
| | | |
| | | @ApiModelProperty("组织") |
| | | private String org; |
| | | |
| | | @ApiModelProperty("组织人数") |
| | | private Integer orgPersonNum; |
| | | |
| | | @ApiModelProperty("志愿者") |
| | | List<ComMngVolunteerMngVO> volunteers; |
| | | } |
| | |
| | | @ApiModelProperty("所属团队类型") |
| | | private Long teamType; |
| | | |
| | | @ApiModelProperty("所属团队类型名") |
| | | private String teamTypeName; |
| | | |
| | | @ApiModelProperty("团队照片") |
| | | private String image; |
| | | |
| | |
| | | /** |
| | | * 设备类型 |
| | | */ |
| | | @ApiModelProperty(value = "设备类型 1红外报警 2一键报警 ") |
| | | @ApiModelProperty(value = "设备类型 1异常报警 2一键报警 ") |
| | | private Integer type; |
| | | |
| | | @ApiModelProperty(value = "手机号") |
| | |
| | | |
| | | @ApiModelProperty(value = "回显路径") |
| | | private String path; |
| | | |
| | | @ApiModelProperty(value = "设备状态(1.待服务 2.有异常报警 3.正常)") |
| | | private Integer equipmentStatus; |
| | | } |
| | |
| | | */ |
| | | @GetMapping("/building/getBuildListByVillageId") |
| | | R getBuildListByVillageId(@RequestParam(value = "villageId") Long villageId); |
| | | |
| | | /** |
| | | * 金沙定制页面-党建引领基础数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | @GetMapping("/screen/partyBuildIng/base") |
| | | R getPartyBuildIngBaseData(@RequestParam("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 党员活动展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | @PostMapping("/screen/partyBuildIng/partyAct") |
| | | R pagePartyBuildIngAct(@RequestBody PageBaseDTO pageBaseDTO); |
| | | |
| | | /** |
| | | * 议事投票展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | @PostMapping("/screen/partyBuildIng/discuss") |
| | | R pagePartyBuildIngDiscuss(@RequestBody PageBaseDTO pageBaseDTO); |
| | | |
| | | /** |
| | | * 金沙定制页面-四长四员 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | @GetMapping("/screen/fourMember/base") |
| | | R getFourMemberBaseData(@RequestParam("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 杨家坪定制页面-五微服务 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | @GetMapping("/screen/fms/base") |
| | | R getFmsBaseData(@RequestParam("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 杨家坪定制页面-微团队展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | @PostMapping("/screen/fms/team") |
| | | R pageFmsTeam(@RequestBody PageBaseDTO pageBaseDTO); |
| | | |
| | | /** |
| | | * 杨家坪定制页面-居家养老基础数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | @GetMapping("/screen/alarm/base") |
| | | R getAlarmBaseData(@RequestParam("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 杨家坪定制页面-报警记录展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | @PostMapping("/screen/alarm/record") |
| | | R pageAlarmRecord(@RequestBody PageBaseDTO pageBaseDTO); |
| | | |
| | | /** |
| | | * 杨家坪定制页面-报警设备点位图 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | @GetMapping("/screen/alarm/pointMap") |
| | | R getAlarmPointMap(@RequestParam("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 杨家坪定制页面-志愿服务 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | @GetMapping("/screen/volunteer/base") |
| | | R getVolunteerBaseData(@RequestParam("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 金沙定制页面-志愿线展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | @PostMapping("/screen/partyBuildIng/microWish") |
| | | R pagePartyBuildIngMicroWish(@RequestBody PageBaseDTO pageBaseDTO); |
| | | |
| | | /** |
| | | * 金沙定制页面-四长四员解决问题展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | @PostMapping("/screen/fourMember/resolve") |
| | | R pageFourMemberResolve(@RequestBody PageBaseDTO pageBaseDTO); |
| | | } |
| | |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | import com.panzhihua.common.model.vos.community.ComActActivityVO; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenResidentActStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenVolunteerActStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.screen.event.EventGridIncidentStatisticsVO; |
| | | import io.swagger.annotations.ApiImplicitParam; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | | import org.springframework.web.bind.annotation.RequestBody; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import com.panzhihua.common.model.vos.community.bigscreen.EquipmentPointMapDataVO; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | | import org.springframework.web.bind.annotation.RequestBody; |
| | |
| | | import com.panzhihua.common.model.dtos.community.bigscreen.event.ScreenDrawEventListDTO; |
| | | import com.panzhihua.common.model.dtos.community.bigscreen.event.ScreenEventListDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PagePopularMerchantDTO; |
| | | import com.panzhihua.common.model.dtos.community.integral.ComActIntegralCommunityRankDTO; |
| | | import com.panzhihua.common.model.dtos.property.CommonPage; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.community.*; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenStatisticPartyOrg; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.WestScreenStatics; |
| | | import com.panzhihua.common.model.vos.partybuilding.PartyBuildingComPbDynVO; |
| | | import com.panzhihua.common.service.partybuilding.PartyBuildingService; |
| | | import com.panzhihua.common.model.vos.community.ComActActivityVO; |
| | | import com.panzhihua.common.model.vos.community.ComActDiscussVO; |
| | | import com.panzhihua.common.model.vos.community.ComActDynVO; |
| | | import com.panzhihua.common.model.vos.community.ComActEasyPhotoVO; |
| | | import com.panzhihua.common.model.vos.community.ComActMicroWishVO; |
| | | import com.panzhihua.common.model.vos.community.ComActQuestnaireVO; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenActivityLine; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenAlarmStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenCommunityStatisticsVO; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenDynStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenEasyPhotoStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenFmsStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenFourMemberStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenHmkBaseInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenMerchantStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenMicroWishStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenNeighborStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenPartyBuildIngStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenQuestionnaireStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenResidentActStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenServiceData; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenServiceUser; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenStatisticPartyOrg; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenVolunteerActStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenVolunteerStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.GridsGovernanceStatisticsVO; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.IndexInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.ResidentAutonomyStatisticsVO; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.WestScreenStatics; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.*; |
| | | import com.panzhihua.common.model.vos.community.convenient.ConvenientMerchantVO; |
| | | import com.panzhihua.common.model.vos.community.fms.ComFmsTeamVO; |
| | | import com.panzhihua.common.model.vos.community.integral.ComActIntegralCommunityRankVO; |
| | | import com.panzhihua.common.model.vos.community.screen.civil.CivilStatisticsVO; |
| | | import com.panzhihua.common.model.vos.community.screen.event.EventComprehensiveGovernanceStatisticsVO; |
| | | import com.panzhihua.common.model.vos.community.screen.event.EventGridIncidentStatisticsVO; |
| | | import com.panzhihua.common.model.vos.community.screen.event.EventGridMemberVO; |
| | | import com.panzhihua.common.model.vos.community.screen.event.EventGridStatisticsVO; |
| | | import com.panzhihua.common.model.vos.community.screen.event.EventListVO; |
| | |
| | | import com.panzhihua.common.model.vos.community.screen.event.EventPopulationStreetVO; |
| | | import com.panzhihua.common.model.vos.community.screen.event.EventStatisticsVO; |
| | | import com.panzhihua.common.model.vos.community.screen.index.IndexStatisticsVO; |
| | | import com.panzhihua.common.model.vos.neighbor.ComActNeighborCircleAdminVO; |
| | | import com.panzhihua.common.model.vos.partybuilding.PartyBuildingComPbDynVO; |
| | | import com.panzhihua.common.model.vos.community.switchs.StreetAllAppletsVO; |
| | | import com.panzhihua.common.model.vos.neighbor.ComActNeighborCircleAdminVO; |
| | | import com.panzhihua.common.model.vos.partybuilding.PartyBuildingActivityVO; |
| | | import com.panzhihua.common.model.vos.partybuilding.PartyBuildingComPbDynVO; |
| | | import com.panzhihua.common.model.vos.property.ComPropertyAlarmVO; |
| | | import com.panzhihua.common.model.vos.screen.ScreenDrawEventPopulationTotalVO; |
| | | import com.panzhihua.common.model.vos.screen.ScreenDrawEventVO; |
| | | import com.panzhihua.common.service.community.CommunityService; |
| | |
| | | import com.panzhihua.common.utlis.HttpUtils; |
| | | |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiImplicitParam; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | |
| | | import static java.util.Objects.isNull; |
| | | |
| | | @Slf4j |
| | | @Api(tags = {"大屏统计数据模块"}) |
| | |
| | | /** |
| | | * 首页二级页面-社区问卷展示列表 |
| | | */ |
| | | @ApiOperation(value = "首页二级页面-随手拍展示列表", response = ComActQuestnaireVO.class) |
| | | @ApiOperation(value = "首页二级页面-社区问卷展示列表", response = ComActQuestnaireVO.class) |
| | | @PostMapping("/index/questionnaireList") |
| | | public R indexQuestionnaireList(@RequestBody PageBaseDTO pageBaseDTO) { |
| | | pageBaseDTO.setCommunityId(this.getCommunityId()); |
| | |
| | | public R projectActivityTop(@RequestBody CommonPage commonPage){ |
| | | return communityService.projectActivityProject(commonPage); |
| | | } |
| | | |
| | | @ApiOperation(value = "金沙定制页面-党建引领基础数据", response = BigScreenPartyBuildIngStatisticsInfo.class) |
| | | @GetMapping("/partyBuildIng/base") |
| | | public R getPartyBuildIngBaseData() { |
| | | return communityService.getPartyBuildIngBaseData(this.getCommunityId()); |
| | | } |
| | | |
| | | @ApiOperation(value = "金沙定制页面-党员活动展示列表", response = PartyBuildingActivityVO.class) |
| | | @PostMapping("/partyBuildIng/partyAct") |
| | | public R pagePartyAct(@RequestBody PageBaseDTO pageBaseDTO) { |
| | | pageBaseDTO.setCommunityId(this.getCommunityId()); |
| | | return communityService.pagePartyBuildIngAct(pageBaseDTO); |
| | | } |
| | | |
| | | @ApiOperation(value = "金沙定制页面-议事投票展示列表", response = ComActDiscussVO.class) |
| | | @PostMapping("/partyBuildIng/discuss") |
| | | public R pageDiscuss(@RequestBody PageBaseDTO pageBaseDTO) { |
| | | pageBaseDTO.setCommunityId(this.getCommunityId()); |
| | | return communityService.pagePartyBuildIngDiscuss(pageBaseDTO); |
| | | } |
| | | |
| | | @ApiOperation(value = "金沙定制页面-志愿线展示列表", response = ComActMicroWishVO.class) |
| | | @PostMapping("/partyBuildIng/microWish") |
| | | public R pagePartyBuildIngMicroWish(@RequestBody PageBaseDTO pageBaseDTO) { |
| | | pageBaseDTO.setCommunityId(this.getCommunityId()); |
| | | return communityService.pagePartyBuildIngMicroWish(pageBaseDTO); |
| | | } |
| | | |
| | | @ApiOperation(value = "金沙定制页面-四长四员", response = BigScreenFourMemberStatisticsInfo.class) |
| | | @GetMapping("/fourMember/base") |
| | | public R getFourMemberBaseData() { |
| | | return communityService.getFourMemberBaseData(this.getCommunityId()); |
| | | } |
| | | |
| | | @ApiOperation(value = "金沙定制页面-四长四员解决问题展示列表", response = ComActMicroWishVO.class) |
| | | @PostMapping("/fourMember/resolve") |
| | | public R pageFourMemberResolve(@RequestBody PageBaseDTO pageBaseDTO) { |
| | | pageBaseDTO.setCommunityId(this.getCommunityId()); |
| | | return communityService.pageFourMemberResolve(pageBaseDTO); |
| | | } |
| | | |
| | | @ApiOperation(value = "杨家坪定制页面-五微服务", response = BigScreenFmsStatisticsInfo.class) |
| | | @GetMapping("/fms/base") |
| | | public R getFmsBaseData() { |
| | | return communityService.getFmsBaseData(this.getCommunityId()); |
| | | } |
| | | |
| | | @ApiOperation(value = "杨家坪定制页面-微团队展示列表", response = ComFmsTeamVO.class) |
| | | @PostMapping("/fms/team") |
| | | public R pageFmsTeam(@RequestBody PageBaseDTO pageBaseDTO) { |
| | | pageBaseDTO.setCommunityId(this.getCommunityId()); |
| | | return communityService.pageFmsTeam(pageBaseDTO); |
| | | } |
| | | |
| | | @ApiOperation(value = "杨家坪定制页面-居家养老", response = BigScreenAlarmStatisticsInfo.class) |
| | | @GetMapping("/alarm/base") |
| | | public R getAlarmBaseData() { |
| | | return communityService.getAlarmBaseData(this.getCommunityId()); |
| | | } |
| | | |
| | | @ApiOperation(value = "杨家坪定制页面-报警记录展示列表,参数param3(1.待处理异常 2.已处理 3.待服务 4.已服务)", response = ComPropertyAlarmVO.class) |
| | | @PostMapping("/alarm/record") |
| | | public R pageAlarmRecord(@RequestBody PageBaseDTO pageBaseDTO) { |
| | | if (isNull(pageBaseDTO.getParam3())) { |
| | | return R.fail("缺少参数"); |
| | | } |
| | | pageBaseDTO.setCommunityId(this.getCommunityId()); |
| | | return communityService.pageAlarmRecord(pageBaseDTO); |
| | | } |
| | | |
| | | @ApiOperation(value = "杨家坪定制页面-报警设备点位图", response = EquipmentPointMapDataVO.class) |
| | | @GetMapping("/alarm/pointMap") |
| | | public R getAlarmPointMap() { |
| | | return communityService.getAlarmPointMap(this.getCommunityId()); |
| | | } |
| | | |
| | | @ApiOperation(value = "杨家坪定制页面-志愿服务", response = BigScreenVolunteerStatisticsInfo.class) |
| | | @GetMapping("/volunteer/base") |
| | | public R getVolunteerBaseData() { |
| | | return communityService.getVolunteerBaseData(this.getCommunityId()); |
| | | } |
| | | |
| | | @ApiOperation(value = "杨家坪定制页面-志愿者积分排行榜", response = ComActIntegralCommunityRankVO.class) |
| | | @PostMapping("/volunteer/rank") |
| | | public R getIntegralCommunityRank(@RequestBody ComActIntegralCommunityRankDTO communityRankDTO) { |
| | | communityRankDTO.setType(3); |
| | | communityRankDTO.setCommunityId(this.getCommunityId()); |
| | | return communityService.getIntegralCommunityRankApplets(communityRankDTO); |
| | | } |
| | | } |
| | |
| | | public R projectType(@RequestParam("name") String name){ |
| | | return bigScreenStatisticsService.projectType(name); |
| | | } |
| | | |
| | | /** |
| | | * 金沙定制页面-党建引领基础数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | @GetMapping("/partyBuildIng/base") |
| | | public R getPartyBuildIngBaseData(@RequestParam("communityId") Long communityId) { |
| | | return bigScreenStatisticsService.getPartyBuildIngBaseData(communityId); |
| | | } |
| | | |
| | | /** |
| | | * 党员活动展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | @PostMapping("/partyBuildIng/partyAct") |
| | | public R pagePartyBuildIngAct(@RequestBody PageBaseDTO pageBaseDTO) { |
| | | return bigScreenStatisticsService.pagePartyBuildIngAct(pageBaseDTO); |
| | | } |
| | | |
| | | /** |
| | | * 议事投票展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | @PostMapping("/partyBuildIng/discuss") |
| | | public R pagePartyBuildIngDiscuss(@RequestBody PageBaseDTO pageBaseDTO) { |
| | | return bigScreenStatisticsService.pagePartyBuildIngDiscuss(pageBaseDTO); |
| | | } |
| | | |
| | | /** |
| | | * 金沙定制页面-四长四员 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | @GetMapping("/fourMember/base") |
| | | public R getFourMemberBaseData(@RequestParam("communityId") Long communityId) { |
| | | return bigScreenStatisticsService.getFourMemberBaseData(communityId); |
| | | } |
| | | |
| | | /** |
| | | * 杨家坪定制页面-五微服务 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | @GetMapping("/fms/base") |
| | | public R getFmsBaseData(@RequestParam("communityId") Long communityId) { |
| | | return bigScreenStatisticsService.getFmsBaseData(communityId); |
| | | } |
| | | |
| | | /** |
| | | * 杨家坪定制页面-微团队展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | @PostMapping("/fms/team") |
| | | public R pageFmsTeam(@RequestBody PageBaseDTO pageBaseDTO) { |
| | | return bigScreenStatisticsService.pageFmsTeam(pageBaseDTO); |
| | | } |
| | | |
| | | /** |
| | | * 杨家坪定制页面-居家养老基础数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | @GetMapping("/alarm/base") |
| | | public R getAlarmBaseData(@RequestParam("communityId") Long communityId) { |
| | | return bigScreenStatisticsService.getAlarmBaseData(communityId); |
| | | } |
| | | |
| | | /** |
| | | * 杨家坪定制页面-报警记录展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | @PostMapping("/alarm/record") |
| | | public R pageAlarmRecord(@RequestBody PageBaseDTO pageBaseDTO) { |
| | | return bigScreenStatisticsService.pageAlarmRecord(pageBaseDTO); |
| | | } |
| | | |
| | | /** |
| | | * 杨家坪定制页面-报警设备点位图 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | @GetMapping("/alarm/pointMap") |
| | | public R getAlarmPointMap(@RequestParam("communityId") Long communityId) { |
| | | return bigScreenStatisticsService.getAlarmPointMap(communityId); |
| | | } |
| | | |
| | | /** |
| | | * 杨家坪定制页面-志愿服务 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | @GetMapping("/volunteer/base") |
| | | public R getVolunteerBaseData(@RequestParam("communityId") Long communityId) { |
| | | return bigScreenStatisticsService.getVolunteerBaseData(communityId); |
| | | } |
| | | |
| | | /** |
| | | * 金沙定制页面-志愿线展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | @PostMapping("/partyBuildIng/microWish") |
| | | public R pagePartyBuildIngMicroWish(@RequestBody PageBaseDTO pageBaseDTO) { |
| | | return bigScreenStatisticsService.pagePartyBuildIngMicroWish(pageBaseDTO); |
| | | } |
| | | |
| | | /** |
| | | * 金沙定制页面-四长四员解决问题展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | @PostMapping("/fourMember/resolve") |
| | | public R pageFourMemberResolve(@RequestBody PageBaseDTO pageBaseDTO) { |
| | | return bigScreenStatisticsService.pageFourMemberResolve(pageBaseDTO); |
| | | } |
| | | } |
| | |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | import com.panzhihua.common.model.vos.community.*; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | import org.apache.ibatis.annotations.Select; |
| | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.panzhihua.common.model.dtos.PageBaseDTO; |
| | | import com.panzhihua.common.model.dtos.community.bigscreen.work.ScreenActActivityListDTO; |
| | | import com.panzhihua.common.model.vos.community.*; |
| | | import com.panzhihua.common.model.vos.community.ComActActivityStatisticsVO; |
| | | import com.panzhihua.common.model.vos.community.ComActActivityTypeVO; |
| | | import com.panzhihua.common.model.vos.community.ComActActivityVO; |
| | | import com.panzhihua.common.model.vos.community.CommunityActivitiesVO; |
| | | import com.panzhihua.common.model.vos.community.PartyActivityStatics; |
| | | import com.panzhihua.common.model.vos.community.PartyActivityTypeChart; |
| | | import com.panzhihua.common.model.vos.community.StatisticsCommVO; |
| | | import com.panzhihua.common.model.vos.community.screen.work.ActActivityListVO; |
| | | import com.panzhihua.common.model.vos.screen.CarouselInfoVO; |
| | | import com.panzhihua.service_community.model.dos.ComActActivityDO; |
| | |
| | | import java.util.Map; |
| | | |
| | | import com.panzhihua.common.model.dtos.PageBaseDTO; |
| | | import com.panzhihua.common.model.vos.community.ComActDiscussVO; |
| | | import com.panzhihua.common.model.vos.community.ComSwPatrolRecordVO; |
| | | import com.panzhihua.common.model.vos.community.StatisticsCommVO; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenPartyBuildIngStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.partybuilding.PartyBuildingActivityVO; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | import org.apache.ibatis.annotations.Select; |
| | |
| | | StatisticsCommVO getDynTotalPolylineDate(@Param("communityId") Long communityId, @Param("date") String date); |
| | | |
| | | IPage<ComActDynVO> indexDynList(@Param("page") Page page, @Param("pageBaseDTO") PageBaseDTO pageBaseDTO); |
| | | |
| | | /** |
| | | * 获取党建引领基础数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | BigScreenPartyBuildIngStatisticsInfo getPartyBuildIngBaseData(@Param("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 分页获取党员活动 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | IPage<PartyBuildingActivityVO> pagePartyBuildIngAct(@Param("page") Page page, @Param("pageBaseDTO") PageBaseDTO pageBaseDTO); |
| | | |
| | | /** |
| | | * 分页获取议事投票数据 |
| | | * @param page |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | IPage<ComActDiscussVO> pagePartyBuildIngDiscuss(@Param("page") Page page, @Param("pageBaseDTO") PageBaseDTO pageBaseDTO); |
| | | |
| | | /** |
| | | * 获取居民宣传记录 |
| | | * @param communityId |
| | | * @param pageSize |
| | | * @return |
| | | */ |
| | | List<ComActDynVO> getPartyBuildIngDynRecord(@Param("communityId") Long communityId, @Param("pageSize") Integer pageSize); |
| | | |
| | | /** |
| | | * 获取巡查记录 |
| | | * @param communityId |
| | | * @param pageSize |
| | | * @return |
| | | */ |
| | | List<ComSwPatrolRecordVO> getPartyBuildIngPatrolRecord(@Param("communityId") Long communityId, @Param("pageSize") Integer pageSize); |
| | | } |
| | |
| | | * @return |
| | | */ |
| | | IPage<ComActEasyPhotoVO> indexEasyPhotoList(@Param("page") Page page, @Param("pageBaseDTO") PageBaseDTO pageBaseDTO); |
| | | |
| | | /** |
| | | * 随手拍治安防控记录列表 |
| | | * @param communityId |
| | | * @param pageSize |
| | | * @return |
| | | */ |
| | | List<ComActEasyPhotoVO> getPartyBuildIngRecord(@Param("communityId") Long communityId, @Param("pageSize") Integer pageSize); |
| | | } |
| | |
| | | import com.panzhihua.common.model.dtos.property.CommonPage; |
| | | import com.panzhihua.common.model.vos.community.ComActCommiteeVO; |
| | | import com.panzhihua.common.model.vos.community.ComActFourMemberVO; |
| | | import com.panzhihua.common.model.vos.community.StatisticsCommVO; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenFourMemberStatisticsInfo; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import com.panzhihua.service_community.entity.ComActFourMember; |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * (ComActFourMember)表数据库访问层 |
| | |
| | | IPage<ComActFourMemberVO> pageList(Page page, @Param("commonPage")CommonPage commonPage); |
| | | ComActFourMemberVO getById(Integer id); |
| | | ComActFourMemberVO getByIdVillage(Integer id); |
| | | |
| | | /** |
| | | * 获取四长四员基础数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | BigScreenFourMemberStatisticsInfo getFourMemberBaseData(@Param("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 获取四长四员成员数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | List<ComActFourMemberVO> getFourMembers(@Param("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 新增解决问题数统计 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | List<StatisticsCommVO> retrieveJJWTAddPolylineData(@Param("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 累计解决问题数 |
| | | * @param communityId |
| | | * @param date |
| | | * @return |
| | | */ |
| | | StatisticsCommVO retrieveJJWTTotalPolylineData(@Param("communityId") Long communityId, @Param("date") String date); |
| | | } |
| | |
| | | * @return |
| | | */ |
| | | IPage<ComActMicroWishVO> selectScreenDisplayList(@Param("page") Page page, @Param("pageBaseDTO") PageBaseDTO pageBaseDTO); |
| | | |
| | | /** |
| | | * 金沙定制页面-志愿线展示列表 |
| | | * @param page |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | IPage<ComActMicroWishVO> pagePartyBuildIngMicroWish(@Param("page") Page page, @Param("pageBaseDTO") PageBaseDTO pageBaseDTO); |
| | | |
| | | /** |
| | | * 金沙定制页面-四长四员解决问题展示列表 |
| | | * @param page |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | IPage<ComActMicroWishVO> pageFourMemberResolve(@Param("page") Page page, @Param("pageBaseDTO") PageBaseDTO pageBaseDTO); |
| | | } |
| | |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.panzhihua.common.model.dtos.PageBaseDTO; |
| | | import com.panzhihua.common.model.dtos.community.fms.PageFmsServiceAdminDTO; |
| | | import com.panzhihua.common.model.dtos.community.fms.PageFmsServiceAppletsDTO; |
| | | import com.panzhihua.common.model.vos.community.StatisticsCommVO; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenFmsStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.fms.ComFmsServiceVO; |
| | | import com.panzhihua.common.model.vos.community.fms.ComFmsTeamVO; |
| | | import com.panzhihua.common.model.vos.community.fms.FmsServiceTopStatisticsVO; |
| | | import com.panzhihua.common.model.vos.grid.EventVO; |
| | | import org.apache.ibatis.annotations.Param; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import com.panzhihua.service_community.entity.ComFmsService; |
| | |
| | | * @return |
| | | */ |
| | | IPage<ComFmsServiceVO> pageDealFmsService(@Param("page") Page page, @Param("adminDTO") PageFmsServiceAppletsDTO adminDTO); |
| | | |
| | | /** |
| | | * 获取五微服务基础数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | BigScreenFmsStatisticsInfo getFmsBaseData(@Param("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 获取团队类型占比圆形图数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | List<ComFmsTeamVO> retrieveTeamTypeCircleData(@Param("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 微服务新增折线数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | List<StatisticsCommVO> retrieveServiceAddPolylineData(@Param("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 报事报修累计折线数据获取 |
| | | * @param communityId |
| | | * @param date |
| | | * @return |
| | | */ |
| | | StatisticsCommVO retrieveServiceTotalPolylineData(@Param("communityId") Long communityId, @Param("date") String date); |
| | | |
| | | /** |
| | | * 获取微调节矛盾类型占比圆形图数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | List<EventVO> retrieveAdjustCircleData(@Param("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 新增解决矛盾折线数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | List<StatisticsCommVO> retrieveAdjustAddPolylineData(@Param("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 累计解决矛盾折线数据 |
| | | * @param communityId |
| | | * @param date |
| | | * @return |
| | | */ |
| | | StatisticsCommVO retrieveAdjustTotalPolylineData(@Param("communityId") Long communityId, @Param("date") String date); |
| | | |
| | | /** |
| | | * 微防控防控类型占比圆形图数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | List<EventVO> retrieveControlCircleData(@Param("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 杨家坪定制页面-微团队展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | IPage<ComFmsTeamVO> pageFmsTeam(@Param("page") Page page, @Param("pageBaseDTO") PageBaseDTO pageBaseDTO); |
| | | } |
| | |
| | | |
| | | import java.util.List; |
| | | |
| | | import com.panzhihua.common.model.vos.community.StatisticsCommVO; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenVolunteerStatisticsInfo; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.apache.ibatis.annotations.Param; |
| | | import org.apache.ibatis.annotations.Select; |
| | |
| | | @Select("select id_card from sys_user where type=1 and phone=#{idCard}") |
| | | Long selectUserIdByIdCard(String idCard); |
| | | |
| | | /** |
| | | * 志愿者-组织直方图数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | List<StatisticsCommVO> retrieveVolunteerOrgHistogram(@Param("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 获取杨家坪定制页面-志愿服务基础数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | BigScreenVolunteerStatisticsInfo getVolunteerBaseData(@Param("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 获取志愿者数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | List<ComMngVolunteerMngVO> retrieveVolunteerServiceTypeCircleData(@Param("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 志愿者年龄段占比圆形图数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | List<StatisticsCommVO> retrieveVolunteerAgeCircleData(@Param("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 志愿者技能占比圆形图 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | List<ComMngVolunteerMngVO> retrieveVolunteerSkillCircleData(@Param("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 根据社区id查询志愿者 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | List<ComMngVolunteerMngVO> selectVolunteerByCommunityId(@Param("communityId") Long communityId); |
| | | } |
| | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.panzhihua.common.model.dtos.property.CommonPage; |
| | | import com.panzhihua.common.model.vos.community.ComActSocialOrgVO; |
| | | import com.panzhihua.common.model.vos.community.ComPropertyVO; |
| | | import com.panzhihua.common.model.vos.community.StatisticsCommVO; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenAlarmStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.property.ComPropertyAlarmVO; |
| | | import com.panzhihua.common.model.vos.property.ComPropertyEquipmentVO; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import com.panzhihua.service_community.entity.ComProperty; |
| | | import org.apache.ibatis.annotations.Param; |
| | |
| | | List<StatisticsCommVO> getEventAddPolylineData(@Param("communityId") Long communityId); |
| | | |
| | | StatisticsCommVO getEventTotalPolylineDate(@Param("communityId") Long communityId, @Param("date") String date); |
| | | |
| | | /** |
| | | * 杨家坪定制页面-居家养老基础数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | BigScreenAlarmStatisticsInfo getAlarmBaseData(@Param("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 异常报警新增折线数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | List<StatisticsCommVO> retrieveAbnormalAddPolylineData(@Param("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 异常报警累计折线数据 |
| | | * @param communityId |
| | | * @param date |
| | | * @return |
| | | */ |
| | | StatisticsCommVO retrieveAbnormalTotalPolylineData(@Param("communityId") Long communityId, @Param("date") String date); |
| | | |
| | | /** |
| | | * 一键求助服务新增折线数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | List<StatisticsCommVO> retrieveServiceAddPolylineData(@Param("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 一键求助服务累计折线数据 |
| | | * @param communityId |
| | | * @param date |
| | | * @return |
| | | */ |
| | | StatisticsCommVO retrieveServiceTotalPolylineData(@Param("communityId") Long communityId, @Param("date") String date); |
| | | |
| | | /** |
| | | * 获取报警记录 |
| | | * @param page |
| | | * @param type |
| | | * @param status |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | IPage<ComPropertyAlarmVO> getAbnormalList(@Param("page") Page page, @Param("type") Integer type, |
| | | @Param("status") Integer status, @Param("communityId") Long communityId); |
| | | |
| | | /** |
| | | * 获取报警设备点位图 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | List<ComPropertyEquipmentVO> getAlarmPointMapData(@Param("communityId") Long communityId); |
| | | } |
| | |
| | | * @return |
| | | */ |
| | | R projectType(String name); |
| | | |
| | | /** |
| | | * 金沙定制页面-党建引领基础数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | R getPartyBuildIngBaseData(Long communityId); |
| | | |
| | | /** |
| | | * 党员活动展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | R pagePartyBuildIngAct(PageBaseDTO pageBaseDTO); |
| | | |
| | | /** |
| | | * 议事投票展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | R pagePartyBuildIngDiscuss(PageBaseDTO pageBaseDTO); |
| | | |
| | | /** |
| | | * 金沙定制页面-四长四员 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | R getFourMemberBaseData(Long communityId); |
| | | |
| | | /** |
| | | * 杨家坪定制页面-五微服务 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | R getFmsBaseData(Long communityId); |
| | | |
| | | /** |
| | | * 杨家坪定制页面-微团队展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | R pageFmsTeam(PageBaseDTO pageBaseDTO); |
| | | |
| | | /** |
| | | * 杨家坪定制页面-居家养老基础数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | R getAlarmBaseData(Long communityId); |
| | | |
| | | /** |
| | | * 杨家坪定制页面-报警记录展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | R pageAlarmRecord(PageBaseDTO pageBaseDTO); |
| | | |
| | | /** |
| | | * 杨家坪定制页面-报警设备点位图 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | R getAlarmPointMap(Long communityId); |
| | | |
| | | /** |
| | | * 杨家坪定制页面-志愿服务 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | R getVolunteerBaseData(Long communityId); |
| | | |
| | | /** |
| | | * 金沙定制页面-志愿线展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | R pagePartyBuildIngMicroWish(PageBaseDTO pageBaseDTO); |
| | | |
| | | /** |
| | | * 金沙定制页面-四长四员解决问题展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | R pageFourMemberResolve(PageBaseDTO pageBaseDTO); |
| | | } |
| | |
| | | import static java.util.Objects.isNull; |
| | | import static java.util.Objects.nonNull; |
| | | |
| | | import java.text.SimpleDateFormat; |
| | | import java.math.BigDecimal; |
| | | import java.util.ArrayList; |
| | | import java.util.Comparator; |
| | | import java.util.Date; |
| | |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | import com.panzhihua.common.model.dtos.property.CommonPage; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.*; |
| | | import com.panzhihua.common.utlis.DateUtils; |
| | | import com.panzhihua.service_community.dao.*; |
| | | import com.panzhihua.common.model.vos.community.ComActEasyPhotoVO; |
| | | import com.panzhihua.common.model.vos.community.ComMngVolunteerMngVO; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenAlarmStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenVolunteerStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.EquipmentPointMapDataVO; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.VolunteerOrgRelationVO; |
| | | import com.panzhihua.common.model.vos.grid.EventVO; |
| | | import com.panzhihua.common.model.vos.property.ComPropertyAlarmVO; |
| | | import com.panzhihua.common.model.vos.property.ComPropertyEquipmentVO; |
| | | import com.panzhihua.service_community.dao.ComMngVolunteerMngDAO; |
| | | import org.apache.commons.lang3.StringUtils; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.panzhihua.common.model.dtos.PageBaseDTO; |
| | | import com.panzhihua.common.model.dtos.community.convenient.PagePopularMerchantDTO; |
| | | import com.panzhihua.common.model.dtos.property.CommonPage; |
| | | import com.panzhihua.common.model.vos.R; |
| | | import com.panzhihua.common.model.vos.community.ComActEasyPhotoVO; |
| | | import com.panzhihua.common.model.vos.community.ComActDynVO; |
| | | import com.panzhihua.common.model.vos.community.ComActFourMemberVO; |
| | | import com.panzhihua.common.model.vos.community.ComSwPatrolRecordVO; |
| | | import com.panzhihua.common.model.vos.community.StatisticsCommVO; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenActivityLine; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenCommunityStatisticsVO; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenDynStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenEasyPhotoStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenFmsStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenFourMemberStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenHmkBaseInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenHmkProjectInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenHmkProjectTypeInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenHmkSocialOrgInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenHmkSocialWorkerInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenMerchantStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenMicroWishStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenNeighborStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenPartyBuildIngStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenQuestionnaireStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenResidentActStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.BigScreenVolunteerActStatisticsInfo; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.FourMemberOrgRelationVO; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.GridsGovernanceStatisticsVO; |
| | | import com.panzhihua.common.model.vos.community.bigscreen.ResidentAutonomyStatisticsVO; |
| | | import com.panzhihua.common.model.vos.community.convenient.ConvenientMerchantVO; |
| | | import com.panzhihua.common.model.vos.community.fms.ComFmsTeamVO; |
| | | import com.panzhihua.common.model.vos.community.screen.civil.CivilVillageStatisticsVO; |
| | | import com.panzhihua.common.model.vos.community.screen.event.EventGridIncidentStatisticsVO; |
| | | import com.panzhihua.common.model.vos.community.screen.event.EventGridStatisticsVO; |
| | | import com.panzhihua.common.utlis.DateUtils; |
| | | import com.panzhihua.service_community.dao.ComActActivityDAO; |
| | | import com.panzhihua.service_community.dao.ComActCommitteeDao; |
| | | import com.panzhihua.service_community.dao.ComActDiscussDAO; |
| | | import com.panzhihua.service_community.dao.ComActDynDAO; |
| | | import com.panzhihua.service_community.dao.ComActEasyPhotoDAO; |
| | | import com.panzhihua.service_community.dao.ComActFourMemberDao; |
| | | import com.panzhihua.service_community.dao.ComActMicroWishDAO; |
| | | import com.panzhihua.service_community.dao.ComActNeighborCircleDAO; |
| | | import com.panzhihua.service_community.dao.ComActQuestnaireDAO; |
| | | import com.panzhihua.service_community.dao.ComActSocialOrgDao; |
| | | import com.panzhihua.service_community.dao.ComActSocialProjectDao; |
| | | import com.panzhihua.service_community.dao.ComActSocialWorkerDao; |
| | | import com.panzhihua.service_community.dao.ComActWarehouseDonatesDao; |
| | | import com.panzhihua.service_community.dao.ComFmsServiceDAO; |
| | | import com.panzhihua.service_community.dao.ComMngPopulationDAO; |
| | | import com.panzhihua.service_community.dao.ComPropertyDao; |
| | | import com.panzhihua.service_community.dao.ConvenientMerchantDAO; |
| | |
| | | |
| | | @Resource |
| | | private ComActSocialWorkerDao comActSocialWorkerDao; |
| | | |
| | | @Resource |
| | | private ComActFourMemberDao comActFourMemberDao; |
| | | @Resource |
| | | private ComFmsServiceDAO comFmsServiceDAO; |
| | | @Resource |
| | | private ComMngVolunteerMngDAO comMngVolunteerMngDAO; |
| | | |
| | | /** |
| | | * 大数据分析平台-居民自治 |
| | |
| | | */ |
| | | @Override |
| | | public R indexVolunteerAct(Long communityId) { |
| | | BigScreenVolunteerActStatisticsInfo statisticsInfo = getBigScreenVolunteerActStatisticsInfo(communityId); |
| | | return R.ok(statisticsInfo); |
| | | } |
| | | |
| | | private BigScreenVolunteerActStatisticsInfo getBigScreenVolunteerActStatisticsInfo(Long communityId) { |
| | | BigScreenVolunteerActStatisticsInfo statisticsInfo = new BigScreenVolunteerActStatisticsInfo(); |
| | | List<StatisticsCommVO> actCircleData = comActActivityDAO.getIndexResidentActBaseData(communityId, false); |
| | | statisticsInfo.setActCircleData(actCircleData); |
| | |
| | | actTotalPolylineData.add(temp); |
| | | }); |
| | | statisticsInfo.setActTotalPolylineData(actTotalPolylineData); |
| | | return R.ok(statisticsInfo); |
| | | return statisticsInfo; |
| | | } |
| | | |
| | | /** |
| | |
| | | return R.ok(comActSocialProjectDao.selectType(name,null)); |
| | | } |
| | | |
| | | /** |
| | | * 金沙定制页面-党建引领基础数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public R getPartyBuildIngBaseData(Long communityId) { |
| | | //基础统计数据查询 |
| | | BigScreenPartyBuildIngStatisticsInfo statisticsInfo = comActDynDAO.getPartyBuildIngBaseData(communityId); |
| | | statisticsInfo.setAqxTotal(statisticsInfo.getJmxcTotal() + statisticsInfo.getShjdTotal() + statisticsInfo.getXqxcTotal()); |
| | | statisticsInfo.setZyxHelpTotal(statisticsInfo.getZyxServiceTotal()); |
| | | statisticsInfo.setZyfwTotal(statisticsInfo.getZyxServiceTotal()); |
| | | //随手拍治安防控记录列表 |
| | | List<ComActEasyPhotoVO> zafkList = comActEasyPhotoDAO.getPartyBuildIngRecord(communityId, pageSize); |
| | | statisticsInfo.setZafkList(zafkList); |
| | | //居民宣传记录列表 |
| | | List<ComActDynVO> JMXCList = comActDynDAO.getPartyBuildIngDynRecord(communityId, pageSize); |
| | | statisticsInfo.setJmxcList(JMXCList); |
| | | //商户监督记录列表 |
| | | |
| | | //辖区巡查记录列表 |
| | | List<ComSwPatrolRecordVO> XQXCList = comActDynDAO.getPartyBuildIngPatrolRecord(communityId, pageSize); |
| | | StringBuilder sb = new StringBuilder(); |
| | | XQXCList.forEach(e -> { |
| | | String personName = e.getPersonName(); |
| | | if (StringUtils.isNotBlank(personName)) { |
| | | String[] split = personName.split(","); |
| | | for (int i = 0;i < split.length;i++) { |
| | | sb.append(split[i].substring(0, 1).concat(split[i].substring(1).replaceAll("\\S", "*"))); |
| | | if (i != split.length - 1) { |
| | | sb.append(","); |
| | | } |
| | | } |
| | | e.setPersonName(sb.toString()); |
| | | sb.delete(0, sb.length()); |
| | | } |
| | | }); |
| | | statisticsInfo.setXqxcList(XQXCList); |
| | | return R.ok(statisticsInfo); |
| | | } |
| | | |
| | | /** |
| | | * 党员活动展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | @Override |
| | | public R pagePartyBuildIngAct(PageBaseDTO pageBaseDTO) { |
| | | Page page = retrievePage(pageBaseDTO); |
| | | return R.ok(comActDynDAO.pagePartyBuildIngAct(page, pageBaseDTO)); |
| | | } |
| | | |
| | | /** |
| | | * 议事投票展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | @Override |
| | | public R pagePartyBuildIngDiscuss(PageBaseDTO pageBaseDTO) { |
| | | Page page = retrievePage(pageBaseDTO); |
| | | return R.ok(comActDynDAO.pagePartyBuildIngDiscuss(page, pageBaseDTO)); |
| | | } |
| | | |
| | | /** |
| | | * 金沙定制页面-四长四员 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public R getFourMemberBaseData(Long communityId) { |
| | | //基础统计数据查询 |
| | | BigScreenFourMemberStatisticsInfo statisticsInfo = comActFourMemberDao.getFourMemberBaseData(communityId); |
| | | //四长四员楼栋组织关系 |
| | | List<ComActFourMemberVO> members = comActFourMemberDao.getFourMembers(communityId); |
| | | List<FourMemberOrgRelationVO> relations = new ArrayList<>(); |
| | | if (!members.isEmpty()) { |
| | | members.forEach(e -> e.setJurisdictionContent(e.getJurisdictionContent().replaceAll("\\[|\"|]", ""))); |
| | | Map<String, List<ComActFourMemberVO>> collect = members.stream().collect(Collectors.groupingBy(ComActFourMemberVO::getJurisdictionContent)); |
| | | for (Map.Entry<String, List<ComActFourMemberVO>> entry : collect.entrySet()) { |
| | | FourMemberOrgRelationVO relationVO = new FourMemberOrgRelationVO(); |
| | | relationVO.setRelation(entry.getKey()); |
| | | relationVO.setMembers(entry.getValue()); |
| | | relations.add(relationVO); |
| | | } |
| | | } |
| | | statisticsInfo.setFourMemberOrgList(relations); |
| | | //新增解决问题数 |
| | | List<StatisticsCommVO> jjwtAddPolylineData = comActFourMemberDao.retrieveJJWTAddPolylineData(communityId); |
| | | statisticsInfo.setJjwtAddPolylineData(jjwtAddPolylineData); |
| | | //累计解决问题数 |
| | | List<StatisticsCommVO> jjwtTotalPolylineData = new ArrayList<>(); |
| | | jjwtAddPolylineData.forEach(e -> { |
| | | StatisticsCommVO temp = comActFourMemberDao.retrieveJJWTTotalPolylineData(communityId, e.getFiled()); |
| | | temp.setFiled(e.getFiled()); |
| | | jjwtTotalPolylineData.add(temp); |
| | | }); |
| | | statisticsInfo.setJjwtTotalPolylineData(jjwtTotalPolylineData); |
| | | return R.ok(statisticsInfo); |
| | | } |
| | | |
| | | /** |
| | | * 杨家坪定制页面-五微服务 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public R getFmsBaseData(Long communityId) { |
| | | BigScreenFmsStatisticsInfo statisticsInfo = comFmsServiceDAO.getFmsBaseData(communityId); |
| | | //团队类型占比圆形图 |
| | | List<ComFmsTeamVO> preTeamTypeCircleData = comFmsServiceDAO.retrieveTeamTypeCircleData(communityId); |
| | | List<StatisticsCommVO> teamTypeCircleData = new ArrayList<>(); |
| | | if (!preTeamTypeCircleData.isEmpty()) { |
| | | Integer teamCount = preTeamTypeCircleData.size(); |
| | | Map<String, List<ComFmsTeamVO>> collect = preTeamTypeCircleData.stream().collect(Collectors.groupingBy(ComFmsTeamVO::getTeamTypeName)); |
| | | for (Map.Entry<String, List<ComFmsTeamVO>> entry : collect.entrySet()) { |
| | | StatisticsCommVO temp = new StatisticsCommVO(); |
| | | int size = entry.getValue().size(); |
| | | temp.setFiled(entry.getKey()); |
| | | temp.setNum(size); |
| | | temp.setPercent(new BigDecimal(size/teamCount).setScale(2)); |
| | | teamTypeCircleData.add(temp); |
| | | } |
| | | } |
| | | statisticsInfo.setTeamTypeCircleData(teamTypeCircleData); |
| | | //微服务新增折线数据 |
| | | List<StatisticsCommVO> serviceAddPolylineData = comFmsServiceDAO.retrieveServiceAddPolylineData(communityId); |
| | | statisticsInfo.setServiceAddPolylineData(serviceAddPolylineData); |
| | | //微服务累计折线数据 |
| | | List<StatisticsCommVO> serviceTotalPolylineData = new ArrayList<>(); |
| | | serviceAddPolylineData.forEach(e -> { |
| | | StatisticsCommVO temp = comFmsServiceDAO.retrieveServiceTotalPolylineData(communityId, e.getFiled()); |
| | | temp.setFiled(e.getFiled()); |
| | | serviceTotalPolylineData.add(temp); |
| | | }); |
| | | statisticsInfo.setServiceTotalPolylineData(serviceTotalPolylineData); |
| | | //微调节矛盾类型占比圆形图 |
| | | List<EventVO> preAdjustCircleData = comFmsServiceDAO.retrieveAdjustCircleData(communityId); |
| | | List<StatisticsCommVO> adjustCircleData = new ArrayList<>(); |
| | | if (!preAdjustCircleData.isEmpty()) { |
| | | Integer adjustCount = preAdjustCircleData.size(); |
| | | Map<String, List<EventVO>> collect = preAdjustCircleData.stream().collect(Collectors.groupingBy(EventVO::getEventClazz)); |
| | | for (Map.Entry<String, List<EventVO>> entry : collect.entrySet()) { |
| | | StatisticsCommVO temp = new StatisticsCommVO(); |
| | | int size = entry.getValue().size(); |
| | | temp.setFiled(entry.getKey()); |
| | | temp.setNum(size); |
| | | temp.setPercent(new BigDecimal(size/adjustCount).setScale(2)); |
| | | adjustCircleData.add(temp); |
| | | } |
| | | } |
| | | statisticsInfo.setAdjustCircleData(adjustCircleData); |
| | | //新增解决矛盾折线数据 |
| | | List<StatisticsCommVO> adjustAddPolylineData = comFmsServiceDAO.retrieveAdjustAddPolylineData(communityId); |
| | | statisticsInfo.setAdjustAddPolylineData(adjustAddPolylineData); |
| | | //累计解决矛盾折线数据 |
| | | List<StatisticsCommVO> adjustTotalPolylineData = new ArrayList<>(); |
| | | adjustAddPolylineData.forEach(e -> { |
| | | StatisticsCommVO temp = comFmsServiceDAO.retrieveAdjustTotalPolylineData(communityId, e.getFiled()); |
| | | temp.setFiled(e.getFiled()); |
| | | adjustTotalPolylineData.add(temp); |
| | | }); |
| | | statisticsInfo.setAdjustTotalPolylineData(adjustTotalPolylineData); |
| | | //微防控防控类型占比圆形图 |
| | | List<EventVO> preControlCircleData = comFmsServiceDAO.retrieveControlCircleData(communityId); |
| | | List<StatisticsCommVO> controlCircleData = new ArrayList<>(); |
| | | if (!preControlCircleData.isEmpty()) { |
| | | Integer controlCount = preControlCircleData.size(); |
| | | Map<String, List<EventVO>> collect = preControlCircleData.stream().collect(Collectors.groupingBy(EventVO::getEventClazz)); |
| | | for (Map.Entry<String, List<EventVO>> entry : collect.entrySet()) { |
| | | StatisticsCommVO temp = new StatisticsCommVO(); |
| | | int size = entry.getValue().size(); |
| | | temp.setFiled(entry.getKey()); |
| | | temp.setNum(size); |
| | | temp.setPercent(new BigDecimal(size/controlCount).setScale(2)); |
| | | controlCircleData.add(temp); |
| | | } |
| | | } |
| | | statisticsInfo.setControlCircleData(controlCircleData); |
| | | return R.ok(statisticsInfo); |
| | | } |
| | | |
| | | /** |
| | | * 杨家坪定制页面-微团队展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | @Override |
| | | public R pageFmsTeam(PageBaseDTO pageBaseDTO) { |
| | | Page page = retrievePage(pageBaseDTO); |
| | | return R.ok(comFmsServiceDAO.pageFmsTeam(page, pageBaseDTO)); |
| | | } |
| | | |
| | | /** |
| | | * 杨家坪定制页面-居家养老基础数据 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public R getAlarmBaseData(Long communityId) { |
| | | BigScreenAlarmStatisticsInfo statisticsInfo = comPropertyDao.getAlarmBaseData(communityId); |
| | | //异常报警新增折线数据 |
| | | List<StatisticsCommVO> abnormalAddPolylineData = comPropertyDao.retrieveAbnormalAddPolylineData(communityId); |
| | | statisticsInfo.setAbnormalAddPolylineData(abnormalAddPolylineData); |
| | | //异常报警累计折线数据 |
| | | List<StatisticsCommVO> abnormalTotalPolylineData = new ArrayList<>(); |
| | | abnormalAddPolylineData.forEach(e -> { |
| | | StatisticsCommVO temp = comPropertyDao.retrieveAbnormalTotalPolylineData(communityId, e.getFiled()); |
| | | temp.setFiled(e.getFiled()); |
| | | abnormalTotalPolylineData.add(temp); |
| | | }); |
| | | statisticsInfo.setAbnormalTotalPolylineData(abnormalTotalPolylineData); |
| | | //一键求助服务新增折线数据 |
| | | List<StatisticsCommVO> serviceAddPolylineData = comPropertyDao.retrieveServiceAddPolylineData(communityId); |
| | | statisticsInfo.setServiceAddPolylineData(serviceAddPolylineData); |
| | | //一键求助服务累计折线数据 |
| | | List<StatisticsCommVO> serviceTotalPolylineData = new ArrayList<>(); |
| | | serviceAddPolylineData.forEach(e -> { |
| | | StatisticsCommVO temp = comPropertyDao.retrieveServiceTotalPolylineData(communityId, e.getFiled()); |
| | | temp.setFiled(e.getFiled()); |
| | | serviceTotalPolylineData.add(temp); |
| | | }); |
| | | statisticsInfo.setServiceTotalPolylineData(serviceTotalPolylineData); |
| | | return R.ok(statisticsInfo); |
| | | } |
| | | |
| | | /** |
| | | * 杨家坪定制页面-报警记录展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | @Override |
| | | public R pageAlarmRecord(PageBaseDTO pageBaseDTO) { |
| | | Page page = retrievePage(pageBaseDTO); |
| | | Integer param3 = pageBaseDTO.getParam3(); |
| | | Long communityId = pageBaseDTO.getCommunityId(); |
| | | IPage<ComPropertyAlarmVO> abnormalList = null; |
| | | switch (param3) { |
| | | case 1: |
| | | //待处理异常展示列表 |
| | | abnormalList = comPropertyDao.getAbnormalList(page,2, 0, communityId); |
| | | break; |
| | | case 2: |
| | | //已处理异常展示列表 |
| | | abnormalList = comPropertyDao.getAbnormalList(page,2, 1, communityId); |
| | | break; |
| | | case 3: |
| | | //待服务展示列表 |
| | | abnormalList = comPropertyDao.getAbnormalList(page,1, 0, communityId); |
| | | break; |
| | | case 4: |
| | | //已服务展示列表 |
| | | abnormalList = comPropertyDao.getAbnormalList(page,1, 1, communityId); |
| | | break; |
| | | default: |
| | | break; |
| | | } |
| | | return R.ok(abnormalList); |
| | | } |
| | | |
| | | /** |
| | | * 杨家坪定制页面-报警设备点位图 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public R getAlarmPointMap(Long communityId) { |
| | | List<ComPropertyEquipmentVO> list = comPropertyDao.getAlarmPointMapData(communityId); |
| | | List<EquipmentPointMapDataVO> pointMapDataList = new ArrayList<>(); |
| | | if (!list.isEmpty()) { |
| | | Map<String, List<ComPropertyEquipmentVO>> collect = list.stream().collect(Collectors.groupingBy(e -> "[" + e.getLatitude() + "," + e.getLongitude() + "]")); |
| | | for (Map.Entry<String, List<ComPropertyEquipmentVO>> entry : collect.entrySet()) { |
| | | EquipmentPointMapDataVO pointMapDataVO = new EquipmentPointMapDataVO(); |
| | | List<ComPropertyEquipmentVO> value = entry.getValue(); |
| | | pointMapDataVO.setPosition(entry.getKey()); |
| | | List<ComPropertyEquipmentVO> sortedList = value.stream() |
| | | .sorted(Comparator.comparing(ComPropertyEquipmentVO::getEquipmentStatus)).collect(Collectors.toList()); |
| | | pointMapDataVO.setEquipments(sortedList); |
| | | pointMapDataVO.setEquipmentNum(value.size()); |
| | | boolean isRed = value.stream().anyMatch(e -> e.getEquipmentStatus().equals(1)); |
| | | boolean isYellow = value.stream().anyMatch(e -> e.getEquipmentStatus().equals(2)); |
| | | pointMapDataVO.setPointColor(isRed ? 1 : (isYellow ? 2 : 3)); |
| | | pointMapDataList.add(pointMapDataVO); |
| | | } |
| | | } |
| | | return R.ok(pointMapDataList); |
| | | } |
| | | |
| | | /** |
| | | * 杨家坪定制页面-志愿服务 |
| | | * @param communityId |
| | | * @return |
| | | */ |
| | | @Override |
| | | public R getVolunteerBaseData(Long communityId) { |
| | | BigScreenVolunteerStatisticsInfo statisticsInfo = comMngVolunteerMngDAO.getVolunteerBaseData(communityId); |
| | | BigScreenVolunteerActStatisticsInfo info = getBigScreenVolunteerActStatisticsInfo(communityId); |
| | | BeanUtils.copyProperties(info, statisticsInfo); |
| | | //志愿者统计-组织人数直方图 |
| | | statisticsInfo.setVolunteerOrgHistogram(comMngVolunteerMngDAO.retrieveVolunteerOrgHistogram(communityId)); |
| | | //志愿者服务类型占比圆形图 |
| | | List<ComMngVolunteerMngVO> preVolunteerServiceTypeCircleData = comMngVolunteerMngDAO.retrieveVolunteerServiceTypeCircleData(communityId); |
| | | List<StatisticsCommVO> volunteerServiceTypeCircleData = new ArrayList<>(); |
| | | if (!preVolunteerServiceTypeCircleData.isEmpty()) { |
| | | Integer count = preVolunteerServiceTypeCircleData.size(); |
| | | Map<String, List<ComMngVolunteerMngVO>> collect = preVolunteerServiceTypeCircleData.stream().collect(Collectors.groupingBy(ComMngVolunteerMngVO::getServiceTypeName)); |
| | | for (Map.Entry<String, List<ComMngVolunteerMngVO>> entry : collect.entrySet()) { |
| | | StatisticsCommVO temp = new StatisticsCommVO(); |
| | | int size = entry.getValue().size(); |
| | | temp.setFiled(entry.getKey()); |
| | | temp.setNum(size); |
| | | temp.setPercent(new BigDecimal(size/count).setScale(2)); |
| | | volunteerServiceTypeCircleData.add(temp); |
| | | } |
| | | } |
| | | statisticsInfo.setVolunteerServiceTypeCircleData(volunteerServiceTypeCircleData); |
| | | //志愿者年龄段占比圆形图 |
| | | List<StatisticsCommVO> volunteerAgeCircleData = comMngVolunteerMngDAO.retrieveVolunteerAgeCircleData(communityId); |
| | | int sum = volunteerAgeCircleData.stream().mapToInt(StatisticsCommVO::getNum).sum(); |
| | | volunteerAgeCircleData.forEach(e -> { |
| | | if (sum != 0) { |
| | | e.setPercent(new BigDecimal(e.getNum()/sum).setScale(2)); |
| | | } else { |
| | | e.setPercent(new BigDecimal(0)); |
| | | } |
| | | }); |
| | | statisticsInfo.setVolunteerAgeCircleData(volunteerAgeCircleData); |
| | | //志愿者技能占比圆形图 |
| | | List<ComMngVolunteerMngVO> preVolunteerSkillCircleData = comMngVolunteerMngDAO.retrieveVolunteerSkillCircleData(communityId); |
| | | List<StatisticsCommVO> volunteerSkillCircleData = new ArrayList<>(); |
| | | if (!preVolunteerSkillCircleData.isEmpty()) { |
| | | Integer count = preVolunteerSkillCircleData.size(); |
| | | Map<String, List<ComMngVolunteerMngVO>> collect = preVolunteerSkillCircleData.stream().collect(Collectors.groupingBy(ComMngVolunteerMngVO::getSkillName)); |
| | | for (Map.Entry<String, List<ComMngVolunteerMngVO>> entry : collect.entrySet()) { |
| | | StatisticsCommVO temp = new StatisticsCommVO(); |
| | | int size = entry.getValue().size(); |
| | | temp.setFiled(entry.getKey()); |
| | | temp.setNum(size); |
| | | temp.setPercent(new BigDecimal(size/count).setScale(2)); |
| | | volunteerSkillCircleData.add(temp); |
| | | } |
| | | } |
| | | statisticsInfo.setVolunteerSkillCircleData(volunteerSkillCircleData); |
| | | //志愿者组织数据 |
| | | List<VolunteerOrgRelationVO> volunteerOrgRelationList = new ArrayList<>(); |
| | | List<ComMngVolunteerMngVO> volunteerData = comMngVolunteerMngDAO.selectVolunteerByCommunityId(communityId); |
| | | if (!volunteerData.isEmpty()) { |
| | | Map<String, List<ComMngVolunteerMngVO>> collect = volunteerData.stream().collect(Collectors.groupingBy(ComMngVolunteerMngVO::getOrgName)); |
| | | for (Map.Entry<String, List<ComMngVolunteerMngVO>> entry : collect.entrySet()) { |
| | | VolunteerOrgRelationVO relationVO = new VolunteerOrgRelationVO(); |
| | | relationVO.setOrg(entry.getKey()); |
| | | relationVO.setOrgPersonNum(entry.getValue().size()); |
| | | relationVO.setVolunteers(entry.getValue()); |
| | | volunteerOrgRelationList.add(relationVO); |
| | | } |
| | | } |
| | | statisticsInfo.setVolunteerOrgRelationList(volunteerOrgRelationList); |
| | | return R.ok(statisticsInfo); |
| | | } |
| | | |
| | | /** |
| | | * 金沙定制页面-志愿线展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | @Override |
| | | public R pagePartyBuildIngMicroWish(PageBaseDTO pageBaseDTO) { |
| | | Page page = retrievePage(pageBaseDTO); |
| | | return R.ok(comActMicroWishDAO.pagePartyBuildIngMicroWish(page, pageBaseDTO)); |
| | | } |
| | | |
| | | /** |
| | | * 金沙定制页面-四长四员解决问题展示列表 |
| | | * @param pageBaseDTO |
| | | * @return |
| | | */ |
| | | @Override |
| | | public R pageFourMemberResolve(PageBaseDTO pageBaseDTO) { |
| | | Page page = retrievePage(pageBaseDTO); |
| | | return R.ok(comActMicroWishDAO.pageFourMemberResolve(page, pageBaseDTO)); |
| | | } |
| | | |
| | | private Page retrievePage(PageBaseDTO pageBaseDTO) { |
| | | Long pageNum = pageBaseDTO.getPageNum(); |
| | | Long size = pageBaseDTO.getPageSize(); |
| | |
| | | </if> |
| | | ORDER BY t1.id DESC |
| | | </select> |
| | | <select id="getPartyBuildIngBaseData" |
| | | resultType="com.panzhihua.common.model.vos.community.bigscreen.BigScreenPartyBuildIngStatisticsInfo"> |
| | | SELECT |
| | | (SELECT COUNT( d.id ) FROM com_pb_dyn d LEFT JOIN com_pb_dyn_user u ON d.id = u.dyn_id LEFT JOIN com_act t ON d.community_id = t.community_id WHERE d.type = 1 AND d.community_id = #{communityId}) AS djdtTotal, |
| | | (SELECT COUNT( a.id ) FROM com_pb_activity a LEFT JOIN sys_user u ON a.create_by = u.user_id WHERE a.community_id = #{communityId} AND a.`status` IN ( 3, 4, 5 )) AS djhdTotal, |
| | | (SELECT COUNT(id) FROM com_act_discuss WHERE community_id = #{communityId} AND is_del = 2) AS ystpTotal, |
| | | (SELECT COUNT(DISTINCT d2.user_id) FROM com_act_discuss d1 INNER JOIN com_act_discuss_comment d2 ON d1.id = d2.discuss_id WHERE d1.community_id = #{communityId} AND d1.is_del = 2) AS ystpcyTotal, |
| | | (SELECT COUNT(id) FROM com_act_discuss WHERE community_id = #{communityId} AND is_del = 2 AND `type` = 1) AS ysTotal, |
| | | (SELECT COUNT(id) FROM com_act_discuss WHERE community_id = #{communityId} AND is_del = 2 AND `type` = 2) AS tpTotal, |
| | | (SELECT COUNT(id) FROM com_pb_member WHERE community_id = #{communityId} AND audit_result = 1) AS dyTotal, |
| | | (SELECT COUNT(id) FROM com_act_four_member WHERE community_id = #{communityId}) AS szsyTotal, |
| | | (SELECT COUNT(id) FROM com_act_four_member WHERE community_id = #{communityId} AND (position LIKE CONCAT('%','居民小组长','%') OR position = '全部')) AS jmxzzTotal, |
| | | (SELECT COUNT(id) FROM com_act_four_member WHERE community_id = #{communityId} AND (position LIKE CONCAT('%','妇女小组长','%') OR position = '全部')) AS fnxzzTotal, |
| | | (SELECT COUNT(id) FROM com_act_four_member WHERE community_id = #{communityId} AND (position LIKE CONCAT('%','党小组长','%') OR position = '全部')) AS dxzzTotal, |
| | | (SELECT COUNT(id) FROM com_act_four_member WHERE community_id = #{communityId} AND (position LIKE CONCAT('%','楼栋长','%') OR position = '全部')) AS ldzTotal, |
| | | (SELECT COUNT(id) FROM com_act_four_member WHERE community_id = #{communityId} AND (position LIKE CONCAT('%','调解员','%') OR position = '全部')) AS tjyTotal, |
| | | (SELECT COUNT(id) FROM com_act_four_member WHERE community_id = #{communityId} AND (position LIKE CONCAT('%','安全员','%') OR position = '全部')) AS aqyTotal, |
| | | (SELECT COUNT(id) FROM com_act_four_member WHERE community_id = #{communityId} AND (position LIKE CONCAT('%','宣传员','%') OR position = '全部')) AS xcyTotal, |
| | | (SELECT COUNT(id) FROM com_act_four_member WHERE community_id = #{communityId} AND (position LIKE CONCAT('%','监督员','%') OR position = '全部')) AS jdyTotal, |
| | | (SELECT COUNT(t1.id) FROM com_act_easy_photo_handler t1 INNER JOIN com_act_micro_wish t2 ON t1.service_id = t2.id |
| | | WHERE t1.community_id = #{communityId} AND t1.`type` = 2 AND t1.service_type = 2 AND t2.`status` = 6) AS zyxServiceTotal, |
| | | (SELECT COUNT(id) FROM com_act_dyn WHERE community_id = #{communityId} AND `status` = 1) AS jmxcTotal, |
| | | (SELECT COUNT(id) FROM com_sw_patrol_record WHERE community_id = #{communityId}) AS xqxcTotal, |
| | | (SELECT IF(AVG(score) IS NULL,0,ROUND(AVG(score),1)) FROM com_act_easy_photo_evaluate WHERE community_id = #{communityId} AND service_type = 1) AS qzmydStar |
| | | </select> |
| | | <select id="pagePartyBuildIngAct" |
| | | resultType="com.panzhihua.common.model.vos.partybuilding.PartyBuildingActivityVO"> |
| | | SELECT |
| | | a.id, |
| | | a.NAME, |
| | | a.release_time, |
| | | a.cover |
| | | FROM com_pb_activity a |
| | | LEFT JOIN sys_user u ON a.create_by = u.user_id |
| | | WHERE a.community_id = #{pageBaseDTO.communityId} AND a.`status` IN ( 3, 4, 5 ) |
| | | ORDER BY a.release_time desc |
| | | </select> |
| | | <select id="pagePartyBuildIngDiscuss" |
| | | resultType="com.panzhihua.common.model.vos.community.ComActDiscussVO"> |
| | | SELECT |
| | | id, |
| | | discuss_subject, |
| | | `type`, |
| | | photo_pah |
| | | FROM com_act_discuss |
| | | WHERE community_id = #{pageBaseDTO.communityId} AND is_del = 2 |
| | | ORDER BY create_at DESC |
| | | </select> |
| | | <select id="getPartyBuildIngDynRecord" resultType="com.panzhihua.common.model.vos.community.ComActDynVO"> |
| | | SELECT id,title,publish_at FROM com_act_dyn WHERE community_id = #{communityId} AND `status` = 1 LIMIT #{pageSize} |
| | | </select> |
| | | <select id="getPartyBuildIngPatrolRecord" |
| | | resultType="com.panzhihua.common.model.vos.community.ComSwPatrolRecordVO"> |
| | | SELECT id,person_name,patrol_type,patrol_time FROM com_sw_patrol_record WHERE community_id = #{communityId} LIMIT #{pageSize} |
| | | </select> |
| | | </mapper> |
| | |
| | | |
| | | IFNULL((SELECT count(id) FROM com_sw_patrol_record WHERE community_id = ${communityId}), 0) AS safety |
| | | </select> |
| | | <select id="getPartyBuildIngRecord" |
| | | resultType="com.panzhihua.common.model.vos.community.ComActEasyPhotoVO"> |
| | | SELECT t1.id, t1.create_at, t2.`name` AS classifyName, t3.nick_name AS userNickName, t4.score |
| | | FROM com_act_easy_photo t1 |
| | | LEFT JOIN com_act_easy_photo_classify t2 ON t1.classify_id = t2.id |
| | | LEFT JOIN sys_user t3 ON t1.sponsor_id = t3.user_id |
| | | LEFT JOIN (SELECT * FROM com_act_easy_photo_evaluate WHERE service_type = 1) t4 ON t1.id = t4.service_id |
| | | WHERE t1.community_id = #{communityId} AND t1.`status` = 5 LIMIT #{pageSize} |
| | | </select> |
| | | |
| | | </mapper> |
| | |
| | | <select id="getById" resultMap="baseResultMap"> |
| | | select t.*,t1.*,t2.role_id from com_act_four_member t left join sys_user t1 on t.user_id = t1.user_id left join sys_user_role t2 on t.user_id =t2.user_id where t.id =#{id} |
| | | </select> |
| | | <select id="getFourMemberBaseData" |
| | | resultType="com.panzhihua.common.model.vos.community.bigscreen.BigScreenFourMemberStatisticsInfo"> |
| | | SELECT |
| | | (SELECT COUNT(id) FROM com_act_four_member WHERE community_id = #{communityId}) AS szsyTotal, |
| | | (SELECT COUNT(id) FROM com_act_four_member WHERE community_id = #{communityId} AND (position LIKE CONCAT('%','居民小组长','%') OR position = '全部')) AS jmxzzTotal, |
| | | (SELECT COUNT(id) FROM com_act_four_member WHERE community_id = #{communityId} AND (position LIKE CONCAT('%','妇女小组长','%') OR position = '全部')) AS fnxzzTotal, |
| | | (SELECT COUNT(id) FROM com_act_four_member WHERE community_id = #{communityId} AND (position LIKE CONCAT('%','党小组长','%') OR position = '全部')) AS dxzzTotal, |
| | | (SELECT COUNT(id) FROM com_act_four_member WHERE community_id = #{communityId} AND (position LIKE CONCAT('%','楼栋长','%') OR position = '全部')) AS ldzTotal, |
| | | (SELECT COUNT(id) FROM com_act_four_member WHERE community_id = #{communityId} AND (position LIKE CONCAT('%','调解员','%') OR position = '全部')) AS tjyTotal, |
| | | (SELECT COUNT(id) FROM com_act_four_member WHERE community_id = #{communityId} AND (position LIKE CONCAT('%','安全员','%') OR position = '全部')) AS aqyTotal, |
| | | (SELECT COUNT(id) FROM com_act_four_member WHERE community_id = #{communityId} AND (position LIKE CONCAT('%','宣传员','%') OR position = '全部')) AS xcyTotal, |
| | | (SELECT COUNT(id) FROM com_act_four_member WHERE community_id = #{communityId} AND (position LIKE CONCAT('%','监督员','%') OR position = '全部')) AS jdyTotal, |
| | | (SELECT |
| | | (SELECT COUNT(t1.id) |
| | | FROM com_act_easy_photo_handler t1 |
| | | INNER JOIN com_act_easy_photo t2 ON t1.service_id = t2.id |
| | | WHERE t1.community_id = #{communityId} AND t1.`type` = 5 AND t1.service_type = 1 AND t2.`status` = 5 |
| | | ) + |
| | | (SELECT COUNT(t1.id) |
| | | FROM com_act_easy_photo_handler t1 |
| | | INNER JOIN com_act_micro_wish t2 ON t1.service_id = t2.id |
| | | WHERE t1.community_id = #{communityId} AND t1.`type` = 5 AND t1.service_type = 2 AND t2.`status` = 6 |
| | | ) |
| | | ) AS jjwtTotal |
| | | </select> |
| | | <select id="getFourMembers" resultType="com.panzhihua.common.model.vos.community.ComActFourMemberVO"> |
| | | SELECT |
| | | a.id, |
| | | su.`name`, |
| | | a.position, |
| | | a.url, |
| | | substring_index( substring_index( a.jurisdiction_content, ',', b.help_topic_id + 1 ), ',',- 1 ) AS jurisdiction_content |
| | | FROM |
| | | com_act_four_member a |
| | | LEFT JOIN sys_user su ON a.user_id = su.user_id |
| | | JOIN mysql.help_topic b ON b.help_topic_id < ( length( a.jurisdiction_content ) - length( REPLACE ( a.jurisdiction_content, ',', '' ))+ 1 ) |
| | | WHERE |
| | | a.community_id = #{communityId} |
| | | </select> |
| | | <select id="retrieveJJWTAddPolylineData" |
| | | resultType="com.panzhihua.common.model.vos.community.StatisticsCommVO"> |
| | | SELECT filed, SUM(num) AS num FROM ( |
| | | SELECT DATE_FORMAT( create_at, '%Y-%m' ) AS filed, COUNT(1) AS num |
| | | FROM com_act_easy_photo_handler t1 |
| | | INNER JOIN com_act_easy_photo t2 ON t1.service_id = t2.id |
| | | WHERE t1.community_id = #{communityId} AND t1.`type` = 5 AND t1.service_type = 1 AND t2.`status` = 5 AND DATE_FORMAT( create_at, '%Y-%m' ) > DATE_FORMAT(date_sub(curdate(), interval 12 month),'%Y-%m' |
| | | ) GROUP BY filed |
| | | UNION ALL |
| | | SELECT DATE_FORMAT( create_at, '%Y-%m' ) AS filed, COUNT(1) AS num |
| | | FROM com_act_easy_photo_handler t1 |
| | | INNER JOIN com_act_micro_wish t2 ON t1.service_id = t2.id |
| | | WHERE t1.community_id = #{communityId} AND t1.`type` = 5 AND t1.service_type = 2 AND t2.`status` = 6 AND DATE_FORMAT( create_at, '%Y-%m' ) > DATE_FORMAT(date_sub(curdate(), interval 12 month),'%Y-%m' |
| | | ) GROUP BY filed |
| | | UNION ALL SELECT * FROM |
| | | ( |
| | | SELECT DATE_FORMAT(curdate(),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 1 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 2 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 3 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 4 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 5 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 6 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 7 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 8 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 9 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 10 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 11 month),'%Y-%m') AS filed, 0 AS num |
| | | ) temT |
| | | ) temp GROUP BY filed ORDER BY filed ASC |
| | | </select> |
| | | <select id="retrieveJJWTTotalPolylineData" |
| | | resultType="com.panzhihua.common.model.vos.community.StatisticsCommVO"> |
| | | SELECT |
| | | (SELECT COUNT(1) AS num |
| | | FROM com_act_easy_photo_handler t1 |
| | | INNER JOIN com_act_easy_photo t2 ON t1.service_id = t2.id |
| | | WHERE t1.community_id = #{communityId} AND t1.`type` = 5 |
| | | AND t1.service_type = 1 AND t2.`status` = 5 AND DATE_FORMAT( t2.create_at, '%Y-%m' ) <= #{date} |
| | | ) |
| | | + |
| | | (SELECT COUNT(1) AS num |
| | | FROM com_act_easy_photo_handler t1 |
| | | INNER JOIN com_act_micro_wish t2 ON t1.service_id = t2.id |
| | | WHERE t1.community_id = #{communityId} AND t1.`type` = 5 |
| | | AND t1.service_type = 2 AND t2.`status` = 6 AND DATE_FORMAT( t2.create_at, '%Y-%m' ) <= #{date} |
| | | ) AS num |
| | | </select> |
| | | |
| | | </mapper> |
| | |
| | | FROM com_act_micro_wish |
| | | WHERE community_id = ${pageBaseDTO.communityId} AND `status` NOT IN(1,4) ORDER BY create_at DESC |
| | | </select> |
| | | <select id="pagePartyBuildIngMicroWish" |
| | | resultType="com.panzhihua.common.model.vos.community.ComActMicroWishVO"> |
| | | SELECT t2.id, t2.photo_path_list |
| | | FROM com_act_easy_photo_handler t1 |
| | | INNER JOIN com_act_micro_wish t2 ON t1.service_id = t2.id |
| | | WHERE t1.community_id = #{pageBaseDTO.communityId} AND t1.`type` = 2 AND t1.service_type = 2 AND t2.`status` = 6 AND t2.photo_path_list IS NOT NULL |
| | | </select> |
| | | <select id="pageFourMemberResolve" resultType="com.panzhihua.common.model.vos.community.ComActMicroWishVO"> |
| | | SELECT * FROM( |
| | | SELECT t2.id, t2.photo_path_list |
| | | FROM com_act_easy_photo_handler t1 |
| | | INNER JOIN com_act_micro_wish t2 ON t1.service_id = t2.id |
| | | WHERE t1.community_id = #{pageBaseDTO.communityId} AND t1.`type` = 5 AND t1.service_type = 2 AND t2.`status` = 6 AND t2.photo_path_list IS NOT NULL |
| | | UNION ALL |
| | | SELECT t2.id, t2.photo_path_list |
| | | FROM com_act_easy_photo_handler t1 |
| | | INNER JOIN com_act_easy_photo t2 ON t1.service_id = t2.id |
| | | WHERE t1.community_id = #{pageBaseDTO.communityId} AND t1.`type` = 5 AND t1.service_type = 1 AND t2.`status` = 5 AND t2.photo_path_list IS NOT NULL |
| | | ) temp |
| | | </select> |
| | | |
| | | </mapper> |
| | |
| | | </if> |
| | | ORDER BY t1.created_at DESC |
| | | </select> |
| | | <select id="getFmsBaseData" |
| | | resultType="com.panzhihua.common.model.vos.community.bigscreen.BigScreenFmsStatisticsInfo"> |
| | | SELECT |
| | | (SELECT COUNT(id) FROM com_fms_team WHERE community_id = #{communityId}) AS teamTotal, |
| | | (SELECT COUNT(id) FROM com_fms_team_member WHERE community_id = #{communityId}) AS memberTotal, |
| | | (SELECT COUNT(id) FROM com_fms_service WHERE community_id = #{communityId}) AS serviceTotal, |
| | | (SELECT COUNT(id) FROM com_fms_service WHERE community_id = #{communityId} AND service_status = 4) AS completeServiceTotal, |
| | | (SELECT COUNT(id) FROM com_fms_classroom WHERE community_id = #{communityId}) AS classroomTotal, |
| | | (SELECT COUNT(e.id) FROM `event` AS e LEFT JOIN event_grid_data AS egd ON egd.id = e.grid_id |
| | | WHERE e.event_category = 1 AND e.event_status = 2 AND e.event_process_status = 2 AND egd.grid_community_id = #{communityId} AND e.event_type = 3) AS adjustTotal, |
| | | (SELECT COUNT(e.id) FROM `event` AS e LEFT JOIN event_grid_data AS egd ON egd.id = e.grid_id |
| | | WHERE e.event_category = 1 AND e.event_status = 2 AND e.event_process_status IN(1,2) AND egd.grid_community_id = #{communityId} AND e.event_type = 1) AS controlTotal, |
| | | (SELECT IF(SUM(scholars) IS NULL,0,SUM(scholars)) FROM com_fms_classroom WHERE community_id = #{communityId}) AS learnTotal, |
| | | (SELECT COUNT(e.id) FROM `event` AS e LEFT JOIN event_grid_data AS egd ON egd.id = e.grid_id |
| | | WHERE e.event_category = 1 AND e.event_status = 2 AND e.event_process_status IN(1,2) AND egd.grid_community_id = #{communityId} AND e.event_type = 1 AND e.danger_level > 0) AS fxyhTotal, |
| | | (SELECT COUNT(e.id) FROM `event` AS e LEFT JOIN event_grid_data AS egd ON egd.id = e.grid_id |
| | | WHERE e.event_category = 1 AND e.event_status = 2 AND e.event_process_status = 2 AND egd.grid_community_id = #{communityId} AND e.event_type = 1 AND e.danger_level > 0) AS jjyhTotal |
| | | </select> |
| | | <select id="retrieveTeamTypeCircleData" |
| | | resultType="com.panzhihua.common.model.vos.community.fms.ComFmsTeamVO"> |
| | | SELECT |
| | | t1.id, |
| | | t1.`name`, |
| | | t2.`name` AS teamTypeName |
| | | FROM |
| | | com_fms_team t1 |
| | | LEFT JOIN com_fms_team_type t2 ON t1.team_type = t2.id |
| | | WHERE |
| | | t1.community_id = #{communityId} |
| | | </select> |
| | | <select id="retrieveServiceAddPolylineData" |
| | | resultType="com.panzhihua.common.model.vos.community.StatisticsCommVO"> |
| | | SELECT filed, SUM(num) AS num FROM ( |
| | | SELECT DATE_FORMAT( created_at, '%Y-%m' ) AS filed, COUNT(1) AS num |
| | | FROM com_fms_service |
| | | WHERE community_id = #{communityId} AND DATE_FORMAT( created_at, '%Y-%m' ) > DATE_FORMAT(date_sub(curdate(), interval 12 month),'%Y-%m' |
| | | ) GROUP BY filed |
| | | UNION ALL SELECT * FROM |
| | | ( |
| | | SELECT DATE_FORMAT(curdate(),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 1 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 2 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 3 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 4 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 5 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 6 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 7 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 8 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 9 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 10 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 11 month),'%Y-%m') AS filed, 0 AS num |
| | | ) temT |
| | | ) temp GROUP BY filed ORDER BY filed ASC |
| | | </select> |
| | | <select id="retrieveServiceTotalPolylineData" |
| | | resultType="com.panzhihua.common.model.vos.community.StatisticsCommVO"> |
| | | SELECT |
| | | COUNT( 1 ) AS num |
| | | FROM |
| | | com_fms_service |
| | | WHERE |
| | | community_id = #{communityId} |
| | | AND DATE_FORMAT( created_at, '%Y-%m' ) <= #{date} |
| | | </select> |
| | | <select id="retrieveAdjustCircleData" resultType="com.panzhihua.common.model.vos.grid.EventVO"> |
| | | SELECT |
| | | e.id, |
| | | substring_index( substring_index( e.event_clazz, ',', b.help_topic_id + 1 ), ',',- 1 ) AS event_clazz |
| | | FROM |
| | | `event` AS e |
| | | LEFT JOIN event_grid_data AS egd ON egd.id = e.grid_id |
| | | JOIN mysql.help_topic b ON b.help_topic_id < ( length( e.event_clazz ) - length( REPLACE ( e.event_clazz, ',', '' ))+ 1 ) |
| | | WHERE |
| | | e.event_category = 1 |
| | | AND e.event_status = 2 |
| | | AND e.event_process_status = 2 |
| | | AND egd.grid_community_id = #{communityId} |
| | | AND e.event_type = 3 |
| | | </select> |
| | | <select id="retrieveAdjustAddPolylineData" |
| | | resultType="com.panzhihua.common.model.vos.community.StatisticsCommVO"> |
| | | SELECT filed, SUM(num) AS num FROM ( |
| | | SELECT DATE_FORMAT( e.create_at, '%Y-%m' ) AS filed, COUNT(1) AS num |
| | | FROM `event` AS e |
| | | LEFT JOIN event_grid_data AS egd ON egd.id = e.grid_id |
| | | WHERE e.event_category = 1 |
| | | AND e.event_status = 2 |
| | | AND e.event_process_status = 2 |
| | | AND egd.grid_community_id = #{communityId} |
| | | AND e.event_type = 3 AND DATE_FORMAT( e.create_at, '%Y-%m' ) > DATE_FORMAT(date_sub(curdate(), interval 12 month),'%Y-%m' |
| | | ) GROUP BY filed |
| | | UNION ALL SELECT * FROM |
| | | ( |
| | | SELECT DATE_FORMAT(curdate(),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 1 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 2 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 3 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 4 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 5 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 6 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 7 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 8 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 9 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 10 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 11 month),'%Y-%m') AS filed, 0 AS num |
| | | ) temT |
| | | ) temp GROUP BY filed ORDER BY filed ASC |
| | | </select> |
| | | <select id="retrieveAdjustTotalPolylineData" |
| | | resultType="com.panzhihua.common.model.vos.community.StatisticsCommVO"> |
| | | SELECT |
| | | COUNT( e.id ) AS num |
| | | FROM `event` AS e |
| | | LEFT JOIN event_grid_data AS egd ON egd.id = e.grid_id |
| | | WHERE e.event_category = 1 |
| | | AND e.event_status = 2 |
| | | AND e.event_process_status = 2 |
| | | AND egd.grid_community_id = #{communityId} |
| | | AND e.event_type = 3 |
| | | AND DATE_FORMAT( e.create_at, '%Y-%m' ) <= #{date} |
| | | </select> |
| | | <select id="retrieveControlCircleData" resultType="com.panzhihua.common.model.vos.grid.EventVO"> |
| | | SELECT |
| | | e.id, |
| | | substring_index( substring_index( e.event_clazz, ',', b.help_topic_id + 1 ), ',',- 1 ) AS event_clazz |
| | | FROM |
| | | `event` AS e |
| | | LEFT JOIN event_grid_data AS egd ON egd.id = e.grid_id |
| | | JOIN mysql.help_topic b ON b.help_topic_id < ( length( e.event_clazz ) - length( REPLACE ( e.event_clazz, ',', '' ))+ 1 ) |
| | | WHERE |
| | | e.event_category = 1 |
| | | AND e.event_status = 2 |
| | | AND e.event_process_status = 2 |
| | | AND egd.grid_community_id = #{communityId} |
| | | AND e.event_type = 1 |
| | | </select> |
| | | <select id="pageFmsTeam" resultType="com.panzhihua.common.model.vos.community.fms.ComFmsTeamVO"> |
| | | SELECT |
| | | t1.id, |
| | | t1.`name`, |
| | | t2.`name` AS teamTypeName, |
| | | COUNT(t3.team_id) AS teamMemberTotal |
| | | FROM com_fms_team t1 |
| | | LEFT JOIN com_fms_team_type t2 ON t1.team_type = t2.id |
| | | LEFT JOIN com_fms_team_member_relation t3 ON t1.id = t3.team_id |
| | | WHERE t1.community_id = #{pageBaseDTO.communityId} |
| | | GROUP BY t1.id |
| | | </select> |
| | | |
| | | </mapper> |
| | | |
| | |
| | | integral DESC, |
| | | cmvm.create_at DESC |
| | | </select> |
| | | <select id="retrieveVolunteerOrgHistogram" |
| | | resultType="com.panzhihua.common.model.vos.community.StatisticsCommVO"> |
| | | SELECT |
| | | t2.`name` AS filed, |
| | | COUNT( 1 ) AS num |
| | | FROM |
| | | com_mng_volunteer_mng t1 |
| | | JOIN com_mng_volunteer_org_team t2 ON t1.org_id = t2.id |
| | | WHERE |
| | | t1.community_id = #{communityId} |
| | | GROUP BY |
| | | filed |
| | | </select> |
| | | <select id="getVolunteerBaseData" |
| | | resultType="com.panzhihua.common.model.vos.community.bigscreen.BigScreenVolunteerStatisticsInfo"> |
| | | SELECT |
| | | (SELECT COUNT(id) FROM com_mng_volunteer_mng WHERE community_id = #{communityId} AND state = 2) AS volunteerNum, |
| | | (SELECT COUNT(id) FROM com_mng_volunteer_org_team WHERE community_id = #{communityId} AND parent_id = 0) AS volunteerOrgNum, |
| | | (SELECT COUNT(id) FROM com_mng_volunteer_org_team WHERE community_id = #{communityId} AND parent_id != 0) AS volunteerTeamNum |
| | | </select> |
| | | <select id="retrieveVolunteerServiceTypeCircleData" |
| | | resultType="com.panzhihua.common.model.vos.community.ComMngVolunteerMngVO"> |
| | | SELECT t1.id, t3.`name` AS serviceTypeName |
| | | FROM com_mng_volunteer_mng t1 |
| | | JOIN com_mng_volunteer_org_team t2 ON t1.team_id = t2.id |
| | | LEFT JOIN com_mng_volunteer_service_type t3 ON t2.service_type_id = t3.id |
| | | WHERE t1.community_id = #{communityId} AND t1.state = 2 |
| | | </select> |
| | | <select id="retrieveVolunteerAgeCircleData" |
| | | resultType="com.panzhihua.common.model.vos.community.StatisticsCommVO"> |
| | | SELECT filed, SUM(num) AS num FROM ( |
| | | SELECT filed, COUNT(filed) AS num FROM ( |
| | | SELECT |
| | | CASE |
| | | WHEN TIMESTAMPDIFF(YEAR, SUBSTRING(id_card, 7, 8), NOW()) BETWEEN 0 AND 18 THEN '0-18岁' |
| | | WHEN TIMESTAMPDIFF(YEAR, SUBSTRING(id_card, 7, 8), NOW()) BETWEEN 19 AND 30 THEN '19-30岁' |
| | | WHEN TIMESTAMPDIFF(YEAR, SUBSTRING(id_card, 7, 8), NOW()) BETWEEN 31 AND 40 THEN '31-40岁' |
| | | WHEN TIMESTAMPDIFF(YEAR, SUBSTRING(id_card, 7, 8), NOW()) BETWEEN 41 AND 50 THEN '41-50岁' |
| | | WHEN TIMESTAMPDIFF(YEAR, SUBSTRING(id_card, 7, 8), NOW()) BETWEEN 51 AND 60 THEN '51-60岁' |
| | | WHEN TIMESTAMPDIFF(YEAR, SUBSTRING(id_card, 7, 8), NOW()) BETWEEN 61 AND 79 THEN '61-79岁' |
| | | WHEN TIMESTAMPDIFF(YEAR, SUBSTRING(id_card, 7, 8), NOW()) BETWEEN 80 AND 89 THEN '80-89岁' |
| | | WHEN TIMESTAMPDIFF(YEAR, SUBSTRING(id_card, 7, 8), NOW()) > 89 THEN '89岁以上' |
| | | END filed |
| | | FROM com_mng_volunteer_mng WHERE community_id = #{communityId} |
| | | ) temp WHERE filed is not null GROUP BY filed |
| | | UNION ALL |
| | | (SELECT '0-18岁' AS filed, 0 AS num) |
| | | UNION ALL |
| | | (SELECT '19-30岁' AS filed, 0 AS num) |
| | | UNION ALL |
| | | (SELECT '31-40岁' AS filed, 0 AS num) |
| | | UNION ALL |
| | | (SELECT '41-50岁' AS filed, 0 AS num) |
| | | UNION ALL |
| | | (SELECT '51-60岁' AS filed, 0 AS num) |
| | | UNION ALL |
| | | (SELECT '61-79岁' AS filed, 0 AS num) |
| | | UNION ALL |
| | | (SELECT '80-89岁' AS filed, 0 AS num) |
| | | UNION ALL |
| | | (SELECT '89岁以上' AS filed, 0 AS num) |
| | | ) t GROUP BY filed |
| | | </select> |
| | | <select id="retrieveVolunteerSkillCircleData" |
| | | resultType="com.panzhihua.common.model.vos.community.ComMngVolunteerMngVO"> |
| | | SELECT t1.id, t2.`name` AS skillName |
| | | FROM com_mng_volunteer_mng t1 |
| | | JOIN com_mng_volunteer_skill t2 ON t1.skill_id = t2.id |
| | | WHERE t1.community_id = #{communityId} AND t1.state = 2 |
| | | </select> |
| | | <select id="selectVolunteerByCommunityId" |
| | | resultType="com.panzhihua.common.model.vos.community.ComMngVolunteerMngVO"> |
| | | SELECT t1.id, t1.`name`, t1.photo_path, t2.`name` AS teamName, t3.`name` AS orgName |
| | | FROM com_mng_volunteer_mng t1 |
| | | INNER JOIN com_mng_volunteer_org_team t2 ON t1.team_id = t2.id |
| | | INNER JOIN com_mng_volunteer_org_team t3 ON t1.org_id = t2.id |
| | | WHERE t1.community_id = #{communityId} |
| | | </select> |
| | | |
| | | </mapper> |
| | |
| | | FROM com_act_easy_photo WHERE community_id = ${communityId} AND `status` IN (1,2,4) AND del_tag = 0 AND classify_id IN (1,3,4,5,6,7,8) AND DATE_FORMAT( create_at, '%Y-%m' ) <= #{date} |
| | | ) temp |
| | | </select> |
| | | <select id="getAlarmBaseData" |
| | | resultType="com.panzhihua.common.model.vos.community.bigscreen.BigScreenAlarmStatisticsInfo"> |
| | | SELECT |
| | | (SELECT COUNT(id) FROM com_property_equipment WHERE community_id = #{communityId} AND `type` = 1) AS abnormalAlarmTotal, |
| | | (SELECT COUNT(id) FROM com_property_equipment WHERE community_id = #{communityId} AND `type` = 2) AS oneKeyAlarmTotal, |
| | | (SELECT COUNT(t1.id) FROM com_property_alarm t1 LEFT JOIN com_property_equipment t2 ON t1.serial_no = t2.serial_no |
| | | WHERE t2.community_id = #{communityId} AND t2.`type` = 1) AS abnormalTotal, |
| | | (SELECT COUNT(t1.id) FROM com_property_alarm t1 LEFT JOIN com_property_equipment t2 ON t1.serial_no = t2.serial_no |
| | | WHERE t2.community_id = #{communityId} AND t2.`type` = 2) AS oneKeyTotal, |
| | | (SELECT COUNT(t1.id) FROM com_property_alarm t1 LEFT JOIN com_property_equipment t2 ON t1.serial_no = t2.serial_no |
| | | WHERE t2.community_id = #{communityId} AND t1.`status` = 0 AND t1.`type` = 2) AS pendingAbnormalTotal, |
| | | (SELECT COUNT(t1.id) FROM com_property_alarm t1 LEFT JOIN com_property_equipment t2 ON t1.serial_no = t2.serial_no |
| | | WHERE t2.community_id = #{communityId} AND t1.`status` = 1 AND t1.`type` = 2) AS completeAbnormalTotal, |
| | | (SELECT COUNT(t1.id) FROM com_property_alarm t1 LEFT JOIN com_property_equipment t2 ON t1.serial_no = t2.serial_no |
| | | WHERE t2.community_id = #{communityId} AND t1.`status` = 0 AND t1.`type` = 1) AS pendingServiceTotal, |
| | | (SELECT COUNT(t1.id) FROM com_property_alarm t1 LEFT JOIN com_property_equipment t2 ON t1.serial_no = t2.serial_no |
| | | WHERE t2.community_id = #{communityId} AND t1.`status` = 1 AND t1.`type` = 1) AS completeServiceTotal |
| | | </select> |
| | | <select id="retrieveAbnormalAddPolylineData" |
| | | resultType="com.panzhihua.common.model.vos.community.StatisticsCommVO"> |
| | | SELECT filed, SUM(num) AS num FROM ( |
| | | SELECT DATE_FORMAT( t.create_time, '%Y-%m' ) AS filed, COUNT(1) AS num |
| | | FROM com_property_alarm t |
| | | LEFT JOIN com_property_equipment t1 ON t.serial_no = t1.serial_no |
| | | WHERE t1.community_id = #{communityId} AND t.`type` = 2 AND DATE_FORMAT( t.create_time, '%Y-%m' ) > DATE_FORMAT(date_sub(curdate(), interval 12 month),'%Y-%m' |
| | | ) GROUP BY filed |
| | | UNION ALL SELECT * FROM |
| | | ( |
| | | SELECT DATE_FORMAT(curdate(),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 1 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 2 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 3 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 4 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 5 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 6 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 7 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 8 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 9 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 10 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 11 month),'%Y-%m') AS filed, 0 AS num |
| | | ) temT |
| | | ) temp GROUP BY filed ORDER BY filed ASC |
| | | </select> |
| | | <select id="retrieveAbnormalTotalPolylineData" |
| | | resultType="com.panzhihua.common.model.vos.community.StatisticsCommVO"> |
| | | SELECT COUNT( 1 ) AS num |
| | | FROM com_property_alarm t |
| | | LEFT JOIN com_property_equipment t1 ON t.serial_no = t1.serial_no |
| | | WHERE t1.community_id = #{communityId} AND t.`type` = 2 AND DATE_FORMAT( t.create_time, '%Y-%m' ) <= #{date} |
| | | </select> |
| | | <select id="retrieveServiceAddPolylineData" |
| | | resultType="com.panzhihua.common.model.vos.community.StatisticsCommVO"> |
| | | SELECT filed, SUM(num) AS num FROM ( |
| | | SELECT DATE_FORMAT( t.create_time, '%Y-%m' ) AS filed, COUNT(1) AS num |
| | | FROM com_property_alarm t |
| | | LEFT JOIN com_property_equipment t1 ON t.serial_no = t1.serial_no |
| | | WHERE t1.community_id = #{communityId} AND t.`type` = 1 AND DATE_FORMAT( t.create_time, '%Y-%m' ) > DATE_FORMAT(date_sub(curdate(), interval 12 month),'%Y-%m' |
| | | ) GROUP BY filed |
| | | UNION ALL SELECT * FROM |
| | | ( |
| | | SELECT DATE_FORMAT(curdate(),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 1 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 2 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 3 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 4 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 5 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 6 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 7 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 8 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 9 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 10 month),'%Y-%m') AS filed, 0 AS num union |
| | | SELECT DATE_FORMAT(date_sub(curdate(), interval 11 month),'%Y-%m') AS filed, 0 AS num |
| | | ) temT |
| | | ) temp GROUP BY filed ORDER BY filed ASC |
| | | </select> |
| | | <select id="retrieveServiceTotalPolylineData" |
| | | resultType="com.panzhihua.common.model.vos.community.StatisticsCommVO"> |
| | | SELECT COUNT( 1 ) AS num |
| | | FROM com_property_alarm t |
| | | LEFT JOIN com_property_equipment t1 ON t.serial_no = t1.serial_no |
| | | WHERE t1.community_id = #{communityId} AND t.`type` = 1 AND DATE_FORMAT( t.create_time, '%Y-%m' ) <= #{date} |
| | | </select> |
| | | <select id="getAbnormalList" resultType="com.panzhihua.common.model.vos.property.ComPropertyAlarmVO"> |
| | | SELECT |
| | | t.id, |
| | | t.create_time, |
| | | t1.phone, |
| | | t1.username AS NAME, |
| | | t3.address AS position |
| | | FROM |
| | | com_property_alarm t |
| | | LEFT JOIN com_property_equipment t1 ON t.serial_no = t1.serial_no |
| | | LEFT JOIN com_mng_population_house t3 ON t1.village_id = t3.id |
| | | WHERE t1.community_id = #{communityId} AND t.`type` = #{type} AND t.`status` = #{status} |
| | | ORDER BY t.create_time DESC |
| | | </select> |
| | | <select id="getAlarmPointMapData" |
| | | resultType="com.panzhihua.common.model.vos.property.ComPropertyEquipmentVO"> |
| | | SELECT |
| | | id, |
| | | phone, |
| | | username, |
| | | latitude, |
| | | longitude, |
| | | `type`, |
| | | `position`, |
| | | CASE `type` |
| | | WHEN 1 THEN 2 |
| | | WHEN 2 THEN 1 |
| | | END AS equipmentStatus |
| | | FROM com_property_equipment |
| | | WHERE serial_no IN( |
| | | SELECT DISTINCT(t1.serial_no) |
| | | FROM com_property_alarm t1 |
| | | LEFT JOIN com_property_equipment t2 ON t1.serial_no = t2.serial_no |
| | | WHERE t2.community_id = #{communityId} AND t1.`status` = 0 |
| | | ) |
| | | UNION ALL |
| | | SELECT |
| | | id, |
| | | phone, |
| | | username, |
| | | latitude, |
| | | longitude, |
| | | `type`, |
| | | `position`, |
| | | 3 AS equipmentStatus |
| | | FROM com_property_equipment |
| | | WHERE serial_no NOT IN( |
| | | SELECT DISTINCT(t1.serial_no) |
| | | FROM com_property_alarm t1 |
| | | LEFT JOIN com_property_equipment t2 ON t1.serial_no = t2.serial_no |
| | | WHERE t2.community_id = #{communityId} AND t1.`status` = 0 |
| | | ) |
| | | </select> |
| | | |
| | | </mapper> |