diff --git a/package.json b/package.json index c6a4e6f..60fd6fc 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "quirons-broker", - "version": "0.0.1-alpha.135", + "version": "0.0.1-alpha.136", "description": "A small library to expose the broker types", "typings": "index.d.ts", "types": "index.d.ts", diff --git a/src/inventory/schema/StockLevel.ts b/src/inventory/schema/StockLevel.ts index 7b2f623..42fcf03 100644 --- a/src/inventory/schema/StockLevel.ts +++ b/src/inventory/schema/StockLevel.ts @@ -71,6 +71,20 @@ const WarehouseStock = t.type({ BookedStockAmount: t.union([t.string, t.number]), }) +const ListOfLotStock = t.intersection([ + t.type({ + WarehouseInternalId: t.string, + LotNumber: t.string, + CurrentStockAmount: t.union([t.string, t.number]), + AvaliableStockAmount: t.union([t.string, t.number]), + BookedStockAmount: t.union([t.string, t.number]), + }), + t.partial({ + SubLotCode: t.string, + LotExpirationDate: t.union([datetime, date]), + }) +]) + const ReturnItem = t.intersection([ t.type({ CompanyId: t.string, @@ -81,6 +95,7 @@ const ReturnItem = t.intersection([ UnitItemCost: t.union([t.string, t.number]), WarehouseInternalId: t.string, BranchId: nullable(t.string), + ListOfLotStock: nullable(t.array(ListOfLotStock)) }) ]) diff --git a/src/inventory/schema/StockTurnOver.ts b/src/inventory/schema/StockTurnOver.ts index ecdf0b5..e0851b9 100644 --- a/src/inventory/schema/StockTurnOver.ts +++ b/src/inventory/schema/StockTurnOver.ts @@ -80,7 +80,8 @@ const StockTurnoverItem = t.intersection([ CostCenterInternalId: nullable(t.string), CostCenterCode: nullable(t.string), UnitPrice: nullable(t.number), - TotalPrice: nullable(t.number) + TotalPrice: nullable(t.number), + LotOrSerialNumber: nullable(t.string), }) ])