Browse Source

运维概览:统计图数据、系统消息数据

zhj 2 năm trước cách đây
mục cha
commit
334816ec3a
28 tập tin đã thay đổi với 842 bổ sung0 xóa
  1. 26 0
      src/main/java/com/welampiot/controller/DataController.java
  2. 115 0
      src/main/java/com/welampiot/controller/WorkManageController.java
  3. 5 0
      src/main/java/com/welampiot/dao/AllAlarmInfoLogDao.java
  4. 10 0
      src/main/java/com/welampiot/dao/DefectManageDao.java
  5. 11 0
      src/main/java/com/welampiot/dao/PatrolTaskDao.java
  6. 20 0
      src/main/java/com/welampiot/dao/ProReviewerDao.java
  7. 6 0
      src/main/java/com/welampiot/dao/RepairProjectDao.java
  8. 10 0
      src/main/java/com/welampiot/dao/WorkManageDao.java
  9. 31 0
      src/main/java/com/welampiot/dto/ProReviewerDTO.java
  10. 5 0
      src/main/java/com/welampiot/service/AllAlarmInfoLogService.java
  11. 10 0
      src/main/java/com/welampiot/service/DefectManageService.java
  12. 11 0
      src/main/java/com/welampiot/service/PatrolTaskService.java
  13. 18 0
      src/main/java/com/welampiot/service/ProReviewerService.java
  14. 6 0
      src/main/java/com/welampiot/service/RepairProjectService.java
  15. 10 0
      src/main/java/com/welampiot/service/WorkManageService.java
  16. 15 0
      src/main/java/com/welampiot/service/impl/AllAlarmInfoLogServiceImpl.java
  17. 25 0
      src/main/java/com/welampiot/service/impl/DefectManageServiceImpl.java
  18. 26 0
      src/main/java/com/welampiot/service/impl/PatrolTaskServiceImpl.java
  19. 36 0
      src/main/java/com/welampiot/service/impl/ProReviewerServiceImpl.java
  20. 15 0
      src/main/java/com/welampiot/service/impl/RepairProjectServiceImpl.java
  21. 25 0
      src/main/java/com/welampiot/service/impl/WorkManageServiceImpl.java
  22. 24 0
      src/main/java/com/welampiot/vo/OperationDataVO.java
  23. 51 0
      src/main/resources/mapper/AllAlarmInfoLogMapper.xml
  24. 85 0
      src/main/resources/mapper/DefectManageMapper.xml
  25. 85 0
      src/main/resources/mapper/PatrolTaskMapper.xml
  26. 25 0
      src/main/resources/mapper/ProReviewerMapper.xml
  27. 51 0
      src/main/resources/mapper/RepairProjectMapper.xml
  28. 85 0
      src/main/resources/mapper/WorkManageMapper.xml

+ 26 - 0
src/main/java/com/welampiot/controller/DataController.java

@@ -1,6 +1,7 @@
 package com.welampiot.controller;
 
 import com.welampiot.common.BaseResult;
+import com.welampiot.common.InterfaceResultEnum;
 import com.welampiot.dto.*;
 import com.welampiot.service.*;
 import com.welampiot.utils.ToolUtils;
@@ -40,6 +41,10 @@ public class DataController {
     private UserService userService;
     @Autowired
     private OperationLogService operationLogService;
+    @Autowired
+    private ProReviewerService proReviewerService;
+    @Autowired
+    private RepairPersonnelService repairPersonnelService;
     @RequestMapping(value = "/info",method = RequestMethod.POST)
     public BaseResult<InfoResponseVO> info(HttpServletRequest request){
         Integer version = request.getParameter("version") == null ? 0 : Integer.parseInt(request.getParameter("version"));
@@ -183,4 +188,25 @@ public class DataController {
         }
         return BaseResult.success(data);
     }
+
+    /**
+     * 系统消息统计
+     * @param request 用户名
+     * @return 已读未读消息数
+     */
+    @RequestMapping(value = "/getSysInfoCount", method = RequestMethod.POST)
+    public BaseResult<?> getSysInfoCount(HttpServletRequest request) {
+        Integer version = (Integer) toolUtils.getRequestContent(request,"version",1);
+        String username = (String) toolUtils.getRequestContent(request,"username",2);
+        if (username.length() == 0) return toolUtils.response(InterfaceResultEnum.LACK_PARAM_ERROR,version);
+        Integer userid = repairPersonnelService.getUserIdByUsername(username);
+        Integer sysInfoUnReadCount = proReviewerService.getSysInfoUnReadCount(userid);
+        Integer sysInfoReadCount = proReviewerService.getSysInfoReadCount(userid);
+        Integer sysInfoCount = proReviewerService.getSysInfoCount(userid);
+        OperationDataVO operationDataVO = new OperationDataVO();
+        operationDataVO.setData1(sysInfoUnReadCount);
+        operationDataVO.setData2(sysInfoReadCount);
+        operationDataVO.setData(sysInfoCount);
+        return toolUtils.response(InterfaceResultEnum.OPERATION_SUCCESS,version,operationDataVO);
+    }
 }

+ 115 - 0
src/main/java/com/welampiot/controller/WorkManageController.java

