|
|
@ -31,7 +31,6 @@ import org.apache.commons.lang3.ObjectUtils;
|
|
|
|
import org.apache.commons.lang3.StringUtils;
|
|
|
|
import org.apache.commons.lang3.StringUtils;
|
|
|
|
import org.jfree.chart.ChartUtils;
|
|
|
|
import org.jfree.chart.ChartUtils;
|
|
|
|
import org.jfree.chart.JFreeChart;
|
|
|
|
import org.jfree.chart.JFreeChart;
|
|
|
|
import org.jfree.chart.plot.PiePlot;
|
|
|
|
|
|
|
|
import org.jfree.data.general.DefaultPieDataset;
|
|
|
|
import org.jfree.data.general.DefaultPieDataset;
|
|
|
|
import org.springframework.core.io.ClassPathResource;
|
|
|
|
import org.springframework.core.io.ClassPathResource;
|
|
|
|
import org.springframework.data.domain.Page;
|
|
|
|
import org.springframework.data.domain.Page;
|
|
|
@ -41,14 +40,12 @@ import org.springframework.stereotype.Service;
|
|
|
|
import javax.annotation.Resource;
|
|
|
|
import javax.annotation.Resource;
|
|
|
|
import javax.servlet.ServletOutputStream;
|
|
|
|
import javax.servlet.ServletOutputStream;
|
|
|
|
import javax.servlet.http.HttpServletResponse;
|
|
|
|
import javax.servlet.http.HttpServletResponse;
|
|
|
|
import java.awt.*;
|
|
|
|
|
|
|
|
import java.io.ByteArrayOutputStream;
|
|
|
|
import java.io.ByteArrayOutputStream;
|
|
|
|
import java.io.IOException;
|
|
|
|
import java.io.IOException;
|
|
|
|
import java.io.InputStream;
|
|
|
|
import java.io.InputStream;
|
|
|
|
import java.time.Instant;
|
|
|
|
import java.time.Instant;
|
|
|
|
import java.time.LocalDate;
|
|
|
|
import java.time.LocalDate;
|
|
|
|
import java.util.*;
|
|
|
|
import java.util.*;
|
|
|
|
import java.util.List;
|
|
|
|
|
|
|
|
import java.util.stream.Collectors;
|
|
|
|
import java.util.stream.Collectors;
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
/**
|
|
|
@ -659,10 +656,6 @@ public class EvaluationServiceImpl implements EvaluationService {
|
|
|
|
praiseDistributionDataset.setValue(FiveEducations.ART.getName(), reportVo.getPraiseDistribution().get(FiveEducations.ART.getCode()));
|
|
|
|
praiseDistributionDataset.setValue(FiveEducations.ART.getName(), reportVo.getPraiseDistribution().get(FiveEducations.ART.getCode()));
|
|
|
|
praiseDistributionDataset.setValue(FiveEducations.LABOUR.getName(), reportVo.getPraiseDistribution().get(FiveEducations.LABOUR.getCode()));
|
|
|
|
praiseDistributionDataset.setValue(FiveEducations.LABOUR.getName(), reportVo.getPraiseDistribution().get(FiveEducations.LABOUR.getCode()));
|
|
|
|
JFreeChart praisePieChart = ChartUtil.pieChart("五育表扬指标分布", praiseDistributionDataset);
|
|
|
|
JFreeChart praisePieChart = ChartUtil.pieChart("五育表扬指标分布", praiseDistributionDataset);
|
|
|
|
PiePlot plot1 = (PiePlot) praisePieChart.getPlot();
|
|
|
|
|
|
|
|
plot1.setNoDataMessage("无数据");
|
|
|
|
|
|
|
|
plot1.setNoDataMessageFont(new Font("宋体", Font.PLAIN, 18));
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ByteArrayOutputStream praiseBos = new ByteArrayOutputStream();
|
|
|
|
ByteArrayOutputStream praiseBos = new ByteArrayOutputStream();
|
|
|
|
ChartUtils.writeChartAsJPEG(praiseBos, praisePieChart, 340, 330);
|
|
|
|
ChartUtils.writeChartAsJPEG(praiseBos, praisePieChart, 340, 330);
|
|
|
|
|
|
|
|
|
|
|
@ -674,11 +667,6 @@ public class EvaluationServiceImpl implements EvaluationService {
|
|
|
|
criticalDistributionDataset.setValue(FiveEducations.ART.getName(), reportVo.getCriticalDistribution().get(FiveEducations.ART.getCode()));
|
|
|
|
criticalDistributionDataset.setValue(FiveEducations.ART.getName(), reportVo.getCriticalDistribution().get(FiveEducations.ART.getCode()));
|
|
|
|
criticalDistributionDataset.setValue(FiveEducations.LABOUR.getName(), reportVo.getCriticalDistribution().get(FiveEducations.LABOUR.getCode()));
|
|
|
|
criticalDistributionDataset.setValue(FiveEducations.LABOUR.getName(), reportVo.getCriticalDistribution().get(FiveEducations.LABOUR.getCode()));
|
|
|
|
JFreeChart criticalPieChart = ChartUtil.pieChart("五育待改进指标分布", criticalDistributionDataset);
|
|
|
|
JFreeChart criticalPieChart = ChartUtil.pieChart("五育待改进指标分布", criticalDistributionDataset);
|
|
|
|
|
|
|
|
|
|
|
|
PiePlot plot2 = (PiePlot) criticalPieChart.getPlot();
|
|
|
|
|
|
|
|
plot2.setNoDataMessage("无数据");
|
|
|
|
|
|
|
|
plot2.setNoDataMessageFont(new Font("宋体", Font.PLAIN, 18));
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ByteArrayOutputStream criticalBos = new ByteArrayOutputStream();
|
|
|
|
ByteArrayOutputStream criticalBos = new ByteArrayOutputStream();
|
|
|
|
ChartUtils.writeChartAsJPEG(criticalBos, criticalPieChart, 340, 330);
|
|
|
|
ChartUtils.writeChartAsJPEG(criticalBos, criticalPieChart, 340, 330);
|
|
|
|
|
|
|
|
|
|
|
|