| | |
| | | allDeviceSum = Double.parseDouble(o.toString()); |
| | | } |
| | | |
| | | List<HistoryMonthly> preofessionDeviceHistoryMonthlyList = professionDataMap.get(resultTime); |
| | | List<HistoryMonthly> professionDeviceHistoryMonthlyList = professionDataMap.get(resultTime); |
| | | //贡献率 |
| | | String contributionRate = null; |
| | | Double professionAvg = null; |
| | | if (!ObjectUtils.isEmpty(preofessionDeviceHistoryMonthlyList)) { |
| | | if (!ObjectUtils.isEmpty(professionDeviceHistoryMonthlyList)) { |
| | | //该行业均值计算 |
| | | professionAvg = historyMonthlyService.calculatedValue(preofessionDeviceHistoryMonthlyList, sensorCode, "avg"); |
| | | professionAvg = historyMonthlyService.calculatedValue(professionDeviceHistoryMonthlyList, sensorCode, "avg"); |
| | | //该行业累加值计算 |
| | | Double professionSum = historyMonthlyService.calculatedValue(preofessionDeviceHistoryMonthlyList, sensorCode, "sum"); |
| | | Double professionSum = historyMonthlyService.calculatedValue(professionDeviceHistoryMonthlyList, sensorCode, "sum"); |
| | | //行业贡献率计算 |
| | | NumberFormat numberFormat = NumberFormat.getInstance(); |
| | | numberFormat.setMaximumFractionDigits(2); |