Quellcode durchsuchen

Merge branch 'dev' of liuwenbin/patient-co-management into dev

yeshijie vor 7 Jahren
Ursprung
Commit
008735b351

+ 8 - 0
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/service/app/statistics/StatisticsService.java

@ -4624,6 +4624,14 @@ public class StatisticsService extends BaseService {
        return result;
    }
    /**
     * 续签 签入、签出统计
     * @param teamCode
     * @param startDate
     * @param endDate
     * @param type
     * @return
     */
    public JSONObject getTeamRenewChangeLine(String teamCode, String startDate, String endDate, String type) {
        startDate = startDate + " 00:00:00";
        endDate = endDate + " 23:59:59";

+ 39 - 0
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/service/app/statisticsES/StatisticsESService.java

@ -2703,4 +2703,43 @@ public class StatisticsESService {
        }
        return rs;
    }
    public JSONArray getTeamGuidLine(String teamCode, String startDate, String endDate, String type) throws Exception{
        startDate = elasticsearchUtil.changeTime(startDate + " 00:00:00");
        endDate = elasticsearchUtil.changeTime(endDate + " 23:59:59");
        Integer interval = Integer.parseInt(type)+2;
        List<SaveModel> list = elasticsearchUtil.findLineChartDateQuotaLevel0(startDate,endDate,teamCode,Integer.parseInt(SaveModel.teamLevel),"5","2",interval+"");
        Map<String, Object> map = null;
        List<Map<String, Object>> totalList = new ArrayList<>();
        for(SaveModel one:list){
            map = new HashMap<>();
            if ("0".equals(type)) {
                map.put("dateNo",dateFormat.format(one.getQuotaDate()));
            }else{
                map.put("weekOfMonth",DateUtil.getWeekOfMonth(dateFormat.format(one.getQuotaDate())));
            }
            map.put("guidanceCount",one.getResult2().longValue());
            totalList.add(map);
        }
        return new JSONArray(totalList);
    }
    /**
     * 续签 签入、签出统计
     * @param teamCode
     * @param startDate
     * @param endDate
     * @param type
     * @return
     */
    public JSONObject getTeamRenewChangeLine(String teamCode, String startDate, String endDate, String type) throws Exception{
        startDate = elasticsearchUtil.changeTime(startDate + " 00:00:00");
        endDate = elasticsearchUtil.changeTime(endDate + " 23:59:59");
        Integer interval = Integer.parseInt(type)+2;
        List<SaveModel> inData = elasticsearchUtil.findLineChartDateQuotaLevel0(startDate,endDate,teamCode,Integer.parseInt(SaveModel.teamLevel),"34","2",interval+"");
        List<SaveModel> outData = elasticsearchUtil.findLineChartDateQuotaLevel0(startDate,endDate,teamCode,Integer.parseInt(SaveModel.teamLevel),"35","2",interval+"");
        return null;
    }
}

+ 10 - 2
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/web/statistic/EsStatisticsController.java

@ -1245,7 +1245,7 @@ public class EsStatisticsController extends BaseController {
                                  @RequestParam(required = true) String endDate,
                                  @RequestParam(required = true) String type) {
        try {
            return write(200, "查询成功", "data", statisticsService.getTeamGuidLine(teamCode, startDate, endDate, type));
            return write(200, "查询成功", "data", statisticsESService.getTeamGuidLine(teamCode, startDate, endDate, type));
        } catch (Exception e) {
            error(e);
            return error(-1, "查询失败");
@ -1253,7 +1253,7 @@ public class EsStatisticsController extends BaseController {
    }
    /**
     * 获取团队医生则线图
     * 获取团队医生折线图
     *
     * @param teamCode
     * @param startDate
@ -1422,6 +1422,14 @@ public class EsStatisticsController extends BaseController {
        }
    }
    /**
     * 续签 签入、签出统计
     * @param teamCode
     * @param startDate
     * @param endDate
     * @param type
     * @return
     */
    @RequestMapping("/getTeamRenewChangeLine")
    @ResponseBody
    public String getTeamRenewChangeLine(@RequestParam(required = true) String teamCode,