@things-factory/operato-wms 4.3.246 → 4.3.248
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.
- package/client/pages/components/select-inventory-popup.js +4 -1
- package/client/pages/constants/location.js +4 -0
- package/client/pages/inbound/putaway-product.js +43 -10
- package/client/pages/inbound/putaway-same-carton-popup.js +9 -7
- package/client/pages/inbound/unload-product.js +65 -67
- package/client/pages/inbound/worksheet-putaway-return.js +1 -1
- package/client/pages/inbound/worksheet-putaway.js +1 -1
- package/client/pages/inbound/worksheet-unloading-return.js +3 -3
- package/client/pages/inbound/worksheet-unloading.js +1 -1
- package/client/pages/inventory/inventory-by-product.js +11 -0
- package/client/pages/inventory/onhand-inventory.js +64 -3
- package/client/pages/master/product/product-list.js +5 -5
- package/client/pages/order/release-order/create-release-order.js +406 -116
- package/client/pages/order/vas-order/create-vas-order.js +1 -1
- package/client/pages/order/vas-order/popup/select-vas-popup.js +1 -1
- package/client/pages/outbound/loading-product.js +14 -4
- package/client/pages/outbound/sorting-product.js +1 -1
- package/client/pages/outbound/worksheet-batch-picking.js +1 -1
- package/client/pages/outbound/worksheet-loading.js +15 -4
- package/client/pages/outbound/worksheet-packing.js +1 -1
- package/client/pages/outbound/worksheet-picking.js +21 -6
- package/client/pages/outbound/worksheet-return.js +1 -1
- package/client/pages/outbound/worksheet-sorting.js +1 -1
- package/client/pages/report/vas-report.js +12 -11
- package/client/pages/vas/vas-execution-page.js +23 -11
- package/client/pages/vas/worksheet-ref-vas.js +28 -16
- package/config.development.js +96 -77
- package/dist-server/graphql/resolvers/reports/vas-report.js +19 -18
- package/dist-server/graphql/resolvers/reports/vas-report.js.map +1 -1
- package/package.json +23 -23
- package/server/graphql/resolvers/reports/vas-report.ts +19 -19
- package/translations/en.json +13 -2
- package/translations/ko.json +13 -2
- package/translations/ms.json +13 -2
- package/translations/zh.json +13 -2
|
@@ -504,7 +504,7 @@ class CreateVasOrder extends localize(i18next)(PageView) {
|
|
|
504
504
|
this._selectedVasRecord = null
|
|
505
505
|
this._selectedVasRecordIdx = null
|
|
506
506
|
navigate(`vas_order_detail/${response.data.generateVasOrder.name}`)
|
|
507
|
-
this._showToast({ message: i18next.t('vas_order_created') })
|
|
507
|
+
this._showToast({ message: i18next.t('text.vas_order_created') })
|
|
508
508
|
}
|
|
509
509
|
} catch (e) {
|
|
510
510
|
this._showToast(e)
|
|
@@ -157,7 +157,7 @@ class SelectVasPopup extends localize(i18next)(LitElement) {
|
|
|
157
157
|
return this.shadowRoot.querySelector('search-form')
|
|
158
158
|
}
|
|
159
159
|
|
|
160
|
-
async fetchVas({ page, limit, sorters = [] }) {
|
|
160
|
+
async fetchVas({ page, limit, sorters = [{ name: 'name' }] }) {
|
|
161
161
|
let filters = await this.searchForm.getQueryFilters()
|
|
162
162
|
|
|
163
163
|
if (this.type) filters = [...filters, { name: 'type', operator: 'eq', value: this.type }]
|
|
@@ -340,7 +340,7 @@ class LoadingProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
340
340
|
width: 140
|
|
341
341
|
})
|
|
342
342
|
|
|
343
|
-
fields = [
|
|
343
|
+
fields = this._hasVas ? [
|
|
344
344
|
'hasVas',
|
|
345
345
|
'palletId',
|
|
346
346
|
'productSku',
|
|
@@ -352,6 +352,16 @@ class LoadingProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
352
352
|
'releaseQty',
|
|
353
353
|
'pickedQty',
|
|
354
354
|
'loadedQty'
|
|
355
|
+
] : [
|
|
356
|
+
'palletId',
|
|
357
|
+
'productSku',
|
|
358
|
+
'product',
|
|
359
|
+
'packingType',
|
|
360
|
+
'packingSize',
|
|
361
|
+
'batchId',
|
|
362
|
+
'batchIdRef',
|
|
363
|
+
'pickedQty',
|
|
364
|
+
'loadedQty'
|
|
355
365
|
]
|
|
356
366
|
}
|
|
357
367
|
|
|
@@ -666,10 +676,10 @@ class LoadingProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
666
676
|
|
|
667
677
|
this._hasVas = this.pickedProductData.records.find(data => data.hasVas == true) ? true : false
|
|
668
678
|
|
|
669
|
-
this.pickedProductData = { records: this.sortByNameField(this.pickedProductData) }
|
|
670
|
-
|
|
671
679
|
// causes grist unable to display data
|
|
672
|
-
|
|
680
|
+
await this.pageInitialized()
|
|
681
|
+
this.pickedProductData = { records: this.sortByNameField(this.pickedProductData) }
|
|
682
|
+
//this.updateContext()
|
|
673
683
|
// causes grist unable to display data
|
|
674
684
|
} else {
|
|
675
685
|
throw new Error(response.errors[0])
|
|
@@ -206,7 +206,7 @@ class WorksheetBatchPicking extends localize(i18next)(PageView) {
|
|
|
206
206
|
</fieldset>
|
|
207
207
|
</form>
|
|
208
208
|
|
|
209
|
-
<barcode-tag bcid="qrcode" .value=${this._taskNo}></barcode-tag>
|
|
209
|
+
<barcode-tag bcid="qrcode" .value=${this._taskNo} showLogo="true"></barcode-tag>
|
|
210
210
|
</div>
|
|
211
211
|
|
|
212
212
|
<div class="grist">
|
|
@@ -150,7 +150,7 @@ class WorksheetLoading extends localize(i18next)(PageView) {
|
|
|
150
150
|
</fieldset>
|
|
151
151
|
</form>
|
|
152
152
|
|
|
153
|
-
<barcode-tag bcid="qrcode" .value=${this._roNo}></barcode-tag>
|
|
153
|
+
<barcode-tag bcid="qrcode" .value=${this._roNo} showLogo="true"></barcode-tag>
|
|
154
154
|
</div>
|
|
155
155
|
|
|
156
156
|
<div class="grist">
|
|
@@ -162,7 +162,8 @@ class WorksheetLoading extends localize(i18next)(PageView) {
|
|
|
162
162
|
.config=${this.config}
|
|
163
163
|
.data="${this.data}"
|
|
164
164
|
></data-grist>
|
|
165
|
-
|
|
165
|
+
<!-- hides vas Grist -->
|
|
166
|
+
<!--
|
|
166
167
|
${this.vasData?.records
|
|
167
168
|
? html`
|
|
168
169
|
<h2><mwc-icon>list_alt</mwc-icon>${i18next.t('title.vas')}</h2>
|
|
@@ -173,7 +174,7 @@ class WorksheetLoading extends localize(i18next)(PageView) {
|
|
|
173
174
|
.data="${this.vasData}"
|
|
174
175
|
></data-grist>
|
|
175
176
|
`
|
|
176
|
-
: ''}
|
|
177
|
+
: ''} -->
|
|
177
178
|
</div>
|
|
178
179
|
`
|
|
179
180
|
}
|
|
@@ -199,7 +200,9 @@ class WorksheetLoading extends localize(i18next)(PageView) {
|
|
|
199
200
|
pageInitialized() {
|
|
200
201
|
this.preConfig = {
|
|
201
202
|
rows: { appendable: false },
|
|
202
|
-
list: {
|
|
203
|
+
list: {
|
|
204
|
+
fields: ['batchId', 'palletId', 'product', 'packingType', 'releaseQty', 'pickedQty', 'batchIdRef', 'status']
|
|
205
|
+
},
|
|
203
206
|
pagination: { infinite: true },
|
|
204
207
|
columns: [
|
|
205
208
|
{ type: 'gutter', gutterName: 'sequence' },
|
|
@@ -254,6 +257,12 @@ class WorksheetLoading extends localize(i18next)(PageView) {
|
|
|
254
257
|
{
|
|
255
258
|
type: 'integer',
|
|
256
259
|
name: 'releaseQty',
|
|
260
|
+
header: i18next.t('field.release_qty'),
|
|
261
|
+
width: 60
|
|
262
|
+
},
|
|
263
|
+
{
|
|
264
|
+
type: 'integer',
|
|
265
|
+
name: 'pickedQty',
|
|
257
266
|
header: i18next.t('field.picked_qty'),
|
|
258
267
|
width: 60
|
|
259
268
|
},
|
|
@@ -412,6 +421,7 @@ class WorksheetLoading extends localize(i18next)(PageView) {
|
|
|
412
421
|
description
|
|
413
422
|
targetInventory {
|
|
414
423
|
releaseQty
|
|
424
|
+
pickedQty
|
|
415
425
|
product {
|
|
416
426
|
sku
|
|
417
427
|
brand
|
|
@@ -465,6 +475,7 @@ class WorksheetLoading extends localize(i18next)(PageView) {
|
|
|
465
475
|
productSku: worksheetDetail.targetInventory.product.sku,
|
|
466
476
|
productBrand: worksheetDetail.targetInventory.product.brand,
|
|
467
477
|
releaseQty: worksheetDetail.targetInventory.releaseQty,
|
|
478
|
+
pickedQty: worksheetDetail.targetInventory.pickedQty,
|
|
468
479
|
packingType: worksheetDetail.targetInventory.inventory.packingType
|
|
469
480
|
}
|
|
470
481
|
})
|
|
@@ -192,7 +192,7 @@ class WorksheetPacking extends localize(i18next)(PageView) {
|
|
|
192
192
|
</fieldset>
|
|
193
193
|
</form>
|
|
194
194
|
|
|
195
|
-
<barcode-tag bcid="qrcode" .value=${this._roNo}></barcode-tag>
|
|
195
|
+
<barcode-tag bcid="qrcode" .value=${this._roNo} showLogo="true"></barcode-tag>
|
|
196
196
|
</div>
|
|
197
197
|
|
|
198
198
|
<div class="grist">
|
|
@@ -268,7 +268,7 @@ class WorksheetPicking extends localize(i18next)(PageView) {
|
|
|
268
268
|
</fieldset>
|
|
269
269
|
</form>
|
|
270
270
|
|
|
271
|
-
<barcode-tag bcid="qrcode" .value=${this._roNo}></barcode-tag>
|
|
271
|
+
<barcode-tag bcid="qrcode" .value=${this._roNo} showLogo="true"></barcode-tag>
|
|
272
272
|
</div>
|
|
273
273
|
|
|
274
274
|
<div class="grist">
|
|
@@ -296,7 +296,8 @@ class WorksheetPicking extends localize(i18next)(PageView) {
|
|
|
296
296
|
.data="${this.worksheetDetailData}"
|
|
297
297
|
></data-grist>
|
|
298
298
|
|
|
299
|
-
|
|
299
|
+
<!-- vas data -->
|
|
300
|
+
<!-- ${this.vasData?.records
|
|
300
301
|
? html`
|
|
301
302
|
<h2><mwc-icon>list_alt</mwc-icon>${i18next.t('title.vas')}</h2>
|
|
302
303
|
<data-grist
|
|
@@ -306,7 +307,7 @@ class WorksheetPicking extends localize(i18next)(PageView) {
|
|
|
306
307
|
.data="${this.vasData}"
|
|
307
308
|
></data-grist>
|
|
308
309
|
`
|
|
309
|
-
: ''}
|
|
310
|
+
: ''} -->
|
|
310
311
|
</div>
|
|
311
312
|
</div>
|
|
312
313
|
`
|
|
@@ -463,6 +464,7 @@ class WorksheetPicking extends localize(i18next)(PageView) {
|
|
|
463
464
|
'packingType',
|
|
464
465
|
'location',
|
|
465
466
|
'releaseQty',
|
|
467
|
+
'pickedQty',
|
|
466
468
|
'batchIdRef',
|
|
467
469
|
'status'
|
|
468
470
|
]
|
|
@@ -525,6 +527,12 @@ class WorksheetPicking extends localize(i18next)(PageView) {
|
|
|
525
527
|
header: i18next.t('field.release_qty'),
|
|
526
528
|
width: 60
|
|
527
529
|
},
|
|
530
|
+
{
|
|
531
|
+
type: 'integer',
|
|
532
|
+
name: 'pickedQty',
|
|
533
|
+
header: i18next.t('field.picked_qty'),
|
|
534
|
+
width: 60
|
|
535
|
+
},
|
|
528
536
|
{
|
|
529
537
|
type: 'string',
|
|
530
538
|
name: 'releaseUomValueWithUom',
|
|
@@ -711,6 +719,7 @@ class WorksheetPicking extends localize(i18next)(PageView) {
|
|
|
711
719
|
packingSize
|
|
712
720
|
uom
|
|
713
721
|
releaseQty
|
|
722
|
+
pickedQty
|
|
714
723
|
releaseUomValue
|
|
715
724
|
inventory {
|
|
716
725
|
qty
|
|
@@ -1003,6 +1012,7 @@ class WorksheetPicking extends localize(i18next)(PageView) {
|
|
|
1003
1012
|
batchId
|
|
1004
1013
|
batchIdRef
|
|
1005
1014
|
releaseQty
|
|
1015
|
+
pickedQty
|
|
1006
1016
|
releaseUomValue
|
|
1007
1017
|
product {
|
|
1008
1018
|
sku
|
|
@@ -1083,13 +1093,18 @@ class WorksheetPicking extends localize(i18next)(PageView) {
|
|
|
1083
1093
|
productSku: wsd.targetInventory.inventory.product.sku,
|
|
1084
1094
|
productBrand: wsd.targetInventory.inventory.product.brand,
|
|
1085
1095
|
releaseQty: wsd.targetInventory.releaseQty,
|
|
1096
|
+
pickedQty: wsd.targetInventory.pickedQty,
|
|
1086
1097
|
releaseUomValue: wsd.targetInventory.releaseUomValue,
|
|
1087
1098
|
releaseUomValueWithUom:
|
|
1088
1099
|
wsd.targetInventory.releaseUomValue.toFixed(2) + ' ' + wsd.targetInventory.inventory.uom,
|
|
1089
1100
|
availableQty:
|
|
1090
|
-
|
|
1091
|
-
|
|
1092
|
-
|
|
1101
|
+
orderVass.length == 0
|
|
1102
|
+
? wsd.targetInventory.inventory.qty -
|
|
1103
|
+
wsd.targetInventory.inventory.lockedQty +
|
|
1104
|
+
wsd.targetInventory.releaseQty
|
|
1105
|
+
: wsd.targetInventory.inventory.qty -
|
|
1106
|
+
wsd.targetInventory.inventory.lockedQty +
|
|
1107
|
+
wsd.targetInventory.pickedQty
|
|
1093
1108
|
}
|
|
1094
1109
|
|
|
1095
1110
|
if (wsd.targetInventory?.inventory) {
|
|
@@ -129,7 +129,7 @@ class WorksheetReturn extends localize(i18next)(PageView) {
|
|
|
129
129
|
</fieldset>
|
|
130
130
|
</form>
|
|
131
131
|
|
|
132
|
-
<barcode-tag bcid="qrcode" .value=${this._roNo}></barcode-tag>
|
|
132
|
+
<barcode-tag bcid="qrcode" .value=${this._roNo} showLogo="true"></barcode-tag>
|
|
133
133
|
</div>
|
|
134
134
|
|
|
135
135
|
<div class="grist">
|
|
@@ -126,7 +126,7 @@ class WorksheetSorting extends localize(i18next)(PageView) {
|
|
|
126
126
|
</fieldset>
|
|
127
127
|
</form>
|
|
128
128
|
|
|
129
|
-
<barcode-tag bcid="qrcode" .value=${this._taskNo}></barcode-tag>
|
|
129
|
+
<barcode-tag bcid="qrcode" .value=${this._taskNo} showLogo="true"></barcode-tag>
|
|
130
130
|
</div>
|
|
131
131
|
|
|
132
132
|
<div class="grist">
|
|
@@ -112,15 +112,10 @@ class VasReport extends connect(store)(localize(i18next)(PageView)) {
|
|
|
112
112
|
searchOper: 'eq',
|
|
113
113
|
max: new Date().toISOString().split('T')[0]
|
|
114
114
|
},
|
|
115
|
-
// value: (() => {
|
|
116
|
-
// let date = new Date()
|
|
117
|
-
// date.setMonth(date.getMonth() - 1)
|
|
118
|
-
// return date.toISOString().split('T')[0]
|
|
119
|
-
// })(),
|
|
120
115
|
handlers: { change: this._modifyDateRange.bind(this) }
|
|
121
116
|
},
|
|
122
117
|
{
|
|
123
|
-
|
|
118
|
+
label: i18next.t('field.completion_vas_to_date'),
|
|
124
119
|
name: 'toDate',
|
|
125
120
|
type: 'date',
|
|
126
121
|
props: {
|
|
@@ -131,20 +126,19 @@ class VasReport extends connect(store)(localize(i18next)(PageView)) {
|
|
|
131
126
|
return date.toISOString().split('T')[0]
|
|
132
127
|
})(),
|
|
133
128
|
max: new Date().toISOString().split('T')[0]
|
|
134
|
-
}
|
|
135
|
-
// value: new Date().toISOString().split('T')[0]
|
|
129
|
+
}
|
|
136
130
|
},
|
|
137
131
|
{
|
|
138
132
|
label: i18next.t('field.product_info'),
|
|
139
133
|
name: 'productInfo',
|
|
140
134
|
type: 'string',
|
|
141
|
-
props: { searchOper: '
|
|
135
|
+
props: { searchOper: 'i_like' }
|
|
142
136
|
},
|
|
143
137
|
{
|
|
144
138
|
label: i18next.t('field.order_no'),
|
|
145
139
|
name: 'orderNo',
|
|
146
140
|
type: 'string',
|
|
147
|
-
props: { searchOper: '
|
|
141
|
+
props: { searchOper: 'i_like' }
|
|
148
142
|
}
|
|
149
143
|
]
|
|
150
144
|
}
|
|
@@ -510,7 +504,14 @@ class VasReport extends connect(store)(localize(i18next)(PageView)) {
|
|
|
510
504
|
|
|
511
505
|
return {
|
|
512
506
|
header: headerSetting,
|
|
513
|
-
data: this.report.data.records
|
|
507
|
+
data: this.report.data.records.map(record => {
|
|
508
|
+
let date = new Date(parseInt(record.worksheet.endedAt))
|
|
509
|
+
return flattenObject({
|
|
510
|
+
...record,
|
|
511
|
+
completionDate:
|
|
512
|
+
date.getDate().toString() + '/' + (date.getMonth() + 1).toString() + '/' + date.getFullYear().toString()
|
|
513
|
+
})
|
|
514
|
+
}),
|
|
514
515
|
groups: this.report._config.rows.groups,
|
|
515
516
|
totals: this.report._config.rows.totals
|
|
516
517
|
}
|
|
@@ -75,8 +75,8 @@ class VasExecution extends connect(store)(localize(i18next)(PageView)) {
|
|
|
75
75
|
<form id="info-form" class="multi-column-form">
|
|
76
76
|
<fieldset>
|
|
77
77
|
<legend>
|
|
78
|
-
${i18next.t('title.vas')}
|
|
79
|
-
|
|
78
|
+
${i18next.t('title.vas')} [
|
|
79
|
+
${this._selectedVas?.__seq__
|
|
80
80
|
? this._selectedVas?.__seq__
|
|
81
81
|
: this.data
|
|
82
82
|
? parseFloat(
|
|
@@ -327,7 +327,7 @@ class VasExecution extends connect(store)(localize(i18next)(PageView)) {
|
|
|
327
327
|
if (i == 0) {
|
|
328
328
|
wd.push({ ...wsd, targetVas: { ...wsd.targetVas, orderVasItems: wsd.targetVas.orderVasItems[i] } })
|
|
329
329
|
} else {
|
|
330
|
-
wd.push({ targetVas: { orderVasItems: wsd.targetVas.orderVasItems[i] } })
|
|
330
|
+
wd.push({ targetVas: { id: wsd.targetVas.id, orderVasItems: wsd.targetVas.orderVasItems[i] } })
|
|
331
331
|
}
|
|
332
332
|
}
|
|
333
333
|
} else {
|
|
@@ -362,19 +362,24 @@ class VasExecution extends connect(store)(localize(i18next)(PageView)) {
|
|
|
362
362
|
if (!result.value) return
|
|
363
363
|
|
|
364
364
|
this.validateVas(this._selectedVas?.targetVas?.orderVasItems)
|
|
365
|
-
let patches = this.
|
|
365
|
+
let patches = this.data.records
|
|
366
|
+
.filter(d => d.targetVas.id == this._selectedVas.targetVas.id)
|
|
367
|
+
.map(d => {
|
|
368
|
+
return { id: d.targetVas.orderVasItems.id, executedAt: new Date().getTime(), cuFlag: 'M' }
|
|
369
|
+
})
|
|
366
370
|
|
|
367
371
|
if (patches.length === 0) {
|
|
368
372
|
throw new Error(i18next.t('text.nothing_changed'))
|
|
369
373
|
}
|
|
370
374
|
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
375
|
+
// if executed one by one not by set
|
|
376
|
+
// patches = [
|
|
377
|
+
// {
|
|
378
|
+
// id: patches.id,
|
|
379
|
+
// executedAt: new Date().getTime(),
|
|
380
|
+
// cuFlag: 'M'
|
|
381
|
+
// }
|
|
382
|
+
// ]
|
|
378
383
|
|
|
379
384
|
const response = await client.mutate({
|
|
380
385
|
mutation: gql`
|
|
@@ -439,6 +444,8 @@ class VasExecution extends connect(store)(localize(i18next)(PageView)) {
|
|
|
439
444
|
if (!response.errors) {
|
|
440
445
|
this._showToast({ message: i18next.t('text.vas_is_completed') })
|
|
441
446
|
this.clearview()
|
|
447
|
+
this.updateContext()
|
|
448
|
+
this.pageInitialized()
|
|
442
449
|
navigate('vas_worksheets')
|
|
443
450
|
}
|
|
444
451
|
} catch (e) {
|
|
@@ -450,6 +457,11 @@ class VasExecution extends connect(store)(localize(i18next)(PageView)) {
|
|
|
450
457
|
}
|
|
451
458
|
|
|
452
459
|
clearview() {
|
|
460
|
+
this._selectedVas = this._selectedVas?.__seq__
|
|
461
|
+
? this._selectedVas?.__seq__
|
|
462
|
+
: this.data
|
|
463
|
+
? parseFloat(this.data?.records.map(data => data.targetVas.orderVasItems.executedAt === null).indexOf(true)) + 1
|
|
464
|
+
: ''
|
|
453
465
|
this.orderNoInput.value = ''
|
|
454
466
|
this.data = {}
|
|
455
467
|
}
|
|
@@ -126,7 +126,7 @@ class WorksheetRefVas extends localize(i18next)(PageView) {
|
|
|
126
126
|
? html` <label>${i18next.t('label.arrival_notice')}</label>
|
|
127
127
|
<input readonly value="${this.formData.orderNo}" />`
|
|
128
128
|
: this.formData.orderType === ORDER_TYPES.RELEASE_OF_GOODS.value
|
|
129
|
-
? html` <label>${i18next.t('label.
|
|
129
|
+
? html` <label>${i18next.t('label.release_good_no')}</label>
|
|
130
130
|
<input readonly value="${this.formData.orderNo}" />`
|
|
131
131
|
: ''}
|
|
132
132
|
<!-- TODO: Showing reference order number -->
|
|
@@ -173,7 +173,7 @@ class WorksheetRefVas extends localize(i18next)(PageView) {
|
|
|
173
173
|
rows: { appendable: false, handlers: { click: this.taskGristClickHandler.bind(this) } },
|
|
174
174
|
list: {
|
|
175
175
|
fields: [
|
|
176
|
-
'
|
|
176
|
+
'batchId',
|
|
177
177
|
'packingType',
|
|
178
178
|
'uomValue',
|
|
179
179
|
'newSku',
|
|
@@ -196,7 +196,7 @@ class WorksheetRefVas extends localize(i18next)(PageView) {
|
|
|
196
196
|
},
|
|
197
197
|
{
|
|
198
198
|
type: 'string',
|
|
199
|
-
name: '
|
|
199
|
+
name: 'batchId',
|
|
200
200
|
header: i18next.t('field.batch_no'),
|
|
201
201
|
record: { align: 'center' },
|
|
202
202
|
width: 100
|
|
@@ -226,7 +226,7 @@ class WorksheetRefVas extends localize(i18next)(PageView) {
|
|
|
226
226
|
width: 80
|
|
227
227
|
},
|
|
228
228
|
{
|
|
229
|
-
type: '
|
|
229
|
+
type: 'string',
|
|
230
230
|
name: 'vas',
|
|
231
231
|
header: i18next.t('field.vas'),
|
|
232
232
|
width: 250
|
|
@@ -326,17 +326,14 @@ class WorksheetRefVas extends localize(i18next)(PageView) {
|
|
|
326
326
|
description
|
|
327
327
|
sku
|
|
328
328
|
}
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
uomValue
|
|
332
|
-
}
|
|
329
|
+
newPackingType
|
|
330
|
+
newUomValue
|
|
333
331
|
orderVasItems {
|
|
334
332
|
vas {
|
|
335
333
|
name
|
|
336
334
|
description
|
|
337
335
|
operationGuide
|
|
338
336
|
}
|
|
339
|
-
vasQty
|
|
340
337
|
}
|
|
341
338
|
status
|
|
342
339
|
remark
|
|
@@ -382,20 +379,35 @@ class WorksheetRefVas extends localize(i18next)(PageView) {
|
|
|
382
379
|
return formData
|
|
383
380
|
}
|
|
384
381
|
|
|
385
|
-
|
|
382
|
+
formatTaskData() {
|
|
386
383
|
return {
|
|
387
|
-
records: this.worksheet.worksheetDetails.
|
|
388
|
-
|
|
384
|
+
records: this.worksheet.worksheetDetails.reduce((acc, wsd) => {
|
|
385
|
+
acc.push({
|
|
389
386
|
...wsd.targetVas,
|
|
390
387
|
bufferLocation: this.worksheet.bufferLocation,
|
|
391
388
|
sku: wsd.targetVas.product.sku,
|
|
392
389
|
newSku: wsd.targetVas.newProduct?.sku,
|
|
393
|
-
newPackingType: wsd.targetVas.newProductDetail?.packingType,
|
|
394
|
-
newUomValue: wsd.targetVas.newProductDetail?.uomValue,
|
|
395
390
|
description: wsd.description,
|
|
396
391
|
issue: wsd.issue
|
|
397
|
-
}
|
|
398
|
-
|
|
392
|
+
})
|
|
393
|
+
|
|
394
|
+
wsd.targetVas.orderVasItems.forEach((item, idx) => {
|
|
395
|
+
if (idx == 0) {
|
|
396
|
+
acc[acc.length - 1] = {
|
|
397
|
+
...acc[acc.length - 1],
|
|
398
|
+
vas: item.vas.name,
|
|
399
|
+
// newSku: item.newProduct?.sku
|
|
400
|
+
}
|
|
401
|
+
} else {
|
|
402
|
+
acc.push({
|
|
403
|
+
vas: item.vas.name,
|
|
404
|
+
// newSku: item.newProduct?.sku
|
|
405
|
+
})
|
|
406
|
+
}
|
|
407
|
+
})
|
|
408
|
+
|
|
409
|
+
return acc
|
|
410
|
+
}, [])
|
|
399
411
|
}
|
|
400
412
|
}
|
|
401
413
|
|