From a847034b6393114d1a43b5a7f0b9c7e9da044d2d Mon Sep 17 00:00:00 2001 From: DominikNoga Date: Wed, 4 Sep 2024 18:11:20 +0200 Subject: [PATCH] ANGOLASUP-909: passed right payload and fixed request problem --- src/shipment-view/shipment-view.controller.js | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/src/shipment-view/shipment-view.controller.js b/src/shipment-view/shipment-view.controller.js index 899aecc..e01ba28 100644 --- a/src/shipment-view/shipment-view.controller.js +++ b/src/shipment-view/shipment-view.controller.js @@ -119,14 +119,9 @@ } vm.confirm = function() { - vm.shipment.lineItems = vm.shipment.lineItems.map(function(item) { - return { - id: item.id, - lot: item.lot, - orderable: item.orderable, - quantityShipped: item.quantityShipped, - stockOnHand: item.stockOnHand, - unitOfOrderableId: item.unitOfOrderableId + vm.shipment.lineItems.forEach(function(lineItem) { + lineItem.unitOfOrderable = { + id: lineItem.unit.id }; });