Koha-clms/Koha/Acquisition
Martin Renvoize 08a2e0475b
Bug 30144: (QA follow-up) Exclude servicing_instruction from order API representation
The servicing_instruction column was not mapped in
Koha::Acquisition::Order->to_api_mapping, so it was exposed verbatim in
the REST API order representation. Since api/v1/swagger/definitions/order.yaml
does not declare this property and sets additionalProperties: false, any
request touching the acquisitions/orders endpoint (e.g. the "Receive
shipments" page) failed with a 500 error: "Properties not allowed:
servicing_instruction".

Exclude it from the API representation, consistent with the other
EDIFACT-only columns (line_item_id, suppliers_reference_number, etc.)
that are already excluded the same way.

Test plan:
1) Go to a vendor page, create a basket, add an order line, and close
   the basket.
2) From the vendor page, click "Receive shipments".
3) Without this patch, the orders table fails to load with a 500 error
   mentioning "Properties not allowed: servicing_instruction".
4) With this patch applied, the orders table loads correctly.
5) prove t/db_dependent/api/v1/acquisitions_orders.t

Signed-off-by: Pedro Amorim <pedro.amorim@openfifth.co.uk>
2026-08-28 16:36:28 +00:00
..
Bookseller Bug 40163: Fix several http addresses in the code docs 2025-09-23 16:21:29 -06:00
Invoice Bug 40163: Fix several http addresses in the code docs 2025-09-23 16:21:29 -06:00
Order Bug 39830: Add order claim object definition 2025-09-29 14:02:21 -06:00
Basket.pm Bug 29668: Add API route to add a basket 2026-01-21 15:28:09 -07:00
BasketGroup.pm Bug 40163: Fix several http addresses in the code docs 2025-09-23 16:21:29 -06:00
BasketGroups.pm Bug 40163: Fix several http addresses in the code docs 2025-09-23 16:21:29 -06:00
Baskets.pm Bug 40163: Fix several http addresses in the code docs 2025-09-23 16:21:29 -06:00
Bookseller.pm Bug 41950: (follow-up) Add DBIC relationship aliases for +count embeds 2026-06-29 16:19:49 +00:00
Booksellers.pm Bug 38262: Enable additional fields support for acquisition vendors 2026-01-12 10:53:35 -07:00
Budget.pm Bug 40163: Fix several http addresses in the code docs 2025-09-23 16:21:29 -06:00
Budgets.pm Bug 40163: Fix several http addresses in the code docs 2025-09-23 16:21:29 -06:00
Currencies.pm Bug 40163: Fix several http addresses in the code docs 2025-09-23 16:21:29 -06:00
Currency.pm Bug 40163: Fix several http addresses in the code docs 2025-09-23 16:21:29 -06:00
Fund.pm Bug 40163: Fix several http addresses in the code docs 2025-09-23 16:21:29 -06:00
Funds.pm Bug 40163: Fix several http addresses in the code docs 2025-09-23 16:21:29 -06:00
Invoice.pm Bug 40163: Fix several http addresses in the code docs 2025-09-23 16:21:29 -06:00
Invoices.pm Bug 40163: Fix several http addresses in the code docs 2025-09-23 16:21:29 -06:00
Order.pm Bug 30144: (QA follow-up) Exclude servicing_instruction from order API representation 2026-08-28 16:36:28 +00:00
Orders.pm Bug 40163: Fix several http addresses in the code docs 2025-09-23 16:21:29 -06:00