|
|
@ -859,6 +859,9 @@ public class RetailAppServiceImp implements RetailAppService {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
Date to = DateUtils.addDays(date, 1);
|
|
|
|
Date to = DateUtils.addDays(date, 1);
|
|
|
|
List<JSONObject> transactions = transactionMapper.listDailyTransactions(date, to, devId, device.getIntValue("client_id"));
|
|
|
|
List<JSONObject> transactions = transactionMapper.listDailyTransactions(date, to, devId, device.getIntValue("client_id"));
|
|
|
|
|
|
|
|
if (transactions.isEmpty()) {
|
|
|
|
|
|
|
|
throw new BadRequestException("No Transactions in date " + dateStr + " at " + timezone);
|
|
|
|
|
|
|
|
}
|
|
|
|
TimeZoneUtils.switchTimeZoneToString(transactions, timezone, "HH:mm:ss", Collections.singletonList("transaction_time"));
|
|
|
|
TimeZoneUtils.switchTimeZoneToString(transactions, timezone, "HH:mm:ss", Collections.singletonList("transaction_time"));
|
|
|
|
JSONObject res = new JSONObject();
|
|
|
|
JSONObject res = new JSONObject();
|
|
|
|
res.put("transactions", transactions);
|
|
|
|
res.put("transactions", transactions);
|
|
|
|