@@ -61,6 +61,9 @@ public class WorkManageController {
     @Autowired
     private DefectManageService defectManageService;
 
+    @Autowired
+    private PatrolTaskService patrolTaskService;
+
     @Autowired
     private PatrolManageService patrolManageService;
 
@@ -709,4 +712,116 @@ public class WorkManageController {
         vo.setDataList(dataList);
         return toolUtils.response(InterfaceResultEnum.OPERATION_SUCCESS,version,vo);
     }
+
+    /**
+     * 统计图数据
+     * @param request 时间筛选,类型筛选
+     * @return 统计图数据
+     */
+    @RequestMapping(value = "/operationDataDetails", method = RequestMethod.POST)
+    public BaseResult<?> operationDataDetails(HttpServletRequest request) throws ParseException {
+        Integer version = (Integer) toolUtils.getRequestContent(request, "version", 1);
+        Integer dateType = (Integer) toolUtils.getRequestContent(request, "dateType", 1);
+        Integer mode = (Integer) toolUtils.getRequestContent(request, "mode", 1);
+
+        long l = System.currentTimeMillis();
+        Date date1 = new Date(l);
+        Calendar calendar = Calendar.getInstance();
+        calendar.setTime(date1);
+        int year = calendar.get(Calendar.YEAR); // 获取年份
+        int month = calendar.get(Calendar.MONTH) + 1; // 获取月份
+        long startTime, endTime;
+        String startDate = "";
+        SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd");
+        String endDate = simpleDateFormat.format(l);
+        if (dateType == 0) { // 当月
+            if (month < 10) {
+                startDate = year + "-0" + month + "-01";
+            } else {
+                startDate = year + "-" + month + "-01";
+            }
+        } else if (dateType == 1) { // 当年
+            month = 1;
+            startDate = year + "-0" + month + "-01";
+            endDate = simpleDateFormat.format(l);
+        } else if (dateType == 2) { // 全部
+            endDate = simpleDateFormat.format(l);
+        } else if (dateType == 3) { // 具体月份
+            String date = (String) toolUtils.getRequestContent(request, "date", 2);
+            if (date.length() == 0) return toolUtils.response(InterfaceResultEnum.LACK_DATE_ERROR, version);
+            List<String> list = Arrays.asList(date.split("-"));
+            int yearNum = Integer.parseInt(list.get(0));
+            int monthNum = Integer.parseInt(list.get(1));
+            int daysInMonth = YearMonth.of(yearNum, monthNum).lengthOfMonth();
+            if (yearNum == year && monthNum == month) {
+                if (month < 10) {
+                    startDate = year + "-" + "0" + month + "-01";
+                } else {
+                    startDate = year + "-" + month + "-01";
+                }
+            } else if ((yearNum == year && monthNum > month) || (yearNum > year)) {
+                return toolUtils.response(InterfaceResultEnum.DATE_CHOOSE_ERROR, version);
+            } else {
+                startTime = simpleDateFormat.parse(date + "-01").getTime();
+                endTime = simpleDateFormat.parse(date + "-" + daysInMonth).getTime();
+                startDate = simpleDateFormat.format(startTime);
+                endDate = simpleDateFormat.format(endTime);
+            }
+        }
+
+        OperationVO operationVO = new OperationVO();
+        operationVO.setStartDate(startDate);
+        operationVO.setEndDate(endDate);
+        operationVO.setSectionList(toolUtils.getSectionList(request));
+        OperationDataVO operationDataVO = new OperationDataVO();
+        if (mode == 4) { // 报警数据
+            Integer alarmUntreatedCount = allAlarmInfoLogService.getAlarmUntreatedCount(operationVO);
+            Integer alarmHandlingCount = allAlarmInfoLogService.getAlarmHandlingCount(operationVO);
+            Integer alarmHandledCount = allAlarmInfoLogService.getAlarmHandledCount(operationVO);
+            operationDataVO.setData1(alarmUntreatedCount);
+            operationDataVO.setData2(alarmHandlingCount);
+            operationDataVO.setData3(alarmHandledCount);
+        } else if (mode == 3) { // 维修项目数据
+            Integer projectNormalCount = repairProjectService.getProjectNormalCount(operationVO);
+            Integer projectAnticipateCount = repairProjectService.getProjectAnticipateCount(operationVO);
+            Integer projectCompleteCount = repairProjectService.getProjectCompleteCount(operationVO);
+            operationDataVO.setData1(projectNormalCount);
+            operationDataVO.setData2(projectAnticipateCount);
+            operationDataVO.setData3(projectCompleteCount);
+        } else if (mode == 2) { // 巡视数据
+            Integer patrolTaskUnStartCount = patrolTaskService.getPatrolTaskUnStartCount(operationVO);
+            Integer patrolTaskHandlingCount = patrolTaskService.getPatrolTaskHandlingCount(operationVO);
+            Integer patrolTaskEndCount = patrolTaskService.getPatrolTaskEndCount(operationVO);
+            Integer patrolCloseArchiveCount = patrolTaskService.getPatrolCloseArchiveCount(operationVO);
+            Integer patrolPostponeCount = patrolTaskService.getPatrolPostponeCount(operationVO);
+            operationDataVO.setData1(patrolTaskUnStartCount);
+            operationDataVO.setData2(patrolTaskHandlingCount);
+            operationDataVO.setData3(patrolTaskEndCount);
+            operationDataVO.setData4(patrolCloseArchiveCount);
+            operationDataVO.setData5(patrolPostponeCount);
+        } else if (mode == 1) { // 缺陷数据
+            Integer defectManageUndistributedCount = defectManageService.getDefectManageUndistributedCount(operationVO);
+            Integer defectManageHandlingCount = defectManageService.getDefectManageHandlingCount(operationVO);
+            Integer defectManageRecheckCount = defectManageService.getDefectManageRecheckCount(operationVO);
+            Integer defectManageCloseCaseCount = defectManageService.getDefectManageCloseCaseCount(operationVO);
+            Integer defectManageArchiveCount = defectManageService.getDefectManageArchiveCount(operationVO);
+            operationDataVO.setData1(defectManageUndistributedCount);
+            operationDataVO.setData2(defectManageHandlingCount);
+            operationDataVO.setData3(defectManageRecheckCount);
+            operationDataVO.setData4(defectManageCloseCaseCount);
+            operationDataVO.setData5(defectManageArchiveCount);
+        } else { // 工单数据
+            Integer workManageUndistributedCount = workManageService.getWorkManageUndistributedCount(operationVO);
+            Integer workManageHandlingCount = workManageService.getWorkManageHandlingCount(operationVO);
+            Integer workManageRecheckCount = workManageService.getWorkManageRecheckCount(operationVO);
+            Integer workManageCloseCaseCount = workManageService.getWorkManageCloseCaseCount(operationVO);
+            Integer workManageArchiveCount = workManageService.getWorkManageArchiveCount(operationVO);
+            operationDataVO.setData1(workManageUndistributedCount);
+            operationDataVO.setData2(workManageHandlingCount);
+            operationDataVO.setData3(workManageRecheckCount);
+            operationDataVO.setData4(workManageCloseCaseCount);
+            operationDataVO.setData5(workManageArchiveCount);
+        }
+        return toolUtils.response(InterfaceResultEnum.OPERATION_SUCCESS,version,operationDataVO);
+    }
 }

