@things-factory/operato-wms 4.3.25 → 4.3.28

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -192,6 +192,7 @@ class CreateLoadingManifest extends localize(i18next)(PageView) {
192
192
  const filters = [
193
193
  { name: 'trackingNo', operator: 'eq', value: this.trackingNoInput.value.trim() },
194
194
  { name: 'manifest_id', operator: 'is_null', value: '' },
195
+ { name: 'releaseGoodOnly', operator: '', value: '' },
195
196
  { name: 'status', operator: 'in', value: ['PACKING', 'DONE'] }
196
197
  ]
197
198
  const response = await client.query({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@things-factory/operato-wms",
3
- "version": "4.3.25",
3
+ "version": "4.3.28",
4
4
  "main": "dist-server/index.js",
5
5
  "browser": "client/index.js",
6
6
  "things-factory": true,
@@ -63,60 +63,60 @@
63
63
  "@operato/scene-tab": "^0.1.6",
64
64
  "@operato/scene-table": "^0.1.6",
65
65
  "@operato/scene-wheel-sorter": "^0.1.6",
66
- "@things-factory/apptool-ui": "^4.3.23",
67
- "@things-factory/attachment-ui": "^4.3.24",
68
- "@things-factory/auth-ui": "^4.3.24",
69
- "@things-factory/barcode-ui": "^4.3.23",
70
- "@things-factory/biz-ui": "^4.3.24",
71
- "@things-factory/board-service": "^4.3.24",
72
- "@things-factory/board-ui": "^4.3.24",
73
- "@things-factory/code-ui": "^4.3.24",
74
- "@things-factory/context-ui": "^4.3.23",
75
- "@things-factory/export-ui": "^4.3.23",
76
- "@things-factory/export-ui-csv": "^4.3.23",
77
- "@things-factory/export-ui-excel": "^4.3.23",
78
- "@things-factory/fav-base": "^4.3.24",
79
- "@things-factory/form-ui": "^4.3.23",
80
- "@things-factory/grist-ui": "^4.3.23",
81
- "@things-factory/help": "^4.3.23",
82
- "@things-factory/i18n-base": "^4.3.23",
83
- "@things-factory/id-rule-base": "^4.3.24",
84
- "@things-factory/import-ui": "^4.3.23",
85
- "@things-factory/import-ui-excel": "^4.3.23",
86
- "@things-factory/menu-ui": "^4.3.24",
87
- "@things-factory/more-ui": "^4.3.23",
88
- "@things-factory/notification": "^4.3.24",
89
- "@things-factory/pdf": "^4.3.23",
90
- "@things-factory/print-proxy-service": "^4.3.23",
91
- "@things-factory/print-service": "^4.3.23",
92
- "@things-factory/print-ui": "^4.3.23",
93
- "@things-factory/product-base": "^4.3.24",
94
- "@things-factory/resource-ui": "^4.3.24",
95
- "@things-factory/sales-ui": "^4.3.25",
96
- "@things-factory/scene-data-transform": "^4.3.23",
97
- "@things-factory/scene-excel": "^4.3.23",
98
- "@things-factory/scene-firebase": "^4.3.23",
99
- "@things-factory/scene-form": "^4.3.23",
100
- "@things-factory/scene-google-map": "^4.3.23",
101
- "@things-factory/scene-graphql": "^4.3.23",
102
- "@things-factory/scene-label": "^4.3.23",
103
- "@things-factory/scene-marker": "^4.3.23",
104
- "@things-factory/scene-mqtt": "^4.3.23",
105
- "@things-factory/scene-restful": "^4.3.23",
106
- "@things-factory/scene-visualizer": "^4.3.23",
107
- "@things-factory/setting-ui": "^4.3.24",
108
- "@things-factory/system-ui": "^4.3.23",
109
- "@things-factory/transport-base": "^4.3.24",
110
- "@things-factory/tutorial-ui": "^4.3.24",
111
- "@things-factory/warehouse-base": "^4.3.25",
112
- "@things-factory/worksheet-base": "^4.3.25"
66
+ "@things-factory/apptool-ui": "^4.3.27",
67
+ "@things-factory/attachment-ui": "^4.3.27",
68
+ "@things-factory/auth-ui": "^4.3.27",
69
+ "@things-factory/barcode-ui": "^4.3.27",
70
+ "@things-factory/biz-ui": "^4.3.27",
71
+ "@things-factory/board-service": "^4.3.27",
72
+ "@things-factory/board-ui": "^4.3.27",
73
+ "@things-factory/code-ui": "^4.3.27",
74
+ "@things-factory/context-ui": "^4.3.27",
75
+ "@things-factory/export-ui": "^4.3.27",
76
+ "@things-factory/export-ui-csv": "^4.3.27",
77
+ "@things-factory/export-ui-excel": "^4.3.27",
78
+ "@things-factory/fav-base": "^4.3.27",
79
+ "@things-factory/form-ui": "^4.3.27",
80
+ "@things-factory/grist-ui": "^4.3.27",
81
+ "@things-factory/help": "^4.3.27",
82
+ "@things-factory/i18n-base": "^4.3.27",
83
+ "@things-factory/id-rule-base": "^4.3.27",
84
+ "@things-factory/import-ui": "^4.3.27",
85
+ "@things-factory/import-ui-excel": "^4.3.27",
86
+ "@things-factory/menu-ui": "^4.3.27",
87
+ "@things-factory/more-ui": "^4.3.27",
88
+ "@things-factory/notification": "^4.3.27",
89
+ "@things-factory/pdf": "^4.3.27",
90
+ "@things-factory/print-proxy-service": "^4.3.27",
91
+ "@things-factory/print-service": "^4.3.27",
92
+ "@things-factory/print-ui": "^4.3.27",
93
+ "@things-factory/product-base": "^4.3.27",
94
+ "@things-factory/resource-ui": "^4.3.27",
95
+ "@things-factory/sales-ui": "^4.3.28",
96
+ "@things-factory/scene-data-transform": "^4.3.27",
97
+ "@things-factory/scene-excel": "^4.3.27",
98
+ "@things-factory/scene-firebase": "^4.3.27",
99
+ "@things-factory/scene-form": "^4.3.27",
100
+ "@things-factory/scene-google-map": "^4.3.27",
101
+ "@things-factory/scene-graphql": "^4.3.27",
102
+ "@things-factory/scene-label": "^4.3.27",
103
+ "@things-factory/scene-marker": "^4.3.27",
104
+ "@things-factory/scene-mqtt": "^4.3.27",
105
+ "@things-factory/scene-restful": "^4.3.27",
106
+ "@things-factory/scene-visualizer": "^4.3.27",
107
+ "@things-factory/setting-ui": "^4.3.27",
108
+ "@things-factory/system-ui": "^4.3.27",
109
+ "@things-factory/transport-base": "^4.3.27",
110
+ "@things-factory/tutorial-ui": "^4.3.27",
111
+ "@things-factory/warehouse-base": "^4.3.28",
112
+ "@things-factory/worksheet-base": "^4.3.28"
113
113
  },
114
114
  "devDependencies": {
115
- "@things-factory/builder": "^4.3.23",
115
+ "@things-factory/builder": "^4.3.27",
116
116
  "cypress": "^9.4.1",
117
117
  "cypress-file-upload": "^5.0.8",
118
118
  "cypress-localstorage-commands": "^1.6.1",
119
119
  "eslint-plugin-cypress": "^2.12.1"
120
120
  },
121
- "gitHead": "bdcecd8454d7a76df3c5676a39440d57bc21d5cb"
121
+ "gitHead": "f1af695e2848b49871ca1d4f1661a5620ed428da"
122
122
  }
@@ -3,9 +3,16 @@ import { EntityManager } from 'typeorm'
3
3
  import { User } from '@things-factory/auth-base'
4
4
  import { Bizplace } from '@things-factory/biz-base'
5
5
  import { Product } from '@things-factory/product-base'
6
- import { ORDER_INVENTORY_STATUS, OrderInventory, OrderNoGenerator, ReleaseGood } from '@things-factory/sales-base'
6
+ import {
7
+ ORDER_INVENTORY_STATUS,
8
+ ORDER_PRODUCT_STATUS,
9
+ OrderInventory,
10
+ OrderNoGenerator,
11
+ OrderProduct,
12
+ ReleaseGood
13
+ } from '@things-factory/sales-base'
7
14
  import { Domain } from '@things-factory/shell'
8
- import { Inventory, INVENTORY_TRANSACTION_TYPE, InventoryHistory } from '@things-factory/warehouse-base'
15
+ import { Inventory } from '@things-factory/warehouse-base'
9
16
  import {
10
17
  generatePickingWorksheetDetail,
11
18
  Worksheet,
@@ -49,14 +56,6 @@ export const addReleaseGoodProducts = {
49
56
  const foundInv: Inventory = await tx.getRepository(Inventory).findOne(curOrderInv.inventory.id)
50
57
  curOrderInv.inventory = foundInv
51
58
 
52
- let foundPickingHistory: InventoryHistory = await tx.getRepository(InventoryHistory).findOne({
53
- where: {
54
- refOrderId: releaseGood.id,
55
- palletId: foundInv.palletId,
56
- transactionType: INVENTORY_TRANSACTION_TYPE.PICKING
57
- }
58
- })
59
-
60
59
  existingOrderInv = await tx.getRepository(OrderInventory).findOne({
61
60
  where: {
62
61
  releaseGood,
@@ -141,14 +140,12 @@ export const addReleaseGoodProducts = {
141
140
  await tx.getRepository(Inventory).save(foundInv)
142
141
 
143
142
  if (existingOrderInv) {
144
- const orderInvStatus = ORDER_INVENTORY_STATUS.PICKING
145
-
146
143
  // if found existing OrderInventory and worksheetDetail then qty, uomValue, and status are updated
147
144
  curOrderInv = {
148
145
  ...existingOrderInv,
149
146
  releaseQty: curOrderInv.releaseQty,
150
147
  releaseUomValue: curOrderInv.releaseUomValue,
151
- status: orderInvStatus
148
+ status: ORDER_INVENTORY_STATUS.PICKING
152
149
  }
153
150
 
154
151
  let existingWorksheetDetail: WorksheetDetail = await tx.getRepository(WorksheetDetail).findOne({
@@ -234,6 +231,18 @@ export const addReleaseGoodProducts = {
234
231
  foundInv.lockedUomValue = Number(foundInv.lockedUomValue) + newOrderInv.releaseUomValue
235
232
  foundInv.updater = user
236
233
 
234
+ let newOrderProduct: OrderProduct = Object.assign(new OrderProduct(), newOrderInv)
235
+ newOrderProduct = {
236
+ ...newOrderProduct,
237
+ packQty: 0,
238
+ actualPackQty: 0,
239
+ palletQty: 0,
240
+ actualPalletQty: 0,
241
+ status: ORDER_PRODUCT_STATUS.ASSIGNED
242
+ }
243
+
244
+ newOrderProduct = await tx.getRepository(OrderProduct).save(newOrderProduct)
245
+
237
246
  await tx.getRepository(Inventory).save(foundInv)
238
247
  } else {
239
248
  // check for existing released OrderInventory specifying product, batchId and packingType