Skip to content

Commit

Permalink
Merge pull request #213 from fiterlatam/feature/FBR-316
Browse files Browse the repository at this point in the history
View details on prequaalification exceptions
  • Loading branch information
BrianMuhimbura authored Oct 6, 2023
2 parents 34d4b91 + 63ba19f commit 9dd53ee
Showing 1 changed file with 2 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -634,19 +634,16 @@ public CommandProcessingResult sendForAnalysis(Long entityId, JsonCommand comman
Integer fromStatus = prequalificationGroup.getStatus();
List<String> exceptionsList = List.of("ORANGE", "RED", "YELLOW");
List<List<String>> rows = prequalification.getRows();
AtomicReference<PrequalificationStatus> status = new AtomicReference<>(PrequalificationStatus.AGENCY_LEAD_PENDING_APPROVAL);
AtomicReference<PrequalificationStatus> status = new AtomicReference<>(PrequalificationStatus.ANALYSIS_UNIT_PENDING_APPROVAL);
for (List<String> innerList : rows) {
innerList.forEach(item -> {
if (exceptionsList.contains(item)) {
status.set(PrequalificationStatus.AGENCY_LEAD_PENDING_APPROVAL_WITH_EXCEPTIONS);
status.set(PrequalificationStatus.ANALYSIS_UNIT_PENDING_APPROVAL_WITH_EXCEPTIONS);
}
});
}

prequalificationGroup.updateStatus(status.get());
prequalificationGroupRepositoryWrapper.save(prequalificationGroup);

this.prequalificationGroupRepositoryWrapper.save(prequalificationGroup);

PrequalificationStatusLog statusLog = PrequalificationStatusLog.fromJson(appUser, fromStatus, prequalificationGroup.getStatus(),
null, prequalificationGroup);
Expand Down

0 comments on commit 9dd53ee

Please sign in to comment.