+ 5 - 0
src/main/java/com/welampiot/dao/AllAlarmInfoLogDao.java

@@ -23,4 +23,9 @@ public interface AllAlarmInfoLogDao {
     void updateAlarmStatus(AllAlarmInfoLogDTO dto);
     Integer getAllAlarmInfoLogCount(OperationVO vo);
     List<AllAlarmInfoLogDTO> getAllAlarmCountOnMonth(OperationVO vo);
+    Integer getAlarmUntreatedCount(OperationVO vo);
+
+    Integer getAlarmHandlingCount(OperationVO vo);
+
+    Integer getAlarmHandledCount(OperationVO vo);
 }

+ 10 - 0
src/main/java/com/welampiot/dao/DefectManageDao.java

@@ -44,4 +44,14 @@ public interface DefectManageDao {
     Integer getDefectManageCount(OperationVO vo);
 
     List<DefectManageDTO> getDefectManageCountOnMonth(OperationVO vo);
+
+    Integer getDefectManageUndistributedCount(OperationVO vo);
+
+    Integer getDefectManageHandlingCount(OperationVO vo);
+
+    Integer getDefectManageRecheckCount(OperationVO vo);
+
+    Integer getDefectManageCloseCaseCount(OperationVO vo);
+
+    Integer getDefectManageArchiveCount(OperationVO vo);
 }

+ 11 - 0
src/main/java/com/welampiot/dao/PatrolTaskDao.java

@@ -1,6 +1,7 @@
 package com.welampiot.dao;
 
 import com.welampiot.dto.PatrolTaskDTO;
+import com.welampiot.vo.OperationVO;
 import com.welampiot.vo.PatrolTaskVO;
 
 import java.util.List;
@@ -22,4 +23,14 @@ public interface PatrolTaskDao {
     void addPatrolTaskData(PatrolTaskDTO dto);
 
     void updatePatrolTaskStatus(PatrolTaskDTO dto);
+
+    Integer getPatrolTaskUnStartCount(OperationVO vo);
+
+    Integer getPatrolTaskHandlingCount(OperationVO vo);
+
+    Integer getPatrolTaskEndCount(OperationVO vo);
+
+    Integer getPatrolCloseArchiveCount(OperationVO vo);
+
+    Integer getPatrolPostponeCount(OperationVO vo);
 }

+ 20 - 0
src/main/java/com/welampiot/dao/ProReviewerDao.java

@@ -0,0 +1,20 @@
+package com.welampiot.dao;
+
+import org.apache.ibatis.annotations.Param;
+
+/**
+ * ClassName: ProReviewerDao
+ * Package: com.welampiot.dao
+ * Description:
+ *
+ * @Author: zhj_Start
+ * @Create: 2023/7/5 - 11:23
+ * @Version: v1.0
+ */
+public interface ProReviewerDao {
+    Integer getSysInfoUnReadCount(@Param("userid") Integer userid);
+
+    Integer getSysInfoReadCount(@Param("userid") Integer userid);
+
+    Integer getSysInfoCount(@Param("userid") Integer userid);
+}

+ 6 - 0
src/main/java/com/welampiot/dao/RepairProjectDao.java

@@ -35,4 +35,10 @@ public interface RepairProjectDao {
     Integer getRepairProjectCount(OperationVO vo);
 
     List<RepairProjectDTO> getRepairProjectCountOnMonth(OperationVO vo);
+
+    Integer getProjectNormalCount(OperationVO vo);
+
+    Integer getProjectAnticipateCount(OperationVO vo);
+
+    Integer getProjectCompleteCount(OperationVO vo);
 }

+ 10 - 0
src/main/java/com/welampiot/dao/WorkManageDao.java

@@ -44,4 +44,14 @@ public interface WorkManageDao {
     Integer getWorkManageCount(OperationVO vo);
 
     List<WorkManageDTO> getWorkManageCountOnMonth(OperationVO vo);
+
+    Integer getWorkManageUndistributedCount(OperationVO vo);
+
+    Integer getWorkManageHandlingCount(OperationVO vo);
+
+    Integer getWorkManageRecheckCount(OperationVO vo);
+
+    Integer getWorkManageCloseCaseCount(OperationVO vo);
+
+    Integer getWorkManageArchiveCount(OperationVO vo);
 }

+ 31 - 0
src/main/java/com/welampiot/dto/ProReviewerDTO.java

@@ -0,0 +1,31 @@
+package com.welampiot.dto;
+
+import lombok.Data;
+
+import java.io.Serializable;
+
+/**
+ * ClassName: ProReviewerDTO
+ * Package: com.welampiot.dto
+ * Description:
+ *
+ * @Author: zhj_Start
+ * @Create: 2023/7/5 - 11:11
+ * @Version: v1.0
+ */
+@Data
+public class ProReviewerDTO implements Serializable {
+    private Integer id;
+
+    private Integer reviewer; // 审核人
+
+    private Integer userid; // 提交人
+
+    private Integer proId; // 素材id
+
+    private Integer status; // 审核状态(0 初始,1 通过,2 未通过)
+
+    private String res; // 审核未通过原因
+
+    private Integer viewStatus; // 查看状态(0 未查看,1 已查看)
+}

