|
@@ -211,9 +211,11 @@ public class BytedanceReportServiceImpl implements IBytedanceReportService {
|
|
|
if (maxHour == 0 || Check.isNull(maxHour)) {
|
|
|
return accountJson;
|
|
|
}
|
|
|
- accountJson = reportMapper.selectSumDayHourlyByHourAndDate(nowDate, String.valueOf(maxHour - 1));
|
|
|
+ String maxHourStr = String.valueOf(maxHour - 1);
|
|
|
+ accountJson = reportMapper.selectSumDayHourlyByHourAndDate(nowDate, maxHourStr);
|
|
|
+ accountJson.put("maxHour", maxHourStr);
|
|
|
if (!Check.isNull(accountJson)) {
|
|
|
- JSONObject yesterdayJson = reportMapper.selectSumDayHourlyByHourAndDate(anotherDay, String.valueOf(maxHour - 1));
|
|
|
+ JSONObject yesterdayJson = reportMapper.selectSumDayHourlyByHourAndDate(anotherDay, maxHourStr);
|
|
|
if (!Check.isNull(yesterdayJson)) {
|
|
|
BigDecimal cost = accountJson.getBigDecimal("cost"); // 今日消耗
|
|
|
BigDecimal yesterdayCost = yesterdayJson.getBigDecimal("cost");// 昨日消耗
|