Skip to content

Commit

Permalink
Update BDI_DataImportService.cls
Browse files Browse the repository at this point in the history
  • Loading branch information
enzigma-pratishtha-upadhyay committed May 10, 2024
1 parent b4779d9 commit afdd2b5
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions force-app/main/default/classes/BDI_DataImportService.cls
Original file line number Diff line number Diff line change
Expand Up @@ -624,11 +624,12 @@ global with sharing class BDI_DataImportService {
this.listDI = checkRDFields(listDI);

if(apexJobId != null && listDI.size() > 0) {
DataImportBatch__c batch = [SELECT Name, Batch_Number__c, Batch_Status__c, Batch_Defaults__c,
List<DataImportBatch__c> listBatch = [SELECT Name, Batch_Number__c, Batch_Status__c, Batch_Defaults__c,
Form_Template__c, RequireTotalMatch__c, Expected_Count_of_Gifts__c,
Expected_Total_Batch_Amount__c, Batch_Table_Columns__c, LastModifiedDate
FROM DataImportBatch__c WHERE Id= :listDI[0].NPSP_Data_Import_Batch__c LIMIT 1];
GiftBatch giftBatch = new GiftBatch(batch);
if(listBatch.size() > 0 ){
GiftBatch giftBatch = new GiftBatch(listBatch[0]);
Boolean firstInstallmentPaid = giftBatch.shouldPayFirstInstallment();

for (DataImport__c dataImport : listDI) {
Expand All @@ -640,6 +641,7 @@ global with sharing class BDI_DataImportService {
}
}
}
}
// do any performance optimizations to avoid unnecessary code
disableAllOppRollups();

Expand Down

0 comments on commit afdd2b5

Please sign in to comment.