新统计方式

This commit is contained in:
zhangyue 2026-08-15 16:00:39 +08:00
parent cab1861edf
commit 4a333ba8b6
3 changed files with 8 additions and 6 deletions

View File

@ -512,9 +512,9 @@ public class BigScreenController {
}
@PostMapping("/getIndexSummry")
@PostMapping("/getIndexSummry2")
@ApiOperation("大屏首页统计")
public Result<List<ScreenIndexSummaryDetailVo>> getIndexSummry (@RequestBody ScreenSummaryVo screenSummaryVo){
public Result<List<ScreenIndexSummaryDetailVo>> getIndexSummry2 (@RequestBody ScreenSummaryVo screenSummaryVo){
String tenantId= iotTools.getTenantId(screenSummaryVo.getAuthId());
List<ScreenIndexSummaryDetailVo> results = new ArrayList<>();
if(StringUtils.isBlank(screenSummaryVo.getSummrayMode())){//不传模式默认为天数据

View File

@ -234,9 +234,9 @@ public class BigScreenControllerP2 {
return result;
}
@PostMapping("/getIndexSummry2")
@ApiOperation("大屏首页统计2")
public Result<List<ScreenIndexSummaryDetailVo2>> getIndexSummry2 (@RequestBody ScreenSummaryVo screenSummaryVo){
@PostMapping("/getIndexSummry")
@ApiOperation("大屏首页统计")
public Result<List<ScreenIndexSummaryDetailVo2>> getIndexSummry (@RequestBody ScreenSummaryVo screenSummaryVo){
String tenantId= iotTools.getTenantId(screenSummaryVo.getAuthId());
List<ScreenIndexSummaryDetailVo2> results = staticticsService.stationStatistic(screenSummaryVo);

View File

@ -6,6 +6,7 @@ import org.jeecg.common.config.TenantContext;
import org.jeecg.common.constant.IotConstants;
import org.jeecg.common.constant.PollutionConstants;
import org.jeecg.common.constant.StatisticConstants;
import org.jeecg.common.constant.enums.PollutionEnum;
import org.jeecg.common.entity.ScEquZhibiao;
import org.jeecg.common.entity.SurvDeviceDeploy;
import org.jeecg.common.entity.SurvStationInfo;
@ -285,7 +286,8 @@ public class StaticticsServiceImpl {
BigDecimal decimal = new BigDecimal(value);
value = decimal.setScale(4, RoundingMode.HALF_UP).stripTrailingZeros().toPlainString();
zhibiaoData.add(value);
dataMap.put(zhibiaoKey,zhibiaoData);
String name = PollutionEnum.catchPollution(zhibiaoKey).getDescription();
dataMap.put(name.replace("水样",""),zhibiaoData);
}
}
}