@things-factory/operato-wms 4.3.38 → 4.3.41

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.
Files changed (42) hide show
  1. package/client/pages/bulk-operation/bulk-operation.js +13 -2
  2. package/client/pages/bulk-operation/validate-ro-popup.js +40 -0
  3. package/client/pages/inventory/onhand-inventory.js +1 -18
  4. package/client/pages/order/arrival-notice/arrival-notice-detail.js +2 -2
  5. package/client/pages/order/arrival-notice/create-arrival-notice.js +2 -2
  6. package/client/pages/order/goods-received-note/received-note-detail.js +187 -15
  7. package/client/pages/order/release-order/create-release-order.js +500 -6
  8. package/client/pages/order/release-order/release-order-detail.js +760 -169
  9. package/client/pages/order/transport-order/delivery-note-popup.js +970 -126
  10. package/client/pages/order/transport-order/print-delivery-note.js +162 -2
  11. package/client/pages/outbound/loading-product.js +87 -77
  12. package/client/pages/outbound/merged-outbound-worksheet.js +2 -2
  13. package/client/pages/outbound/picking-product.js +11 -7
  14. package/client/pages/outbound/route-label-popup.js +283 -191
  15. package/client/pages/outbound/sorting-product.js +7 -7
  16. package/client/pages/report/inbound-serial-number-report.js +86 -9
  17. package/client/pages/report/inventory-report.js +10 -0
  18. package/client/pages/report/outbound-serial-number-report.js +87 -9
  19. package/dist-server/graphql/resolvers/dashboard/inventory-expiry-monitor.js +10 -5
  20. package/dist-server/graphql/resolvers/dashboard/inventory-expiry-monitor.js.map +1 -1
  21. package/dist-server/graphql/resolvers/dashboard/outbound-order-by-status.js +11 -5
  22. package/dist-server/graphql/resolvers/dashboard/outbound-order-by-status.js.map +1 -1
  23. package/dist-server/graphql/resolvers/reports/inbound-serial-number-report.js +33 -4
  24. package/dist-server/graphql/resolvers/reports/inbound-serial-number-report.js.map +1 -1
  25. package/dist-server/graphql/resolvers/reports/outbound-serial-number-report.js +33 -8
  26. package/dist-server/graphql/resolvers/reports/outbound-serial-number-report.js.map +1 -1
  27. package/dist-server/utils/report-query-util.js +3 -2
  28. package/dist-server/utils/report-query-util.js.map +1 -1
  29. package/helps/release-note.ko.md +10 -12
  30. package/helps/release-note.md +10 -12
  31. package/helps/release-note.ms.md +10 -12
  32. package/helps/release-note.zh.md +10 -12
  33. package/package.json +21 -20
  34. package/server/graphql/resolvers/dashboard/inventory-expiry-monitor.ts +10 -8
  35. package/server/graphql/resolvers/dashboard/outbound-order-by-status.ts +10 -7
  36. package/server/graphql/resolvers/reports/inbound-serial-number-report.ts +34 -4
  37. package/server/graphql/resolvers/reports/outbound-serial-number-report.ts +34 -8
  38. package/server/utils/report-query-util.ts +3 -2
  39. package/translations/en.json +31 -0
  40. package/translations/ko.json +10 -1
  41. package/translations/ms.json +11 -1
  42. package/translations/zh.json +10 -1
@@ -23,7 +23,10 @@ class PrintDeliveryOrder extends localize(i18next)(PageView) {
23
23
  _customerContactPoints: Array,
24
24
  _bizplace: Object,
25
25
  _orderInfo: Object,
26
- _isManualDo: Boolean
26
+ _isManualDo: Boolean,
27
+ _data: Object,
28
+ _roNo: String,
29
+ _refNo: String
27
30
  }
28
31
  }
29
32
 
@@ -87,7 +90,11 @@ class PrintDeliveryOrder extends localize(i18next)(PageView) {
87
90
  return {
88
91
  title: i18next.t('title.goods_delivery_note_details'),
89
92
  help: 'operato-wms/transport-order/print-delivery-note',
90
- actions
93
+ actions,
94
+ exportable: {
95
+ name: i18next.t('title.goods_delivery_note_details'),
96
+ data: this._exportableData.bind(this)
97
+ },
91
98
  }
92
99
  }
