Browse Source

echarts导出加单位

develop
lau572 9 months ago
parent
commit
174b01b3c9
  1. 21
      zc-business/src/main/java/com/zc/business/controller/DCPerceivedEventsWarningController.java
  2. 42
      zc-business/src/main/java/com/zc/business/controller/DcPublishManageController.java
  3. 38
      zc-business/src/main/java/com/zc/business/controller/DcTrafficStatisticsController.java
  4. 4
      zc-business/src/main/java/com/zc/business/domain/export/AccidentVehicleAnalysis.java
  5. 2
      zc-business/src/main/java/com/zc/business/domain/export/AllEventNum.java
  6. 4
      zc-business/src/main/java/com/zc/business/domain/export/EventTrend.java
  7. 8
      zc-business/src/main/java/com/zc/business/domain/export/EventTypeAnalysis.java
  8. 6
      zc-business/src/main/java/com/zc/business/domain/export/EventTypePublishManageMonth.java
  9. 4
      zc-business/src/main/java/com/zc/business/domain/export/ManyTimesInterval.java
  10. 2
      zc-business/src/main/java/com/zc/business/domain/export/NonAutomaticWarningFacility.java
  11. 2
      zc-business/src/main/java/com/zc/business/domain/export/NonAutomaticWarningTimeType.java
  12. 2
      zc-business/src/main/java/com/zc/business/domain/export/NonAutomaticWarningType.java
  13. 8
      zc-business/src/main/java/com/zc/business/domain/export/RealTimeTrafficFlow.java
  14. 8
      zc-business/src/main/java/com/zc/business/domain/export/RoadSectionAnalysis.java
  15. 2
      zc-business/src/main/java/com/zc/business/domain/export/SectionPerceivedList.java
  16. 2
      zc-business/src/main/java/com/zc/business/domain/export/SectionTrafficRanking.java
  17. 4
      zc-business/src/main/java/com/zc/business/domain/export/SelectSection.java
  18. 12
      zc-business/src/main/java/com/zc/business/domain/export/SelectStateType.java
  19. 6
      zc-business/src/main/java/com/zc/business/domain/export/SelectTollStationAnalysis.java
  20. 2
      zc-business/src/main/java/com/zc/business/domain/export/SelectWarningType.java
  21. 2
      zc-business/src/main/java/com/zc/business/domain/export/StatisticsPublishManage.java
  22. 4
      zc-business/src/main/java/com/zc/business/domain/export/TollStationAnalysis.java
  23. 4
      zc-business/src/main/java/com/zc/business/domain/export/TrafficPeriodAnalysis.java
  24. 6
      zc-business/src/main/java/com/zc/business/domain/export/TrendsPublishManage.java
  25. 4
      zc-business/src/main/resources/mapper/business/DcPerceivedEventsWarningMapper.xml

21
zc-business/src/main/java/com/zc/business/controller/DCPerceivedEventsWarningController.java

