master
yixian 5 years ago
parent c4848c521f
commit 7b487bd1ee

@ -90,13 +90,13 @@ public class ATOReportServiceImpl implements ATOReportService {
DateTime startOfMon = new DateTime(fromDateTime);
DateTime endOfMon = new DateTime(fromDateTime.plusMonths(1).withDayOfMonth(1));
while (endOfMon.isBefore(toDateTime)) {
logger.debug("Exporting date range:" + startOfMon.toString("yyyy-MM-dd") + " ~ " + endOfMon.toString("yyyy-MM-dd"));
logger.debug("Exporting date range:{} ~ {}", startOfMon.toString("yyyy-MM-dd"), endOfMon.toString("yyyy-MM-dd"));
loadMonthTransactions(reportingParty, startOfMon, endOfMon);
startOfMon = new DateTime(endOfMon);
endOfMon = new DateTime(endOfMon.plusMonths(1));
}
endOfMon = new DateTime(toDateTime);
logger.debug("Exporting date range:" + startOfMon.toString("yyyy-MM-dd") + " ~ " + endOfMon.toString("yyyy-MM-dd"));
logger.debug("Exporting date range:{} ~ {}", startOfMon.toString("yyyy-MM-dd"), endOfMon.toString("yyyy-MM-dd"));
loadMonthTransactions(reportingParty, startOfMon, endOfMon);
logger.info("output BTTPS file");
return data.outputBTTPS();
@ -109,7 +109,7 @@ public class ATOReportServiceImpl implements ATOReportService {
private void loadClientMonthTransactions(ReportingPartyData reportingParty, Integer clientId, DateTime startOfMon, DateTime endOfMon) {
BusinessData biz = reportingParty.findBusiness(clientId);
logger.debug("Exporting date range for client[" + clientId + "]:" + startOfMon.toString("yyyy-MM-dd") + " ~ " + endOfMon.toString("yyyy-MM-dd"));
logger.debug("Exporting date range for client[{}]:{} ~ {}",clientId,startOfMon.toString("yyyy-MM-dd"), endOfMon.toString("yyyy-MM-dd"));
if (biz == null) {
JSONObject cli = clientMapper.findClientIgnoreInvalid(clientId);
AddressInfo addr = new AddressInfo(cli.getString("address"), cli.getString("suburb"), cli.getString("state"), cli.getString("postcode"), cli.getString("country"));

@ -227,7 +227,7 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
$scope.exportPartnersExcel = function () {
var params = angular.copy($scope.params);
var param_str = keys(params).map(function (key) {
var param_str = Object.keys(params).map(function (key) {
var value = params[key];
if (angular.isDate(value)) {
value = $filter('date')(value, 'yyyy-MM-ddTHH:mm:ssZ')

Loading…
Cancel
Save