From d972c344c06537c299338b1923d6f3673357775b Mon Sep 17 00:00:00 2001 From: 21819 Date: Sun, 10 Mar 2024 19:13:54 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A4=A7=E5=B1=8F=E6=95=B0=E6=8D=AE=E8=AE=A1?= =?UTF-8?q?=E7=AE=97=E6=96=B9=E5=BC=8F=E6=9B=B4=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../datascreen/DataScreenController.java | 2 -- .../biutag/lan/service/DataScreenService.java | 24 +++++-------------- 2 files changed, 6 insertions(+), 20 deletions(-) diff --git a/mailbox-lan/src/main/java/com/biutag/lan/controller/datascreen/DataScreenController.java b/mailbox-lan/src/main/java/com/biutag/lan/controller/datascreen/DataScreenController.java index 83f2a14..1bb1f4e 100644 --- a/mailbox-lan/src/main/java/com/biutag/lan/controller/datascreen/DataScreenController.java +++ b/mailbox-lan/src/main/java/com/biutag/lan/controller/datascreen/DataScreenController.java @@ -39,8 +39,6 @@ public class DataScreenController { String deptId= params.get("id").toString(); return AjaxResult.success(dataScreenService.mapCountyData(deptId)); } - - } @NotLogin diff --git a/mailbox-lan/src/main/java/com/biutag/lan/service/DataScreenService.java b/mailbox-lan/src/main/java/com/biutag/lan/service/DataScreenService.java index f2b80b2..3077d97 100644 --- a/mailbox-lan/src/main/java/com/biutag/lan/service/DataScreenService.java +++ b/mailbox-lan/src/main/java/com/biutag/lan/service/DataScreenService.java @@ -8,23 +8,15 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.biutag.entity.system.Duty; import com.biutag.enums.DeptTypeEnum; import com.biutag.lan.domain.Mail; -import com.biutag.lan.domain.MailFlow; +import com.biutag.lan.domain.MailMark; import com.biutag.lan.domain.vo.MailDetail; import com.biutag.lan.flow.FlowNodeEnum; import com.biutag.lan.mapper.DataScreenMapper; -import com.biutag.lan.mapper.MailMapper; -import com.biutag.lan.mapper.MailSourceMapper; import com.biutag.util.DateUtils; import com.biutag.util.StringUtils; import com.biutag.util.TimeUtils; -import com.fasterxml.jackson.core.JsonProcessingException; -import com.fasterxml.jackson.databind.JsonNode; -import com.google.gson.Gson; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; import lombok.RequiredArgsConstructor; import org.springframework.stereotype.Service; -import com.fasterxml.jackson.databind.ObjectMapper; import java.util.*; import java.util.concurrent.atomic.AtomicReference; @@ -33,10 +25,10 @@ import java.util.concurrent.atomic.AtomicReference; @Service public class DataScreenService extends ServiceImpl { - private final MailMapper mailMapper; - private final MailFlowService mailFlowService; + private final MailMarkService mailMarkService; + public List> mapData(String deptId) { return baseMapper.mapData(deptId); } @@ -123,9 +115,7 @@ public class DataScreenService extends ServiceImpl { Map mapCompleted = baseMapper.getAllCompletedRate(null);//获取长沙市局 办结率 Map mapResolved = baseMapper.getAllResolvedRate(null);//获取长沙市局 解决率 Map mapSatisfied = baseMapper.getAllSatisfiedRate(null);//获取长沙市局 满意率 -// Integer allSum = baseMapper.getAllMailCount(null); - Long allSum = mailMapper.selectCount(new LambdaQueryWrapper().ne(Mail::getMailFirstCategory, "无效类").ne(Mail::getMailFirstCategory, "终止类") - .ne(Mail::getMailFirstCategory, "感谢信类")); + Long allSum = mailMarkService.count(); Integer toDayCount = baseMapper.getTodayMailCount(null); mapCompleted.putAll(mapResolved); @@ -138,9 +128,7 @@ public class DataScreenService extends ServiceImpl { Map mapCompleted = baseMapper.getAllCompletedRate(deptId);//获取长沙市局 办结率 Map mapResolved = baseMapper.getAllResolvedRate(deptId);//获取长沙市局 解决率 Map mapSatisfied = baseMapper.getAllSatisfiedRate(deptId);//获取长沙市局 满意率 -// Integer allSum = baseMapper.getAllMailCount(deptId); - Long allSum = mailMapper.selectCount(new LambdaQueryWrapper().ne(Mail::getMailFirstCategory, "无效类").ne(Mail::getMailFirstCategory, "终止类") - .ne(Mail::getMailFirstCategory, "感谢信类")); + Long allSum = mailMarkService.count(new LambdaQueryWrapper().eq(MailMark::getSecondDeptId, deptId)); Integer toDayCount = baseMapper.getTodayMailCount(deptId); mapCompleted.putAll(mapResolved); @@ -255,7 +243,7 @@ public class DataScreenService extends ServiceImpl { map.put("dutyZdList", dutyZdList); map.put("dutyBwList", dutyBwList); } else { - String deptId = StringUtils.isNull(params.get("id")) ? null : params.get("id").toString(); + String deptId = StringUtils.isNull(params.get("id")) ? null : params.get("id"); List dutySjList = baseMapper.getToDayDuty(DeptTypeEnum.SJ_TYPE.getType(), null); List dutyFjList = baseMapper.getToDayDuty(DeptTypeEnum.FJ_TYPE.getType(), deptId); List dutyPcsList = baseMapper.getToDayDuty(DeptTypeEnum.PCS_TYPE.getType(), deptId);