+ 5 - 0
src/main/java/com/welampiot/service/AllAlarmInfoLogService.java

@@ -22,4 +22,9 @@ public interface AllAlarmInfoLogService {
     void updateAlarmStatus(AllAlarmInfoLogDTO dto);
     Integer getAllAlarmInfoLogCount(OperationVO vo);
     List<AllAlarmInfoLogDTO> getAllAlarmCountOnMonth(OperationVO vo);
+    Integer getAlarmUntreatedCount(OperationVO vo);
+
+    Integer getAlarmHandlingCount(OperationVO vo);
+
+    Integer getAlarmHandledCount(OperationVO vo);
 }

+ 10 - 0
src/main/java/com/welampiot/service/DefectManageService.java

@@ -43,4 +43,14 @@ public interface DefectManageService {
     Integer getDefectManageCount(OperationVO vo);
 
     List<DefectManageDTO> getDefectManageCountOnMonth(OperationVO vo);
+
+    Integer getDefectManageUndistributedCount(OperationVO vo);
+
+    Integer getDefectManageHandlingCount(OperationVO vo);
+
+    Integer getDefectManageRecheckCount(OperationVO vo);
+
+    Integer getDefectManageCloseCaseCount(OperationVO vo);
+
+    Integer getDefectManageArchiveCount(OperationVO vo);
 }

+ 11 - 0
src/main/java/com/welampiot/service/PatrolTaskService.java

@@ -1,6 +1,7 @@
 package com.welampiot.service;
 
 import com.welampiot.dto.PatrolTaskDTO;
+import com.welampiot.vo.OperationVO;
 import com.welampiot.vo.PatrolTaskVO;
 
 import java.util.List;
@@ -22,4 +23,14 @@ public interface PatrolTaskService {
     void addPatrolTaskData(PatrolTaskDTO dto);
 
     void updatePatrolTaskStatus(PatrolTaskDTO dto);
+
+    Integer getPatrolTaskUnStartCount(OperationVO vo);
+
+    Integer getPatrolTaskHandlingCount(OperationVO vo);
+
+    Integer getPatrolTaskEndCount(OperationVO vo);
+
+    Integer getPatrolCloseArchiveCount(OperationVO vo);
+
+    Integer getPatrolPostponeCount(OperationVO vo);
 }

+ 18 - 0
src/main/java/com/welampiot/service/ProReviewerService.java

@@ -0,0 +1,18 @@
+package com.welampiot.service;
+
+/**
+ * ClassName: ProReviewerService
+ * Package: com.welampiot.service
+ * Description:
+ *
+ * @Author: zhj_Start
+ * @Create: 2023/7/5 - 11:24
+ * @Version: v1.0
+ */
+public interface ProReviewerService {
+    Integer getSysInfoUnReadCount(Integer userid);
+
+    Integer getSysInfoReadCount(Integer userid);
+
+    Integer getSysInfoCount(Integer userid);
+}

+ 6 - 0
src/main/java/com/welampiot/service/RepairProjectService.java

@@ -35,4 +35,10 @@ public interface RepairProjectService {
     Integer getRepairProjectCount(OperationVO vo);
 
     List<RepairProjectDTO> getRepairProjectCountOnMonth(OperationVO vo);
+
+    Integer getProjectNormalCount(OperationVO vo);
+
+    Integer getProjectAnticipateCount(OperationVO vo);
+
+    Integer getProjectCompleteCount(OperationVO vo);
 }

+ 10 - 0
src/main/java/com/welampiot/service/WorkManageService.java

@@ -43,4 +43,14 @@ public interface WorkManageService {
     Integer getWorkManageCount(OperationVO vo);
 
     List<WorkManageDTO> getWorkManageCountOnMonth(OperationVO vo);
+
+    Integer getWorkManageUndistributedCount(OperationVO vo);
+
+    Integer getWorkManageHandlingCount(OperationVO vo);
+
+    Integer getWorkManageRecheckCount(OperationVO vo);
+
+    Integer getWorkManageCloseCaseCount(OperationVO vo);
+
+    Integer getWorkManageArchiveCount(OperationVO vo);
 }

+ 15 - 0
src/main/java/com/welampiot/service/impl/AllAlarmInfoLogServiceImpl.java

@@ -132,4 +132,19 @@ public class AllAlarmInfoLogServiceImpl implements AllAlarmInfoLogService {
     public List<AllAlarmInfoLogDTO> getAllAlarmCountOnMonth(OperationVO vo) {
         return allAlarmInfoLogDao.getAllAlarmCountOnMonth(vo);
     }
+
+    @Override
+    public Integer getAlarmUntreatedCount(OperationVO vo) {
+        return allAlarmInfoLogDao.getAlarmHandledCount(vo);
+    }
+
+    @Override
+    public Integer getAlarmHandlingCount(OperationVO vo) {
+        return allAlarmInfoLogDao.getAlarmHandlingCount(vo);
+    }
+
+    @Override
+    public Integer getAlarmHandledCount(OperationVO vo) {
+        return allAlarmInfoLogDao.getAlarmHandledCount(vo);
+    }
 }

+ 25 - 0
src/main/java/com/welampiot/service/impl/DefectManageServiceImpl.java

