@things-factory/operato-wms 4.3.19 → 4.4.0-alpha.3
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/constants/index.js +0 -1
- package/client/pages/constants/setting.js +0 -1
- package/client/pages/inbound/pallet-label-popup.js +0 -6
- package/client/pages/inbound/putaway-product.js +1 -3
- package/client/pages/inbound/unload-product.js +11 -21
- package/client/pages/inventory/inventory-adjustment-approval.js +9 -24
- package/client/pages/inventory/inventory-adjustment.js +16 -121
- package/client/pages/master/product/product-list.js +1 -1
- package/client/pages/order/arrival-notice/arrival-notice-detail.js +2 -0
- package/client/pages/order/arrival-notice/receive-arrival-notice.js +2 -0
- package/client/pages/order/goods-received-note/customer-received-note.js +0 -3
- package/client/pages/order/goods-received-note/received-note-detail.js +0 -3
- package/client/pages/order/release-order/b2c/b2c-order-requests.js +30 -21
- package/client/pages/order/release-order/bulk-print-packing-list.js +0 -4
- package/client/pages/order/release-order/receive-release-order-request.js +2 -0
- package/client/pages/order/release-order/release-order-detail.js +26 -44
- package/client/pages/order/return-order/receive-return-order-requests.js +2 -0
- package/client/pages/order/transfer-order/receive-transfer-order-request.js +1 -1
- package/client/pages/order/transport-order/print-delivery-note.js +1 -0
- package/client/pages/order/transport-order/view-delivery-note.js +1 -1
- package/client/pages/order/vas-order/receive-vas-order.js +2 -0
- package/client/pages/outbound/inventory-assign-popup.js +2 -7
- package/client/pages/outbound/inventory-auto-assign-popup.js +1 -2
- package/client/pages/outbound/loading-product.js +11 -49
- package/client/pages/outbound/packing-product.js +6 -42
- package/client/pages/outbound/packing-worksheet-list.js +0 -15
- package/client/pages/outbound/picking-product.js +13 -153
- package/client/pages/outbound/single-outbound-worksheet.js +22 -10
- package/client/pages/outbound/sorting-product.js +15 -78
- package/client/pages/outbound/worksheet-batch-picking.js +2 -9
- package/client/pages/outbound/worksheet-packing.js +2 -7
- package/client/pages/outbound/worksheet-picking.js +2 -9
- package/client/pages/report/inventory-summary-report.js +0 -8
- package/client/pages/report/outbound-order-details-report.js +0 -18
- package/client/pages/vas/abstract-execute-vas.js +7 -12
- package/client/pages/vas/print-product-label.js +6 -15
- package/client/pages/vas/reverse-kitting/execute-reverse-kitting.js +1 -3
- package/client/pages/vas/reverse-kitting/popup-reverse-kitting-template.js +1 -3
- package/client/route.js +0 -12
- package/dist-server/entities/index.js +5 -0
- package/dist-server/entities/index.js.map +1 -0
- package/dist-server/graphql/index.js +5 -1
- package/dist-server/graphql/index.js.map +1 -1
- package/dist-server/graphql/resolvers/board-setting/board-settings.js +1 -2
- package/dist-server/graphql/resolvers/board-setting/board-settings.js.map +1 -1
- package/dist-server/graphql/resolvers/dashboard/inventory-expiry-monitor.js +6 -5
- package/dist-server/graphql/resolvers/dashboard/inventory-expiry-monitor.js.map +1 -1
- package/dist-server/graphql/resolvers/dashboard/outbound-order-by-status.js +22 -53
- package/dist-server/graphql/resolvers/dashboard/outbound-order-by-status.js.map +1 -1
- package/dist-server/graphql/resolvers/index.js +7 -4
- package/dist-server/graphql/resolvers/index.js.map +1 -1
- package/dist-server/graphql/resolvers/reports/outbound-order-details-report.js +1 -3
- package/dist-server/graphql/resolvers/reports/outbound-order-details-report.js.map +1 -1
- package/dist-server/graphql/types/dashboard/inventory-expiry-counter.js +3 -2
- package/dist-server/graphql/types/dashboard/inventory-expiry-counter.js.map +1 -1
- package/dist-server/graphql/types/index.js +8 -5
- package/dist-server/graphql/types/index.js.map +1 -1
- package/dist-server/graphql/types/reports/outbound-order-details-report.js +0 -2
- package/dist-server/graphql/types/reports/outbound-order-details-report.js.map +1 -1
- package/dist-server/index.js +5 -1
- package/dist-server/index.js.map +1 -1
- package/dist-server/opa-app-setting-constants.js +1 -2
- package/dist-server/opa-app-setting-constants.js.map +1 -1
- package/dist-server/utils/index.js +5 -1
- package/dist-server/utils/index.js.map +1 -1
- package/helps/release-note.ko.md +9 -11
- package/helps/release-note.md +9 -11
- package/helps/release-note.ms.md +9 -11
- package/helps/release-note.zh.md +9 -11
- package/package.json +51 -51
- package/server/entities/index.ts +3 -0
- package/server/graphql/resolvers/board-setting/board-settings.ts +2 -4
- package/server/graphql/resolvers/dashboard/inventory-expiry-monitor.ts +6 -5
- package/server/graphql/resolvers/dashboard/outbound-order-by-status.ts +22 -53
- package/server/graphql/resolvers/index.ts +2 -3
- package/server/graphql/resolvers/reports/outbound-order-details-report.ts +2 -6
- package/server/graphql/types/dashboard/inventory-expiry-counter.ts +3 -2
- package/server/graphql/types/index.ts +4 -4
- package/server/graphql/types/reports/outbound-order-details-report.ts +0 -2
- package/server/index.ts +1 -1
- package/server/opa-app-setting-constants.ts +0 -1
- package/things-factory.config.js +0 -13
- package/translations/en.json +8 -50
- package/translations/ko.json +1 -37
- package/translations/ms.json +1 -37
- package/translations/zh.json +1 -37
- package/client/constants/index.js +0 -1
- package/client/constants/order.js +0 -14
- package/client/pages/constants/tote.js +0 -14
- package/client/pages/master/tote-list.js +0 -740
- package/client/pages/order/draft-release-good/draft-release-good-detail.js +0 -1163
- package/client/pages/order/draft-release-good/draft-release-good-list.js +0 -546
- package/client/pages/outbound/order-remark-popup.js +0 -112
- package/client/pages/outbound/tote-popup.js +0 -461
- package/dist-server/graphql/resolvers/warehouse-inventory-adjustment/index.js +0 -6
- package/dist-server/graphql/resolvers/warehouse-inventory-adjustment/index.js.map +0 -1
- package/dist-server/graphql/resolvers/warehouse-inventory-adjustment/warehouse-intentory-adjustment.js +0 -58
- package/dist-server/graphql/resolvers/warehouse-inventory-adjustment/warehouse-intentory-adjustment.js.map +0 -1
- package/dist-server/graphql/types/warehouse-inventory-adjustment/index.js +0 -9
- package/dist-server/graphql/types/warehouse-inventory-adjustment/index.js.map +0 -1
- package/server/graphql/resolvers/warehouse-inventory-adjustment/index.ts +0 -5
- package/server/graphql/resolvers/warehouse-inventory-adjustment/warehouse-intentory-adjustment.ts +0 -68
- package/server/graphql/types/warehouse-inventory-adjustment/index.ts +0 -5
|
@@ -6,4 +6,3 @@ export const PRODUCT_LABEL_SETTING_KEY = 'product-label'
|
|
|
6
6
|
export const REUSABLE_PALLET_LABEL_SETTING_KEY = 'reusable-pallet-label'
|
|
7
7
|
export const INTENALIZED_AWB_SETTING_KEY = 'internalized-awb-label'
|
|
8
8
|
export const ROUTE_LABEL_SETTING_KEY = 'route-label'
|
|
9
|
-
export const TOTE_LABEL_SETTING_KEY = 'tote-label'
|
|
@@ -154,9 +154,6 @@ class PalletLabelPopup extends connect(store)(localize(i18next)(LitElement)) {
|
|
|
154
154
|
packingType
|
|
155
155
|
palletId
|
|
156
156
|
remark
|
|
157
|
-
orderProductRemark
|
|
158
|
-
purchaseOrderNo
|
|
159
|
-
arrivalNoticeRefNo
|
|
160
157
|
}
|
|
161
158
|
}
|
|
162
159
|
`,
|
|
@@ -191,9 +188,6 @@ class PalletLabelPopup extends connect(store)(localize(i18next)(LitElement)) {
|
|
|
191
188
|
searchParams.append('remark', results[i].remark)
|
|
192
189
|
searchParams.append('batchRef', results[i].batchIdRef)
|
|
193
190
|
searchParams.append('expirationDate', '')
|
|
194
|
-
searchParams.append('orderProductRemark', results[i].orderProductRemark)
|
|
195
|
-
searchParams.append('purchaseOrderNo', results[i].purchaseOrderNo)
|
|
196
|
-
searchParams.append('refNo', results[i].arrivalNoticeRefNo)
|
|
197
191
|
try {
|
|
198
192
|
const response = await fetch(`label-command/${labelId}?${searchParams.toString()}`, {
|
|
199
193
|
method: 'GET'
|
|
@@ -9,7 +9,6 @@ import gql from 'graphql-tag'
|
|
|
9
9
|
import { css, html } from 'lit-element'
|
|
10
10
|
import { connect } from 'pwa-helpers/connect-mixin.js'
|
|
11
11
|
|
|
12
|
-
import { sleep } from '@operato/utils'
|
|
13
12
|
import { MultiColumnFormStyles } from '@things-factory/form-ui'
|
|
14
13
|
import { i18next, localize } from '@things-factory/i18n-base'
|
|
15
14
|
import { openPopup } from '@things-factory/layout-base'
|
|
@@ -1252,8 +1251,7 @@ class PutawayProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
1252
1251
|
)
|
|
1253
1252
|
}
|
|
1254
1253
|
|
|
1255
|
-
|
|
1256
|
-
await sleep(1010)
|
|
1254
|
+
_openUndoPopup() {
|
|
1257
1255
|
openPopup(
|
|
1258
1256
|
html`
|
|
1259
1257
|
<undo-putaway-popup
|
|
@@ -19,7 +19,7 @@ import { i18next, localize } from '@things-factory/i18n-base'
|
|
|
19
19
|
import { openPopup } from '@things-factory/layout-base'
|
|
20
20
|
import { client, CustomAlert, PageView, store } from '@things-factory/shell'
|
|
21
21
|
import { CommonButtonStyles } from '@things-factory/styles'
|
|
22
|
-
import { isMobileDevice
|
|
22
|
+
import { isMobileDevice } from '@things-factory/utils'
|
|
23
23
|
|
|
24
24
|
import { fetchSettingRule } from '../../fetch-setting-value'
|
|
25
25
|
import { ARRIVAL_NOTICE, RETURN_ORDER, VAS_TYPE } from '../constants'
|
|
@@ -372,7 +372,7 @@ class UnloadProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
372
372
|
this.productBarcodeInput.readOnly = false
|
|
373
373
|
this.productBarcodeInput.value = ''
|
|
374
374
|
}
|
|
375
|
-
if (
|
|
375
|
+
if (this.serialNumberInput) {
|
|
376
376
|
this.serialNumberInput.value = ''
|
|
377
377
|
}
|
|
378
378
|
this.cartonInput.value = ''
|
|
@@ -1090,14 +1090,10 @@ class UnloadProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
1090
1090
|
if (this._selectedOrderProduct && this._selectedOrderProduct.product.sku !== product.sku)
|
|
1091
1091
|
this._selectedOrderProduct = null
|
|
1092
1092
|
|
|
1093
|
-
if (!this._selectedOrderProduct) {
|
|
1094
|
-
|
|
1095
|
-
|
|
1096
|
-
|
|
1097
|
-
this._selectedOrderProduct = foundOrderProducts[0]
|
|
1098
|
-
} else if (foundOrderProducts?.length == 0 && foundParentProducts?.length > 0) {
|
|
1099
|
-
this._selectedOrderProduct = foundParentProducts[0]
|
|
1100
|
-
}
|
|
1093
|
+
if (foundOrderProducts?.length > 1 && !this._selectedOrderProduct) {
|
|
1094
|
+
this.selectOrderProduct(foundOrderProducts)
|
|
1095
|
+
} else {
|
|
1096
|
+
this._selectedOrderProduct = foundParentProducts[0]
|
|
1101
1097
|
}
|
|
1102
1098
|
}
|
|
1103
1099
|
} catch (e) {
|
|
@@ -1210,8 +1206,7 @@ class UnloadProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
1210
1206
|
}
|
|
1211
1207
|
}
|
|
1212
1208
|
|
|
1213
|
-
|
|
1214
|
-
await sleep(1010)
|
|
1209
|
+
_openIssueNote() {
|
|
1215
1210
|
openPopup(
|
|
1216
1211
|
html`
|
|
1217
1212
|
<popup-note
|
|
@@ -1412,8 +1407,7 @@ class UnloadProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
1412
1407
|
}
|
|
1413
1408
|
}
|
|
1414
1409
|
|
|
1415
|
-
|
|
1416
|
-
await sleep(1010)
|
|
1410
|
+
_openUndoUnloadPopup() {
|
|
1417
1411
|
openPopup(
|
|
1418
1412
|
html`
|
|
1419
1413
|
<undo-unload-popup
|
|
@@ -1449,9 +1443,7 @@ class UnloadProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
1449
1443
|
}
|
|
1450
1444
|
)
|
|
1451
1445
|
}
|
|
1452
|
-
|
|
1453
|
-
async _reusablePalletMode() {
|
|
1454
|
-
await sleep(1010)
|
|
1446
|
+
_reusablePalletMode() {
|
|
1455
1447
|
openPopup(
|
|
1456
1448
|
html`
|
|
1457
1449
|
<popup-reusable-pallet
|
|
@@ -1474,8 +1466,7 @@ class UnloadProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
1474
1466
|
)
|
|
1475
1467
|
}
|
|
1476
1468
|
|
|
1477
|
-
|
|
1478
|
-
await sleep(1010)
|
|
1469
|
+
_openSerialNumberList() {
|
|
1479
1470
|
openPopup(
|
|
1480
1471
|
html`
|
|
1481
1472
|
<serial-number-list-popup
|
|
@@ -1543,8 +1534,7 @@ class UnloadProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
1543
1534
|
})
|
|
1544
1535
|
}
|
|
1545
1536
|
|
|
1546
|
-
|
|
1547
|
-
await sleep(1010)
|
|
1537
|
+
_openVasPopup() {
|
|
1548
1538
|
openPopup(
|
|
1549
1539
|
html`
|
|
1550
1540
|
<palletizing-pallet-popup
|
|
@@ -8,7 +8,7 @@ import { connect } from 'pwa-helpers/connect-mixin'
|
|
|
8
8
|
|
|
9
9
|
import { getCodeByName } from '@things-factory/code-base'
|
|
10
10
|
import { i18next, localize } from '@things-factory/i18n-base'
|
|
11
|
-
import { client, PageView, store
|
|
11
|
+
import { client, PageView, store } from '@things-factory/shell'
|
|
12
12
|
import { CommonButtonStyles, ScrollbarStyles } from '@things-factory/styles'
|
|
13
13
|
import { isMobileDevice } from '@things-factory/utils'
|
|
14
14
|
import { openPopup } from '@things-factory/layout-base'
|
|
@@ -141,9 +141,7 @@ class InventoryAdjustmentApproval extends connect(store)(localize(i18next)(PageV
|
|
|
141
141
|
{ column: 'expirationDate', name: 'Exp. Date' },
|
|
142
142
|
{ column: 'manufactureDate', name: 'Mfg. Date' },
|
|
143
143
|
{ column: 'unitCost', name: 'Unit Cost' },
|
|
144
|
-
{ column: 'inventoryItemChange', name: 'Inventory Item Changes' }
|
|
145
|
-
{ column: 'status', name: 'Status' },
|
|
146
|
-
|
|
144
|
+
{ column: 'inventoryItemChange', name: 'Inventory Item Changes' }
|
|
147
145
|
]
|
|
148
146
|
|
|
149
147
|
this.config = {
|
|
@@ -196,17 +194,7 @@ class InventoryAdjustmentApproval extends connect(store)(localize(i18next)(PageV
|
|
|
196
194
|
} else {
|
|
197
195
|
this._compareColumn.map(item => {
|
|
198
196
|
let currentVal = compareData[item.column]?.name || compareData[item.column] || '[N/A]'
|
|
199
|
-
let updatedVal
|
|
200
|
-
|
|
201
|
-
if (item.column == 'status' && record.transactionType == 'MISSING') {
|
|
202
|
-
updatedVal = record.transactionType || '[N/A]'
|
|
203
|
-
}else if(item.column == 'status'){
|
|
204
|
-
updatedVal = '[N/A]'
|
|
205
|
-
}
|
|
206
|
-
|
|
207
|
-
if (item.column !== 'status') {
|
|
208
|
-
updatedVal = record[item.column]?.name || record[item.column] || '[N/A]'
|
|
209
|
-
}
|
|
197
|
+
let updatedVal = record[item.column]?.name || record[item.column] || '[N/A]'
|
|
210
198
|
|
|
211
199
|
recordDiff.push({
|
|
212
200
|
column: item.name,
|
|
@@ -416,7 +404,6 @@ class InventoryAdjustmentApproval extends connect(store)(localize(i18next)(PageV
|
|
|
416
404
|
batchIdRef
|
|
417
405
|
packingType
|
|
418
406
|
packingSize
|
|
419
|
-
status
|
|
420
407
|
bizplace {
|
|
421
408
|
id
|
|
422
409
|
name
|
|
@@ -445,7 +432,6 @@ class InventoryAdjustmentApproval extends connect(store)(localize(i18next)(PageV
|
|
|
445
432
|
packingType
|
|
446
433
|
packingSize
|
|
447
434
|
batchIdRef
|
|
448
|
-
status
|
|
449
435
|
bizplace {
|
|
450
436
|
id
|
|
451
437
|
name
|
|
@@ -562,8 +548,8 @@ class InventoryAdjustmentApproval extends connect(store)(localize(i18next)(PageV
|
|
|
562
548
|
if (patches && patches.length) {
|
|
563
549
|
const response = await client.mutate({
|
|
564
550
|
mutation: gql`
|
|
565
|
-
mutation
|
|
566
|
-
|
|
551
|
+
mutation approveInventoryChanges($patches: [InventoryChangePatch!]!) {
|
|
552
|
+
approveInventoryChanges(patches: $patches) {
|
|
567
553
|
items {
|
|
568
554
|
id
|
|
569
555
|
}
|
|
@@ -571,14 +557,13 @@ class InventoryAdjustmentApproval extends connect(store)(localize(i18next)(PageV
|
|
|
571
557
|
}
|
|
572
558
|
}
|
|
573
559
|
`,
|
|
574
|
-
variables: { patches }
|
|
575
|
-
context: gqlContext()
|
|
560
|
+
variables: { patches }
|
|
576
561
|
})
|
|
577
562
|
if (!response.errors) {
|
|
578
|
-
this._lockedPallet = response.data.
|
|
563
|
+
this._lockedPallet = response.data.approveInventoryChanges.items
|
|
579
564
|
this._showToast({
|
|
580
565
|
message:
|
|
581
|
-
response.data.
|
|
566
|
+
response.data.approveInventoryChanges.total > 0
|
|
582
567
|
? 'Highlighted pallet could not be approved due to ongoing process.'
|
|
583
568
|
: i18next.t('text.data_approved'),
|
|
584
569
|
option: 7000
|
|
@@ -692,4 +677,4 @@ class InventoryAdjustmentApproval extends connect(store)(localize(i18next)(PageV
|
|
|
692
677
|
}
|
|
693
678
|
}
|
|
694
679
|
|
|
695
|
-
window.customElements.define('inventory-adjustment-approval', InventoryAdjustmentApproval)
|
|
680
|
+
window.customElements.define('inventory-adjustment-approval', InventoryAdjustmentApproval)
|
|
@@ -13,7 +13,7 @@ import { DirectPrinter } from '@things-factory/barcode-base'
|
|
|
13
13
|
import { getCodeByName } from '@things-factory/code-base'
|
|
14
14
|
import { i18next, localize } from '@things-factory/i18n-base'
|
|
15
15
|
import { openPopup } from '@things-factory/layout-base'
|
|
16
|
-
import { client,
|
|
16
|
+
import { client, PageView, store } from '@things-factory/shell'
|
|
17
17
|
import { CommonButtonStyles, ScrollbarStyles } from '@things-factory/styles'
|
|
18
18
|
import { isMobileDevice } from '@things-factory/utils'
|
|
19
19
|
|
|
@@ -75,11 +75,6 @@ class InventoryAdjustment extends connect(store)(localize(i18next)(PageView)) {
|
|
|
75
75
|
action: this.printCartonLabel.bind(this),
|
|
76
76
|
...CommonButtonStyles.label
|
|
77
77
|
},
|
|
78
|
-
{
|
|
79
|
-
title: i18next.t('button.missing_stock'),
|
|
80
|
-
action: this.missingStock.bind(this),
|
|
81
|
-
...CommonButtonStyles.save
|
|
82
|
-
},
|
|
83
78
|
{
|
|
84
79
|
title: i18next.t('button.save'),
|
|
85
80
|
action: this.saveInventories.bind(this),
|
|
@@ -582,9 +577,6 @@ class InventoryAdjustment extends connect(store)(localize(i18next)(PageView)) {
|
|
|
582
577
|
expirationDate
|
|
583
578
|
unitCost
|
|
584
579
|
inventoryItemCount
|
|
585
|
-
purchaseOrderNo
|
|
586
|
-
orderProductRemark
|
|
587
|
-
arrivalNoticeRefNo
|
|
588
580
|
}
|
|
589
581
|
total
|
|
590
582
|
}
|
|
@@ -712,17 +704,15 @@ class InventoryAdjustment extends connect(store)(localize(i18next)(PageView)) {
|
|
|
712
704
|
const record = event.detail
|
|
713
705
|
const columnName = event.detail.column.name
|
|
714
706
|
|
|
715
|
-
if (
|
|
716
|
-
columnName === 'bizplace' &&
|
|
717
|
-
record.before?.bizplace?.id != record.after?.bizplace?.id &&
|
|
718
|
-
this.dataGrist._data.records[record.row].lockedQty <= 0
|
|
719
|
-
) {
|
|
707
|
+
if (columnName === 'bizplace' && record.before?.bizplace?.id != record.after?.bizplace?.id) {
|
|
720
708
|
delete this.dataGrist._data.records[event.detail.row].product
|
|
721
709
|
delete this.dataGrist._data.records[event.detail.row].sku
|
|
722
710
|
delete this.dataGrist._data.records[event.detail.row].brand
|
|
723
711
|
delete this.dataGrist._data.records[event.detail.row].packingType
|
|
724
712
|
delete this.dataGrist._data.records[event.detail.row].packingSize
|
|
725
713
|
delete this.dataGrist._data.records[event.detail.row].uom
|
|
714
|
+
delete this.dataGrist._data.records[event.detail.row].qty
|
|
715
|
+
delete this.dataGrist._data.records[event.detail.row].uomValue
|
|
726
716
|
}
|
|
727
717
|
}
|
|
728
718
|
|
|
@@ -731,26 +721,13 @@ class InventoryAdjustment extends connect(store)(localize(i18next)(PageView)) {
|
|
|
731
721
|
|
|
732
722
|
let item = e.target.localName == 'import-pop-up' ? popUpDataGrist : this.dataGrist
|
|
733
723
|
|
|
734
|
-
if (
|
|
735
|
-
item._data.records[e.detail.row].lockedQty > 0 &&
|
|
736
|
-
(e.detail.column.name == 'batchId' || e.detail.column.name == 'product' || e.detail.column.name == 'bizplace')
|
|
737
|
-
) {
|
|
738
|
-
this._showToast({ level: 'error', message: i18next.t('text.there_is_release_qty_no_amendment_is_allowed') })
|
|
739
|
-
item._data.records[e.detail.row][e.detail.column.name] = e.detail.before
|
|
740
|
-
return
|
|
741
|
-
}
|
|
742
|
-
|
|
743
724
|
switch (e.detail.column.name) {
|
|
744
725
|
case 'uomValue':
|
|
745
|
-
if (e.detail.after < 0
|
|
746
|
-
item._data.records[e.detail.row].uomValue = 0
|
|
747
|
-
this._showToast({ level: 'error', message: i18next.t('text.invalid_uom_value') })
|
|
748
|
-
}
|
|
726
|
+
if (e.detail.after < 0) item._data.records[e.detail.row].uomValue = 0
|
|
749
727
|
break
|
|
750
728
|
case 'qty':
|
|
751
|
-
if (e.detail.after < 0 || !Number.isInteger(e.detail.after))
|
|
752
|
-
|
|
753
|
-
}
|
|
729
|
+
if (e.detail.after < 0 || !Number.isInteger(e.detail.after))
|
|
730
|
+
item._data.records[e.detail.row].qty = e.detail.before
|
|
754
731
|
break
|
|
755
732
|
case 'unitCost':
|
|
756
733
|
if (e.detail.after < 0) item._data.records[e.detail.row].unitCost = e.detail.before
|
|
@@ -769,21 +746,6 @@ class InventoryAdjustment extends connect(store)(localize(i18next)(PageView)) {
|
|
|
769
746
|
|
|
770
747
|
item._data.records[e.detail.row].sku = e.detail.after?.sku ? e.detail.after.sku : ''
|
|
771
748
|
break
|
|
772
|
-
case 'bizplace':
|
|
773
|
-
item._data.records[e.detail.row].uom = ''
|
|
774
|
-
|
|
775
|
-
item._data.records[e.detail.row].packingType = ''
|
|
776
|
-
|
|
777
|
-
item._data.records[e.detail.row].packingSize = 1
|
|
778
|
-
|
|
779
|
-
item._data.records[e.detail.row].brand = ''
|
|
780
|
-
|
|
781
|
-
item._data.records[e.detail.row].sku = ''
|
|
782
|
-
|
|
783
|
-
item._data.records[e.detail.row].qty = e.detail.record.qty
|
|
784
|
-
|
|
785
|
-
item._data.records[e.detail.row].uomValue = e.detail.record.uomValue
|
|
786
|
-
break
|
|
787
749
|
default:
|
|
788
750
|
break
|
|
789
751
|
}
|
|
@@ -799,46 +761,6 @@ class InventoryAdjustment extends connect(store)(localize(i18next)(PageView)) {
|
|
|
799
761
|
}
|
|
800
762
|
}
|
|
801
763
|
|
|
802
|
-
async missingStock() {
|
|
803
|
-
const selectOrderInventory = this.dataGrist.selected
|
|
804
|
-
|
|
805
|
-
const patchesArr = [...selectOrderInventory]
|
|
806
|
-
|
|
807
|
-
const patches = patchesArr.map(p => {
|
|
808
|
-
return {
|
|
809
|
-
palletId: p.palletId,
|
|
810
|
-
transactionType: 'MISSING'
|
|
811
|
-
}
|
|
812
|
-
})
|
|
813
|
-
|
|
814
|
-
const result = await CustomAlert({
|
|
815
|
-
title: i18next.t('title.are_you_sure'),
|
|
816
|
-
text: i18next.t('text.do_you_want_to_mark_it_as_missing'),
|
|
817
|
-
confirmButton: { text: i18next.t('button.confirm') },
|
|
818
|
-
cancelButton: { text: i18next.t('button.cancel') }
|
|
819
|
-
})
|
|
820
|
-
|
|
821
|
-
if (result.isConfirmed) {
|
|
822
|
-
try {
|
|
823
|
-
const response = await client.mutate({
|
|
824
|
-
mutation: gql`
|
|
825
|
-
mutation submitInventoryChanges($patches: [InventoryPatch!]!) {
|
|
826
|
-
submitInventoryChanges(patches: $patches)
|
|
827
|
-
}
|
|
828
|
-
`,
|
|
829
|
-
variables: { patches }
|
|
830
|
-
})
|
|
831
|
-
|
|
832
|
-
if (!response.error) {
|
|
833
|
-
this._showToast({ message: i18next.t('text.data_inventory_adjustment_has_been_submitted_for_approval') })
|
|
834
|
-
this.updateContext()
|
|
835
|
-
}
|
|
836
|
-
} catch (error) {
|
|
837
|
-
throw new Error(error)
|
|
838
|
-
}
|
|
839
|
-
}
|
|
840
|
-
}
|
|
841
|
-
|
|
842
764
|
async saveInventories() {
|
|
843
765
|
try {
|
|
844
766
|
var patches = this.dataGrist.exportPatchList({ flagName: 'cuFlag' })
|
|
@@ -850,13 +772,6 @@ class InventoryAdjustment extends connect(store)(localize(i18next)(PageView)) {
|
|
|
850
772
|
throw new Error(i18next.t('text.empty_value_in_list'))
|
|
851
773
|
}
|
|
852
774
|
}
|
|
853
|
-
|
|
854
|
-
if (row.cuFlag == 'M' && row.bizplace) {
|
|
855
|
-
if (!row.product) {
|
|
856
|
-
throw new Error(i18next.t('text.empty_value_in_list'))
|
|
857
|
-
}
|
|
858
|
-
}
|
|
859
|
-
|
|
860
775
|
if (row.bizplace) {
|
|
861
776
|
row.bizplace = { id: row.bizplace.id }
|
|
862
777
|
}
|
|
@@ -878,34 +793,18 @@ class InventoryAdjustment extends connect(store)(localize(i18next)(PageView)) {
|
|
|
878
793
|
})
|
|
879
794
|
|
|
880
795
|
if (patches && patches.length) {
|
|
881
|
-
const
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
796
|
+
const response = await client.mutate({
|
|
797
|
+
mutation: gql`
|
|
798
|
+
mutation submitInventoryChanges($patches: [InventoryPatch!]!) {
|
|
799
|
+
submitInventoryChanges(patches: $patches)
|
|
885
800
|
}
|
|
886
801
|
`,
|
|
887
802
|
variables: { patches }
|
|
888
803
|
})
|
|
889
804
|
|
|
890
|
-
if (
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
mutation submitInventoryChanges($patches: [InventoryPatch!]!) {
|
|
894
|
-
submitInventoryChanges(patches: $patches)
|
|
895
|
-
}
|
|
896
|
-
`,
|
|
897
|
-
variables: { patches }
|
|
898
|
-
})
|
|
899
|
-
|
|
900
|
-
if (!response.errors) {
|
|
901
|
-
this.dataGrist.fetch()
|
|
902
|
-
this._showToast({ message: i18next.t('text.data_inventory_adjustment_has_been_submitted_for_approval') })
|
|
903
|
-
}
|
|
904
|
-
} else {
|
|
905
|
-
this._showToast({
|
|
906
|
-
type: 'error',
|
|
907
|
-
message: `${i18next.t('text.complete_the_picking_process_before_adjust_the_batch_number')}`
|
|
908
|
-
})
|
|
805
|
+
if (!response.errors) {
|
|
806
|
+
this.dataGrist.fetch()
|
|
807
|
+
this._showToast({ message: i18next.t('text.data_submitted_for_approval') })
|
|
909
808
|
}
|
|
910
809
|
}
|
|
911
810
|
} catch (e) {
|
|
@@ -994,7 +893,7 @@ class InventoryAdjustment extends connect(store)(localize(i18next)(PageView)) {
|
|
|
994
893
|
if (!response.errors) {
|
|
995
894
|
history.back()
|
|
996
895
|
this.dataGrist.fetch()
|
|
997
|
-
this._showToast({ message: i18next.t('text.
|
|
896
|
+
this._showToast({ message: i18next.t('text.data_submitted_for_approval') })
|
|
998
897
|
}
|
|
999
898
|
} catch (e) {
|
|
1000
899
|
this._showToast(e)
|
|
@@ -1327,9 +1226,6 @@ class InventoryAdjustment extends connect(store)(localize(i18next)(PageView)) {
|
|
|
1327
1226
|
searchParams.append('remark', record.remark)
|
|
1328
1227
|
searchParams.append('batchRef', record.batchIdRef)
|
|
1329
1228
|
searchParams.append('expirationDate', record.expirationDate)
|
|
1330
|
-
searchParams.append('purchaseOrderNo', record.purchaseOrderNo)
|
|
1331
|
-
searchParams.append('orderProductRemark', record.orderProductRemark)
|
|
1332
|
-
searchParams.append('refNo', record.arrivalNoticeRefNo)
|
|
1333
1229
|
|
|
1334
1230
|
try {
|
|
1335
1231
|
const response = await fetch(`label-command/${labelId}?${searchParams.toString()}`, {
|
|
@@ -1431,11 +1327,10 @@ class InventoryAdjustment extends connect(store)(localize(i18next)(PageView)) {
|
|
|
1431
1327
|
}
|
|
1432
1328
|
}
|
|
1433
1329
|
|
|
1434
|
-
_showToast({
|
|
1330
|
+
_showToast({ type, message }) {
|
|
1435
1331
|
document.dispatchEvent(
|
|
1436
1332
|
new CustomEvent('notify', {
|
|
1437
1333
|
detail: {
|
|
1438
|
-
level,
|
|
1439
1334
|
type,
|
|
1440
1335
|
message
|
|
1441
1336
|
}
|
|
@@ -653,7 +653,7 @@ class ProductList extends localize(i18next)(PageView) {
|
|
|
653
653
|
|
|
654
654
|
const response = await client.query({
|
|
655
655
|
query: gql`
|
|
656
|
-
query productsByBizplace($filters: [Filter
|
|
656
|
+
query productsByBizplace($filters: [Filter], $pagination: Pagination, $sortings: [Sorting]) {
|
|
657
657
|
productsByBizplace(filters: $filters, pagination: $pagination, sortings: $sortings) {
|
|
658
658
|
items {
|
|
659
659
|
sku
|
|
@@ -90,9 +90,6 @@ class CustomerReceivedNote extends localize(i18next)(PageView) {
|
|
|
90
90
|
case 'seebuu-warehouse':
|
|
91
91
|
this.shadowRoot.querySelector('#container').src = `/view_seebuu_grn/${this._grnNo}`
|
|
92
92
|
break
|
|
93
|
-
case 'freight-mark-warehouse':
|
|
94
|
-
this.shadowRoot.querySelector('#container').src = `/view_fm_grn/${this._grnNo}/${timezoneOffSet}`
|
|
95
|
-
break
|
|
96
93
|
case 'kimeda-warehouse':
|
|
97
94
|
this.shadowRoot.querySelector('#container').src = `/view_kimeda_grn/${this._grnNo}/${timezoneOffSet}`
|
|
98
95
|
break
|
|
@@ -92,9 +92,6 @@ class ReceivedNoteDetail extends localize(i18next)(PageView) {
|
|
|
92
92
|
case 'seebuu-warehouse':
|
|
93
93
|
this.shadowRoot.querySelector('#container').src = `/view_seebuu_grn/${this._grnNo}`
|
|
94
94
|
break
|
|
95
|
-
case 'freight-mark-warehouse':
|
|
96
|
-
this.shadowRoot.querySelector('#container').src = `/view_fm_grn/${this._grnNo}/${timezoneOffSet}`
|
|
97
|
-
break
|
|
98
95
|
case 'kimeda-warehouse':
|
|
99
96
|
this.shadowRoot.querySelector('#container').src = `/view_kimeda_grn/${this._grnNo}/${timezoneOffSet}`
|
|
100
97
|
break
|
|
@@ -3,20 +3,38 @@ import '@things-factory/grist-ui'
|
|
|
3
3
|
import '../batch-picking-popup'
|
|
4
4
|
|
|
5
5
|
import gql from 'graphql-tag'
|
|
6
|
-
import {
|
|
6
|
+
import {
|
|
7
|
+
css,
|
|
8
|
+
html
|
|
9
|
+
} from 'lit-element'
|
|
7
10
|
import { connect } from 'pwa-helpers/connect-mixin'
|
|
8
11
|
|
|
9
12
|
import { GhostPrint } from '@operato/ghost-print'
|
|
10
13
|
import { DirectPrinter } from '@things-factory/barcode-base'
|
|
11
14
|
import { getCodeByName } from '@things-factory/code-base'
|
|
12
|
-
import {
|
|
15
|
+
import {
|
|
16
|
+
i18next,
|
|
17
|
+
localize
|
|
18
|
+
} from '@things-factory/i18n-base'
|
|
13
19
|
import { openPopup } from '@things-factory/layout-base'
|
|
14
|
-
import {
|
|
15
|
-
|
|
20
|
+
import {
|
|
21
|
+
client,
|
|
22
|
+
CustomAlert,
|
|
23
|
+
navigate,
|
|
24
|
+
PageView,
|
|
25
|
+
store
|
|
26
|
+
} from '@things-factory/shell'
|
|
27
|
+
import {
|
|
28
|
+
CommonButtonStyles,
|
|
29
|
+
ScrollbarStyles
|
|
30
|
+
} from '@things-factory/styles'
|
|
16
31
|
import { isMobileDevice } from '@things-factory/utils'
|
|
17
32
|
|
|
18
33
|
import { fetchSettingRule } from '../../../../fetch-setting-value'
|
|
19
|
-
import {
|
|
34
|
+
import {
|
|
35
|
+
INTENALIZED_AWB_SETTING_KEY,
|
|
36
|
+
ORDER_STATUS
|
|
37
|
+
} from '../../../constants'
|
|
20
38
|
|
|
21
39
|
const HEADER_JSON = {
|
|
22
40
|
'Content-Type': 'application/json',
|
|
@@ -242,13 +260,6 @@ class B2cOrderRequests extends connect(store)(localize(i18next)(PageView)) {
|
|
|
242
260
|
name: 'sku',
|
|
243
261
|
type: 'text',
|
|
244
262
|
props: { searchOper: 'i_like' }
|
|
245
|
-
},
|
|
246
|
-
{
|
|
247
|
-
label: i18next.t('field.order_remark'),
|
|
248
|
-
name: 'orderRemark',
|
|
249
|
-
type: 'checkbox',
|
|
250
|
-
props: { searchOper: 'eq' },
|
|
251
|
-
attrs: ['indeterminate']
|
|
252
263
|
}
|
|
253
264
|
]
|
|
254
265
|
|
|
@@ -292,14 +303,6 @@ class B2cOrderRequests extends connect(store)(localize(i18next)(PageView)) {
|
|
|
292
303
|
}
|
|
293
304
|
}
|
|
294
305
|
},
|
|
295
|
-
{
|
|
296
|
-
type: 'boolean',
|
|
297
|
-
name: 'orderRemark',
|
|
298
|
-
header: i18next.t('field.order_remark'),
|
|
299
|
-
imex: { header: i18next.t('field.order_remark'), key: 'orderRemark', width: 20, type: 'string' },
|
|
300
|
-
sortable: true,
|
|
301
|
-
width: 100
|
|
302
|
-
},
|
|
303
306
|
{
|
|
304
307
|
type: 'string',
|
|
305
308
|
name: 'name',
|
|
@@ -362,6 +365,13 @@ class B2cOrderRequests extends connect(store)(localize(i18next)(PageView)) {
|
|
|
362
365
|
sortable: true,
|
|
363
366
|
width: 120
|
|
364
367
|
},
|
|
368
|
+
// {
|
|
369
|
+
// type: 'string',
|
|
370
|
+
// name: 'marketplaceOrderStatus',
|
|
371
|
+
// header: i18next.t('field.marketplace_order_status'),
|
|
372
|
+
// sortable: true,
|
|
373
|
+
// width: 120
|
|
374
|
+
// },
|
|
365
375
|
{
|
|
366
376
|
type: 'string',
|
|
367
377
|
name: 'status',
|
|
@@ -431,7 +441,6 @@ class B2cOrderRequests extends connect(store)(localize(i18next)(PageView)) {
|
|
|
431
441
|
postalCode
|
|
432
442
|
marketplaceOrderStatus
|
|
433
443
|
transporter
|
|
434
|
-
orderRemark
|
|
435
444
|
bizplace {
|
|
436
445
|
id
|
|
437
446
|
name
|
|
@@ -168,9 +168,6 @@ class BulkPrintPackingList extends localize(i18next)(PageView) {
|
|
|
168
168
|
rows="5"
|
|
169
169
|
readonly
|
|
170
170
|
></textarea>
|
|
171
|
-
|
|
172
|
-
<label>${i18next.t('label.order_remark')}</label>
|
|
173
|
-
<textarea rows="5" readonly></textarea>
|
|
174
171
|
</fieldset>
|
|
175
172
|
</form>
|
|
176
173
|
|
|
@@ -268,7 +265,6 @@ class BulkPrintPackingList extends localize(i18next)(PageView) {
|
|
|
268
265
|
attentionTo
|
|
269
266
|
phone1
|
|
270
267
|
deliveryAddress1
|
|
271
|
-
remark
|
|
272
268
|
bizplace {
|
|
273
269
|
id
|
|
274
270
|
name
|