|
@ -272,9 +272,21 @@ public class StatisticsService {
|
|
SaveModel saveModel = elasticsearchUtil.findOneDateQuotaLevel0(endDate, endDate, defalutArea, defalutLevel, ind, SaveModel.timeLevel_DDL);
|
|
SaveModel saveModel = elasticsearchUtil.findOneDateQuotaLevel0(endDate, endDate, defalutArea, defalutLevel, ind, SaveModel.timeLevel_DDL);
|
|
res.put("index_" + ind, saveModel.getResult2().longValue());
|
|
res.put("index_" + ind, saveModel.getResult2().longValue());
|
|
}
|
|
}
|
|
String emergencyCallSql = "SELECT COUNT(1) FROM base_emergency_assistance_order WHERE status >= 0 ";
|
|
|
|
|
|
|
|
|
|
String sqltmp = "SELECT GROUP_CONCAT(dict_code) orgCodes from wlyy_hospital_sys_dict WHERE dict_name = 'jkzl_org' ";
|
|
|
|
List<Map<String, Object>> listtmp = jdbcTemplate.queryForList(sqltmp);
|
|
|
|
String filter = "";
|
|
|
|
String filter2 = "";
|
|
|
|
if (listtmp.size() > 0) {
|
|
|
|
String orgCodes = String.valueOf(listtmp.get(0).get("orgCodes"));
|
|
|
|
orgCodes = orgCodes.replaceAll(",", "','");
|
|
|
|
filter = " and hospital not in ('" + orgCodes + "') ";
|
|
|
|
filter2 = " and org_code not in ('" + orgCodes + "') ";
|
|
|
|
}
|
|
|
|
|
|
|
|
String emergencyCallSql = "SELECT COUNT(1) FROM base_emergency_assistance_order WHERE status >= 0 "+filter;
|
|
Integer emergencyCallNum = jdbcTemplate.queryForObject(emergencyCallSql, Integer.class);
|
|
Integer emergencyCallNum = jdbcTemplate.queryForObject(emergencyCallSql, Integer.class);
|
|
String securityMonitoringSql = "SELECT COUNT(1) FROM base_security_monitoring_order where 1=1 ";
|
|
|
|
|
|
String securityMonitoringSql = "SELECT COUNT(1) FROM base_security_monitoring_order where 1=1 "+filter;
|
|
Integer securityMonitoringNum = jdbcTemplate.queryForObject(securityMonitoringSql, Integer.class);
|
|
Integer securityMonitoringNum = jdbcTemplate.queryForObject(securityMonitoringSql, Integer.class);
|
|
res.put("index_41", emergencyCallNum);
|
|
res.put("index_41", emergencyCallNum);
|
|
res.put("index_43", securityMonitoringNum);
|
|
res.put("index_43", securityMonitoringNum);
|
|
@ -1815,26 +1827,26 @@ public class StatisticsService {
|
|
for (String ind : split) {
|
|
for (String ind : split) {
|
|
long total = 0l;
|
|
long total = 0l;
|
|
SaveModel saveModelAdd = elasticsearchUtil.findOneDateQuotaLevel0(endDate, endDate, "330100", 2, ind, SaveModel.timeLevel_DDL, "6");
|
|
SaveModel saveModelAdd = elasticsearchUtil.findOneDateQuotaLevel0(endDate, endDate, "330100", 2, ind, SaveModel.timeLevel_DDL, "6");
|
|
res.put("index_"+ind, saveModelAdd.getResult2().longValue());
|
|
|
|
|
|
res.put("index_" + ind, saveModelAdd.getResult2().longValue());
|
|
}
|
|
}
|
|
Long index_28 = (Long) res.get("index_28");
|
|
Long index_28 = (Long) res.get("index_28");
|
|
Long index_29 = (Long) res.get("index_29");
|
|
Long index_29 = (Long) res.get("index_29");
|
|
Long index_30 = (Long) res.get("index_30");
|
|
Long index_30 = (Long) res.get("index_30");
|
|
DecimalFormat df=new DecimalFormat("0.00");
|
|
|
|
if (index_28!=0){
|
|
|
|
if (index_29!=0){
|
|
|
|
res.put("noReply",df.format((float) index_29/index_28*100)+"%");
|
|
|
|
}else {
|
|
|
|
res.put("noReply","0.00%");
|
|
|
|
|
|
DecimalFormat df = new DecimalFormat("0.00");
|
|
|
|
if (index_28 != 0) {
|
|
|
|
if (index_29 != 0) {
|
|
|
|
res.put("noReply", df.format((float) index_29 / index_28 * 100) + "%");
|
|
|
|
} else {
|
|
|
|
res.put("noReply", "0.00%");
|
|
}
|
|
}
|
|
if (index_30!=0){
|
|
|
|
res.put("reply",df.format((float) index_30/index_28*100 )+"%");
|
|
|
|
}else {
|
|
|
|
res.put("reply","0.00%");
|
|
|
|
|
|
if (index_30 != 0) {
|
|
|
|
res.put("reply", df.format((float) index_30 / index_28 * 100) + "%");
|
|
|
|
} else {
|
|
|
|
res.put("reply", "0.00%");
|
|
}
|
|
}
|
|
}else{
|
|
|
|
res.put("reply","0.00%");
|
|
|
|
res.put("noReply","0.00%");
|
|
|
|
|
|
} else {
|
|
|
|
res.put("reply", "0.00%");
|
|
|
|
res.put("noReply", "0.00%");
|
|
}
|
|
}
|
|
return res;
|
|
return res;
|
|
}
|
|
}
|