@@ -93,4 +93,29 @@ public class DefectManageServiceImpl implements DefectManageService {
     public List<DefectManageDTO> getDefectManageCountOnMonth(OperationVO vo) {
         return defectManageDao.getDefectManageCountOnMonth(vo);
     }
+
+    @Override
+    public Integer getDefectManageUndistributedCount(OperationVO vo) {
+        return defectManageDao.getDefectManageUndistributedCount(vo);
+    }
+
+    @Override
+    public Integer getDefectManageHandlingCount(OperationVO vo) {
+        return defectManageDao.getDefectManageHandlingCount(vo);
+    }
+
+    @Override
+    public Integer getDefectManageRecheckCount(OperationVO vo) {
+        return defectManageDao.getDefectManageRecheckCount(vo);
+    }
+
+    @Override
+    public Integer getDefectManageCloseCaseCount(OperationVO vo) {
+        return defectManageDao.getDefectManageCloseCaseCount(vo);
+    }
+
+    @Override
+    public Integer getDefectManageArchiveCount(OperationVO vo) {
+        return defectManageDao.getDefectManageArchiveCount(vo);
+    }
 }

+ 26 - 0
src/main/java/com/welampiot/service/impl/PatrolTaskServiceImpl.java

@@ -3,6 +3,7 @@ package com.welampiot.service.impl;
 import com.welampiot.dao.PatrolTaskDao;
 import com.welampiot.dto.PatrolTaskDTO;
 import com.welampiot.service.PatrolTaskService;
+import com.welampiot.vo.OperationVO;
 import com.welampiot.vo.PatrolTaskVO;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
@@ -42,4 +43,29 @@ public class PatrolTaskServiceImpl implements PatrolTaskService {
     public void updatePatrolTaskStatus(PatrolTaskDTO dto) {
         patrolTaskDao.updatePatrolTaskStatus(dto);
     }
+
+    @Override
+    public Integer getPatrolTaskUnStartCount(OperationVO vo) {
+        return patrolTaskDao.getPatrolTaskUnStartCount(vo);
+    }
+
+    @Override
+    public Integer getPatrolTaskHandlingCount(OperationVO vo) {
+        return patrolTaskDao.getPatrolTaskHandlingCount(vo);
+    }
+
+    @Override
+    public Integer getPatrolTaskEndCount(OperationVO vo) {
+        return patrolTaskDao.getPatrolTaskEndCount(vo);
+    }
+
+    @Override
+    public Integer getPatrolCloseArchiveCount(OperationVO vo) {
+        return patrolTaskDao.getPatrolCloseArchiveCount(vo);
+    }
+
+    @Override
+    public Integer getPatrolPostponeCount(OperationVO vo) {
+        return patrolTaskDao.getPatrolPostponeCount(vo);
+    }
 }

+ 36 - 0
src/main/java/com/welampiot/service/impl/ProReviewerServiceImpl.java

@@ -0,0 +1,36 @@
+package com.welampiot.service.impl;
+
+import com.welampiot.dao.ProReviewerDao;
+import com.welampiot.service.ProReviewerService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+/**
+ * ClassName: ProReviewerServiceImpl
+ * Package: com.welampiot.service.impl
+ * Description:
+ *
+ * @Author: zhj_Start
+ * @Create: 2023/7/5 - 11:25
+ * @Version: v1.0
+ */
+@Service
+public class ProReviewerServiceImpl implements ProReviewerService {
+    @Autowired
+    private ProReviewerDao proReviewerDao;
+
+    @Override
+    public Integer getSysInfoUnReadCount(Integer userid) {
+        return proReviewerDao.getSysInfoUnReadCount(userid);
+    }
+
+    @Override
+    public Integer getSysInfoReadCount(Integer userid) {
+        return proReviewerDao.getSysInfoReadCount(userid);
+    }
+
+    @Override
+    public Integer getSysInfoCount(Integer userid) {
+        return proReviewerDao.getSysInfoCount(userid);
+    }
+}

+ 15 - 0
src/main/java/com/welampiot/service/impl/RepairProjectServiceImpl.java

@@ -73,4 +73,19 @@ public class RepairProjectServiceImpl implements RepairProjectService {
     public List<RepairProjectDTO> getRepairProjectCountOnMonth(OperationVO vo) {
         return repairProjectDao.getRepairProjectCountOnMonth(vo);
     }
+
+    @Override
+    public Integer getProjectNormalCount(OperationVO vo) {
+        return repairProjectDao.getProjectNormalCount(vo);
+    }
+
+    @Override
+    public Integer getProjectAnticipateCount(OperationVO vo) {
+        return repairProjectDao.getProjectAnticipateCount(vo);
+    }
+
+    @Override
+    public Integer getProjectCompleteCount(OperationVO vo) {
+        return repairProjectDao.getProjectCompleteCount(vo);
+    }
 }

+ 25 - 0
src/main/java/com/welampiot/service/impl/WorkManageServiceImpl.java

@@ -93,4 +93,29 @@ public class WorkManageServiceImpl implements WorkManageService {
     public List<WorkManageDTO> getWorkManageCountOnMonth(OperationVO vo) {
         return workManageDao.getWorkManageCountOnMonth(vo);
     }
+
+    @Override
+    public Integer getWorkManageUndistributedCount(OperationVO vo) {
+        return workManageDao.getWorkManageUndistributedCount(vo);
+    }
+
+    @Override
+    public Integer getWorkManageHandlingCount(OperationVO vo) {
+        return workManageDao.getWorkManageHandlingCount(vo);
+    }
+
+    @Override
+    public Integer getWorkManageRecheckCount(OperationVO vo) {
+        return workManageDao.getWorkManageRecheckCount(vo);
+    }
+
+    @Override
+    public Integer getWorkManageCloseCaseCount(OperationVO vo) {
+        return workManageDao.getWorkManageCloseCaseCount(vo);
+    }
+
+    @Override
+    public Integer getWorkManageArchiveCount(OperationVO vo) {
+        return workManageDao.getWorkManageArchiveCount(vo);
+    }
 }

+ 24 - 0
src/main/java/com/welampiot/vo/OperationDataVO.java

