1.自定义报表功能调整
2.暂降事件列表添加后端排序功能
This commit is contained in:
@@ -64,5 +64,9 @@ public class TransientParam extends DeviceInfoParam.BusinessParam {
|
|||||||
|
|
||||||
@ApiModelProperty("在线离线 0:在线 1:离线")
|
@ApiModelProperty("在线离线 0:在线 1:离线")
|
||||||
private Integer isType;
|
private Integer isType;
|
||||||
|
|
||||||
|
private String sortBy;
|
||||||
|
|
||||||
|
private String orderBy;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -301,8 +301,23 @@ public class TransientServiceImpl implements TransientService {
|
|||||||
// 事件
|
// 事件
|
||||||
.in(CollUtil.isNotEmpty(transientParam.getWaveType()), RmpEventDetailPO::getEventType, transientParam.getWaveType())
|
.in(CollUtil.isNotEmpty(transientParam.getWaveType()), RmpEventDetailPO::getEventType, transientParam.getWaveType())
|
||||||
.in(CollUtil.isNotEmpty(transientParam.getEventReason()), RmpEventDetailPO::getAdvanceReason, transientParam.getEventReason())
|
.in(CollUtil.isNotEmpty(transientParam.getEventReason()), RmpEventDetailPO::getAdvanceReason, transientParam.getEventReason())
|
||||||
.in(CollUtil.isNotEmpty(transientParam.getEventType()), RmpEventDetailPO::getAdvanceType, transientParam.getEventType())
|
.in(CollUtil.isNotEmpty(transientParam.getEventType()), RmpEventDetailPO::getAdvanceType, transientParam.getEventType());
|
||||||
.orderByDesc(RmpEventDetailPO::getStartTime);
|
|
||||||
|
|
||||||
|
if(StrUtil.isNotBlank(transientParam.getOrderBy())){
|
||||||
|
if(transientParam.getSortBy().equals("start_time")){
|
||||||
|
wrapper.orderBy(true,transientParam.getOrderBy().equals("asc"),RmpEventDetailPO::getStartTime);
|
||||||
|
}else if(transientParam.getSortBy().equals("feature_amplitude")){
|
||||||
|
wrapper.orderBy(true,transientParam.getOrderBy().equals("asc"),RmpEventDetailPO::getFeatureAmplitude);
|
||||||
|
}else if(transientParam.getSortBy().equals("firstMs")){
|
||||||
|
wrapper.orderBy(true,transientParam.getOrderBy().equals("asc"),RmpEventDetailPO::getFirstMs);
|
||||||
|
}else if(transientParam.getSortBy().equals("duration")){
|
||||||
|
wrapper.orderBy(true,transientParam.getOrderBy().equals("asc"),RmpEventDetailPO::getDuration);
|
||||||
|
}
|
||||||
|
}else {
|
||||||
|
wrapper.orderByDesc(RmpEventDetailPO::getStartTime);
|
||||||
|
}
|
||||||
|
|
||||||
//暂态幅值
|
//暂态幅值
|
||||||
if (Objects.nonNull(transientParam.getEventValueMin())) {
|
if (Objects.nonNull(transientParam.getEventValueMin())) {
|
||||||
wrapper.ge(RmpEventDetailPO::getFeatureAmplitude, transientParam.getEventValueMin());
|
wrapper.ge(RmpEventDetailPO::getFeatureAmplitude, transientParam.getEventValueMin());
|
||||||
|
|||||||
@@ -36,4 +36,7 @@ public class ReportSearchParam {
|
|||||||
//目前用于区分不同系统资源,null默认 1.无线系统,配合cs-device
|
//目前用于区分不同系统资源,null默认 1.无线系统,配合cs-device
|
||||||
private Integer resourceType;
|
private Integer resourceType;
|
||||||
|
|
||||||
|
//浙江无线报表特殊标识 null为通用报表 1.浙江无线报表
|
||||||
|
private Integer customType;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -32,4 +32,6 @@ public class ExcelRptTemp extends BaseEntity {
|
|||||||
|
|
||||||
private String reportForm;
|
private String reportForm;
|
||||||
|
|
||||||
|
private Integer sort;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -266,4 +266,6 @@ public class CustomReportController extends BaseController {
|
|||||||
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, res, methodDescribe);
|
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, res, methodDescribe);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -42,19 +42,21 @@
|
|||||||
|
|
||||||
<select id="getReportTemplateByDept" resultType="ReportTemplateVO">
|
<select id="getReportTemplateByDept" resultType="ReportTemplateVO">
|
||||||
SELECT
|
SELECT
|
||||||
DISTINCT
|
DISTINCT
|
||||||
a.id,
|
a.id,
|
||||||
a.NAME,
|
a.NAME,
|
||||||
a.activation,
|
a.activation,
|
||||||
a.report_form
|
a.report_form,
|
||||||
|
a.sort
|
||||||
FROM
|
FROM
|
||||||
sys_excel_rpt_temp a
|
sys_excel_rpt_temp a
|
||||||
LEFT JOIN sys_dept_temp b ON a.Id = b.temp_id
|
LEFT JOIN sys_dept_temp b ON a.Id = b.temp_id
|
||||||
WHERE
|
WHERE
|
||||||
a.activation = 1
|
a.activation = 1
|
||||||
and b.dept_id in
|
and b.dept_id in
|
||||||
<foreach collection="ids" index="index" item="item" separator="," open="(" close=")">
|
<foreach collection="ids" index="index" item="item" separator="," open="(" close=")">
|
||||||
#{item}
|
#{item}
|
||||||
</foreach>
|
</foreach>
|
||||||
|
order by a.sort asc
|
||||||
</select>
|
</select>
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|||||||
@@ -118,4 +118,7 @@ public interface CustomReportService {
|
|||||||
List<ReportTemplateVO> getTemplateByDept(String id);
|
List<ReportTemplateVO> getTemplateByDept(String id);
|
||||||
|
|
||||||
void viewCustomReportTemplateById(String id, HttpServletResponse response);
|
void viewCustomReportTemplateById(String id, HttpServletResponse response);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,8 +1,11 @@
|
|||||||
package com.njcn.harmonic.service.impl;
|
package com.njcn.harmonic.service.impl;
|
||||||
|
|
||||||
import cn.hutool.core.collection.CollUtil;
|
import cn.hutool.core.collection.CollUtil;
|
||||||
|
import cn.hutool.core.date.DatePattern;
|
||||||
import cn.hutool.core.date.DateUtil;
|
import cn.hutool.core.date.DateUtil;
|
||||||
|
import cn.hutool.core.date.LocalDateTimeUtil;
|
||||||
import cn.hutool.core.io.IoUtil;
|
import cn.hutool.core.io.IoUtil;
|
||||||
|
import cn.hutool.core.text.StrBuilder;
|
||||||
import cn.hutool.core.text.StrPool;
|
import cn.hutool.core.text.StrPool;
|
||||||
import cn.hutool.core.util.CharsetUtil;
|
import cn.hutool.core.util.CharsetUtil;
|
||||||
import cn.hutool.core.util.StrUtil;
|
import cn.hutool.core.util.StrUtil;
|
||||||
@@ -13,6 +16,8 @@ import com.njcn.common.pojo.enums.common.DataStateEnum;
|
|||||||
import com.njcn.common.pojo.exception.BusinessException;
|
import com.njcn.common.pojo.exception.BusinessException;
|
||||||
import com.njcn.common.utils.FileUtil;
|
import com.njcn.common.utils.FileUtil;
|
||||||
import com.njcn.csdevice.api.CsCommTerminalFeignClient;
|
import com.njcn.csdevice.api.CsCommTerminalFeignClient;
|
||||||
|
import com.njcn.csdevice.api.WlRecordFeignClient;
|
||||||
|
import com.njcn.csdevice.pojo.po.WlRecord;
|
||||||
import com.njcn.device.biz.commApi.CommTerminalGeneralClient;
|
import com.njcn.device.biz.commApi.CommTerminalGeneralClient;
|
||||||
import com.njcn.device.pq.api.DeptLineFeignClient;
|
import com.njcn.device.pq.api.DeptLineFeignClient;
|
||||||
import com.njcn.device.pq.api.DeviceUnitClient;
|
import com.njcn.device.pq.api.DeviceUnitClient;
|
||||||
@@ -62,10 +67,12 @@ import sun.reflect.generics.tree.Tree;
|
|||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
import java.io.*;
|
import java.io.*;
|
||||||
import java.math.BigDecimal;
|
import java.math.BigDecimal;
|
||||||
|
import java.math.RoundingMode;
|
||||||
import java.text.DateFormat;
|
import java.text.DateFormat;
|
||||||
import java.text.ParseException;
|
import java.text.ParseException;
|
||||||
import java.text.SimpleDateFormat;
|
import java.text.SimpleDateFormat;
|
||||||
import java.time.LocalDateTime;
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.format.DateTimeFormatter;
|
||||||
import java.util.*;
|
import java.util.*;
|
||||||
import java.util.function.Function;
|
import java.util.function.Function;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
@@ -103,6 +110,8 @@ public class CustomReportServiceImpl implements CustomReportService {
|
|||||||
|
|
||||||
private final CsCommTerminalFeignClient csCommTerminalFeignClient;
|
private final CsCommTerminalFeignClient csCommTerminalFeignClient;
|
||||||
|
|
||||||
|
private final WlRecordFeignClient wlRecordFeignClient;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean addCustomReportTemplate(ReportTemplateParam reportTemplateParam) {
|
public boolean addCustomReportTemplate(ReportTemplateParam reportTemplateParam) {
|
||||||
checkName(reportTemplateParam, false);
|
checkName(reportTemplateParam, false);
|
||||||
@@ -206,6 +215,7 @@ public class CustomReportServiceImpl implements CustomReportService {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<ReportTemplateVO> getTemplateList(ReportSearchParam reportSearchParam) {
|
public List<ReportTemplateVO> getTemplateList(ReportSearchParam reportSearchParam) {
|
||||||
return excelRptTempMapper.getReportTemplateList(reportSearchParam);
|
return excelRptTempMapper.getReportTemplateList(reportSearchParam);
|
||||||
@@ -241,10 +251,18 @@ public class CustomReportServiceImpl implements CustomReportService {
|
|||||||
if (Objects.isNull(excelRptTemp)) {
|
if (Objects.isNull(excelRptTemp)) {
|
||||||
throw new BusinessException(HarmonicResponseEnum.CUSTOM_REPORT_ACTIVE);
|
throw new BusinessException(HarmonicResponseEnum.CUSTOM_REPORT_ACTIVE);
|
||||||
}
|
}
|
||||||
analyzeReport(reportSearchParam, excelRptTemp, response);
|
if(Objects.isNull(reportSearchParam.getCustomType())){
|
||||||
|
//通用报表
|
||||||
|
analyzeReport(reportSearchParam, excelRptTemp, response);
|
||||||
|
}else {
|
||||||
|
//浙江无线报表
|
||||||
|
analyzeReportZhejiang(reportSearchParam, excelRptTemp, response);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<ReportTreeVO> reportChooseTree() {
|
public List<ReportTreeVO> reportChooseTree() {
|
||||||
DictData dic = dicDataFeignClient.getDicDataByNameAndTypeName(DicDataTypeEnum.CS_DATA_TYPE.getName(), DicDataEnum.EPD.getName()).getData();
|
DictData dic = dicDataFeignClient.getDicDataByNameAndTypeName(DicDataTypeEnum.CS_DATA_TYPE.getName(), DicDataEnum.EPD.getName()).getData();
|
||||||
@@ -428,10 +446,10 @@ public class CustomReportServiceImpl implements CustomReportService {
|
|||||||
*/
|
*/
|
||||||
private Map<String, String> unitMap(ReportSearchParam reportSearchParam) {
|
private Map<String, String> unitMap(ReportSearchParam reportSearchParam) {
|
||||||
PqsDeviceUnit deviceUnit;
|
PqsDeviceUnit deviceUnit;
|
||||||
if(Objects.isNull(reportSearchParam.getResourceType())){
|
if (Objects.isNull(reportSearchParam.getResourceType())) {
|
||||||
deviceUnit = commTerminalGeneralClient.lineUnitDetail(reportSearchParam.getLineId()).getData();
|
deviceUnit = commTerminalGeneralClient.lineUnitDetail(reportSearchParam.getLineId()).getData();
|
||||||
}else {
|
} else {
|
||||||
deviceUnit = csCommTerminalFeignClient.lineUnitDetail(reportSearchParam.getLineId()).getData();
|
deviceUnit = csCommTerminalFeignClient.lineUnitDetail(reportSearchParam.getLineId()).getData();
|
||||||
}
|
}
|
||||||
List<DictData> dictData = dicDataFeignClient.getDicDataByTypeCode(DicDataTypeEnum.DEVICE_UNIT.getCode()).getData();
|
List<DictData> dictData = dicDataFeignClient.getDicDataByTypeCode(DicDataTypeEnum.DEVICE_UNIT.getCode()).getData();
|
||||||
Map<String, String> unit = new HashMap<>();
|
Map<String, String> unit = new HashMap<>();
|
||||||
@@ -657,27 +675,21 @@ public class CustomReportServiceImpl implements CustomReportService {
|
|||||||
|
|
||||||
|
|
||||||
//处理指标是否合格
|
//处理指标是否合格
|
||||||
reportLimitList = reportLimitList.stream()
|
reportLimitList = new LinkedHashSet<>(reportLimitList).stream().sorted(Comparator.comparing(ReportTemplateDTO::getItemName)).collect(Collectors.toList());
|
||||||
.collect(Collectors.collectingAndThen(Collectors.toCollection(() -> new TreeSet<>(Comparator.comparing(ReportTemplateDTO::getItemName))), ArrayList::new));
|
|
||||||
|
|
||||||
Map<String, Float> limitMap = overLimitDeal(reportLimitList, reportSearchParam);
|
Map<String, Float> limitMap = overLimitDeal(reportLimitList, reportSearchParam);
|
||||||
//存放限值指标的map
|
//存放限值指标的map
|
||||||
Map<String, ReportTemplateDTO> limitTargetMapX = reportLimitList.stream().collect(Collectors.toMap(ReportTemplateDTO::getItemName, Function.identity()));
|
Map<String, ReportTemplateDTO> limitTargetMapX = reportLimitList.stream().collect(Collectors.toMap(ReportTemplateDTO::getItemName, Function.identity()));
|
||||||
|
|
||||||
List<ReportTemplateDTO> endList = new ArrayList<>();
|
List<ReportTemplateDTO> endList = new ArrayList<>();
|
||||||
if (CollUtil.isNotEmpty(reportTemplateDTOList)) {
|
if (CollUtil.isNotEmpty(reportTemplateDTOList)) {
|
||||||
|
|
||||||
//开始组织sql
|
//开始组织sql
|
||||||
reportTemplateDTOList = reportTemplateDTOList.stream()
|
reportTemplateDTOList = new LinkedHashSet<>(reportTemplateDTOList).stream().sorted(Comparator.comparing(ReportTemplateDTO::getItemName)).collect(Collectors.toList());
|
||||||
.collect(Collectors.collectingAndThen(Collectors.toCollection(
|
|
||||||
() -> new TreeSet<>(Comparator.comparing(ReportTemplateDTO::getItemName))), ArrayList::new));
|
|
||||||
|
|
||||||
Map<String, List<ReportTemplateDTO>> classMap = reportTemplateDTOList.stream().collect(Collectors.groupingBy(ReportTemplateDTO::getResourceId));
|
Map<String, List<ReportTemplateDTO>> classMap = reportTemplateDTOList.stream().collect(Collectors.groupingBy(ReportTemplateDTO::getResourceId));
|
||||||
|
//定义存放越限指标的map
|
||||||
Map<String, ReportTemplateDTO> assNoPassMap = new HashMap<>();
|
Map<String, ReportTemplateDTO> assNoPassMap = new HashMap<>();
|
||||||
long deal = System.currentTimeMillis();
|
long deal = System.currentTimeMillis();
|
||||||
classMap.forEach((classKey, templateValue) -> {
|
classMap.forEach((classKey, templateValue) -> {
|
||||||
Map<String, List<ReportTemplateDTO>> valueTypeMap = templateValue.stream().collect(Collectors.groupingBy(ReportTemplateDTO::getStatMethod));
|
Map<String, List<ReportTemplateDTO>> valueTypeMap = templateValue.stream().collect(Collectors.groupingBy(ReportTemplateDTO::getStatMethod));
|
||||||
|
|
||||||
//avg.max,min,cp95
|
//avg.max,min,cp95
|
||||||
valueTypeMap.forEach((valueTypeKey, valueTypeVal) -> {
|
valueTypeMap.forEach((valueTypeKey, valueTypeVal) -> {
|
||||||
|
|
||||||
@@ -699,28 +711,8 @@ public class CustomReportServiceImpl implements CustomReportService {
|
|||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
//处理合格率
|
//处理指标最终判定合格还是不合格
|
||||||
assNoPassMap.forEach((key, val) -> {
|
dealTargetResult(assNoPassMap,limitTargetMapX,endList);
|
||||||
limitTargetMapX.remove(key);
|
|
||||||
if ("Voltage_Dev".equals(val.getTemplateName()) || "Freq_Dev".equals(val.getTemplateName())) {
|
|
||||||
val.setValue("±" + val.getValue());
|
|
||||||
}
|
|
||||||
if (val.getOverLimitFlag() == 1) {
|
|
||||||
val.setValue("不合格 (" + val.getValue() + ")");
|
|
||||||
} else {
|
|
||||||
val.setValue("合格 (" + val.getValue() + ")");
|
|
||||||
}
|
|
||||||
endList.add(val);
|
|
||||||
});
|
|
||||||
|
|
||||||
limitTargetMapX.forEach((key, val) -> {
|
|
||||||
if (Objects.isNull(val.getOverLimitFlag())) {
|
|
||||||
val.setValue("/");
|
|
||||||
} else {
|
|
||||||
val.setValue("合格");
|
|
||||||
}
|
|
||||||
endList.add(val);
|
|
||||||
});
|
|
||||||
|
|
||||||
long dealEnd = System.currentTimeMillis();
|
long dealEnd = System.currentTimeMillis();
|
||||||
System.out.println("模板解析时间:" + (temEnd - begin) / 1000 + "S");
|
System.out.println("模板解析时间:" + (temEnd - begin) / 1000 + "S");
|
||||||
@@ -744,7 +736,6 @@ public class CustomReportServiceImpl implements CustomReportService {
|
|||||||
|
|
||||||
|
|
||||||
//2、把itemName的value赋给v和m
|
//2、把itemName的value赋给v和m
|
||||||
|
|
||||||
jsonArray.forEach(item -> {
|
jsonArray.forEach(item -> {
|
||||||
JSONObject jsonObject = (JSONObject) item;
|
JSONObject jsonObject = (JSONObject) item;
|
||||||
JSONArray itemArr = (JSONArray) jsonObject.get("celldata");
|
JSONArray itemArr = (JSONArray) jsonObject.get("celldata");
|
||||||
@@ -958,6 +949,506 @@ public class CustomReportServiceImpl implements CustomReportService {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
private void analyzeReportZhejiang(ReportSearchParam reportSearchParam, ExcelRptTemp excelRptTemp, HttpServletResponse response) {
|
||||||
|
|
||||||
|
//指标
|
||||||
|
List<ReportTemplateDTO> reportTemplateDTOList = new ArrayList<>();
|
||||||
|
//限值
|
||||||
|
List<ReportTemplateDTO> reportLimitList = new ArrayList<>();
|
||||||
|
//台账
|
||||||
|
List<ReportTemplateDTO> terminalList = new ArrayList<>();
|
||||||
|
JSONArray jsonArray;
|
||||||
|
try (InputStream fileStream = fileStorageUtil.getFileStream(excelRptTemp.getContent())) {
|
||||||
|
jsonArray = new JSONArray(new JSONTokener(fileStream, new JSONConfig()));
|
||||||
|
parseTemplateZhejiang(jsonArray, reportTemplateDTOList, reportLimitList, terminalList);
|
||||||
|
} catch (Exception e) {
|
||||||
|
throw new BusinessException(HarmonicResponseEnum.CUSTOM_REPORT_JSON);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
long temEnd = System.currentTimeMillis();
|
||||||
|
|
||||||
|
|
||||||
|
//处理指标是否合格
|
||||||
|
reportLimitList = new LinkedHashSet<>(reportLimitList)
|
||||||
|
.stream()
|
||||||
|
.sorted(Comparator.comparing(ReportTemplateDTO::getItemName))
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
|
||||||
|
Map<String, Float> limitMap = overLimitDeal(reportLimitList, reportSearchParam);
|
||||||
|
//存放限值指标的map
|
||||||
|
Map<String, ReportTemplateDTO> limitTargetMapX = reportLimitList.stream().collect(Collectors.toMap(ReportTemplateDTO::getItemName, Function.identity()));
|
||||||
|
|
||||||
|
List<ReportTemplateDTO> endList = new ArrayList<>();
|
||||||
|
if (CollUtil.isNotEmpty(reportTemplateDTOList)) {
|
||||||
|
|
||||||
|
//组装最后监测点条件
|
||||||
|
List<WlRecord> wlRecordList = wlRecordFeignClient.getWlAssByWlId(reportSearchParam.getLineId()).getData();
|
||||||
|
if (CollUtil.isEmpty(wlRecordList)) {
|
||||||
|
throw new BusinessException("当前测试项无测试数据");
|
||||||
|
}
|
||||||
|
|
||||||
|
//开始组织sql
|
||||||
|
reportTemplateDTOList = new LinkedHashSet<>(reportTemplateDTOList)
|
||||||
|
.stream()
|
||||||
|
.sorted(Comparator.comparing(ReportTemplateDTO::getItemName))
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
|
||||||
|
|
||||||
|
Map<String, List<ReportTemplateDTO>> classMap = reportTemplateDTOList.stream().collect(Collectors.groupingBy(ReportTemplateDTO::getResourceId));
|
||||||
|
Map<String, ReportTemplateDTO> assNoPassMap = new HashMap<>();
|
||||||
|
long deal = System.currentTimeMillis();
|
||||||
|
classMap.forEach((classKey, templateValue) -> {
|
||||||
|
Map<String, List<ReportTemplateDTO>> valueTypeMap = templateValue.stream().collect(Collectors.groupingBy(ReportTemplateDTO::getStatMethod));
|
||||||
|
|
||||||
|
//avg.max,min,cp95
|
||||||
|
valueTypeMap.forEach((valueTypeKey, valueTypeVal) -> {
|
||||||
|
|
||||||
|
//相别分组
|
||||||
|
Map<String, List<ReportTemplateDTO>> phaseMap = valueTypeVal.stream().collect(Collectors.groupingBy(ReportTemplateDTO::getPhase));
|
||||||
|
phaseMap.forEach((phaseKey, phaseVal) -> {
|
||||||
|
StringBuilder sql = new StringBuilder(InfluxDbSqlConstant.SELECT);
|
||||||
|
if (InfluxDbSqlConstant.MAX.equalsIgnoreCase(valueTypeKey)) {
|
||||||
|
assSqlZhejiang(phaseVal, sql, endList, InfluxDbSqlConstant.MAX, reportSearchParam, limitTargetMapX, limitMap, assNoPassMap, wlRecordList);
|
||||||
|
} else if (InfluxDbSqlConstant.MIN.equalsIgnoreCase(valueTypeKey)) {
|
||||||
|
assSqlZhejiang(phaseVal, sql, endList, InfluxDbSqlConstant.MIN, reportSearchParam, limitTargetMapX, limitMap, assNoPassMap, wlRecordList);
|
||||||
|
} else if (InfluxDbSqlConstant.AVG_WEB.equalsIgnoreCase(valueTypeKey)) {
|
||||||
|
assSqlZhejiang(phaseVal, sql, endList, InfluxDbSqlConstant.AVG, reportSearchParam, limitTargetMapX, limitMap, assNoPassMap, wlRecordList);
|
||||||
|
} else if (InfluxDbSqlConstant.CP95.equalsIgnoreCase(valueTypeKey)) {
|
||||||
|
assSqlZhejiang(phaseVal, sql, endList, InfluxDbSqlConstant.PERCENTILE, reportSearchParam, limitTargetMapX, limitMap, assNoPassMap, wlRecordList);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
});
|
||||||
|
|
||||||
|
//处理指标最终判定合格还是不合格
|
||||||
|
dealTargetResult(assNoPassMap,limitTargetMapX,endList);
|
||||||
|
|
||||||
|
long dealEnd = System.currentTimeMillis();
|
||||||
|
System.out.println("查询数据库花费时间" + (dealEnd - deal) / 1000 + "S");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
if (CollUtil.isNotEmpty(endList)) {
|
||||||
|
long jie = System.currentTimeMillis();
|
||||||
|
//数据单位信息
|
||||||
|
Map<String, String> unit = unitMap(reportSearchParam);
|
||||||
|
//进行反向赋值到模板
|
||||||
|
//1、根据itemName分组
|
||||||
|
Map<String, List<ReportTemplateDTO>> assMap = endList.stream().collect(Collectors.groupingBy(ReportTemplateDTO::getItemName));
|
||||||
|
//处理台账信息
|
||||||
|
/*Map<String, String> terminalMap = null;
|
||||||
|
if (CollUtil.isNotEmpty(terminalList)) {
|
||||||
|
terminalMap = commTerminalGeneralClient.getCustomDetailByLineId(reportSearchParam.getLineId()).getData();
|
||||||
|
}
|
||||||
|
Map<String, String> finalTerminalMap = terminalMap;*/
|
||||||
|
|
||||||
|
|
||||||
|
//2、把itemName的value赋给v和m
|
||||||
|
dealExcelResult(jsonArray,assMap,unit);
|
||||||
|
long jieEnd = System.currentTimeMillis();
|
||||||
|
|
||||||
|
System.out.println("组装信息耗时 " + (jieEnd - jie) / 1000 + "S");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
long daochu = System.currentTimeMillis();
|
||||||
|
//导出自定义报表
|
||||||
|
downReport(jsonArray, response);
|
||||||
|
long daochuEnd = System.currentTimeMillis();
|
||||||
|
System.out.println("导出耗时 " + (daochuEnd - daochu) / 1000 + "S");
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
private void assSqlZhejiang(List<ReportTemplateDTO> data, StringBuilder sql, List<ReportTemplateDTO> endList, String method, ReportSearchParam reportSearchParam, Map<String, ReportTemplateDTO> limitMap, Map<String, Float> overLimitMap, Map<String, ReportTemplateDTO> assNoPassMap, List<WlRecord> wlRecordList) {
|
||||||
|
//sql拼接示例:select MAX(IHA2) as IHA2 from power_quality_data where Phase = 'A' and LineId='1324564568' and Stat_Method='max' tz('Asia/Shanghai')
|
||||||
|
//cp95函数特殊处理 PERCENTILE(field_key, N)
|
||||||
|
if (InfluxDbSqlConstant.PERCENTILE.equals(method)) {
|
||||||
|
for (int i = 0; i < data.size(); i++) {
|
||||||
|
if (i == data.size() - 1) {
|
||||||
|
sql.append(InfluxDbSqlConstant.PERCENTILE)
|
||||||
|
.append(InfluxDbSqlConstant.LBK)
|
||||||
|
.append(data.get(i).getTemplateName()).append(InfluxDbSqlConstant.NUM_95)
|
||||||
|
.append(InfluxDbSqlConstant.RBK)
|
||||||
|
.append(InfluxDbSqlConstant.AS).append(InfluxDbSqlConstant.DQM)
|
||||||
|
.append(data.get(i).getItemName()).append(InfluxDbSqlConstant.DQM);
|
||||||
|
} else {
|
||||||
|
sql.append(InfluxDbSqlConstant.PERCENTILE)
|
||||||
|
.append(InfluxDbSqlConstant.LBK)
|
||||||
|
.append(data.get(i).getTemplateName()).append(InfluxDbSqlConstant.NUM_95)
|
||||||
|
.append(InfluxDbSqlConstant.RBK)
|
||||||
|
.append(InfluxDbSqlConstant.AS).append(InfluxDbSqlConstant.DQM)
|
||||||
|
.append(data.get(i).getItemName()).append(InfluxDbSqlConstant.DQM).append(StrUtil.COMMA);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
for (int i = 0; i < data.size(); i++) {
|
||||||
|
if (i == data.size() - 1) {
|
||||||
|
sql.append(method)
|
||||||
|
.append(InfluxDbSqlConstant.LBK)
|
||||||
|
.append(data.get(i).getTemplateName())
|
||||||
|
.append(InfluxDbSqlConstant.RBK)
|
||||||
|
.append(InfluxDbSqlConstant.AS).append(InfluxDbSqlConstant.DQM)
|
||||||
|
.append(data.get(i).getItemName()).append(InfluxDbSqlConstant.DQM);
|
||||||
|
} else {
|
||||||
|
sql.append(method)
|
||||||
|
.append(InfluxDbSqlConstant.LBK)
|
||||||
|
.append(data.get(i).getTemplateName())
|
||||||
|
.append(InfluxDbSqlConstant.RBK)
|
||||||
|
.append(InfluxDbSqlConstant.AS).append(InfluxDbSqlConstant.DQM)
|
||||||
|
.append(data.get(i).getItemName()).append(InfluxDbSqlConstant.DQM).append(StrUtil.COMMA);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
sql.append(StrPool.C_SPACE).append(InfluxDbSqlConstant.FROM).append("pqd_data");
|
||||||
|
//相别特殊处理
|
||||||
|
sql.append(InfluxDbSqlConstant.WHERE)
|
||||||
|
.append(InfluxDBTableConstant.PHASIC_TYPE)
|
||||||
|
.append(InfluxDbSqlConstant.EQ)
|
||||||
|
.append(InfluxDbSqlConstant.QM)
|
||||||
|
.append(data.get(0).getPhase())
|
||||||
|
.append(InfluxDbSqlConstant.QM);
|
||||||
|
|
||||||
|
//data_flicker、data_fluc、data_plt 无 value_type
|
||||||
|
sql.append(InfluxDbSqlConstant.AND)
|
||||||
|
.append(InfluxDBTableConstant.VALUE_TYPE)
|
||||||
|
.append(InfluxDbSqlConstant.EQ)
|
||||||
|
.append(InfluxDbSqlConstant.QM)
|
||||||
|
.append(data.get(0).getStatMethod().toLowerCase())
|
||||||
|
.append(InfluxDbSqlConstant.QM);
|
||||||
|
|
||||||
|
List<Map<String, Object>> allList = new ArrayList<>();
|
||||||
|
for (WlRecord wlRecord : wlRecordList) {
|
||||||
|
StringBuilder temSql = new StringBuilder(sql);
|
||||||
|
String start = LocalDateTimeUtil.format(wlRecord.getStartTime(), DateTimeFormatter.ofPattern(DatePattern.NORM_DATETIME_PATTERN));
|
||||||
|
String end = LocalDateTimeUtil.format(wlRecord.getEndTime(), DateTimeFormatter.ofPattern(DatePattern.NORM_DATETIME_PATTERN));
|
||||||
|
temSql.append(" and line_id = '").append(wlRecord.getLineId()).append(InfluxDbSqlConstant.QM)
|
||||||
|
.append(InfluxDbSqlConstant.AND)
|
||||||
|
.append(InfluxDbSqlConstant.TIME).append(InfluxDbSqlConstant.GE).append(InfluxDbSqlConstant.QM).append(start).append(InfluxDbSqlConstant.QM)
|
||||||
|
.append(InfluxDbSqlConstant.AND)
|
||||||
|
.append(InfluxDbSqlConstant.TIME).append(InfluxDbSqlConstant.LT).append(InfluxDbSqlConstant.QM).append(end).append(InfluxDbSqlConstant.QM)
|
||||||
|
.append(InfluxDbSqlConstant.TZ);
|
||||||
|
|
||||||
|
List<Map<String, Object>> temMapList = influxDbUtils.getMapResult(temSql.toString());
|
||||||
|
if (CollUtil.isNotEmpty(temMapList)) {
|
||||||
|
allList.add(temMapList.get(0));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Map<String, Object> resultMap = dealResultMap(method, allList);
|
||||||
|
if (resultMap.isEmpty()) {
|
||||||
|
data = data.stream().peek(item -> item.setValue("/")).collect(Collectors.toList());
|
||||||
|
} else {
|
||||||
|
for (ReportTemplateDTO item : data) {
|
||||||
|
if (resultMap.containsKey(item.getItemName())) {
|
||||||
|
double v = (Double) resultMap.get(item.getItemName());
|
||||||
|
item.setValue(String.format("%.3f", v));
|
||||||
|
|
||||||
|
|
||||||
|
if (overLimitMap.containsKey(item.getLimitName())) {
|
||||||
|
Float tagVal = overLimitMap.get(item.getLimitName());
|
||||||
|
if (v > tagVal) {
|
||||||
|
item.setOverLimitFlag(1);
|
||||||
|
} else {
|
||||||
|
item.setOverLimitFlag(0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//结论判断是否越限
|
||||||
|
String key = item.getLimitName() + "#" + item.getStatMethod().toLowerCase() + "#pq_overlimit";
|
||||||
|
if (limitMap.containsKey(key)) {
|
||||||
|
ReportTemplateDTO tem = limitMap.get(key);
|
||||||
|
double limitVal = Double.parseDouble(tem.getValue());
|
||||||
|
if (v > limitVal) {
|
||||||
|
tem.setOverLimitFlag(1);
|
||||||
|
tem.setValue(tem.getValue());
|
||||||
|
assNoPassMap.put(key, tem);
|
||||||
|
} else if (!assNoPassMap.containsKey(key)) {
|
||||||
|
tem.setOverLimitFlag(0);
|
||||||
|
tem.setValue(tem.getValue());
|
||||||
|
assNoPassMap.put(key, tem);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
item.setValue("/");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
endList.addAll(data);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
private Map<String, Object> dealResultMap(String method, List<Map<String, Object>> allList) {
|
||||||
|
Map<String, Object> resultMap = new HashMap<>();
|
||||||
|
// 遍历列表中的每个Map
|
||||||
|
if (method.equals(InfluxDbSqlConstant.MIN)) {
|
||||||
|
for (Map<String, Object> map : allList) {
|
||||||
|
// 遍历当前Map的键值对
|
||||||
|
for (Map.Entry<String, Object> entry : map.entrySet()) {
|
||||||
|
String key = entry.getKey();
|
||||||
|
if (!key.equals("time")) {
|
||||||
|
double value = (double) entry.getValue();
|
||||||
|
// 检查结果Map中是否已包含该键
|
||||||
|
if (!resultMap.containsKey(key) || (double) resultMap.get(key) > value) {
|
||||||
|
// 如果不包含,或当前值更大,则更新结果Map
|
||||||
|
resultMap.put(key, value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else if (method.equals(InfluxDbSqlConstant.MAX) || method.equals(InfluxDbSqlConstant.PERCENTILE)) {
|
||||||
|
for (Map<String, Object> map : allList) {
|
||||||
|
// 遍历当前Map的键值对
|
||||||
|
for (Map.Entry<String, Object> entry : map.entrySet()) {
|
||||||
|
String key = entry.getKey();
|
||||||
|
if (!key.equals("time")) {
|
||||||
|
double value = (double) entry.getValue();
|
||||||
|
// 检查结果Map中是否已包含该键
|
||||||
|
if (!resultMap.containsKey(key) || (double) resultMap.get(key) < value) {
|
||||||
|
// 如果不包含,或当前值更大,则更新结果Map
|
||||||
|
resultMap.put(key, value);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else if (method.equals(InfluxDbSqlConstant.AVG)) {
|
||||||
|
Map<String, Double> sumMap = new HashMap<>();
|
||||||
|
Map<String, Integer> countMap = new HashMap<>();
|
||||||
|
// 遍历列表中的每个Map
|
||||||
|
for (Map<String, Object> map : allList) {
|
||||||
|
// 遍历当前Map的键值对
|
||||||
|
for (Map.Entry<String, Object> entry : map.entrySet()) {
|
||||||
|
String key = entry.getKey();
|
||||||
|
if (!key.equals("time")) {
|
||||||
|
double value = (double) entry.getValue();
|
||||||
|
|
||||||
|
// 更新累计和
|
||||||
|
sumMap.put(key, sumMap.getOrDefault(key, 0.0) + value);
|
||||||
|
// 更新计数
|
||||||
|
countMap.put(key, countMap.getOrDefault(key, 0) + 1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 计算平均值并存储到结果Map中
|
||||||
|
for (String key : sumMap.keySet()) {
|
||||||
|
double sum = sumMap.get(key);
|
||||||
|
int count = countMap.get(key);
|
||||||
|
double average = BigDecimal.valueOf(sum / count).setScale(3, RoundingMode.HALF_UP).doubleValue();
|
||||||
|
resultMap.put(key, average);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return resultMap;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
private void dealExcelResult(JSONArray jsonArray,Map<String,List<ReportTemplateDTO>> assMap,Map<String,String> unit){
|
||||||
|
jsonArray.forEach(item -> {
|
||||||
|
JSONObject jsonObject = (JSONObject) item;
|
||||||
|
JSONArray itemArr = (JSONArray) jsonObject.get("celldata");
|
||||||
|
itemArr.forEach((it) -> {
|
||||||
|
if (Objects.nonNull(it) && !"null".equals(it.toString())) {
|
||||||
|
//获取到1列
|
||||||
|
JSONObject data = (JSONObject) it;
|
||||||
|
JSONObject son = (JSONObject) data.get("v");
|
||||||
|
if (son.containsKey("v")) {
|
||||||
|
String v = son.getStr("v");
|
||||||
|
//数据格式:$HA[_25]#B#max#classId$ 或 $HA[_25]#max#classId$
|
||||||
|
if (v.charAt(0) == '$' && v.contains("#")) {
|
||||||
|
String str = "";
|
||||||
|
List<ReportTemplateDTO> rDto = assMap.get(v.replace("$", ""));
|
||||||
|
if (Objects.nonNull(rDto)) {
|
||||||
|
str = rDto.get(0).getValue();
|
||||||
|
//没有值,赋"/"
|
||||||
|
if (StringUtils.isBlank(str)) {
|
||||||
|
str = "/";
|
||||||
|
}
|
||||||
|
son.set("v", str);
|
||||||
|
if (Objects.nonNull(rDto.get(0).getOverLimitFlag()) && rDto.get(0).getOverLimitFlag() == 1) {
|
||||||
|
son.set("fc", "#990000");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else if (v.charAt(0) == '%' && v.contains("#")) {
|
||||||
|
//指标合格情况
|
||||||
|
String str = "";
|
||||||
|
List<ReportTemplateDTO> rDto = assMap.get(v.replace("%", ""));
|
||||||
|
if (Objects.nonNull(rDto)) {
|
||||||
|
str = rDto.get(0).getValue();
|
||||||
|
//没有值,赋"/"
|
||||||
|
if (StringUtils.isBlank(str)) {
|
||||||
|
str = "/";
|
||||||
|
}
|
||||||
|
son.set("v", str);
|
||||||
|
if ("不合格".equals(str)) {
|
||||||
|
son.set("fc", "#990000");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} /*else if (v.charAt(0) == '&') {
|
||||||
|
//结论
|
||||||
|
String tem = v.replace("&", "");
|
||||||
|
if (Objects.nonNull(finalTerminalMap)) {
|
||||||
|
if ("statis_time".equals(tem)) {
|
||||||
|
son.set("v", reportSearchParam.getStartTime() + InfluxDbSqlConstant.START_TIME + "_" + reportSearchParam.getEndTime() + InfluxDbSqlConstant.END_TIME);
|
||||||
|
} else {
|
||||||
|
//台账信息
|
||||||
|
son.set("v", finalTerminalMap.getOrDefault(tem, "/"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}*/ else if (v.charAt(0) == '@' && v.contains("#")) {
|
||||||
|
//解决数据单位问题 @指标#类型@
|
||||||
|
String replace = v.replace("@", "");
|
||||||
|
son.set("v", unit.getOrDefault(replace, "/"));
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 处理指标超标结论
|
||||||
|
*/
|
||||||
|
private void dealTargetResult(Map<String,ReportTemplateDTO> assNoPassMap,Map<String,ReportTemplateDTO> limitTargetMapX,List<ReportTemplateDTO> endList){
|
||||||
|
assNoPassMap.forEach((key, val) -> {
|
||||||
|
limitTargetMapX.remove(key);
|
||||||
|
if ("Voltage_Dev".equals(val.getTemplateName()) || "Freq_Dev".equals(val.getTemplateName())) {
|
||||||
|
val.setValue("±" + val.getValue());
|
||||||
|
}
|
||||||
|
if (val.getOverLimitFlag() == 1) {
|
||||||
|
val.setValue("不合格 (" + val.getValue() + ")");
|
||||||
|
} else {
|
||||||
|
val.setValue("合格 (" + val.getValue() + ")");
|
||||||
|
}
|
||||||
|
endList.add(val);
|
||||||
|
});
|
||||||
|
|
||||||
|
limitTargetMapX.forEach((key, val) -> {
|
||||||
|
if (Objects.isNull(val.getOverLimitFlag())) {
|
||||||
|
val.setValue("/");
|
||||||
|
} else {
|
||||||
|
val.setValue("合格");
|
||||||
|
}
|
||||||
|
endList.add(val);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 解析模板
|
||||||
|
*
|
||||||
|
* @author cdf
|
||||||
|
* @date 2023/10/20
|
||||||
|
*/
|
||||||
|
private void parseTemplateZhejiang(JSONArray jsonArray, List<ReportTemplateDTO> reportTemplateDTOList, List<ReportTemplateDTO> reportLimitList, List<ReportTemplateDTO> terminalList) {
|
||||||
|
try {
|
||||||
|
//通过文件服务器获取
|
||||||
|
|
||||||
|
jsonArray.forEach(item -> {
|
||||||
|
JSONObject jsonObject = (JSONObject) item;
|
||||||
|
JSONArray itemArr = (JSONArray) jsonObject.get("celldata");
|
||||||
|
itemArr.forEach((it) -> {
|
||||||
|
if (Objects.nonNull(it) && !"null".equals(it.toString())) {
|
||||||
|
//获取到1列
|
||||||
|
JSONObject data = (JSONObject) it;
|
||||||
|
JSONObject son = (JSONObject) data.get("v");
|
||||||
|
if (son.containsKey("v")) {
|
||||||
|
String v = son.getStr("v");
|
||||||
|
//数据格式:$HA[_25]#B#max#classId$ 或 $HA[_25]#max#classId$
|
||||||
|
if (v.charAt(0) == '$' && v.contains("#")) {
|
||||||
|
//剔除前后$
|
||||||
|
v = v.replace("$", "");
|
||||||
|
//封装ReportTemplateDTO
|
||||||
|
ReportTemplateDTO reportTemplateDTO = new ReportTemplateDTO();
|
||||||
|
reportTemplateDTO.setItemName(v);
|
||||||
|
//根据#分割数据
|
||||||
|
String[] vItem = v.split("#");
|
||||||
|
if (vItem.length == 5) {
|
||||||
|
//$HA[_25]#B#max#classId$
|
||||||
|
reportTemplateDTO.setTemplateName(vItem[0]);
|
||||||
|
reportTemplateDTO.setPhase(vItem[1]);
|
||||||
|
reportTemplateDTO.setStatMethod(vItem[2].toUpperCase());
|
||||||
|
reportTemplateDTO.setResourceId(vItem[3]);
|
||||||
|
reportTemplateDTO.setLimitName(vItem[4]);
|
||||||
|
} else if (vItem.length == 4) {
|
||||||
|
//$HA[_25]#max#classId$
|
||||||
|
reportTemplateDTO.setTemplateName(vItem[0]);
|
||||||
|
reportTemplateDTO.setPhase("M");
|
||||||
|
reportTemplateDTO.setStatMethod(vItem[1].toUpperCase());
|
||||||
|
reportTemplateDTO.setResourceId(vItem[2]);
|
||||||
|
reportTemplateDTO.setLimitName(vItem[3]);
|
||||||
|
}
|
||||||
|
|
||||||
|
reportTemplateDTOList.add(reportTemplateDTO);
|
||||||
|
} else if (v.charAt(0) == '%' && v.contains("#")) {
|
||||||
|
//封装ReportTemplateDTO
|
||||||
|
ReportTemplateDTO reportTemplateDTO = new ReportTemplateDTO();
|
||||||
|
|
||||||
|
v = v.replace("%", "");
|
||||||
|
reportTemplateDTO.setItemName(v);
|
||||||
|
//根据#分割数据
|
||||||
|
String[] vItem = v.split("#");
|
||||||
|
if (vItem.length == 3) {
|
||||||
|
//$HA[_25]#B#max#classId$
|
||||||
|
reportTemplateDTO.setTemplateName(vItem[0]);
|
||||||
|
reportTemplateDTO.setStatMethod(vItem[1].toUpperCase());
|
||||||
|
reportTemplateDTO.setResourceId(vItem[2]);
|
||||||
|
}
|
||||||
|
reportLimitList.add(reportTemplateDTO);
|
||||||
|
} else if (v.charAt(0) == '&') {
|
||||||
|
//封装ReportTemplateDTO
|
||||||
|
ReportTemplateDTO reportTemplateDTO = new ReportTemplateDTO();
|
||||||
|
v = v.replace("&", "");
|
||||||
|
reportTemplateDTO.setItemName(v);
|
||||||
|
reportTemplateDTO.setTemplateName(v);
|
||||||
|
terminalList.add(reportTemplateDTO);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
} catch (Exception e) {
|
||||||
|
throw new BusinessException(HarmonicResponseEnum.CUSTOM_REPORT_JSON);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user