代码提交
This commit is contained in:
@@ -1940,7 +1940,7 @@ public class ReportServiceImpl implements ReportService {
|
||||
count.add(Integer.parseInt(timeVO.getTimes()));
|
||||
}
|
||||
}
|
||||
String yftj = getYFTJ(name, count, reasonTypeTime.get(0).getYear(), exportParam.getFlag());
|
||||
String yftj = drawPicUtil.drawMonth(name, count, reasonTypeTime.get(0).getYear(), exportParam.getFlag());
|
||||
createPic(doc, yftj, "月份统计图");
|
||||
two++;
|
||||
}
|
||||
@@ -1983,11 +1983,18 @@ public class ReportServiceImpl implements ReportService {
|
||||
if (exportParam.isYytx()) {
|
||||
createTitle(doc, "4." + i + "." + two + " 原因统计图", "标题 3", 400, 15);
|
||||
List<String> xdata = new ArrayList<>();
|
||||
List<Map<String,Object>> reasonList = new ArrayList<>();
|
||||
|
||||
List<ReasonsVO> reason = statistic.getReason();
|
||||
for (ReasonsVO reasonsVO : reason) {
|
||||
Map<String,Object> map=new LinkedHashMap<>();
|
||||
map.put("value",reasonsVO.getTimes());
|
||||
map.put("name",reasonsVO.getReason());
|
||||
reasonList.add(map);
|
||||
// reasonList.add("{value:"+reasonsVO.getTimes()+",name:'"+reasonsVO.getReason()+"'}");
|
||||
xdata.add(reasonsVO.getReason());
|
||||
}
|
||||
String tr = getR(xdata, reason, "bar9.ftl");
|
||||
String tr = drawPicUtil.drawReason(xdata,reasonList);
|
||||
createPic(doc, tr, "暂降原因图");
|
||||
two++;
|
||||
}
|
||||
@@ -2014,12 +2021,16 @@ public class ReportServiceImpl implements ReportService {
|
||||
createTitle(doc, "4." + i + "." + two + " 类型统计图", "标题 3", 400, 15);
|
||||
List<String> xdata = new ArrayList<>();
|
||||
List<TypesVO> types = statistic.getTypes();
|
||||
|
||||
List<Map<String,Object>> reasonList = new ArrayList<>();
|
||||
for (TypesVO type : types) {
|
||||
if (type.getTimes() > 0) {
|
||||
xdata.add(type.getType());
|
||||
}
|
||||
Map<String,Object> map=new LinkedHashMap<>();
|
||||
map.put("value",type.getTimes());
|
||||
map.put("name",type.getType());
|
||||
reasonList.add(map);
|
||||
xdata.add(type.getType());
|
||||
}
|
||||
String tr = getT(xdata, types, "bar8.ftl");
|
||||
String tr = drawPicUtil.drawType(xdata,reasonList);
|
||||
createPic(doc, tr, "暂降类型图");
|
||||
two++;
|
||||
}
|
||||
@@ -2100,7 +2111,7 @@ public class ReportServiceImpl implements ReportService {
|
||||
|
||||
|
||||
public String getStr(String barName, Map<String, Object> map) throws TemplateException, IOException {
|
||||
String s = freemarkerUtil.generateString(barName, "com/njcn/event/template", map);
|
||||
String s = freemarkerUtil.generateString(barName, "com/njcn/event/templates", map);
|
||||
return EchartsUtil.generateEchartsBase64(s, "8910");
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user