FINERACT-2103: refactor the boilerplate code for ChargeData class and its affiliate code
This commit is contained in:
+1
-1
@@ -334,7 +334,7 @@ public class ProductToGLAccountMappingReadPlatformServiceImpl implements Product
|
||||
final Long chargeId = (Long) chargeToIncomeAccountMap.get("chargeId");
|
||||
final String chargeName = (String) chargeToIncomeAccountMap.get("chargeName");
|
||||
final Boolean penalty1 = (Boolean) chargeToIncomeAccountMap.get("penalty");
|
||||
final ChargeData chargeData = ChargeData.lookup(chargeId, chargeName, penalty1);
|
||||
final ChargeData chargeData = ChargeData.builder().id(chargeId).name(chargeName).penalty(penalty1).build();
|
||||
final ChargeToGLAccountMapper chargeToGLAccountMapper = new ChargeToGLAccountMapper().setCharge(chargeData)
|
||||
.setIncomeAccount(gLAccountData);
|
||||
chargeToGLAccountMappers.add(chargeToGLAccountMapper);
|
||||
|
||||
Reference in New Issue
Block a user