Uploaded image for project: 'mod-orders'
  1. mod-orders
  2. MODORDERS-430

Can't Unopen order - error response 2

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: P2
    • Resolution: Done
    • Affects Version/s: None
    • Fix Version/s: 11.1.1
    • Labels:
      None
    • Template:
      Standard Bug Write-Up Format
    • Sprint:
      ACQ Sprint 100
    • Story Points:
      2
    • Development Team:
      Thunderjet
    • Release:
      Q3 2020 Bug Fix

      Description

      Overview: User gets error response when clicks Unopen button for opened order with PO line without any fund distribution added.
      Steps to Reproduce:

      1. Log into thunderjet-ci FOLIO as user with open/unopen orders permissions;
      2. Click Unopen button for order #10075

      Expected Results: Order is unopened successfully
      Actual Results: error toast message "Order could not be saved."
      Additional Information:
      Request URL: https://thunderjet-okapi.ci.folio.org/orders/composite-orders/a77ddba9-4bb7-46fe-8182-56934adf9b58
      Request Method: PUT
      Status Code: 422

      {
        "errors" : [ {
          "message" : "{\n  \"errors\" : [ {\n    \"message\" : \"Number of order transactions have to be greater than 0\",\n    \"code\" : \"invalidOrderTransactionCount\",\n    \"parameters\" : [ ]\n  } ],\n  \"total_records\" : 1\n}",
          "code" : "genericError",
          "parameters" : [ ]
        } ],
        "total_records" : 1
      }
      

      Approach

      Skip processing encumbrances for line without fund distributions in the org.folio.helper.PurchaseOrderHelper#unOpenOrder

      URL:
      Interested parties:

        TestRail: Results

          Attachments

            Issue Links

              Activity

                People

                Assignee:
                Andrei_Makaranka Andrei Makaranka
                Reporter:
                aliaksei_chumakou Aliaksei Chumakou
                Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                  Dates

                  Created:
                  Updated:
                  Resolved:

                    TestRail: Runs

                      TestRail: Cases