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

Cannot delete PO Line if other PO Line on the same order is linked to an invoice line



    • ACQ Sprint 122, ACQ Sprint 123
    • 2
    • Thunderjet
    • R3 2021
    • MI State University/Library of Michigan, Trinity College


      Overview: Originally reported in Iris, reproduced in Iris Bugfest and in Snapshot on 2021-08-12.

      Steps to Reproduce:

      1. Log in to https://folio-snapshot.dev.folio.org/
      2. Go to Settings/Orders/Purchase order lines limit
      3. Change the limit from 1 to 2 or more, and Save
      4. Go to the Orders app
      5. Create a new order
      6. Create PO Line 1
      7. Create PO Line 2
      8. Open the PO
      9. In Invoices, create an Invoice and link it to PO Line A
      10. In Orders, try to delete PO Line B

      Expected Results:
      PO Line B is successfully deleted.

      Actual Results:
      PO Line B fails to delete, with the following errors:
      "Error while deleting PO Line"
      "This order or order line is linked to Invoice number(s) and can not be deleted"

        "errors" : [ {
          "message" : "This order or order line is linked to Invoice number(s) and can not be deleted",
          "code" : "orderRelatesToInvoice",
          "parameters" : [ ]
        } ],
        "total_records" : 1

      Additional Information:
      I get the same error when trying to delete either PO Line, even though, as far as I can tell, only one of them is actually linked to the Invoice line.

      URL: https://folio-snapshot.dev.folio.org/

      Interested parties: Ben Taylor

      TestRail: Results


          Issue Links



                abreaux Ann-Marie Breaux
                lisams Lisa Sjögren (EBSCO)
                Dennis Bridges Dennis Bridges
                0 Vote for this issue
                4 Start watching this issue



                  TestRail: Runs

                    TestRail: Cases