@@ -0,0 +1,24 @@
+package com.welampiot.vo;
+
+import lombok.Data;
+
+import java.io.Serializable;
+
+/**
+ * ClassName: OperationDataVO
+ * Package: com.welampiot.vo
+ * Description:
+ *
+ * @Author: zhj_Start
+ * @Create: 2023/7/5 - 10:25
+ * @Version: v1.0
+ */
+@Data
+public class OperationDataVO implements Serializable {
+    private Integer data;
+    private Integer data1;
+    private Integer data2;
+    private Integer data3;
+    private Integer data4;
+    private Integer data5;
+}

+ 51 - 0
src/main/resources/mapper/AllAlarmInfoLogMapper.xml

@@ -489,4 +489,55 @@
         order by date(a.updatetime) desc
     </select>
 
+    <!-- 运维概览故障未处理数,当月当年全部具体月份的数据数量 -->
+    <select id="getAlarmUntreatedCount" resultType="Integer">
+        select count(*) as dayCount
+        from all_alarm_info_log a
+        where a.status = 0
+        and date(a.updatetime) <![CDATA[ <= ]]> #{endDate}
+        <if test="startDate != null and startDate != ''">
+            and date(a.updatetime) <![CDATA[ >= ]]> #{startDate}
+        </if>
+        <if test="sectionList != null and !sectionList.isEmpty()">
+            and a.sectionId in
+            <foreach collection="sectionList" item="item" open="(" separator="," close=")">
+                #{item}
+            </foreach>
+        </if>
+    </select>
+
+    <!-- 运维概览故障处理中数,当月当年全部具体月份的数据数量 -->
+    <select id="getAlarmHandlingCount" resultType="Integer">
+        select count(*) as dayCount
+        from all_alarm_info_log a
+        where a.status = 1
+        and date(a.updatetime) <![CDATA[ <= ]]> #{endDate}
+        <if test="startDate != null and startDate != ''">
+            and date(a.updatetime) <![CDATA[ >= ]]> #{startDate}
+        </if>
+        <if test="sectionList != null and !sectionList.isEmpty()">
+            and a.sectionId in
+            <foreach collection="sectionList" item="item" open="(" separator="," close=")">
+                #{item}
+            </foreach>
+        </if>
+    </select>
+
+    <!-- 运维概览故障已处理数,当月当年全部具体月份的数据数量 -->
+    <select id="getAlarmHandledCount" resultType="Integer">
+        select count(*) as dayCount
+        from all_alarm_info_log a
+        where a.status = 2
+        and date(a.updatetime) <![CDATA[ <= ]]> #{endDate}
+        <if test="startDate != null and startDate != ''">
+            and date(a.updatetime) <![CDATA[ >= ]]> #{startDate}
+        </if>
+        <if test="sectionList != null and !sectionList.isEmpty()">
+            and a.sectionId in
+            <foreach collection="sectionList" item="item" open="(" separator="," close=")">
+                #{item}
+            </foreach>
+        </if>
+    </select>
+
 </mapper>

+ 85 - 0
src/main/resources/mapper/DefectManageMapper.xml

@@ -232,4 +232,89 @@
         order by date(d.create_time) desc
     </select>
 
+    <!-- 运维概览缺陷未派发数,当月当年全部具体月份的数据数量 -->
+    <select id="getDefectManageUndistributedCount" resultType="Integer">
+        select count(*) as dayCount
+        from defect_manage d
+        where d.status = 0
+        and date(d.create_time) <![CDATA[ <= ]]> #{endDate}
+        <if test="startDate != null and startDate != ''">
+            and date(d.create_time) <![CDATA[ >= ]]> #{startDate}
+        </if>
+        <if test="sectionList != null and !sectionList.isEmpty()">
+            and d.sectionId in
+            <foreach collection="sectionList" item="item" open="(" separator="," close=")">
+                #{item}
+            </foreach>
+        </if>
+    </select>
+
+    <!-- 运维概览工单处理中数,当月当年全部具体月份的数据数量 -->
+    <select id="getDefectManageHandlingCount" resultType="Integer">
+        select count(*) as dayCount
+        from defect_manage d
+        where d.status = 1
+        and date(d.create_time) <![CDATA[ <= ]]> #{endDate}
+        <if test="startDate != null and startDate != ''">
+            and date(d.create_time) <![CDATA[ >= ]]> #{startDate}
+        </if>
+        <if test="sectionList != null and !sectionList.isEmpty()">
+            and d.sectionId in
+            <foreach collection="sectionList" item="item" open="(" separator="," close=")">
+                #{item}
+            </foreach>
+        </if>
+    </select>
+
+    <!-- 运维概览工单复核数,当月当年全部具体月份的数据数量 -->
+    <select id="getDefectManageRecheckCount" resultType="Integer">
+        select count(*) as dayCount
+        from defect_manage d
+        where d.status = 2
+        and date(d.create_time) <![CDATA[ <= ]]> #{endDate}
+        <if test="startDate != null and startDate != ''">
+            and date(d.create_time) <![CDATA[ >= ]]> #{startDate}
+        </if>
+        <if test="sectionList != null and !sectionList.isEmpty()">
+            and d.sectionId in
+            <foreach collection="sectionList" item="item" open="(" separator="," close=")">
+                #{item}
+            </foreach>
+        </if>
+    </select>
+
+    <!-- 运维概览工单结案数,当月当年全部具体月份的数据数量 -->
+    <select id="getDefectManageCloseCaseCount" resultType="Integer">
+        select count(*) as dayCount
+        from defect_manage d
+        where d.status = 3
+        and date(d.create_time) <![CDATA[ <= ]]> #{endDate}
+        <if test="startDate != null and startDate != ''">
+            and date(d.create_time) <![CDATA[ >= ]]> #{startDate}
+        </if>
+        <if test="sectionList != null and !sectionList.isEmpty()">
+            and d.sectionId in
+            <foreach collection="sectionList" item="item" open="(" separator="," close=")">
+                #{item}
+            </foreach>
+        </if>
+    </select>
+
+    <!-- 运维概览工单归档数,当月当年全部具体月份的数据数量 -->
+    <select id="getDefectManageArchiveCount" resultType="Integer">
+        select count(*) as dayCount
+        from defect_manage d
+        where d.status = 4
+        and date(d.create_time) <![CDATA[ <= ]]> #{endDate}
+        <if test="startDate != null and startDate != ''">
+            and date(d.create_time) <![CDATA[ >= ]]> #{startDate}
+        </if>
+        <if test="sectionList != null and !sectionList.isEmpty()">
+            and d.sectionId in
+            <foreach collection="sectionList" item="item" open="(" separator="," close=")">
+                #{item}
+            </foreach>
+        </if>
+    </select>
+
 </mapper>

