|
@ -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;
|
|
|
}
|
|
|
}
|