@things-factory/operato-wms 4.3.417 → 4.3.418
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.
|
@@ -266,6 +266,11 @@ class SelectInventoryPopUp extends localize(i18next)(LitElement) {
|
|
|
266
266
|
}
|
|
267
267
|
} else {
|
|
268
268
|
this.searchFields = [
|
|
269
|
+
{
|
|
270
|
+
label: i18next.t('field.lot_id'),
|
|
271
|
+
name: 'palletId',
|
|
272
|
+
props: { searchOper: 'i_like' }
|
|
273
|
+
},
|
|
269
274
|
{
|
|
270
275
|
label: i18next.t('field.batch_id'),
|
|
271
276
|
name: 'batchId',
|
|
@@ -7,38 +7,18 @@ import './putaway-same-carton-popup'
|
|
|
7
7
|
import './putaway-replenishment-inventory-popup'
|
|
8
8
|
|
|
9
9
|
import gql from 'graphql-tag'
|
|
10
|
-
import {
|
|
11
|
-
css,
|
|
12
|
-
html
|
|
13
|
-
} from 'lit-element'
|
|
10
|
+
import { css, html } from 'lit-element'
|
|
14
11
|
import { connect } from 'pwa-helpers/connect-mixin.js'
|
|
15
12
|
|
|
16
13
|
import { MultiColumnFormStyles } from '@things-factory/form-ui'
|
|
17
|
-
import {
|
|
18
|
-
i18next,
|
|
19
|
-
localize
|
|
20
|
-
} from '@things-factory/i18n-base'
|
|
14
|
+
import { i18next, localize } from '@things-factory/i18n-base'
|
|
21
15
|
import { openPopup } from '@things-factory/layout-base'
|
|
22
|
-
import {
|
|
23
|
-
client,
|
|
24
|
-
CustomAlert,
|
|
25
|
-
PageView,
|
|
26
|
-
store
|
|
27
|
-
} from '@things-factory/shell'
|
|
16
|
+
import { client, CustomAlert, PageView, store } from '@things-factory/shell'
|
|
28
17
|
import { CommonButtonStyles } from '@things-factory/styles'
|
|
29
|
-
import {
|
|
30
|
-
isMobileDevice,
|
|
31
|
-
sleep
|
|
32
|
-
} from '@things-factory/utils'
|
|
18
|
+
import { isMobileDevice, sleep } from '@things-factory/utils'
|
|
33
19
|
|
|
34
20
|
import { fetchSettingRule } from '../../fetch-setting-value'
|
|
35
|
-
import {
|
|
36
|
-
ARRIVAL_NOTICE,
|
|
37
|
-
CUSTOMER_RETURN,
|
|
38
|
-
REPLENISHMENT,
|
|
39
|
-
WAREHOUSE_RETURN,
|
|
40
|
-
WORKSHEET_STATUS
|
|
41
|
-
} from '../constants'
|
|
21
|
+
import { ARRIVAL_NOTICE, CUSTOMER_RETURN, REPLENISHMENT, WAREHOUSE_RETURN, WORKSHEET_STATUS } from '../constants'
|
|
42
22
|
|
|
43
23
|
const OPERATION_TYPE = {
|
|
44
24
|
PUTAWAY: 'putaway',
|
|
@@ -140,6 +120,132 @@ class PutawayProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
140
120
|
}
|
|
141
121
|
}
|
|
142
122
|
|
|
123
|
+
get gristConfig() {
|
|
124
|
+
let columns = [
|
|
125
|
+
{ type: 'gutter', gutterName: 'sequence' },
|
|
126
|
+
{
|
|
127
|
+
type: 'gutter',
|
|
128
|
+
gutterName: 'button',
|
|
129
|
+
icon: 'reorder',
|
|
130
|
+
handlers: {
|
|
131
|
+
click: (columns, data, column, record, rowIndex, _orderNo) => {
|
|
132
|
+
this._openReplenishmentPutawayInventoriesPopup(this._replenishmentId, record.cartonId)
|
|
133
|
+
}
|
|
134
|
+
},
|
|
135
|
+
exclude: this.refOrderType != AVAIL_ORDER_TYPES.REPLENISHMENT.value
|
|
136
|
+
},
|
|
137
|
+
{
|
|
138
|
+
type: 'boolean',
|
|
139
|
+
name: 'completed',
|
|
140
|
+
header: i18next.t('field.completed'),
|
|
141
|
+
width: 40
|
|
142
|
+
},
|
|
143
|
+
{
|
|
144
|
+
type: 'string',
|
|
145
|
+
name: 'palletId',
|
|
146
|
+
header: i18next.t('field.lot_id'),
|
|
147
|
+
width: 140
|
|
148
|
+
},
|
|
149
|
+
{
|
|
150
|
+
type: 'string',
|
|
151
|
+
name: 'cartonId',
|
|
152
|
+
header: i18next.t('field.carton_id'),
|
|
153
|
+
width: 140
|
|
154
|
+
},
|
|
155
|
+
{
|
|
156
|
+
type: 'string',
|
|
157
|
+
name: 'sku',
|
|
158
|
+
label: true,
|
|
159
|
+
header: i18next.t('field.sku'),
|
|
160
|
+
width: 120
|
|
161
|
+
},
|
|
162
|
+
{
|
|
163
|
+
type: 'object',
|
|
164
|
+
name: 'product',
|
|
165
|
+
header: i18next.t('field.product'),
|
|
166
|
+
width: 140
|
|
167
|
+
},
|
|
168
|
+
{
|
|
169
|
+
type: 'string',
|
|
170
|
+
name: 'batchId',
|
|
171
|
+
header: i18next.t('field.batch_id'),
|
|
172
|
+
width: 140
|
|
173
|
+
},
|
|
174
|
+
{
|
|
175
|
+
type: 'string',
|
|
176
|
+
name: 'packingType',
|
|
177
|
+
header: i18next.t('field.packing_type'),
|
|
178
|
+
width: 140
|
|
179
|
+
},
|
|
180
|
+
{
|
|
181
|
+
type: 'string',
|
|
182
|
+
name: 'packingSize',
|
|
183
|
+
header: i18next.t('field.packing_size'),
|
|
184
|
+
width: 140
|
|
185
|
+
},
|
|
186
|
+
{
|
|
187
|
+
type: 'date',
|
|
188
|
+
name: 'expirationDate',
|
|
189
|
+
header: i18next.t('field.exp_date'),
|
|
190
|
+
width: 140
|
|
191
|
+
},
|
|
192
|
+
{
|
|
193
|
+
type: 'integer',
|
|
194
|
+
name: 'qty',
|
|
195
|
+
header: i18next.t('field.qty'),
|
|
196
|
+
width: 80
|
|
197
|
+
},
|
|
198
|
+
{
|
|
199
|
+
type: 'object',
|
|
200
|
+
name: 'reusablePallet',
|
|
201
|
+
header: i18next.t('field.reusable_pallet'),
|
|
202
|
+
width: 140
|
|
203
|
+
},
|
|
204
|
+
{
|
|
205
|
+
type: 'object',
|
|
206
|
+
name: 'location',
|
|
207
|
+
header: i18next.t('field.location'),
|
|
208
|
+
width: 140
|
|
209
|
+
}
|
|
210
|
+
]
|
|
211
|
+
|
|
212
|
+
return {
|
|
213
|
+
rows: {
|
|
214
|
+
appendable: false,
|
|
215
|
+
handlers: {
|
|
216
|
+
click: async (columns, data, column, record, rowIndex) => {
|
|
217
|
+
if (data.records.length && record) {
|
|
218
|
+
if (this._selectedOrderProduct && this._selectedOrderProduct.name === record) {
|
|
219
|
+
return
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
this._selectedOrderProduct = record
|
|
223
|
+
this._selectedTaskStatus = null
|
|
224
|
+
this._selectedTaskStatus = record.status
|
|
225
|
+
this.recommendLocationName = null
|
|
226
|
+
|
|
227
|
+
if (
|
|
228
|
+
!record.completed &&
|
|
229
|
+
this.refOrderType !== AVAIL_ORDER_TYPES.WAREHOUSE_RETURN.value &&
|
|
230
|
+
this.refOrderType !== AVAIL_ORDER_TYPES.REPLENISHMENT.value
|
|
231
|
+
) {
|
|
232
|
+
this.recommendLocationName = (await this._getLocationRecommendation(record.name)) || null
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
if (this._enableCartonLabel && record?.cartonId) this._focusOnCartonInput()
|
|
236
|
+
else this._focusOnPalletInput()
|
|
237
|
+
}
|
|
238
|
+
}
|
|
239
|
+
}
|
|
240
|
+
},
|
|
241
|
+
pagination: { infinite: true },
|
|
242
|
+
list: {
|
|
243
|
+
fields: ['completed', 'sku', 'product', 'palletId', 'cartonId', 'expirationDate', 'batchId', 'qty', 'location']
|
|
244
|
+
},
|
|
245
|
+
columns: columns.filter(itm => itm.exclude != true)
|
|
246
|
+
}
|
|
247
|
+
}
|
|
248
|
+
|
|
143
249
|
get cartonInput() {
|
|
144
250
|
return this.shadowRoot.querySelector('barcode-scanable-input[name=cartonId]')
|
|
145
251
|
}
|
|
@@ -405,124 +511,12 @@ class PutawayProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
405
511
|
...this._pageSettings,
|
|
406
512
|
cameraScanOnly: (await fetchSettingRule('camera-scan-only')) || false
|
|
407
513
|
}
|
|
408
|
-
|
|
409
|
-
this.config = {
|
|
410
|
-
rows: {
|
|
411
|
-
appendable: false,
|
|
412
|
-
handlers: {
|
|
413
|
-
click: async (columns, data, column, record, rowIndex) => {
|
|
414
|
-
if (data.records.length && record) {
|
|
415
|
-
if (this._selectedOrderProduct && this._selectedOrderProduct.name === record) {
|
|
416
|
-
return
|
|
417
|
-
}
|
|
418
|
-
|
|
419
|
-
this._selectedOrderProduct = record
|
|
420
|
-
this._selectedTaskStatus = null
|
|
421
|
-
this._selectedTaskStatus = record.status
|
|
422
|
-
this.recommendLocationName = null
|
|
423
|
-
|
|
424
|
-
if (
|
|
425
|
-
!record.completed &&
|
|
426
|
-
this.refOrderType !== AVAIL_ORDER_TYPES.WAREHOUSE_RETURN.value &&
|
|
427
|
-
this.refOrderType !== AVAIL_ORDER_TYPES.REPLENISHMENT.value
|
|
428
|
-
) {
|
|
429
|
-
this.recommendLocationName = (await this._getLocationRecommendation(record.name)) || null
|
|
430
|
-
}
|
|
431
|
-
|
|
432
|
-
if (this._enableCartonLabel && record?.cartonId) this._focusOnCartonInput()
|
|
433
|
-
else this._focusOnPalletInput()
|
|
434
|
-
}
|
|
435
|
-
}
|
|
436
|
-
}
|
|
437
|
-
},
|
|
438
|
-
pagination: { infinite: true },
|
|
439
|
-
list: { fields: ['completed', 'sku', 'product', 'palletId', 'cartonId', 'expirationDate', 'batchId', 'qty'] },
|
|
440
|
-
columns: [
|
|
441
|
-
{ type: 'gutter', gutterName: 'sequence' },
|
|
442
|
-
{
|
|
443
|
-
type: 'gutter',
|
|
444
|
-
gutterName: 'button',
|
|
445
|
-
icon: 'reorder',
|
|
446
|
-
handlers: {
|
|
447
|
-
click: (columns, data, column, record, rowIndex, _orderNo) => {
|
|
448
|
-
this.openReplenishmentPutawayInventoriesPopup(this._replenishmentId, record.cartonId)
|
|
449
|
-
}
|
|
450
|
-
}
|
|
451
|
-
},
|
|
452
|
-
{
|
|
453
|
-
type: 'boolean',
|
|
454
|
-
name: 'completed',
|
|
455
|
-
header: i18next.t('field.completed'),
|
|
456
|
-
width: 40
|
|
457
|
-
},
|
|
458
|
-
{
|
|
459
|
-
type: 'string',
|
|
460
|
-
name: 'palletId',
|
|
461
|
-
header: i18next.t('field.lot_id'),
|
|
462
|
-
width: 140
|
|
463
|
-
},
|
|
464
|
-
{
|
|
465
|
-
type: 'string',
|
|
466
|
-
name: 'cartonId',
|
|
467
|
-
header: i18next.t('field.carton_id'),
|
|
468
|
-
width: 140
|
|
469
|
-
},
|
|
470
|
-
{
|
|
471
|
-
type: 'string',
|
|
472
|
-
name: 'sku',
|
|
473
|
-
label: true,
|
|
474
|
-
header: i18next.t('field.sku'),
|
|
475
|
-
width: 120
|
|
476
|
-
},
|
|
477
|
-
{
|
|
478
|
-
type: 'object',
|
|
479
|
-
name: 'product',
|
|
480
|
-
header: i18next.t('field.product'),
|
|
481
|
-
width: 140
|
|
482
|
-
},
|
|
483
|
-
{
|
|
484
|
-
type: 'string',
|
|
485
|
-
name: 'batchId',
|
|
486
|
-
header: i18next.t('field.batch_id'),
|
|
487
|
-
width: 140
|
|
488
|
-
},
|
|
489
|
-
{
|
|
490
|
-
type: 'string',
|
|
491
|
-
name: 'packingType',
|
|
492
|
-
header: i18next.t('field.packing_type'),
|
|
493
|
-
width: 140
|
|
494
|
-
},
|
|
495
|
-
{
|
|
496
|
-
type: 'string',
|
|
497
|
-
name: 'packingSize',
|
|
498
|
-
header: i18next.t('field.packing_size'),
|
|
499
|
-
width: 140
|
|
500
|
-
},
|
|
501
|
-
{
|
|
502
|
-
type: 'date',
|
|
503
|
-
name: 'expirationDate',
|
|
504
|
-
header: i18next.t('field.exp_date'),
|
|
505
|
-
width: 140
|
|
506
|
-
},
|
|
507
|
-
{
|
|
508
|
-
type: 'integer',
|
|
509
|
-
name: 'qty',
|
|
510
|
-
header: i18next.t('field.qty'),
|
|
511
|
-
width: 80
|
|
512
|
-
},
|
|
513
|
-
{
|
|
514
|
-
type: 'object',
|
|
515
|
-
name: 'reusablePallet',
|
|
516
|
-
header: i18next.t('field.reusable_pallet'),
|
|
517
|
-
width: 140
|
|
518
|
-
}
|
|
519
|
-
]
|
|
520
|
-
}
|
|
521
514
|
}
|
|
522
515
|
|
|
523
516
|
pageUpdated() {
|
|
524
517
|
if (this.active) {
|
|
525
518
|
this._focusOnOrderNoField()
|
|
519
|
+
this.config = this.gristConfig
|
|
526
520
|
}
|
|
527
521
|
}
|
|
528
522
|
|
|
@@ -592,6 +586,7 @@ class PutawayProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
592
586
|
packingType
|
|
593
587
|
packingSize
|
|
594
588
|
location {
|
|
589
|
+
id
|
|
595
590
|
name
|
|
596
591
|
description
|
|
597
592
|
}
|
|
@@ -618,41 +613,39 @@ class PutawayProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
618
613
|
this._worksheetInfo = worksheetInfo
|
|
619
614
|
this._bizplaceName = worksheetInfo.bizplaceName
|
|
620
615
|
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
if (a.completed
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
}
|
|
616
|
+
let results = response.data.putawayWorksheet.worksheetDetailInfos
|
|
617
|
+
.map(record => {
|
|
618
|
+
let reusablePalletName = ''
|
|
619
|
+
if (record.reusablePallet) {
|
|
620
|
+
reusablePalletName = record.reusablePallet.name
|
|
621
|
+
}
|
|
622
|
+
return {
|
|
623
|
+
...record,
|
|
624
|
+
completed: record.status === WORKSHEET_STATUS.DONE.value,
|
|
625
|
+
packingTypeSize: `${record.packingType}(${record.packingSize})`,
|
|
626
|
+
reusablePalletName: reusablePalletName,
|
|
627
|
+
sku: record.product.sku,
|
|
628
|
+
minInboundShelfLife: record.product.minInboundShelfLife,
|
|
629
|
+
expirationDate: record.expirationDate
|
|
630
|
+
}
|
|
631
|
+
})
|
|
632
|
+
.sort((a, b) => {
|
|
633
|
+
if (a.completed !== b.completed) {
|
|
634
|
+
if (a.completed) return 1
|
|
635
|
+
if (b.completed) return -1
|
|
636
|
+
}
|
|
643
637
|
|
|
644
|
-
|
|
645
|
-
|
|
638
|
+
if (a.batchId > b.batchId) return 1
|
|
639
|
+
if (b.batchId < b.batchId) return -1
|
|
646
640
|
|
|
647
|
-
|
|
648
|
-
|
|
641
|
+
if (a.palletId > b.palletId) return 1
|
|
642
|
+
if (a.palletId < b.palletId) return -1
|
|
649
643
|
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
}
|
|
644
|
+
return 0
|
|
645
|
+
})
|
|
653
646
|
|
|
654
647
|
this._enableCartonLabel = await fetchSettingRule('enable-carton-label', partnerDomainId)
|
|
655
|
-
this._massageItemList(
|
|
648
|
+
this._massageItemList(results)
|
|
656
649
|
}
|
|
657
650
|
} else if (this.refOrderType === AVAIL_ORDER_TYPES.CUSTOMER_RETURN.value) {
|
|
658
651
|
const response = await client.query({
|
|
@@ -689,6 +682,7 @@ class PutawayProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
689
682
|
packingType
|
|
690
683
|
packingSize
|
|
691
684
|
location {
|
|
685
|
+
id
|
|
692
686
|
name
|
|
693
687
|
description
|
|
694
688
|
}
|
|
@@ -717,7 +711,8 @@ class PutawayProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
717
711
|
completed: record.status === WORKSHEET_STATUS.DONE.value,
|
|
718
712
|
sku: record.product.sku,
|
|
719
713
|
minInboundShelfLife: record.product.minInboundShelfLife,
|
|
720
|
-
expirationDate: record.expirationDate
|
|
714
|
+
expirationDate: record.expirationDate,
|
|
715
|
+
location: record.status === WORKSHEET_STATUS.DONE.value ? record.location : null
|
|
721
716
|
}
|
|
722
717
|
})
|
|
723
718
|
.sort((a, b) => {
|
|
@@ -773,6 +768,7 @@ class PutawayProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
773
768
|
packingType
|
|
774
769
|
packingSize
|
|
775
770
|
location {
|
|
771
|
+
id
|
|
776
772
|
name
|
|
777
773
|
description
|
|
778
774
|
}
|
|
@@ -794,7 +790,8 @@ class PutawayProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
794
790
|
return {
|
|
795
791
|
...record,
|
|
796
792
|
sku: record.product.sku,
|
|
797
|
-
completed: record.status === WORKSHEET_STATUS.DONE.value
|
|
793
|
+
completed: record.status === WORKSHEET_STATUS.DONE.value,
|
|
794
|
+
location: record.status === WORKSHEET_STATUS.DONE.value ? record.location : null
|
|
798
795
|
}
|
|
799
796
|
})
|
|
800
797
|
.sort((a, b) => {
|
|
@@ -851,6 +848,7 @@ class PutawayProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
851
848
|
packingType
|
|
852
849
|
packingSize
|
|
853
850
|
location {
|
|
851
|
+
id
|
|
854
852
|
name
|
|
855
853
|
description
|
|
856
854
|
}
|
|
@@ -887,7 +885,8 @@ class PutawayProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
887
885
|
sku: record.product.sku,
|
|
888
886
|
minInboundShelfLife: record.product.minInboundShelfLife,
|
|
889
887
|
expirationDate: record.expirationDate,
|
|
890
|
-
qty: record.actualPackQty + ' / ' + record.qty
|
|
888
|
+
qty: record.actualPackQty + ' / ' + record.qty,
|
|
889
|
+
location: record.status === WORKSHEET_STATUS.DONE.value ? record.location : null
|
|
891
890
|
}
|
|
892
891
|
})
|
|
893
892
|
.sort((a, b) => {
|
|
@@ -997,6 +996,7 @@ class PutawayProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
997
996
|
packingType
|
|
998
997
|
packingSize
|
|
999
998
|
location {
|
|
999
|
+
id
|
|
1000
1000
|
name
|
|
1001
1001
|
description
|
|
1002
1002
|
}
|
|
@@ -1237,7 +1237,7 @@ class PutawayProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
1237
1237
|
}
|
|
1238
1238
|
}
|
|
1239
1239
|
|
|
1240
|
-
|
|
1240
|
+
_openReplenishmentPutawayInventoriesPopup(replenishmentId, cartonId) {
|
|
1241
1241
|
openPopup(
|
|
1242
1242
|
html`
|
|
1243
1243
|
<putaway-replenishment-inventory-popup .replenishmentId="${replenishmentId}" .cartonId="${cartonId}">
|
|
@@ -1736,6 +1736,7 @@ class PutawayProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
1736
1736
|
orderTypeChangeHandler(e) {
|
|
1737
1737
|
this.refOrderType = e.currentTarget.value
|
|
1738
1738
|
this._clearView()
|
|
1739
|
+
this.config = this.gristConfig
|
|
1739
1740
|
this.orderNoInput.select()
|
|
1740
1741
|
}
|
|
1741
1742
|
|
|
@@ -1776,7 +1777,11 @@ class PutawayProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
1776
1777
|
this._selectedLocation = ''
|
|
1777
1778
|
}
|
|
1778
1779
|
|
|
1779
|
-
this.data = {
|
|
1780
|
+
this.data = {
|
|
1781
|
+
records: worksheetDetailInfos.map(itm => {
|
|
1782
|
+
return { ...itm, location: itm.status === WORKSHEET_STATUS.DONE.value ? itm.location : null }
|
|
1783
|
+
})
|
|
1784
|
+
}
|
|
1780
1785
|
|
|
1781
1786
|
this._completeHandler()
|
|
1782
1787
|
}
|
|
@@ -5,40 +5,21 @@ import '../print-airway-bill-popup'
|
|
|
5
5
|
import '../../../outbound/generate-worksheet-popup'
|
|
6
6
|
|
|
7
7
|
import gql from 'graphql-tag'
|
|
8
|
-
import {
|
|
9
|
-
css,
|
|
10
|
-
html
|
|
11
|
-
} from 'lit-element'
|
|
8
|
+
import { css, html } from 'lit-element'
|
|
12
9
|
import { connect } from 'pwa-helpers/connect-mixin'
|
|
13
10
|
|
|
14
11
|
import { GhostPrint } from '@operato/ghost-print'
|
|
15
12
|
import { DirectPrinter } from '@things-factory/barcode-base'
|
|
16
13
|
import { getCodeByName } from '@things-factory/code-base'
|
|
17
|
-
import {
|
|
18
|
-
i18next,
|
|
19
|
-
localize
|
|
20
|
-
} from '@things-factory/i18n-base'
|
|
14
|
+
import { i18next, localize } from '@things-factory/i18n-base'
|
|
21
15
|
import { openPopup } from '@things-factory/layout-base'
|
|
22
|
-
import {
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
PageView,
|
|
26
|
-
store
|
|
27
|
-
} from '@things-factory/shell'
|
|
28
|
-
import {
|
|
29
|
-
CommonButtonStyles,
|
|
30
|
-
ScrollbarStyles
|
|
31
|
-
} from '@things-factory/styles'
|
|
32
|
-
import {
|
|
33
|
-
isMobileDevice,
|
|
34
|
-
sleep
|
|
35
|
-
} from '@things-factory/utils'
|
|
16
|
+
import { client, navigate, PageView, store } from '@things-factory/shell'
|
|
17
|
+
import { CommonButtonStyles, ScrollbarStyles } from '@things-factory/styles'
|
|
18
|
+
import { isMobileDevice, sleep } from '@things-factory/utils'
|
|
36
19
|
|
|
37
20
|
import { fetchSettingRule } from '../../../../fetch-setting-value'
|
|
38
|
-
import {
|
|
39
|
-
|
|
40
|
-
ORDER_STATUS
|
|
41
|
-
} from '../../../constants'
|
|
21
|
+
import { INTENALIZED_AWB_SETTING_KEY, ORDER_STATUS } from '../../../constants'
|
|
22
|
+
import { error } from 'console'
|
|
42
23
|
|
|
43
24
|
const HEADER_JSON = {
|
|
44
25
|
'Content-Type': 'application/json',
|
|
@@ -244,7 +225,7 @@ class B2cOrderRequests extends connect(store)(localize(i18next)(PageView)) {
|
|
|
244
225
|
props: {
|
|
245
226
|
searchOper: 'gte'
|
|
246
227
|
},
|
|
247
|
-
options: [{ value: '' }, { name: 'Single Item', value: 1 }, { name: 'Multiple Item', value: 2 }]
|
|
228
|
+
options: [{ value: '' }, { name: 'Single Item', value: 1 }, { name: 'Multiple Item', value: 2 }]
|
|
248
229
|
},
|
|
249
230
|
{
|
|
250
231
|
label: i18next.t('field.product_info'),
|
|
@@ -259,7 +240,13 @@ class B2cOrderRequests extends connect(store)(localize(i18next)(PageView)) {
|
|
|
259
240
|
props: {
|
|
260
241
|
searchOper: 'eq'
|
|
261
242
|
},
|
|
262
|
-
options: [
|
|
243
|
+
options: [
|
|
244
|
+
{ value: '' },
|
|
245
|
+
{ name: 'Lazada', value: 'LZD' },
|
|
246
|
+
{ name: 'Shopee', value: 'SHP' },
|
|
247
|
+
{ name: 'Shopify', value: 'SPF' },
|
|
248
|
+
{ name: 'Tiktok', value: 'TTK' }
|
|
249
|
+
]
|
|
263
250
|
},
|
|
264
251
|
{
|
|
265
252
|
label: i18next.t('field.order_remark'),
|
|
@@ -321,6 +308,21 @@ class B2cOrderRequests extends connect(store)(localize(i18next)(PageView)) {
|
|
|
321
308
|
}
|
|
322
309
|
}
|
|
323
310
|
},
|
|
311
|
+
{
|
|
312
|
+
type: 'gutter',
|
|
313
|
+
gutterName: 'button',
|
|
314
|
+
icon: 'assignment_return',
|
|
315
|
+
handlers: {
|
|
316
|
+
click: (columns, data, column, record, rowIndex) => {
|
|
317
|
+
const { status, name } = record
|
|
318
|
+
if (status === ORDER_STATUS.DONE.value) {
|
|
319
|
+
navigate(`create_return_order?releaseOrderNo=${name}`)
|
|
320
|
+
} else {
|
|
321
|
+
this._showToast({ type: 'error', message: 'Only "DONE" order can create return order.' })
|
|
322
|
+
}
|
|
323
|
+
}
|
|
324
|
+
}
|
|
325
|
+
},
|
|
324
326
|
{
|
|
325
327
|
type: 'boolean',
|
|
326
328
|
name: 'orderRemark',
|
|
@@ -964,4 +966,4 @@ class B2cOrderRequests extends connect(store)(localize(i18next)(PageView)) {
|
|
|
964
966
|
}
|
|
965
967
|
}
|
|
966
968
|
|
|
967
|
-
window.customElements.define('b2c-order-requests', B2cOrderRequests)
|
|
969
|
+
window.customElements.define('b2c-order-requests', B2cOrderRequests)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@things-factory/operato-wms",
|
|
3
|
-
"version": "4.3.
|
|
3
|
+
"version": "4.3.418",
|
|
4
4
|
"main": "dist-server/index.js",
|
|
5
5
|
"browser": "client/index.js",
|
|
6
6
|
"things-factory": true,
|
|
@@ -117,5 +117,5 @@
|
|
|
117
117
|
"cypress-localstorage-commands": "^1.6.1",
|
|
118
118
|
"eslint-plugin-cypress": "^2.12.1"
|
|
119
119
|
},
|
|
120
|
-
"gitHead": "
|
|
120
|
+
"gitHead": "ea99e51797c94c66ac2ab700d2ab2de2a787ef39"
|
|
121
121
|
}
|