Skip to content

Commit

Permalink
FBR-333: Guarantee status fix (#272)
Browse files Browse the repository at this point in the history
* FBR-333: Guarantee status fix

* FBR-333: Guarantee status fix

---------

Co-authored-by: Julius Peter Oketayot <[email protected]>
  • Loading branch information
fiter-julius-oketayot and Julius Peter Oketayot authored Nov 14, 2023
1 parent 534e2a2 commit 800ae46
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -410,11 +410,12 @@ public List<GuaranteeData> retrieveGuarantees(String caseId, final String locale
for (int i = 0; i < jsonArray.size(); i++) {
final JsonElement element = jsonArray.get(i);
final Long id = this.fromApiJsonHelper.extractLongNamed("id", element);
final String status = ObjectUtils.defaultIfNull(this.fromApiJsonHelper.extractStringNamed("estado", element),
"Nueva Solicitud");
final JsonElement data = this.fromApiJsonHelper.extractJsonObjectNamed("datos", element);
final String clientNo = this.fromApiJsonHelper.extractStringNamed("numero_cliente", data);
final String clientName = this.fromApiJsonHelper.extractStringNamed("name", data);
final String withdrawalReason = this.fromApiJsonHelper.extractStringNamed("razon_retiro", data);
final String status = this.fromApiJsonHelper.extractStringNamed("razon_retiro", data);
final BigDecimal requestedAmount = this.fromApiJsonHelper.extractBigDecimalNamed("monto", data, reqLocale);
final GuaranteeData guarantee = GuaranteeData.builder().id(id).caseId(caseId).clientNo(clientNo).clientName(clientName)
.withdrawalReason(withdrawalReason).requestedAmount(requestedAmount).status(status).build();
Expand Down

0 comments on commit 800ae46

Please sign in to comment.