maektwain commented on a change in pull request #925:
URL: https://github.com/apache/fineract/pull/925#discussion_r429393478



##########
File path: 
fineract-provider/src/main/java/org/apache/fineract/accounting/producttoaccountmapping/domain/ProductToGLAccountMappingRepository.java
##########
@@ -30,8 +30,9 @@
     ProductToGLAccountMapping 
findByProductIdAndProductTypeAndFinancialAccountTypeAndPaymentTypeId(Long 
productId, int productType,
             int financialAccountType, Long paymentType);
 
-    ProductToGLAccountMapping 
findByProductIdAndProductTypeAndFinancialAccountTypeAndChargeId(Long productId, 
int productType,
-            int financialAccountType, Long chargeId);
+    @Query("select mapping from ProductToGLAccountMapping mapping where 
mapping.productId= :productId and mapping.productType= :productType and 
mapping.financialAccountType= :financialAccountType and mapping.charge.id= 
:chargeId")
+    ProductToGLAccountMapping 
findProductIdAndProductTypeAndFinancialAccountTypeAndChargeId(@Param("productId")
 Long productId, @Param("productType") int productType,
+            @Param("financialAccountType") int financialAccountType, 
@Param("chargeId") Long ChargeId);

Review comment:
       So, if we rename the method then we eventually have to change the 
existing method sigs, since it uses the ChargeId , and then in that case we 
need to pass the Charge. This fixes the problem.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to