@ -362,8 +362,7 @@ public class DCPerceivedEventsWarningController extends BaseController {
List<HashMap<String,Object>> lastYearMap = (List<HashMap<String, Object>>) map.get("lastYearMap"); List<HashMap<String,Object>> lastYearMap = (List<HashMap<String, Object>>) map.get("lastYearMap");
for (int i = UniversalEnum.ZERO.getNumber(); i < currentlyMap.size(); i++) { for (int i = UniversalEnum.ZERO.getNumber(); i < currentlyMap.size(); i++) {
ManyTimesInterval manyTimesInterval = new ManyTimesInterval(); ManyTimesInterval manyTimesInterval = new ManyTimesInterval();
int time = Integer.parseInt(currentlyMap.get(i).get("time").toString()); manyTimesInterval.setTime(i + "点至" + (i +UniversalEnum.ONE.getNumber()) + "点");
manyTimesInterval.setTime(time + "点至" + (time +UniversalEnum.ONE.getNumber()) + "点");
manyTimesInterval.setCurrentData(currentlyMap.get(i).get("number").toString()); manyTimesInterval.setCurrentData(currentlyMap.get(i).get("number").toString());
manyTimesInterval.setContemporaneousData(lastYearMap.get(i).get("number").toString()); manyTimesInterval.setContemporaneousData(lastYearMap.get(i).get("number").toString());
list.add(manyTimesInterval); list.add(manyTimesInterval);
@ -440,7 +439,8 @@ public class DCPerceivedEventsWarningController extends BaseController {
Set<String> allKeys = new HashSet<>(currentlyMap.keySet()); Set<String> allKeys = new HashSet<>(currentlyMap.keySet());
allKeys.addAll(lastYearMap.keySet()); allKeys.addAll(lastYearMap.keySet());
for (String key : allKeys) { List<String> stakeMarkList = allKeys.stream().sorted(Comparator.comparing(item -> item)).collect(Collectors.toList());
for (String key : stakeMarkList) {
SelectSection selectSection = new SelectSection(); SelectSection selectSection = new SelectSection();
selectSection.setStakeMark(key); selectSection.setStakeMark(key);
if (currentlyMap.containsKey(key)){ if (currentlyMap.containsKey(key)){
@ -479,19 +479,20 @@ public class DCPerceivedEventsWarningController extends BaseController {
List<HashMap<String,Object>> lastYearMap = (List<HashMap<String, Object>>) map.get("lastYearMap"); List<HashMap<String,Object>> lastYearMap = (List<HashMap<String, Object>>) map.get("lastYearMap");
List<HashMap<String,Object>> stateDuration = (List<HashMap<String, Object>>) map.get("stateDuration"); List<HashMap<String,Object>> stateDuration = (List<HashMap<String, Object>>) map.get("stateDuration");
Map<String,List<Map<String,Object>>> currentlyData = currentlyMap.stream().collect(Collectors.groupingBy(item -> item.get("sectionName").toString())); Map<String,List<Map<String,Object>>> currentlyData = currentlyMap.stream().collect(Collectors.groupingBy(item -> item.get("startStakeMark").toString()));
Map<String,List<Map<String,Object>>> lastYearData = lastYearMap.stream().collect(Collectors.groupingBy(item -> item.get("sectionName").toString())); Map<String,List<Map<String,Object>>> lastYearData = lastYearMap.stream().collect(Collectors.groupingBy(item -> item.get("startStakeMark").toString()));
Map<String,List<Map<String,Object>>> stateDurationData = stateDuration.stream().collect(Collectors.groupingBy(item -> item.get("sectionName").toString())); Map<String,List<Map<String,Object>>> stateDurationData = stateDuration.stream().collect(Collectors.groupingBy(item -> item.get("startStakeMark").toString()));
Set<String> allKeys = new HashSet<>(currentlyData.keySet()); Set<String> allKeys = new HashSet<>(currentlyData.keySet());
allKeys.addAll(lastYearData.keySet()); allKeys.addAll(lastYearData.keySet());
allKeys.addAll(stateDurationData.keySet()); allKeys.addAll(stateDurationData.keySet());
for (String key : allKeys) {
List<String> stakeMarkList = allKeys.stream().sorted(Comparator.comparing(stakeMark -> stakeMark)).collect(Collectors.toList());
for (String key : stakeMarkList) {
SelectStateType selectStateType = new SelectStateType(); SelectStateType selectStateType = new SelectStateType();
selectStateType.setSectionName(key);
selectStateType.setSectionName(key);
if (currentlyData.containsKey(key)){ if (currentlyData.containsKey(key)){
List<Map<String,Object>> sectionData = currentlyData.get(key); List<Map<String,Object>> sectionData = currentlyData.get(key);
selectStateType.setSectionName(sectionData.get(0).get("sectionName").toString());
for (int i = UniversalEnum.ZERO.getNumber(); i < sectionData.size(); i++) { for (int i = UniversalEnum.ZERO.getNumber(); i < sectionData.size(); i++) {
if (UniversalEnum.ONE.getValue().equals(sectionData.get(i).get("warningState").toString())){ if (UniversalEnum.ONE.getValue().equals(sectionData.get(i).get("warningState").toString())){
selectStateType.setReporting(sectionData.get(i).get("num").toString()); selectStateType.setReporting(sectionData.get(i).get("num").toString());
@ -506,6 +507,7 @@ public class DCPerceivedEventsWarningController extends BaseController {
} }
if (lastYearData.containsKey(key)){ if (lastYearData.containsKey(key)){
List<Map<String,Object>> sectionData = lastYearData.get(key); List<Map<String,Object>> sectionData = lastYearData.get(key);
selectStateType.setSectionName(sectionData.get(0).get("sectionName").toString());
Integer total = UniversalEnum.ZERO.getNumber(); Integer total = UniversalEnum.ZERO.getNumber();
for (Map<String, Object> sectionDatum : sectionData) { for (Map<String, Object> sectionDatum : sectionData) {
total += Integer.parseInt(sectionDatum.get("num").toString()); total += Integer.parseInt(sectionDatum.get("num").toString());
@ -514,6 +516,7 @@ public class DCPerceivedEventsWarningController extends BaseController {
} }
if (stateDurationData.containsKey(key)){ if (stateDurationData.containsKey(key)){
List<Map<String,Object>> sectionData = stateDurationData.get(key); List<Map<String,Object>> sectionData = stateDurationData.get(key);
selectStateType.setSectionName(sectionData.get(0).get("sectionName").toString());
selectStateType.setAverageDuration(sectionData.get(UniversalEnum.ZERO.getNumber()).get("avg").toString()); selectStateType.setAverageDuration(sectionData.get(UniversalEnum.ZERO.getNumber()).get("avg").toString());
} }

42
zc-business/src/main/java/com/zc/business/controller/DcPublishManageController.java

@ -24,6 +24,9 @@ import javax.servlet.http.HttpServletResponse;
import java.io.UnsupportedEncodingException; import java.io.UnsupportedEncodingException;
import java.net.URLEncoder; import java.net.URLEncoder;
import java.nio.charset.StandardCharsets; import java.nio.charset.StandardCharsets;
import java.time.LocalDate;
import java.time.ZoneId;
import java.time.format.DateTimeFormatter;
import java.util.*; import java.util.*;
import java.util.stream.Collectors; import java.util.stream.Collectors;
@ -230,24 +233,43 @@ public class DcPublishManageController extends BaseController
@GetMapping("/exportMonthTrendsPublishManage") @GetMapping("/exportMonthTrendsPublishManage")
public void exportMonthTrendsPublishManage(HttpServletResponse response,DcPublishManage dcPublishManage){ public void exportMonthTrendsPublishManage(HttpServletResponse response,DcPublishManage dcPublishManage){
List<String> dates = new ArrayList<>();
LocalDate currentDate = LocalDate.now();
LocalDate publishLocalDate = dcPublishManage.getPublishTime().toInstant().atZone(ZoneId.systemDefault()).toLocalDate();
if (currentDate.getMonth() == publishLocalDate.getMonth() && currentDate.getYear() == publishLocalDate.getYear()) {
for (int i = 1; i <= currentDate.getDayOfMonth(); i++) {
dates.add(String.format("%d-%02d-%02d", currentDate.getYear(), currentDate.getMonthValue(), i));
}
} else {
int daysInMonth = publishLocalDate.lengthOfMonth();
for (int i = 1; i <= daysInMonth; i++) {
dates.add(String.format("%d-%02d-%02d", publishLocalDate.getYear(), publishLocalDate.getMonthValue(), i));
}
}
List<HashMap<String,Object>> data = dcPublishManageService.monthTrendsPublishManage(dcPublishManage); List<HashMap<String,Object>> data = dcPublishManageService.monthTrendsPublishManage(dcPublishManage);
List<TrendsPublishManage> list = new ArrayList<>(); List<TrendsPublishManage> list = new ArrayList<>();
if (data != null && data.size() > 0) { if (data != null && data.size() > 0) {
Map<String,List<HashMap<String,Object>>> group = data.stream().collect(Collectors.groupingBy(item -> item.get("publishTime").toString())); Map<String,List<HashMap<String,Object>>> group = data.stream().collect(Collectors.groupingBy(item -> item.get("publishTime").toString()));
for (String publishTime : group.keySet()) { for (String publishTime : dates) {
TrendsPublishManage trendsPublishManage = new TrendsPublishManage(); TrendsPublishManage trendsPublishManage = new TrendsPublishManage();
trendsPublishManage.setPublishTime(publishTime); trendsPublishManage.setPublishTime(publishTime);
List<HashMap<String,Object>> groupData = group.get(publishTime); trendsPublishManage.setBoard("0");
for (HashMap<String, Object> groupDatum : groupData) { trendsPublishManage.setBroadcast("0");
if ("4".equals(groupDatum.get("publishChannels").toString())){ trendsPublishManage.setWeChat("0");
trendsPublishManage.setBoard(groupDatum.get("number").toString()); if (group.containsKey(publishTime)) {
} else if ("7".equals(groupDatum.get("publishChannels").toString())){ List<HashMap<String, Object>> groupData = group.get(publishTime);
trendsPublishManage.setBroadcast(groupDatum.get("number").toString()); for (HashMap<String, Object> groupDatum : groupData) {
} else if ("8".equals(groupDatum.get("publishChannels").toString())){ if ("4".equals(groupDatum.get("publishChannels").toString())) {
trendsPublishManage.setWeChat(groupDatum.get("number").toString()); trendsPublishManage.setBoard(groupDatum.get("number").toString());
} else if ("7".equals(groupDatum.get("publishChannels").toString())) {
trendsPublishManage.setBroadcast(groupDatum.get("number").toString());
} else if ("8".equals(groupDatum.get("publishChannels").toString())) {
trendsPublishManage.setWeChat(groupDatum.get("number").toString());
}
} }
} }
list.add(trendsPublishManage); list.add(trendsPublishManage);
} }

38
zc-business/src/main/java/com/zc/business/controller/DcTrafficStatisticsController.java

@ -13,6 +13,7 @@ import com.ruoyi.common.utils.StringUtils;
import com.ruoyi.common.utils.poi.ExcelUtil; import com.ruoyi.common.utils.poi.ExcelUtil;
import com.zc.business.domain.*; import com.zc.business.domain.*;
import com.zc.business.domain.export.*; import com.zc.business.domain.export.*;
import com.zc.business.enums.LocationEnum;
import com.zc.business.enums.StakeMarkRange; import com.zc.business.enums.StakeMarkRange;
import com.zc.business.enums.UniversalEnum; import com.zc.business.enums.UniversalEnum;
import com.zc.business.request.DcTrafficMetricsDataRequest; import com.zc.business.request.DcTrafficMetricsDataRequest;
@ -926,18 +927,18 @@ public AjaxResult trafficFlowAtTollStationEntranceHour(String startDate, String
cell.setCellValue(UniversalEnum.EMPTY_STRING.getValue()); cell.setCellValue(UniversalEnum.EMPTY_STRING.getValue());
cell.setCellStyle(headerStyle); cell.setCellStyle(headerStyle);
cell = subHeaderRow1.createCell(UniversalEnum.ONE.getNumber()); cell = subHeaderRow1.createCell(UniversalEnum.ONE.getNumber());
cell.setCellValue(UniversalEnum.CURRENT_TRAFFIC_FLOW.getValue()); cell.setCellValue(UniversalEnum.CURRENT_TRAFFIC_FLOW.getValue() + "(辆)");
cell.setCellStyle(headerStyle); cell.setCellStyle(headerStyle);
cell = subHeaderRow1.createCell(UniversalEnum.TWO.getNumber()); cell = subHeaderRow1.createCell(UniversalEnum.TWO.getNumber());
cell.setCellValue(UniversalEnum.THE_SAME_PERIOD_LAST_YEAR.getValue()); cell.setCellValue(UniversalEnum.THE_SAME_PERIOD_LAST_YEAR.getValue() + "(辆)");
cell.setCellStyle(headerStyle); cell.setCellStyle(headerStyle);
cell = subHeaderRow1.createCell(UniversalEnum.THREE.getNumber()); cell = subHeaderRow1.createCell(UniversalEnum.THREE.getNumber());
cell.setCellValue(UniversalEnum.CURRENT_TRAFFIC_FLOW.getValue()); cell.setCellValue(UniversalEnum.CURRENT_TRAFFIC_FLOW.getValue() + "(辆)");
cell.setCellStyle(headerStyle); cell.setCellStyle(headerStyle);
cell = subHeaderRow1.createCell(UniversalEnum.FOUR.getNumber()); cell = subHeaderRow1.createCell(UniversalEnum.FOUR.getNumber());
cell.setCellValue(UniversalEnum.THE_SAME_PERIOD_LAST_YEAR.getValue()); cell.setCellValue(UniversalEnum.THE_SAME_PERIOD_LAST_YEAR.getValue() + "(辆)");
cell.setCellStyle(headerStyle); cell.setCellStyle(headerStyle);
//合并单元格,参数依次为起始行,结束行,起始列,结束列 (从0开始) //合并单元格,参数依次为起始行,结束行,起始列,结束列 (从0开始)
@ -949,7 +950,8 @@ public AjaxResult trafficFlowAtTollStationEntranceHour(String startDate, String
sheet.addMergedRegion(new CellRangeAddress(UniversalEnum.ZERO.getNumber(), UniversalEnum.ZERO.getNumber(), UniversalEnum.THREE.getNumber(), UniversalEnum.FOUR.getNumber())); sheet.addMergedRegion(new CellRangeAddress(UniversalEnum.ZERO.getNumber(), UniversalEnum.ZERO.getNumber(), UniversalEnum.THREE.getNumber(), UniversalEnum.FOUR.getNumber()));
int i = 2; int i = 2;
for (String station : stationList) { for (LocationEnum stationEnum : LocationEnum.values()) {
String station = stationEnum.getName();
Row subHeaderRow = sheet.createRow(i); Row subHeaderRow = sheet.createRow(i);
cell = subHeaderRow.createCell(UniversalEnum.ZERO.getNumber()); cell = subHeaderRow.createCell(UniversalEnum.ZERO.getNumber());
cell.setCellValue(station); cell.setCellValue(station);
@ -959,24 +961,40 @@ public AjaxResult trafficFlowAtTollStationEntranceHour(String startDate, String
cell = subHeaderRow.createCell(UniversalEnum.ONE.getNumber()); cell = subHeaderRow.createCell(UniversalEnum.ONE.getNumber());
cell.setCellValue(thisYearEntranceData.get(station).get(0).get("value")); cell.setCellValue(thisYearEntranceData.get(station).get(0).get("value"));
cell.setCellStyle(dataStyle); cell.setCellStyle(dataStyle);
} else {
cell = subHeaderRow.createCell(UniversalEnum.ONE.getNumber());
cell.setCellValue("");
cell.setCellStyle(dataStyle);
} }
if (lastYearEntranceData.containsKey(station)){ if (lastYearEntranceData.containsKey(station)){
cell = subHeaderRow.createCell(UniversalEnum.TWO.getNumber()); cell = subHeaderRow.createCell(UniversalEnum.TWO.getNumber());
cell.setCellValue(lastYearEntranceData.get(station).get(0).get("value")); cell.setCellValue(lastYearEntranceData.get(station).get(0).get("value"));
cell.setCellStyle(dataStyle); cell.setCellStyle(dataStyle);
} else {
cell = subHeaderRow.createCell(UniversalEnum.TWO.getNumber());
cell.setCellValue("");
cell.setCellStyle(dataStyle);
} }
if (thisYearExportData.containsKey(station)){ if (thisYearExportData.containsKey(station)){
cell = subHeaderRow.createCell(UniversalEnum.THREE.getNumber()); cell = subHeaderRow.createCell(UniversalEnum.THREE.getNumber());
cell.setCellValue(thisYearExportData.get(station).get(0).get("value")); cell.setCellValue(thisYearExportData.get(station).get(0).get("value"));
cell.setCellStyle(dataStyle); cell.setCellStyle(dataStyle);
} else {
cell = subHeaderRow.createCell(UniversalEnum.THREE.getNumber());
cell.setCellValue("");
cell.setCellStyle(dataStyle);
} }
if (lastYearExportData.containsKey(station)){ if (lastYearExportData.containsKey(station)){
cell = subHeaderRow.createCell(UniversalEnum.THREE.getNumber()); cell = subHeaderRow.createCell(UniversalEnum.FOUR.getNumber());
cell.setCellValue(lastYearExportData.get(station).get(0).get("value")); cell.setCellValue(lastYearExportData.get(station).get(0).get("value"));
cell.setCellStyle(dataStyle); cell.setCellStyle(dataStyle);
} else {
cell = subHeaderRow.createCell(UniversalEnum.FOUR.getNumber());
cell.setCellValue("");
cell.setCellStyle(dataStyle);
} }
i++; i++;
} }
@ -1111,18 +1129,18 @@ public AjaxResult trafficFlowAtTollStationEntrance(String startDate, String endD
cell.setCellValue(UniversalEnum.EMPTY_STRING.getValue()); cell.setCellValue(UniversalEnum.EMPTY_STRING.getValue());
cell.setCellStyle(headerStyle); cell.setCellStyle(headerStyle);
cell = subHeaderRow1.createCell(UniversalEnum.ONE.getNumber()); cell = subHeaderRow1.createCell(UniversalEnum.ONE.getNumber());
cell.setCellValue(UniversalEnum.CURRENT_TRAFFIC_FLOW.getValue()); cell.setCellValue(UniversalEnum.CURRENT_TRAFFIC_FLOW.getValue() + "(辆)");
cell.setCellStyle(headerStyle); cell.setCellStyle(headerStyle);
cell = subHeaderRow1.createCell(UniversalEnum.TWO.getNumber()); cell = subHeaderRow1.createCell(UniversalEnum.TWO.getNumber());
cell.setCellValue(UniversalEnum.THE_SAME_PERIOD_LAST_YEAR.getValue()); cell.setCellValue(UniversalEnum.THE_SAME_PERIOD_LAST_YEAR.getValue() + "(辆)");
cell.setCellStyle(headerStyle); cell.setCellStyle(headerStyle);
cell = subHeaderRow1.createCell(UniversalEnum.THREE.getNumber()); cell = subHeaderRow1.createCell(UniversalEnum.THREE.getNumber());
cell.setCellValue(UniversalEnum.CURRENT_TRAFFIC_FLOW.getValue()); cell.setCellValue(UniversalEnum.CURRENT_TRAFFIC_FLOW.getValue() + "(辆)");
cell.setCellStyle(headerStyle); cell.setCellStyle(headerStyle);
cell = subHeaderRow1.createCell(UniversalEnum.FOUR.getNumber()); cell = subHeaderRow1.createCell(UniversalEnum.FOUR.getNumber());
cell.setCellValue(UniversalEnum.THE_SAME_PERIOD_LAST_YEAR.getValue()); cell.setCellValue(UniversalEnum.THE_SAME_PERIOD_LAST_YEAR.getValue() + "(辆)");
cell.setCellStyle(headerStyle); cell.setCellStyle(headerStyle);
//合并单元格,参数依次为起始行,结束行,起始列,结束列 (从0开始) //合并单元格,参数依次为起始行,结束行,起始列,结束列 (从0开始)

4
zc-business/src/main/java/com/zc/business/domain/export/AccidentVehicleAnalysis.java

@ -21,10 +21,10 @@ public class AccidentVehicleAnalysis extends BaseEntity
private String typeName; private String typeName;
/** 事件数量 */ /** 事件数量 */
@Excel(name = "事件数量") @Excel(name = "事件数量(起)")
private String num; private String num;
/** 平均处置时长 */ /** 平均处置时长 */
@Excel(name = "平均处置时长") @Excel(name = "平均处置时长(分钟)")
private String avgTime; private String avgTime;
public String getTypeName() { public String getTypeName() {

2
zc-business/src/main/java/com/zc/business/domain/export/AllEventNum.java

@ -20,7 +20,7 @@ public class AllEventNum extends BaseEntity
private String eventName; private String eventName;
/** 数量 */ /** 数量 */
@Excel(name = "数量") @Excel(name = "数量(起)")
private String num; private String num;
/** 占比 */ /** 占比 */
@Excel(name = "占比") @Excel(name = "占比")

4
zc-business/src/main/java/com/zc/business/domain/export/EventTrend.java

@ -21,10 +21,10 @@ public class EventTrend extends BaseEntity
private String hours; private String hours;
/** 感知事件 */ /** 感知事件 */
@Excel(name = "感知事件") @Excel(name = "感知事件(起)")
private String perception; private String perception;
/** 交通事件 */ /** 交通事件 */
@Excel(name = "交通事件") @Excel(name = "交通事件(起)")
private String traffic; private String traffic;
public String getHours() { public String getHours() {

8
zc-business/src/main/java/com/zc/business/domain/export/EventTypeAnalysis.java

@ -21,16 +21,16 @@ public class EventTypeAnalysis extends BaseEntity
private String eventSubclassName; private String eventSubclassName;
/** 事件数量 */ /** 事件数量 */
@Excel(name = "事件数量") @Excel(name = "事件数量(起)")
private String num; private String num;
/** 去年同期总量 */ /** 去年同期总量 */
@Excel(name = "去年同期总量") @Excel(name = "去年同期总量(起)")
private String lastNum; private String lastNum;
/** 平均处置时长 */ /** 平均处置时长 */
@Excel(name = "平均处置时长") @Excel(name = "平均处置时长(分钟)")
private String avgTime; private String avgTime;
/** 去年同期平均处置时长 */ /** 去年同期平均处置时长 */
@Excel(name = "去年同期平均处置时长") @Excel(name = "去年同期平均处置时长(分钟)")
private String lastAvgTime; private String lastAvgTime;

6
zc-business/src/main/java/com/zc/business/domain/export/EventTypePublishManageMonth.java

@ -20,13 +20,13 @@ public class EventTypePublishManageMonth extends BaseEntity
private String typeName; private String typeName;
/** 情报板 */ /** 情报板 */
@Excel(name = "情报板") @Excel(name = "情报板(次)")
private String board; private String board;
/** 语音广播 */ /** 语音广播 */
@Excel(name = "语音广播") @Excel(name = "语音广播(次)")
private String broadcast; private String broadcast;
/** 企业微信 */ /** 企业微信 */
@Excel(name = "企业微信") @Excel(name = "企业微信(次)")
private String weChat; private String weChat;
public String getTypeName() { public String getTypeName() {

4
zc-business/src/main/java/com/zc/business/domain/export/ManyTimesInterval.java

@ -24,10 +24,10 @@ public class ManyTimesInterval extends BaseEntity
private String time; private String time;
/** 本期事件 */ /** 本期事件 */
@Excel(name = "本期事件") @Excel(name = "本期事件(起)")
private String currentData; private String currentData;
/** 去年同期 */ /** 去年同期 */
@Excel(name = "去年同期") @Excel(name = "去年同期(起)")
private String contemporaneousData; private String contemporaneousData;
public String getTime() { public String getTime() {

2
zc-business/src/main/java/com/zc/business/domain/export/NonAutomaticWarningFacility.java

@ -20,7 +20,7 @@ public class NonAutomaticWarningFacility extends BaseEntity
private String facilityName; private String facilityName;
/** 数量 */ /** 数量 */
@Excel(name = "数量") @Excel(name = "数量(起)")
private String number; private String number;
/** 占比 */ /** 占比 */
@Excel(name = "占比") @Excel(name = "占比")

2
zc-business/src/main/java/com/zc/business/domain/export/NonAutomaticWarningTimeType.java

@ -20,7 +20,7 @@ public class NonAutomaticWarningTimeType extends BaseEntity
private String time; private String time;
/** 数量 */ /** 数量 */
@Excel(name = "数量") @Excel(name = "数量(起)")
private String number; private String number;
public String getTime() { public String getTime() {

2
zc-business/src/main/java/com/zc/business/domain/export/NonAutomaticWarningType.java

@ -20,7 +20,7 @@ public class NonAutomaticWarningType extends BaseEntity
private String subclass; private String subclass;
/** 数量 */ /** 数量 */
@Excel(name = "数量") @Excel(name = "数量(起)")
private String number; private String number;
/** 占比 */ /** 占比 */
@Excel(name = "占比") @Excel(name = "占比")

8
zc-business/src/main/java/com/zc/business/domain/export/RealTimeTrafficFlow.java

@ -21,16 +21,16 @@ public class RealTimeTrafficFlow extends BaseEntity
private String name; private String name;
/** 客车 */ /** 客车 */
@Excel(name = "客车") @Excel(name = "客车(辆)")
private String totalPassengerFlow; private String totalPassengerFlow;
/** 货车 */ /** 货车 */
@Excel(name = "货车") @Excel(name = "货车(辆)")
private String typeTruckFlow; private String typeTruckFlow;
/** 专项车 */ /** 专项车 */
@Excel(name = "专项车") @Excel(name = "专项车(辆)")
private String typeSpecialVehicleFlow; private String typeSpecialVehicleFlow;
/** 去年同期 */ /** 去年同期 */
@Excel(name = "去年同期") @Excel(name = "去年同期(辆)")
private String lastYearTotal; private String lastYearTotal;
public String getName() { public String getName() {

8
zc-business/src/main/java/com/zc/business/domain/export/RoadSectionAnalysis.java

@ -21,16 +21,16 @@ public class RoadSectionAnalysis extends BaseEntity
private String section_name; private String section_name;
/** 事故总量 */ /** 事故总量 */
@Excel(name = "事故总量") @Excel(name = "事故总量(起)")
private String num; private String num;
/** 百公里事故总量 */ /** 百公里事故总量 */
@Excel(name = "百公里事故总量") @Excel(name = "百公里事故总量(起)")
private String avgNum; private String avgNum;
/** 去年事故总量 */ /** 去年事故总量 */
@Excel(name = "去年事故总量") @Excel(name = "去年事故总量(起)")
private String lastNum; private String lastNum;
/** 路段里程数 */ /** 路段里程数 */
@Excel(name = "路段里程数") @Excel(name = "路段里程数(公里)")
private String mileage; private String mileage;
public String getSection_name() { public String getSection_name() {

2
zc-business/src/main/java/com/zc/business/domain/export/SectionPerceivedList.java

@ -24,7 +24,7 @@ public class SectionPerceivedList extends BaseEntity
@Excel(name = "路段名称") @Excel(name = "路段名称")
private String sectionName; private String sectionName;
/** 事件数量 */ /** 事件数量 */
@Excel(name = "事件数量") @Excel(name = "事件数量(起)")
private String number; private String number;
public Integer getRank() { public Integer getRank() {

2
zc-business/src/main/java/com/zc/business/domain/export/SectionTrafficRanking.java

@ -24,7 +24,7 @@ public class SectionTrafficRanking extends BaseEntity
@Excel(name = "路段名称") @Excel(name = "路段名称")
private String facilityName; private String facilityName;
/** 车流量 */ /** 车流量 */
@Excel(name = "车流量") @Excel(name = "车流量(辆)")
private String number; private String number;
public Integer getRank() { public Integer getRank() {

4
zc-business/src/main/java/com/zc/business/domain/export/SelectSection.java

@ -21,10 +21,10 @@ public class SelectSection extends BaseEntity
private String stakeMark; private String stakeMark;
/** 本期事件 */ /** 本期事件 */
@Excel(name = "本期事件") @Excel(name = "本期事件(起)")
private String currentData; private String currentData;
/** 去年同期 */ /** 去年同期 */
@Excel(name = "去年同期") @Excel(name = "去年同期(起)")
private String contemporaneousData; private String contemporaneousData;
public String getStakeMark() { public String getStakeMark() {

12
zc-business/src/main/java/com/zc/business/domain/export/SelectStateType.java

@ -21,27 +21,27 @@ public class SelectStateType extends BaseEntity
private String sectionName; private String sectionName;
/** 上报 */ /** 上报 */
@Excel(name = "上报") @Excel(name = "上报(起)")
private String reporting; private String reporting;
/** 已完成 */ /** 已完成 */
@Excel(name = "已完成") @Excel(name = "已完成(起)")
private String completed; private String completed;
/** 已终止 */ /** 已终止 */
@Excel(name = "已终止") @Excel(name = "已终止(起)")
private String terminated; private String terminated;
/** 自动结束 */ /** 自动结束 */
@Excel(name = "自动结束") @Excel(name = "自动结束(起)")
private String automaticTermination; private String automaticTermination;
/** 去年同期 */ /** 去年同期 */
@Excel(name = "去年同期") @Excel(name = "去年同期(起)")
private String contemporaneousData; private String contemporaneousData;
/** 平均时长 */ /** 平均时长 */
@Excel(name = "平均时长") @Excel(name = "平均时长(分钟)")
private String averageDuration; private String averageDuration;
public String getSectionName() { public String getSectionName() {

6
zc-business/src/main/java/com/zc/business/domain/export/SelectTollStationAnalysis.java

@ -21,13 +21,13 @@ public class SelectTollStationAnalysis extends BaseEntity
private String facilityName; private String facilityName;
/** 封闭 */ /** 封闭 */
@Excel(name = "封闭") @Excel(name = "封闭(起)")
private String facilityClose; private String facilityClose;
/** 限行 */ /** 限行 */
@Excel(name = "限行") @Excel(name = "限行(起)")
private String facilityRestriction; private String facilityRestriction;
/** 合计 */ /** 合计 */
@Excel(name = "合计") @Excel(name = "合计(起)")
private String sum; private String sum;
public String getFacilityName() { public String getFacilityName() {

2
zc-business/src/main/java/com/zc/business/domain/export/SelectWarningType.java

@ -21,7 +21,7 @@ public class SelectWarningType extends BaseEntity
private String warningType; private String warningType;
/** 数量 */ /** 数量 */
@Excel(name = "数量") @Excel(name = "数量(起)")
private String number; private String number;
/** 占比 */ /** 占比 */

2
zc-business/src/main/java/com/zc/business/domain/export/StatisticsPublishManage.java

@ -20,7 +20,7 @@ public class StatisticsPublishManage extends BaseEntity
private String channelName; private String channelName;
/** 数量 */ /** 数量 */
@Excel(name = "数量") @Excel(name = "数量(起)")
private String num; private String num;
/** 占比 */ /** 占比 */
@Excel(name = "占比") @Excel(name = "占比")

4
zc-business/src/main/java/com/zc/business/domain/export/TollStationAnalysis.java

@ -20,10 +20,10 @@ public class TollStationAnalysis extends BaseEntity
private String facilityName; private String facilityName;
/** 封闭 */ /** 封闭 */
@Excel(name = "封闭") @Excel(name = "封闭(起)")
private String trafficClose; private String trafficClose;
/** 限行 */ /** 限行 */
@Excel(name = "限行") @Excel(name = "限行(起)")
private String trafficRestriction; private String trafficRestriction;
public String getFacilityName() { public String getFacilityName() {

4
zc-business/src/main/java/com/zc/business/domain/export/TrafficPeriodAnalysis.java

@ -21,10 +21,10 @@ public class TrafficPeriodAnalysis extends BaseEntity
private String time; private String time;
/** 本期车流量 */ /** 本期车流量 */
@Excel(name = "本期车流量") @Excel(name = "本期车流量(辆)")
private String currentData; private String currentData;
/** 去年同期 */ /** 去年同期 */
@Excel(name = "去年同期") @Excel(name = "去年同期(辆)")
private String contemporaneousData; private String contemporaneousData;
public String getTime() { public String getTime() {

6
zc-business/src/main/java/com/zc/business/domain/export/TrendsPublishManage.java

@ -20,13 +20,13 @@ public class TrendsPublishManage extends BaseEntity
private String publishTime; private String publishTime;
/** 情报板 */ /** 情报板 */
@Excel(name = "情报板") @Excel(name = "情报板(次)")
private String board; private String board;
/** 语音广播 */ /** 语音广播 */
@Excel(name = "语音广播") @Excel(name = "语音广播(次)")
private String broadcast; private String broadcast;
/** 企业微信 */ /** 企业微信 */
@Excel(name = "企业微信") @Excel(name = "企业微信(次)")
private String weChat; private String weChat;
public String getPublishTime() { public String getPublishTime() {

4
zc-business/src/main/resources/mapper/business/DcPerceivedEventsWarningMapper.xml

@ -664,7 +664,7 @@
ORDER BY number DESC ORDER BY number DESC
</select> </select>
<select id="newSelectStateType" resultType="java.util.HashMap"> <select id="newSelectStateType" resultType="java.util.HashMap">
SELECT s.section_name sectionName, w.warning_state AS warningState, COUNT(*) AS num SELECT s.section_name sectionName,s.start_stake_mark startStakeMark, w.warning_state AS warningState, COUNT(*) AS num
FROM dc_warning AS w FROM dc_warning AS w
LEFT JOIN dc_stake_mark AS sm ON w.stake_mark = sm.stake_mark and w.direction=sm.direction LEFT JOIN dc_stake_mark AS sm ON w.stake_mark = sm.stake_mark and w.direction=sm.direction
LEFT JOIN dc_road_section AS s ON sm.section_id = s.id LEFT JOIN dc_road_section AS s ON sm.section_id = s.id
@ -673,7 +673,7 @@
ORDER BY s.start_stake_mark ORDER BY s.start_stake_mark
</select> </select>
<select id="newStateDuration" resultType="java.util.HashMap"> <select id="newStateDuration" resultType="java.util.HashMap">
SELECT s.section_name sectionName, s.id sectionId, SELECT s.section_name sectionName, s.id sectionId,s.start_stake_mark startStakeMark,
ROUND(AVG(TIMESTAMPDIFF(MINUTE, w.warning_time, w.end_time)), 2) AS avg ROUND(AVG(TIMESTAMPDIFF(MINUTE, w.warning_time, w.end_time)), 2) AS avg
FROM dc_warning AS w FROM dc_warning AS w
LEFT JOIN LEFT JOIN

Loading…
Cancel
Save