+ 85 - 0
src/main/resources/mapper/PatrolTaskMapper.xml

@@ -88,4 +88,89 @@
         where p.id = #{id}
     </update>
 
+    <!-- 运维概览巡视未开始数,当月当年全部具体月份的数据数量 -->
+    <select id="getPatrolTaskUnStartCount" resultType="Integer">
+        select count(*) as dayCount
+        from patrol_task p
+        where p.status = 0
+        and date(p.create_time) <![CDATA[ <= ]]> #{endDate}
+        <if test="startDate != null and startDate != ''">
+            and date(p.create_time) <![CDATA[ >= ]]> #{startDate}
+        </if>
+        <if test="sectionList != null and !sectionList.isEmpty()">
+            and p.sectionId in
+            <foreach collection="sectionList" item="item" open="(" separator="," close=")">
+                #{item}
+            </foreach>
+        </if>
+    </select>
+
+    <!-- 运维概览巡视中数,当月当年全部具体月份的数据数量 -->
+    <select id="getPatrolTaskHandlingCount" resultType="Integer">
+        select count(*) as dayCount
+        from patrol_task p
+        where p.status = 1
+        and date(p.create_time) <![CDATA[ <= ]]> #{endDate}
+        <if test="startDate != null and startDate != ''">
+            and date(p.create_time) <![CDATA[ >= ]]> #{startDate}
+        </if>
+        <if test="sectionList != null and !sectionList.isEmpty()">
+            and p.sectionId in
+            <foreach collection="sectionList" item="item" open="(" separator="," close=")">
+                #{item}
+            </foreach>
+        </if>
+    </select>
+
+    <!-- 运维概览巡视结束数,当月当年全部具体月份的数据数量 -->
+    <select id="getPatrolTaskEndCount" resultType="Integer">
+        select count(*) as dayCount
+        from patrol_task p
+        where p.status = 2
+        and date(p.create_time) <![CDATA[ <= ]]> #{endDate}
+        <if test="startDate != null and startDate != ''">
+            and date(p.create_time) <![CDATA[ >= ]]> #{startDate}
+        </if>
+        <if test="sectionList != null and !sectionList.isEmpty()">
+            and p.sectionId in
+            <foreach collection="sectionList" item="item" open="(" separator="," close=")">
+                #{item}
+            </foreach>
+        </if>
+    </select>
+
+    <!-- 运维概览巡视结案归档数,当月当年全部具体月份的数据数量 -->
+    <select id="getPatrolCloseArchiveCount" resultType="Integer">
+        select count(*) as dayCount
+        from patrol_task p
+        where p.status = 3
+        and date(p.create_time) <![CDATA[ <= ]]> #{endDate}
+        <if test="startDate != null and startDate != ''">
+            and date(p.create_time) <![CDATA[ >= ]]> #{startDate}
+        </if>
+        <if test="sectionList != null and !sectionList.isEmpty()">
+            and p.sectionId in
+            <foreach collection="sectionList" item="item" open="(" separator="," close=")">
+                #{item}
+            </foreach>
+        </if>
+    </select>
+
+    <!-- 运维概览巡视延期数,当月当年全部具体月份的数据数量 -->
+    <select id="getPatrolPostponeCount" resultType="Integer">
+        select count(*) as dayCount
+        from patrol_task p
+        where p.status = 4
+        and date(p.create_time) <![CDATA[ <= ]]> #{endDate}
+        <if test="startDate != null and startDate != ''">
+            and date(p.create_time) <![CDATA[ >= ]]> #{startDate}
+        </if>
+        <if test="sectionList != null and !sectionList.isEmpty()">
+            and p.sectionId in
+            <foreach collection="sectionList" item="item" open="(" separator="," close=")">
+                #{item}
+            </foreach>
+        </if>
+    </select>
+
 </mapper>

+ 25 - 0
src/main/resources/mapper/ProReviewerMapper.xml

@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.welampiot.dao.ProReviewerDao">
+    
+    <select id="getSysInfoUnReadCount" resultType="Integer">
+        select count(p.id)
+        from pro_reviewer p
+        where p.reviewer = #{userid}
+        and p.view_status = 0
+    </select>
+
+    <select id="getSysInfoReadCount" resultType="Integer">
+        select count(p.id)
+        from pro_reviewer p
+        where p.reviewer = #{userid}
+          and p.view_status = 1
+    </select>
+
+    <select id="getSysInfoCount" resultType="Integer">
+        select count(p.id)
+        from pro_reviewer p
+        where p.reviewer = #{userid}
+    </select>
+
+</mapper>

+ 51 - 0
src/main/resources/mapper/RepairProjectMapper.xml

@@ -149,4 +149,55 @@
         order by date(r.create_time) desc
     </select>
 
