fuliqi
2024-09-18 e34234a332da0663c6207a383becb39b253a8d05
ycl-server/src/main/java/com/ycl/platform/service/impl/CheckScoreServiceImpl.java
@@ -10,6 +10,7 @@
import com.ycl.platform.domain.dto.CheckScoreIndexDTO;
import com.ycl.platform.domain.dto.ScoreIndexDTO;
import com.ycl.platform.domain.entity.*;
import com.ycl.platform.domain.query.DashboardQuery;
import com.ycl.platform.domain.vo.*;
import com.ycl.platform.mapper.CheckRuleMapper;
import com.ycl.platform.mapper.CheckScoreMapper;
@@ -506,6 +507,28 @@
        return scoreMapper.calculate(startDate, endDate, category);
    }
    //大屏展示考核得分
    @Override
    //TODO:考虑limit bug
    public Map<String, List<Map<String, Object>>> dashboard(DashboardQuery dashboardQuery) {
        List<CheckScore> dashboard = scoreMapper.dashboard(dashboardQuery);
        Map<String, List<Map<String, Object>>> resultMap = new HashMap<>();
        for (CheckScore checkScore : dashboard) {
            List<Map<String, Object>> list = new ArrayList<>();
            Map<String, Object> map = new HashMap<>();
            map.put("value",checkScore.getScore());
            if(dashboardQuery.getDataScope() ==1) {
                map.put("name", "省厅得分");
            }else {
                map.put("name", "区县得分");
            }
            list.add(map);
            resultMap.put(checkScore.getDeptName(),list );
        }
        return resultMap;
    }
    //    /**
//     * 新增考核积分
//     *