93
100
 
@@ -107,6 +114,7 @@ class PrintDeliveryOrder extends localize(i18next)(PageView) {
107
114
 
108
115
  if (this._doNo) {
109
116
  await this._fetchDeliveryOrder(this._doNo)
117
+ await this._fetchDeliveryOrderRO(this._doNo)
110
118
  }
111
119
 
112
120
  this.updateContext()
@@ -179,6 +187,43 @@ class PrintDeliveryOrder extends localize(i18next)(PageView) {
179
187
  }
180
188
  }
181
189
 
190
+ async _fetchDeliveryOrderRO(name){
191
+ const response = await client.query({
192
+ query: gql`
193
+ query fetchDeliveryOrderRO($name: String!) {
194
+ fetchDeliveryOrderRO(name: $name){
195
+ roNo
196
+ doNo
197
+ roRef
198
+ roRef2
199
+ roRef3
200
+ companyDomain
201
+ recipientBiz
202
+ doDate
203
+ productList {
204
+ batchNo
205
+ sku
206
+ name
207
+ type
208
+ uom
209
+ loadedQty
210
+ uomValue
211
+ }
212
+ }
213
+ }
214
+ `,
215
+ variables: {
216
+ name
217
+ }
218
+ })
219
+
220
+ if(!response.error){
221
+ this._data = response.data.fetchDeliveryOrderRO
222
+ this._roNo = this._data.roNo
223
+ this._refNo = this._data.roRef
224
+ }
225
+ }
226
+
182
227
  async _checkDeliveredOrder() {
183
228
  const popup = openPopup(
184
229
  html`
@@ -234,6 +279,8 @@ class PrintDeliveryOrder extends localize(i18next)(PageView) {
234
279
  html`
235
280
  <delivery-note-popup
236
281
  .doNo="${this._doNo}"
282
+ .roNo="${this._roNo}"
283
+ .refNo="${this._refNo}"
237
284
  .bizplace="${this._bizplace}"
238
285
  .orderInfo="${this._orderInfo}"
239
286
  .status="${this._status}"
@@ -261,6 +308,119 @@ class PrintDeliveryOrder extends localize(i18next)(PageView) {
261
308
  }
262
309
  }
263
310
 
311
+ _exportableData() {
312
+ const {roNo,doNo,roRef,roRef2,roRef3,companyDomain,recipientBiz,doDate} = this._data
313
+
314
+ const exportData = this._data.productList.map((res)=>{
315
+ return{
316
+ roNo,
317
+ doNo,
318
+ roRef,
319
+ roRef2,
320
+ roRef3,
321
+ companyDomain,
322
+ recipientBiz,
323
+ doDate,
324
+ ...res
325
+ }
326
+ })
327
+
328
+ const headerSetting = [
329
+ {
330
+ header: i18next.t('field.ro'),
331
+ key: 'roNo',
332
+ width: 25,
333
+ type: 'string'
334
+ },
335
+ {
336
+ header: i18next.t('field.do'),
337
+ key: 'doNo',
338
+ width: 25,
339
+ type: 'string'
340
+ },
341
+ {
342
+ header: i18next.t('field.ref_no'),
343
+ key: 'roRef',
344
+ width: 25,
345
+ type: 'string'
346
+ },
347
+ {
348
+ header: i18next.t('field.ref_no_2'),
349
+ key: 'roRef2',
350
+ width: 25,
351
+ type: 'string'
352
+ },
353
+ {
354
+ header: i18next.t('field.ref_no_3'),
355
+ key: 'roRef3',
356
+ width: 25,
357
+ type: 'string'
358
+ },
359
+ {
360
+ header: i18next.t('field.company'),
361
+ key: 'companyDomain',
362
+ width: 25,
363
+ type: 'string'
364
+ },
365
+ {
366
+ header: i18next.t('field.recipient_bizplace'),
367
+ key: 'recipientBiz',
368
+ width: 25,
369
+ type: 'string'
370
+ },
371
+ {
372
+ header: i18next.t('field.do_generated_date'),
373
+ key: 'doDate',
374
+ width: 25,
375
+ type: 'string'
376
+ },
377
+ {
378
+ header: i18next.t('field.batch_no'),
379
+ key: 'batchNo',
380
+ width: 25,
381
+ type: 'string'
382
+ },
383
+ {
384
+ header: i18next.t('field.sku'),
385
+ key: 'sku',
386
+ width: 25,
387
+ type: 'string'
388
+ },
389
+ {
390
+ header: i18next.t('field.product_name'),
391
+ key: 'name',
392
+ width: 25,
393
+ type: 'string'
394
+ },
395
+ {
396
+ header: i18next.t('field.packing_type'),
397
+ key: 'type',
398
+ width: 25,
399
+ type: 'string'
400
+ },
401
+ {
402
+ header: i18next.t('field.loaded_qty'),
403
+ key: 'loadedQty',
404
+ width: 25,
405
+ type: 'string'
406
+ },
407
+ {
408
+ header: i18next.t('field.load_uom_value'),
409
+ key: 'uomValue',
410
+ width: 25,
411
+ type: 'string'
412
+ },
413
+ {
414
+ header: i18next.t('field.uom'),
415
+ key: 'uom',
416
+ width: 25,
417
+ type: 'string'
418
+ }
419
+ ]
420
+
421
+ return { header: headerSetting, data: exportData }
422
+ }
423
+
264
424
  _showToast({ type, message }) {
265
425
  document.dispatchEvent(
266
426
  new CustomEvent('notify', {
@@ -11,6 +11,7 @@ import { sleep } from '@operato/utils'
11
11
  import { MultiColumnFormStyles, SingleColumnFormStyles } from '@things-factory/form-ui'
12
12
  import { i18next, localize } from '@things-factory/i18n-base'
13
13
  import { openPopup } from '@things-factory/layout-base'
14
+ import { fetchSettingRule } from '../../fetch-setting-value'
14
15
  import { client, CustomAlert, PageView, store } from '@things-factory/shell'
15
16
  import { CommonButtonStyles } from '@things-factory/styles'
16
17
  import { isMobileDevice } from '@things-factory/utils'
@@ -308,6 +309,91 @@ class LoadingProduct extends connect(store)(localize(i18next)(PageView)) {
308
309
  }
309
310
 
310
311
  async pageInitialized() {
312
+ let enableToteScanning = await fetchSettingRule('enable-tote-scanning')
313
+ let configColumns = [
314
+ { type: 'gutter', gutterName: 'sequence' },
315
+ { type: 'gutter', gutterName: 'row-selector', multiple: true }
316
+ ]
317
+
318
+ if (enableToteScanning) {
319
+ configColumns.push({
320
+ type: 'string',
321
+ name: 'toteName',
322
+ header: i18next.t('field.tote'),
323
+ width: 140
324
+ })
325
+ }
326
+
327
+ configColumns.push(
328
+ {
329
+ type: 'string',
330
+ name: 'palletId',
331
+ header: i18next.t('field.lot_id'),
332
+ width: 140
333
+ },
334
+ {
335
+ type: 'string',
336
+ name: 'productSku',
337
+ header: i18next.t('field.sku'),
338
+ width: 140
339
+ },
340
+ {
341
+ type: 'object',
342
+ name: 'product',
343
+ header: i18next.t('field.product'),
344
+ width: 140
345
+ },
346
+ {
347
+ type: 'string',
348
+ name: 'packingType',
349
+ header: i18next.t('field.packing_type'),
350
+ width: 140
351
+ },
352
+ {
353
+ type: 'string',
354
+ name: 'packingSize',
355
+ header: i18next.t('field.packing_size'),
356
+ width: 140
357
+ },
358
+ {
359
+ type: 'string',
360
+ name: 'batchId',
361
+ header: i18next.t('field.batch_id'),
362
+ width: 140
363
+ },
364
+ {
365
+ type: 'string',
366
+ name: 'batchIdRef',
367
+ header: i18next.t('field.batch_no_ref'),
368
+ width: 140
369
+ },
370
+ {
371
+ type: 'string',
372
+ name: 'releaseUomValue',
373
+ header: i18next.t('field.release_uom_value'),
374
+ width: 100
375
+ },
376
+ {
377
+ type: 'string',
378
+ name: 'uom',
379
+ header: i18next.t('field.uom'),
380
+ width: 80
381
+ },
382
+ {
383
+ type: 'integer',
384
+ name: 'releaseQty',
385
+ header: i18next.t('field.picked_qty'),
386
+ width: 100
387
+ },
388
+ {
389
+ type: 'integer',
390
+ name: 'loadedQty',
391
+ header: i18next.t('field.loaded_qty'),
392
+ record: { editable: true },
393
+ width: 100
394
+ }
395
+ )
396
+
311
397
  this.pickedProductConfig = {
312
398
  rows: {
313
399
  appendable: false,
@@ -339,83 +425,7 @@ class LoadingProduct extends connect(store)(localize(i18next)(PageView)) {
339
425
  'loadedQty'
340
426
  ]
341
427
  },
342
- columns: [
343
- { type: 'gutter', gutterName: 'sequence' },
344
- { type: 'gutter', gutterName: 'row-selector', multiple: true },
345
- {
346
- type: 'string',
347
- name: 'toteName',
348
- header: i18next.t('field.tote'),
349
- width: 140
350
- },
351
- {
352
- type: 'string',
353
- name: 'palletId',
354
- header: i18next.t('field.lot_id'),
355
- width: 140
356
- },
357
- {
358
- type: 'string',
359
- name: 'productSku',
360
- header: i18next.t('field.sku'),
361
- width: 140
362
- },
363
- {
364
- type: 'object',
365
- name: 'product',
366
- header: i18next.t('field.product'),
367
- width: 140
368
- },
369
- {
370
- type: 'string',
371
- name: 'packingType',
372
- header: i18next.t('field.packing_type'),
373
- width: 140
374
- },
375
- {
376
- type: 'string',
377
- name: 'packingSize',
378
- header: i18next.t('field.packing_size'),
379
- width: 140
380
- },
381
- {
382
- type: 'string',
383
- name: 'batchId',
384
- header: i18next.t('field.batch_id'),
385
- width: 140
386
- },
387
- {
388
- type: 'string',
389
- name: 'batchIdRef',
390
- header: i18next.t('field.batch_no_ref'),
391
- width: 140
392
- },
393
- {
394
- type: 'string',
395
- name: 'releaseUomValue',
396
- header: i18next.t('field.release_uom_value'),
397
- width: 100
398
- },
399
- {
400
- type: 'string',
401
- name: 'uom',
402
- header: i18next.t('field.uom'),
403
- width: 80
404
- },
405
- {
406
- type: 'integer',
407
- name: 'releaseQty',
408
- header: i18next.t('field.picked_qty'),
409
- width: 100
410
- },
411
- {
412
- type: 'integer',
413
- name: 'loadedQty',
414
- header: i18next.t('field.loaded_qty'),
415
- record: { editable: true },
416
- width: 100
417
- }
418
- ]
428
+ columns: configColumns
419
429
  }
420
430
 
421
431
  this.deliveryOrderConfig = {
@@ -110,7 +110,7 @@ class MergedOutboundWorksheet extends localize(i18next)(PageView) {
110
110
  async pageInitialized() {
111
111
  const _worksheetStatus = await getCodeByName('WORKSHEET_STATUS')
112
112
  const partners = [...(await this._fetchPartners())]
113
-
113
+
114
114
  this._searchFields = [
115
115
  {
116
116
  name: 'name',
@@ -371,7 +371,7 @@ class MergedOutboundWorksheet extends localize(i18next)(PageView) {
371
371
 
372
372
  if (!response.errors) {
373
373
  let domain = response.data.worksheets.items[0]?.domain
374
- this._routeLabelSetting = await fetchSettingRule('enable-print-route-label', domain.id)
374
+ this._routeLabelSetting = await fetchSettingRule('enable-print-route-label', domain?.id)
375
375
  this.updateContext()
376
376
  return {
377
377
  total: response.data.worksheets.total || 0,
@@ -349,7 +349,7 @@ class PickingProduct extends connect(store)(localize(i18next)(PageView)) {
349
349
  ${this.scannable
350
350
  ? html`
351
351
  <fieldset>
352
- ${this._hasBinPicking && (!this.toteNo || this.tote !== '')
352
+ ${this._hasBinPicking && (!this.toteNo || this.tote == '')
353
353
  ? html`
354
354
  <label>${i18next.t('label.bin_location')}</label>
355
355
  <barcode-scanable-input
@@ -1023,7 +1023,7 @@ class PickingProduct extends connect(store)(localize(i18next)(PageView)) {
1023
1023
  }
1024
1024
 
1025
1025
  if (!response.errors) {
1026
- if (this._hasBinPicking) {
1026
+ if (this._hasBinPicking && (!this.toteNo || this.tote == '')) {
1027
1027
  this._currentBinLocation = this.binLocationInput.value
1028
1028
  }
1029
1029
  if (this._isRequireSerialNumberScanningOutbound) this.serialInput.value = ''
@@ -1225,7 +1225,8 @@ class PickingProduct extends connect(store)(localize(i18next)(PageView)) {
1225
1225
  palletId: this.palletInput.value.trim(),
1226
1226
  locationName: this._locationName ? this._locationName : this._selectedOrderInventory?.location.name,
1227
1227
  releaseQty: this._isRequireSerialNumberScanningOutbound ? 1 : parseInt(this.releaseQtyInput.value),
1228
- binLocation: this._hasBinPicking ? this.binLocationInput.value : null,
1228
+ binLocation:
1229
+ this._hasBinPicking && (!this.toteNo || this.tote == '') ? this.binLocationInput.value : null,
1229
1230
  serialNumber: this._isRequireSerialNumberScanningOutbound ? this.serialInput.value : null,
1230
1231
  toteNo: this._enableToteScanning && this.toteNo !== '' ? this.toteNo : null
1231
1232
  }
@@ -1257,7 +1258,8 @@ class PickingProduct extends connect(store)(localize(i18next)(PageView)) {
1257
1258
  worksheetType: this.refPickingType,
1258
1259
  palletId: this.palletInput.value.trim(),
1259
1260
  locationName: this._locationName ? this._locationName : this._selectedOrderInventory?.location.name,
1260
- binLocationName: this._hasBinPicking ? this.binLocationInput.value : null,
1261
+ binLocationName:
1262
+ this._hasBinPicking && (!this.toteNo || this.tote == '') ? this.binLocationInput.value : null,
1261
1263
  releaseQty: parseInt(this.releaseQtyInput.value)
1262
1264
  }
1263
1265
  })
@@ -1305,7 +1307,8 @@ class PickingProduct extends connect(store)(localize(i18next)(PageView)) {
1305
1307
  productBarcode: this.productBarcodeInput.value.trim(),
1306
1308
  cartonId: this.cartonInput.value.trim(),
1307
1309
  serialNumber: this._isRequireSerialNumberScanningOutbound ? this.serialInput.value : null,
1308
- binLocation: this._hasBinPicking ? this.binLocationInput.value : null,
1310
+ binLocation:
1311
+ this._hasBinPicking && (!this.toteNo || this.tote == '') ? this.binLocationInput.value : null,
1309
1312
  toteNo: this._enableToteScanning && this.toteNo !== '' ? this.toteNo : null
1310
1313
  }
1311
1314
  })
@@ -1342,7 +1345,8 @@ class PickingProduct extends connect(store)(localize(i18next)(PageView)) {
1342
1345
  packingSize: this._selectedOrderInventory.packingSize,
1343
1346
  product: { id: this._selectedOrderInventory.product.id }
1344
1347
  },
1345
- binLocationName: this._hasBinPicking ? this.binLocationInput.value : null
1348
+ binLocationName:
1349
+ this._hasBinPicking && (!this.toteNo || this.tote == '') ? this.binLocationInput.value : null
1346
1350
  }
1347
1351
  })
1348
1352
  }
@@ -1829,7 +1833,7 @@ class PickingProduct extends connect(store)(localize(i18next)(PageView)) {
1829
1833
  focusOnInput() {
1830
1834
  if (this.scannable) {
1831
1835
  // set bin location value if already has value else focus on bin input if bin picking setting is active
1832
- if (this._currentBinLocation) {
1836
+ if (this._currentBinLocation && this.binLocationInput) {
1833
1837
  this.binLocationInput.value = this._currentBinLocation
1834
1838
  }
1835
1839