Unable to open purchase order when POL currency different from system

Description

Overview: Unable to open an order when one or more POLs have cost information in different currency than system currency

Steps to Reproduce:

  1. Log into some FOLIO environment as User X

  2. Click order app

  3. Create new order

  4. create one or more POLs

  5. Set currency of POL(s) to different currency than system

  6. Save and close

  7. Open PO

Expected Results: PO is set to statue Open and encumbrance values are exchanged into the system currency. Fund distribution amount shows POL currency and Initial encumbrance shows amount in system currency after exchange.

Actual Results: PO can not be opened. Order can not be saved error displays

Additional Information:

URL: https://bugfest-goldenrod.folio.ebsco.com/orders/view/19bcadb4-64ba-4a6c-9718-23cd8c452422?query=11404

Interested parties:

Approach

1. Create new API in mod-finance storage for getting current active budget. Use in API org.folio.services.FundDetailsService#retrieveCurrentBudget
2. Change logic in org.folio.helper.FinanceHelper#getActiveBudgetsByFundIds and use new API

CSP Request Details

None

CSP Rejection Details

None

Potential Workaround

None

Attachments

3
  • 18 Sep 2020, 07:46 AM
  • 09 Sep 2020, 07:39 AM
  • 13 Aug 2020, 02:21 PM

Checklist

hide

TestRail: Results

Activity

Show:

Yauheni KuzmianokSeptember 18, 2020 at 7:46 AM

Verified on snapshot

Andrei MakarankaSeptember 9, 2020 at 7:39 AM

Verified on testing

Andrei MakarankaAugust 17, 2020 at 12:39 PM

Hi

The root problem in getting active budget.
Approach how to fix is added in description

Thanks

Dennis BridgesAugust 13, 2020 at 2:22 PM

After adding a material type the order will still NOT open and error message says that the fund has no budget.


However, it is clear in the finance app that there is a budget with plenty of money in it.

Andrei MakarankaAugust 13, 2020 at 12:59 PM

I found in logs next message :

2020-08-13T06:35:09.134Z java.util.concurrent.CompletionException: org.folio.orders.rest.exceptions.HttpException: { 2020-08-13T06:35:09.134Z "errors" : [ { 2020-08-13T06:35:09.134Z "message" : "Cannot set item.materialtypeid = 1a54b431-2e4f-452d-9cae-9cee66c9a892 because it does not exist in material_type.id.", 2020-08-13T06:35:09.134Z "type" : "1", 2020-08-13T06:35:09.134Z "code" : "-1", 2020-08-13T06:35:09.134Z "parameters" : [ { 2020-08-13T06:35:09.134Z "key" : "item.materialtypeid", 2020-08-13T06:35:09.134Z "value" : "1a54b431-2e4f-452d-9cae-9cee66c9a892" 2020-08-13T06:35:09.134Z } ] 2020-08-13T06:35:09.134Z } ] 2020-08-13T06:35:09.134Z }

Could you please change a product or something else and retest?
Thanks

Done

Details

Assignee

Reporter

Tester Assignee

Priority

Story Points

Sprint

Development Team

Thunderjet

Fix versions

TestRail: Cases

Open TestRail: Cases

TestRail: Runs

Open TestRail: Runs

Created July 31, 2020 at 7:50 PM
Updated October 9, 2020 at 8:56 PM
Resolved September 18, 2020 at 7:48 AM
TestRail: Cases
TestRail: Runs

Flag notifications