+    <!-- 运维概览维修项目正常数,当月当年全部具体月份的数据数量 -->
+    <select id="getProjectNormalCount" resultType="Integer">
+        select count(*) as dayCount
+        from repair_project r
+        where r.status = 0
+        and date(r.create_time) <![CDATA[ <= ]]> #{endDate}
+        <if test="startDate != null and startDate != ''">
+            and date(r.create_time) <![CDATA[ >= ]]> #{startDate}
+        </if>
+        <if test="sectionList != null and !sectionList.isEmpty()">
+            and r.sectionId in
+            <foreach collection="sectionList" item="item" open="(" separator="," close=")">
+                #{item}
+            </foreach>
+        </if>
+    </select>
+
+    <!-- 运维概览维修项目预期数,当月当年全部具体月份的数据数量 -->
+    <select id="getProjectAnticipateCount" resultType="Integer">
+        select count(*) as dayCount
+        from repair_project r
+        where r.status = 1
+        and date(r.create_time) <![CDATA[ <= ]]> #{endDate}
+        <if test="startDate != null and startDate != ''">
+            and date(r.create_time) <![CDATA[ >= ]]> #{startDate}
+        </if>
+        <if test="sectionList != null and !sectionList.isEmpty()">
+            and r.sectionId in
+            <foreach collection="sectionList" item="item" open="(" separator="," close=")">
+                #{item}
+            </foreach>
+        </if>
+    </select>
+
+    <!-- 运维概览维修项目完成数,当月当年全部具体月份的数据数量 -->
+    <select id="getProjectCompleteCount" resultType="Integer">
+        select count(*) as dayCount
+        from repair_project r
+        where r.status = 2
+        and date(r.create_time) <![CDATA[ <= ]]> #{endDate}
+        <if test="startDate != null and startDate != ''">
+            and date(r.create_time) <![CDATA[ >= ]]> #{startDate}
+        </if>
+        <if test="sectionList != null and !sectionList.isEmpty()">
+            and r.sectionId in
+            <foreach collection="sectionList" item="item" open="(" separator="," close=")">
+                #{item}
+            </foreach>
+        </if>
+    </select>
+
 </mapper>

+ 85 - 0
src/main/resources/mapper/WorkManageMapper.xml

@@ -235,4 +235,89 @@
         order by date(w.create_time) desc
     </select>
 
+    <!-- 运维概览工单未派发数,当月当年全部具体月份的数据数量 -->
+    <select id="getWorkManageUndistributedCount" resultType="Integer">
+        select count(*) as dayCount
+        from work_manage w
+        where w.status = 0
+        and date(w.create_time) <![CDATA[ <= ]]> #{endDate}
+        <if test="startDate != null and startDate != ''">
+            and date(w.create_time) <![CDATA[ >= ]]> #{startDate}
+        </if>
+        <if test="sectionList != null and !sectionList.isEmpty()">
+            and w.sectionId in
+            <foreach collection="sectionList" item="item" open="(" separator="," close=")">
+                #{item}
+            </foreach>
+        </if>
+    </select>
+
+    <!-- 运维概览工单处理中数,当月当年全部具体月份的数据数量 -->
+    <select id="getWorkManageHandlingCount" resultType="Integer">
+        select count(*) as dayCount
+        from work_manage w
+        where w.status = 1
+        and date(w.create_time) <![CDATA[ <= ]]> #{endDate}
+        <if test="startDate != null and startDate != ''">
+            and date(w.create_time) <![CDATA[ >= ]]> #{startDate}
+        </if>
+        <if test="sectionList != null and !sectionList.isEmpty()">
+            and w.sectionId in
+            <foreach collection="sectionList" item="item" open="(" separator="," close=")">
+                #{item}
+            </foreach>
+        </if>
+    </select>
+
+    <!-- 运维概览工单复核数,当月当年全部具体月份的数据数量 -->
+    <select id="getWorkManageRecheckCount" resultType="Integer">
+        select count(*) as dayCount
+        from work_manage w
+        where w.status = 2
+        and date(w.create_time) <![CDATA[ <= ]]> #{endDate}
+        <if test="startDate != null and startDate != ''">
+            and date(w.create_time) <![CDATA[ >= ]]> #{startDate}
+        </if>
+        <if test="sectionList != null and !sectionList.isEmpty()">
+            and w.sectionId in
+            <foreach collection="sectionList" item="item" open="(" separator="," close=")">
+                #{item}
+            </foreach>
+        </if>
+    </select>
+
+    <!-- 运维概览工单结案数,当月当年全部具体月份的数据数量 -->
+    <select id="getWorkManageCloseCaseCount" resultType="Integer">
+        select count(*) as dayCount
+        from work_manage w
+        where w.status = 3
+        and date(w.create_time) <![CDATA[ <= ]]> #{endDate}
+        <if test="startDate != null and startDate != ''">
+            and date(w.create_time) <![CDATA[ >= ]]> #{startDate}
+        </if>
+        <if test="sectionList != null and !sectionList.isEmpty()">
+            and w.sectionId in
+            <foreach collection="sectionList" item="item" open="(" separator="," close=")">
+                #{item}
+            </foreach>
+        </if>
+    </select>
+
+    <!-- 运维概览工单归档数,当月当年全部具体月份的数据数量 -->
+    <select id="getWorkManageArchiveCount" resultType="Integer">
+        select count(*) as dayCount
+        from work_manage w
+        where w.status = 4
+        and date(w.create_time) <![CDATA[ <= ]]> #{endDate}
+        <if test="startDate != null and startDate != ''">
+            and date(w.create_time) <![CDATA[ >= ]]> #{startDate}
+        </if>
+        <if test="sectionList != null and !sectionList.isEmpty()">
+            and w.sectionId in
+            <foreach collection="sectionList" item="item" open="(" separator="," close=")">
+                #{item}
+            </foreach>
+        </if>
+    </select>
+
 </mapper>