@things-factory/operato-wms 4.3.700 → 4.3.701
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.
|
@@ -17,7 +17,6 @@ class SelectInventoryPopUp extends localize(i18next)(LitElement) {
|
|
|
17
17
|
productConfig: Object,
|
|
18
18
|
data: Object,
|
|
19
19
|
bizplaceId: String,
|
|
20
|
-
releaseShelfLifeOverride: Number,
|
|
21
20
|
searchFields: Array,
|
|
22
21
|
selectMultipleProducts: Boolean,
|
|
23
22
|
switchTypePane: String,
|
|
@@ -428,13 +427,10 @@ class SelectInventoryPopUp extends localize(i18next)(LitElement) {
|
|
|
428
427
|
}
|
|
429
428
|
|
|
430
429
|
if (paneType === 'product') {
|
|
431
|
-
const data = this.
|
|
432
|
-
const filtered = Array.isArray(data)
|
|
433
|
-
? data.filter(res => res && res.batchId !== null)
|
|
434
|
-
: this.inventoryData.filter(res => res && res.batchId !== null)
|
|
430
|
+
const data = this.inventoryData.filter(res => res.batchId !== null)
|
|
435
431
|
|
|
436
|
-
if (
|
|
437
|
-
const remapData =
|
|
432
|
+
if (data?.length > 0) {
|
|
433
|
+
const remapData = data.map(res => {
|
|
438
434
|
return {
|
|
439
435
|
batchId: res.batchId,
|
|
440
436
|
groupType: res.groupType,
|
|
@@ -447,10 +443,6 @@ class SelectInventoryPopUp extends localize(i18next)(LitElement) {
|
|
|
447
443
|
})
|
|
448
444
|
filters.push({ name: 'batch_product', operator: 'notin', value: remapData })
|
|
449
445
|
}
|
|
450
|
-
// ensure release shelf-life override is passed for product selection as well
|
|
451
|
-
if (typeof this.releaseShelfLifeOverride !== 'undefined' && this.releaseShelfLifeOverride !== null) {
|
|
452
|
-
filters.push({ name: 'releaseShelfLifeOverride', operator: 'eq', value: Number(this.releaseShelfLifeOverride) })
|
|
453
|
-
}
|
|
454
446
|
|
|
455
447
|
const response = await client.query({
|
|
456
448
|
query: gql`
|
|
@@ -488,13 +480,6 @@ class SelectInventoryPopUp extends localize(i18next)(LitElement) {
|
|
|
488
480
|
}
|
|
489
481
|
}
|
|
490
482
|
} else {
|
|
491
|
-
if (typeof this.releaseShelfLifeOverride !== 'undefined' && this.releaseShelfLifeOverride !== null) {
|
|
492
|
-
filters.push({
|
|
493
|
-
name: 'releaseShelfLifeOverride',
|
|
494
|
-
operator: 'eq',
|
|
495
|
-
value: Number(this.releaseShelfLifeOverride)
|
|
496
|
-
})
|
|
497
|
-
}
|
|
498
483
|
filters.push({ name: 'status', operator: 'eq', value: INVENTORY_STATUS.STORED.value })
|
|
499
484
|
|
|
500
485
|
const data = this.inventoryData
|
|
@@ -580,7 +565,7 @@ class SelectInventoryPopUp extends localize(i18next)(LitElement) {
|
|
|
580
565
|
packingSize: selectedProduct.packingSize,
|
|
581
566
|
primaryUnit: selectedProduct.uom,
|
|
582
567
|
primaryValue: selectedProduct.uomValue,
|
|
583
|
-
isInventoryDecimal: selectedProduct.isInventoryDecimal
|
|
568
|
+
isInventoryDecimal: selectedProduct.isInventoryDecimal,
|
|
584
569
|
},
|
|
585
570
|
productDetail: {
|
|
586
571
|
id: selectedProduct.productDetailId
|
|
@@ -117,7 +117,6 @@ class CreateReleaseOrder extends localize(i18next)(PageView) {
|
|
|
117
117
|
|
|
118
118
|
// refractor
|
|
119
119
|
_contactPointInfo: Object,
|
|
120
|
-
_releaseShelfLifeOverride: Number,
|
|
121
120
|
|
|
122
121
|
/* Tab Toggle*/
|
|
123
122
|
_showReleasedOrderInfo: Boolean,
|
|
@@ -1434,7 +1433,6 @@ class CreateReleaseOrder extends localize(i18next)(PageView) {
|
|
|
1434
1433
|
this.refNo = ''
|
|
1435
1434
|
this.refNo2 = ''
|
|
1436
1435
|
this.refNo3 = ''
|
|
1437
|
-
this._releaseShelfLifeOverride = null
|
|
1438
1436
|
this.releaseDate = ''
|
|
1439
1437
|
this.collectionOrderNo = ''
|
|
1440
1438
|
this._files = []
|
|
@@ -2457,10 +2455,6 @@ class CreateReleaseOrder extends localize(i18next)(PageView) {
|
|
|
2457
2455
|
releaseGood.vas = undefined
|
|
2458
2456
|
releaseGood.orderInventories = await this._getOrderInventories()
|
|
2459
2457
|
// releaseGood.orderVass = this._getOrderVass()
|
|
2460
|
-
// attach selected ContactPoint as relation if present (GraphQL expects a string ID)
|
|
2461
|
-
if (this._contactPointId) {
|
|
2462
|
-
releaseGood.deliverTo = this._contactPointId
|
|
2463
|
-
}
|
|
2464
2458
|
releaseGood.ownTransport = this._ownTransport
|
|
2465
2459
|
releaseGood.type = RO_TYPES.B2B.value
|
|
2466
2460
|
releaseGood.orderMethod = this._pickingStd
|
|
@@ -2548,55 +2542,6 @@ class CreateReleaseOrder extends localize(i18next)(PageView) {
|
|
|
2548
2542
|
...this.inventoryData,
|
|
2549
2543
|
records: data
|
|
2550
2544
|
}
|
|
2551
|
-
return
|
|
2552
|
-
}
|
|
2553
|
-
const insufficientError = response.errors.find(err => err?.extensions?.exception?.errorCode == 'ins1')
|
|
2554
|
-
if (insufficientError) {
|
|
2555
|
-
let failed = []
|
|
2556
|
-
try {
|
|
2557
|
-
failed = JSON.parse(insufficientError?.extensions?.exception?.detail?.data || '[]')
|
|
2558
|
-
} catch (e) {
|
|
2559
|
-
// ignore parse error
|
|
2560
|
-
}
|
|
2561
|
-
const data = this.inventoryData.records
|
|
2562
|
-
const skus = []
|
|
2563
|
-
failed.forEach(dt => {
|
|
2564
|
-
if (dt?.productSku) {
|
|
2565
|
-
skus.push(dt.batchId ? `${dt.productSku} (${dt.batchId})` : `${dt.productSku}`)
|
|
2566
|
-
return
|
|
2567
|
-
}
|
|
2568
|
-
const idx = data.findIndex(
|
|
2569
|
-
x =>
|
|
2570
|
-
x.productId == dt.productId &&
|
|
2571
|
-
(x.batchId || '') == (dt.batchId || '') &&
|
|
2572
|
-
x.packingType == dt.packingType
|
|
2573
|
-
)
|
|
2574
|
-
if (idx >= 0) {
|
|
2575
|
-
const rec = data[idx]
|
|
2576
|
-
rec.isError = true
|
|
2577
|
-
const sku =
|
|
2578
|
-
rec.productSKU ||
|
|
2579
|
-
(rec.inventory ? rec.inventory.productSKU : undefined) ||
|
|
2580
|
-
(rec.product ? rec.product.sku : undefined) ||
|
|
2581
|
-
rec.sku
|
|
2582
|
-
if (sku) {
|
|
2583
|
-
skus.push(dt.batchId ? `${sku} (${dt.batchId})` : `${sku}`)
|
|
2584
|
-
} else {
|
|
2585
|
-
skus.push(dt.productId)
|
|
2586
|
-
}
|
|
2587
|
-
} else {
|
|
2588
|
-
// fallback if record not found in grid
|
|
2589
|
-
skus.push(dt.productId)
|
|
2590
|
-
}
|
|
2591
|
-
})
|
|
2592
|
-
this.inventoryData = { ...this.inventoryData, records: [...data] }
|
|
2593
|
-
const uniqueSkus = [...new Set(skus)]
|
|
2594
|
-
const msg =
|
|
2595
|
-
uniqueSkus.length > 0
|
|
2596
|
-
? `Insufficient stock for: ${uniqueSkus.join(', ')}`
|
|
2597
|
-
: i18next.t('text.insufficient_stock')
|
|
2598
|
-
this._showToast({ type: 'error', message: msg })
|
|
2599
|
-
return
|
|
2600
2545
|
}
|
|
2601
2546
|
}
|
|
2602
2547
|
} catch (e) {
|
|
@@ -2855,9 +2800,6 @@ class CreateReleaseOrder extends localize(i18next)(PageView) {
|
|
|
2855
2800
|
.switchTypePane="${type}"
|
|
2856
2801
|
.inventoryData="${this.inventoryGrist.dirtyData.records}"
|
|
2857
2802
|
.recall="${this._recallInput.checked}"
|
|
2858
|
-
.releaseShelfLifeOverride="${this._releaseShelfLifeOverride != null
|
|
2859
|
-
? Number(this._releaseShelfLifeOverride)
|
|
2860
|
-
: null}"
|
|
2861
2803
|
@selected="${e => {
|
|
2862
2804
|
let newRecords = []
|
|
2863
2805
|
for (let i = 0; i < e.detail.multipleProducts.length; i++) {
|
|
@@ -3705,12 +3647,6 @@ class CreateReleaseOrder extends localize(i18next)(PageView) {
|
|
|
3705
3647
|
<contact-points-popup
|
|
3706
3648
|
@selected="${e => {
|
|
3707
3649
|
this._fillUpDeliveryInfo(e.detail)
|
|
3708
|
-
this._contactPointInfo = e.detail || {}
|
|
3709
|
-
this._contactPointId = e.detail?.id || ''
|
|
3710
|
-
this._releaseShelfLifeOverride =
|
|
3711
|
-
e.detail && e.detail.releaseShelfLife != null && e.detail.releaseShelfLife !== 0
|
|
3712
|
-
? Number(e.detail.releaseShelfLife)
|
|
3713
|
-
: null
|
|
3714
3650
|
}}"
|
|
3715
3651
|
.partnerBizplaceIds="${this._bizplaces.map(itm => itm.id)}"
|
|
3716
3652
|
></contact-points-popup>
|
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.701",
|
|
4
4
|
"main": "dist-server/index.js",
|
|
5
5
|
"browser": "client/index.js",
|
|
6
6
|
"things-factory": true,
|
|
@@ -66,7 +66,7 @@
|
|
|
66
66
|
"@things-factory/attachment-ui": "^4.3.695",
|
|
67
67
|
"@things-factory/auth-ui": "^4.3.695",
|
|
68
68
|
"@things-factory/barcode-ui": "^4.3.695",
|
|
69
|
-
"@things-factory/biz-ui": "^4.3.
|
|
69
|
+
"@things-factory/biz-ui": "^4.3.701",
|
|
70
70
|
"@things-factory/board-service": "^4.3.695",
|
|
71
71
|
"@things-factory/board-ui": "^4.3.695",
|
|
72
72
|
"@things-factory/code-ui": "^4.3.695",
|
|
@@ -82,16 +82,16 @@
|
|
|
82
82
|
"@things-factory/i18n-base": "^4.3.695",
|
|
83
83
|
"@things-factory/id-rule-base": "^4.3.695",
|
|
84
84
|
"@things-factory/import-ui": "^4.3.695",
|
|
85
|
-
"@things-factory/import-ui-excel": "^4.3.
|
|
85
|
+
"@things-factory/import-ui-excel": "^4.3.701",
|
|
86
86
|
"@things-factory/menu-ui": "^4.3.695",
|
|
87
87
|
"@things-factory/more-ui": "^4.3.695",
|
|
88
88
|
"@things-factory/notification": "^4.3.695",
|
|
89
89
|
"@things-factory/pdf": "^4.3.591",
|
|
90
90
|
"@things-factory/print-proxy-service": "^4.3.695",
|
|
91
91
|
"@things-factory/print-ui": "^4.3.695",
|
|
92
|
-
"@things-factory/product-base": "^4.3.
|
|
92
|
+
"@things-factory/product-base": "^4.3.701",
|
|
93
93
|
"@things-factory/resource-ui": "^4.3.695",
|
|
94
|
-
"@things-factory/sales-ui": "^4.3.
|
|
94
|
+
"@things-factory/sales-ui": "^4.3.701",
|
|
95
95
|
"@things-factory/scene-data-transform": "^4.3.591",
|
|
96
96
|
"@things-factory/scene-excel": "^4.3.591",
|
|
97
97
|
"@things-factory/scene-firebase": "^4.3.591",
|
|
@@ -105,10 +105,10 @@
|
|
|
105
105
|
"@things-factory/scene-visualizer": "^4.3.591",
|
|
106
106
|
"@things-factory/setting-ui": "^4.3.695",
|
|
107
107
|
"@things-factory/system-ui": "^4.3.695",
|
|
108
|
-
"@things-factory/transport-base": "^4.3.
|
|
108
|
+
"@things-factory/transport-base": "^4.3.701",
|
|
109
109
|
"@things-factory/tutorial-ui": "^4.3.695",
|
|
110
|
-
"@things-factory/warehouse-base": "^4.3.
|
|
111
|
-
"@things-factory/worksheet-base": "^4.3.
|
|
110
|
+
"@things-factory/warehouse-base": "^4.3.701",
|
|
111
|
+
"@things-factory/worksheet-base": "^4.3.701"
|
|
112
112
|
},
|
|
113
113
|
"devDependencies": {
|
|
114
114
|
"@things-factory/builder": "^4.3.591",
|
|
@@ -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": "2cb46fe9d95770899e069846c590a3b24c847d9c"
|
|
121
121
|
}
|