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

po_line_id absent from sub-objects in response when creating POLine

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: P3
    • Resolution: Done
    • Affects Version/s: None
    • Fix Version/s: 3.0.0
    • Labels:
    • Template:
    • Sprint:
      ACQ Sprint 56
    • Story Points:
      1
    • Development Team:
      Thunderjet

      Description

      The recent story MODORDERS-134 addressed the absence of the po_line_id fields in the various sub-objects when creating POLines. However, while verifying that story, it was observed that the POST response does not include the po_line_id fields, even though they apparently have been added. I'm able to see those fields populated when performing subsequent GET requests for the POLine.

      Example:

      Note that the response does not contain the po_line_id fields...

      curl 'http://folio-testing-backend01.aws.indexdata.com:9130/orders/order-lines' -H 'X-Okapi-Token: eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJkaWt1X2FkbWluIiwidXNlcl9pZCI6IjE4ZmIzZmM5LTgxN2QtNWNkMC04OTBhLTdiMDY2N2Q0NDMyNyIsImNhY2hlX2tleSI6IjY2OTE1NGE4LTRlZmEtNGQ0OS05YjEyLTY5YTQxMTdjZDJhNCIsImlhdCI6MTU0ODY4ODE3OCwidGVuYW50IjoiZGlrdSJ9.3wdrUMc2u4Ni0n5rbWwXu_o2X7g2l0cpp-0z_NEB_7E' -H 'Content-Type: application/json' --data-binary '{
      >   "source": {
      >     "code": "FOLIO"
      >   },
      >   "cost": {
      >     "currency": "USD",
      >     "list_price": "10.95",
      >     "quantity_electronic": "1"
      >   },
      >   "vendor_detail": {
      >     "instructions": "",
      >     "ref_number": "555123456978",
      >     "ref_number_type": "Internal vendor number"
      >   },
      >   "purchase_order_id": "2300aafd-6e66-4da8-8cf0-094379ebafe0",
      >   "po_line_number": "10063-2",
      >   "acquisition_method": "Purchase",
      >   "order_format": "Electronic Resource",
      >   "receipt_status": "Awaiting Receipt",
      >   "payment_status": "Awaiting Payment",
      >   "title": "Now Wait For Last Year",
      >   "contributors": [
      >     {
      >       "contributor": "Philip K Dick"
      >     }
      >   ],
      >   "details": {
      >     "material_types": [
      >       "dd0bf600-dbd9-44ab-9ff2-e2a61a6539f1"
      >     ],
      >     "product_ids": [
      >       {
      >         "product_id": "9785123456",
      >         "product_id_type": "ISBN"
      >       }
      >     ]
      >   },
      >   "publisher": "Brilliance Audio",
      >   "description": "JJ180 is a new drug that permits time travel.  Mind bending craziness ensues.  ",
      >   "eresource": {
      >     "access_provider": "94bb315f-dbaa-4a53-a468-019e8f6dd1a2",
      >     "user_limit": "1"
      >   },
      >   "id": "7ae4656b-604e-440b-a5e9-a409682356f2"
      > }'
      {
        "id" : "af493f33-125e-4330-bc3c-4af845af5902",
        "acquisition_method" : "Purchase",
        "alerts" : [ ],
        "claims" : [ ],
        "contributors" : [ {
          "contributor" : "Philip K Dick"
        } ],
        "cost" : {
          "id" : "7a6f6f24-b7bb-446d-9af8-ee34dde95958",
          "list_price" : 10.95,
          "currency" : "USD",
          "quantity_electronic" : 1
        },
        "description" : "JJ180 is a new drug that permits time travel.  Mind bending craziness ensues.  ",
        "details" : {
          "id" : "6a509bab-6474-4f40-b7a1-29e3dd9fb211",
          "product_ids" : [ {
            "product_id" : "9785123456",
            "product_id_type" : "ISBN"
          } ],
          "material_types" : [ "dd0bf600-dbd9-44ab-9ff2-e2a61a6539f1" ]
        },
        "eresource" : {
          "id" : "1721eb9f-ac77-4b75-80cb-8e4cf20e2d8d",
          "user_limit" : 1,
          "access_provider" : "94bb315f-dbaa-4a53-a468-019e8f6dd1a2"
        },
        "fund_distribution" : [ ],
        "order_format" : "Electronic Resource",
        "payment_status" : "Awaiting Payment",
        "po_line_number" : "10063-2",
        "publisher" : "Brilliance Audio",
        "purchase_order_id" : "2300aafd-6e66-4da8-8cf0-094379ebafe0",
        "receipt_status" : "Awaiting Receipt",
        "reporting_codes" : [ ],
        "source" : {
          "id" : "76da1664-5a16-4290-9944-16f9e38fd2f1",
          "code" : "FOLIO"
        },
        "tags" : [ ],
        "title" : "Now Wait For Last Year",
        "vendor_detail" : {
          "id" : "a95253ac-dc6f-4cd0-9cb7-bbdb2a0be150",
          "instructions" : "",
          "ref_number" : "555123456978",
          "ref_number_type" : "Internal vendor number"
        },
        "metadata" : {
          "createdDate" : "2019-01-28T17:26:35.774+0000",
          "createdByUserId" : "18fb3fc9-817d-5cd0-890a-7b0667d44327",
          "updatedDate" : "2019-01-28T17:26:35.774+0000",
          "updatedByUserId" : "18fb3fc9-817d-5cd0-890a-7b0667d44327"
        }
      }
      

      But the po_line_id fields are present when retrieving the record afterwards...

      curl 'http://folio-testing-backend01.aws.indexdata.com:9130/orders/order-lines/af493f33-125e-4330-bc3c-4af845af5902' -H 'X-Okapi-Token: eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJkaWt1X2FkbWluIiwidXNlcl9pZCI6IjE4ZmIzZmM5LTgxN2QtNWNkMC04OTBhLTdiMDY2N2Q0NDMyNyIsImNhY2hlX2tleSI6IjY2OTE1NGE4LTRlZmEtNGQ0OS05YjEyLTY5YTQxMTdjZDJhNCIsImlhdCI6MTU0ODY4ODE3OCwidGVuYW50IjoiZGlrdSJ9.3wdrUMc2u4Ni0n5rbWwXu_o2X7g2l0cpp-0z_NEB_7E' -H 'Content-Type: application/json' 
      {
        "id" : "af493f33-125e-4330-bc3c-4af845af5902",
        "acquisition_method" : "Purchase",
        "alerts" : [ ],
        "claims" : [ ],
        "contributors" : [ {
          "contributor" : "Philip K Dick"
        } ],
        "cost" : {
          "id" : "7a6f6f24-b7bb-446d-9af8-ee34dde95958",
          "list_price" : 10.95,
          "currency" : "USD",
          "quantity_electronic" : 1,
          "po_line_id" : "af493f33-125e-4330-bc3c-4af845af5902"
        },
        "description" : "JJ180 is a new drug that permits time travel.  Mind bending craziness ensues.  ",
        "details" : {
          "id" : "6a509bab-6474-4f40-b7a1-29e3dd9fb211",
          "product_ids" : [ {
            "product_id" : "9785123456",
            "product_id_type" : "ISBN"
          } ],
          "material_types" : [ "dd0bf600-dbd9-44ab-9ff2-e2a61a6539f1" ],
          "po_line_id" : "af493f33-125e-4330-bc3c-4af845af5902"
        },
        "eresource" : {
          "id" : "1721eb9f-ac77-4b75-80cb-8e4cf20e2d8d",
          "user_limit" : 1,
          "access_provider" : "94bb315f-dbaa-4a53-a468-019e8f6dd1a2",
          "po_line_id" : "af493f33-125e-4330-bc3c-4af845af5902"
        },
        "fund_distribution" : [ ],
        "order_format" : "Electronic Resource",
        "payment_status" : "Awaiting Payment",
        "po_line_number" : "10063-2",
        "publisher" : "Brilliance Audio",
        "purchase_order_id" : "2300aafd-6e66-4da8-8cf0-094379ebafe0",
        "receipt_status" : "Awaiting Receipt",
        "reporting_codes" : [ ],
        "source" : {
          "id" : "76da1664-5a16-4290-9944-16f9e38fd2f1",
          "code" : "FOLIO"
        },
        "tags" : [ ],
        "title" : "Now Wait For Last Year",
        "vendor_detail" : {
          "id" : "a95253ac-dc6f-4cd0-9cb7-bbdb2a0be150",
          "instructions" : "",
          "ref_number" : "555123456978",
          "ref_number_type" : "Internal vendor number",
          "po_line_id" : "af493f33-125e-4330-bc3c-4af845af5902"
        },
        "metadata" : {
          "createdDate" : "2019-01-28T17:26:35.853+0000",
          "createdByUserId" : "18fb3fc9-817d-5cd0-890a-7b0667d44327",
          "updatedDate" : "2019-01-28T17:26:35.853+0000",
          "updatedByUserId" : "18fb3fc9-817d-5cd0-890a-7b0667d44327"
        }
      }
      

        TestRail: Results

          Attachments

            Issue Links

              Activity

                People

                Assignee:
                cmcnally Craig McNally
                Reporter:
                cmcnally Craig McNally
                Tester Assignee:
                Craig McNally Craig McNally
                Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                  Dates

                  Created:
                  Updated:
                  Resolved:

                    TestRail: Runs

                      TestRail: Cases