From 89d1b3e0d2fadbfc470a6214824ad5490269ce03 Mon Sep 17 00:00:00 2001 From: Rahul Dev Garg <118716448+rahuldevgarg-egov@users.noreply.github.com> Date: Fri, 8 Sep 2023 20:58:49 +0530 Subject: [PATCH] fixed query --- .../rowmapper/CollectionRowMapper.java | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) diff --git a/municipal-services/ws-services/src/main/java/org/egov/waterconnection/repository/rowmapper/CollectionRowMapper.java b/municipal-services/ws-services/src/main/java/org/egov/waterconnection/repository/rowmapper/CollectionRowMapper.java index 3498b1bea..91d57abcd 100644 --- a/municipal-services/ws-services/src/main/java/org/egov/waterconnection/repository/rowmapper/CollectionRowMapper.java +++ b/municipal-services/ws-services/src/main/java/org/egov/waterconnection/repository/rowmapper/CollectionRowMapper.java @@ -35,30 +35,16 @@ public class CollectionRowMapper implements ResultSetExtractor extractData(ResultSet rs) throws SQLException, DataAccessException { List collectionReportDataList = new ArrayList<>(); -// CollectionReportData collectionReportData = new CollectionReportData(); -// Map reportData = new HashMap<>(); while (rs.next()) { -// if(reportData.get(rs.getString("connectionNo")) != null) { -// setPayments(rs, collectionReportData, reportData); -// } -// else { - CollectionReportData collectionReportData = new CollectionReportData(); -// List paymentAmounts = new ArrayList<>(); collectionReportData.setTenantName(rs.getString("tenantId")); collectionReportData.setConnectionNo(rs.getString("connectionNo")); collectionReportData.setOldConnectionNo(rs.getString("oldConnectionNo")); collectionReportData.setUserId(rs.getString("uuid")); collectionReportData.setPaymentMode(rs.getString("paymentmode")); -// paymentAmounts.add(rs.getBigDecimal("amountpaid")); - collectionReportData.setPaymentAmount(rs.getBigDecimal("amountpaid")); -// collectionReportData.getPaymentAmount().add(rs.getBigDecimal("amountpaid")); + collectionReportData.setPaymentAmount(rs.getBigDecimal("totalAmountPaid")); collectionReportDataList.add(collectionReportData); -// } - } -// List listOfValues = reportData.values().stream().collect( Collectors.toCollection(ArrayList::new)); -// collectionReportDataList.addAll(listOfValues); if(!collectionReportDataList.isEmpty()){ enrichConnectionHolderDetails(collectionReportDataList); }