@things-factory/operato-wms 4.3.464 → 4.3.465
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.
|
@@ -1154,6 +1154,16 @@ class UnloadProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
1154
1154
|
}
|
|
1155
1155
|
}
|
|
1156
1156
|
|
|
1157
|
+
async _checkExpiryFormat() {
|
|
1158
|
+
const inputExpDate = this.expDateInput.value
|
|
1159
|
+
let intValueYear = parseInt(inputExpDate)
|
|
1160
|
+
|
|
1161
|
+
if (intValueYear > 9999) {
|
|
1162
|
+
this._scanning = false
|
|
1163
|
+
throw new Error(i18next.t('text.please_enter_the_correct_date_format'))
|
|
1164
|
+
}
|
|
1165
|
+
}
|
|
1166
|
+
|
|
1157
1167
|
async _checkExpiry() {
|
|
1158
1168
|
let date = new Date()
|
|
1159
1169
|
const acceptBefore = new Date(date.setDate(date.getDate() + this.__minInboundShelfLife))
|
|
@@ -1436,6 +1446,8 @@ class UnloadProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
1436
1446
|
this._focusOnExpiryDateInput()
|
|
1437
1447
|
throw new Error(i18next.t('text.expiry_date_is_empty'))
|
|
1438
1448
|
}
|
|
1449
|
+
|
|
1450
|
+
await this._checkExpiryFormat()
|
|
1439
1451
|
}
|
|
1440
1452
|
}
|
|
1441
1453
|
|
|
@@ -1471,6 +1483,8 @@ class UnloadProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
1471
1483
|
this._focusOnExpiryDateInput()
|
|
1472
1484
|
throw new Error(i18next.t('text.expiry_date_is_empty'))
|
|
1473
1485
|
}
|
|
1486
|
+
|
|
1487
|
+
await this._checkExpiryFormat()
|
|
1474
1488
|
}
|
|
1475
1489
|
|
|
1476
1490
|
return orderProducts
|
|
@@ -862,8 +862,21 @@ class CreateArrivalNotice extends localize(i18next)(PageView) {
|
|
|
862
862
|
}
|
|
863
863
|
|
|
864
864
|
if (changedColumn === 'manufactureDate') {
|
|
865
|
-
|
|
865
|
+
//verify date value
|
|
866
|
+
let getYear = parseInt(changeRecord.manufactureDate.slice(0, 4))
|
|
867
|
+
let getMonth = parseInt(changeRecord.manufactureDate.slice(5, 7))
|
|
868
|
+
let getDay = parseInt(changeRecord.manufactureDate.slice(8, 10))
|
|
869
|
+
|
|
870
|
+
//year must be greater than year 2000
|
|
871
|
+
//month must be between 1 and 12
|
|
872
|
+
//day must be between 1 and 31
|
|
873
|
+
if (getYear < 2000 || getMonth < 1 || getMonth > 12 || getDay < 1 || getDay > 31) {
|
|
874
|
+
throw Error(i18next.t('text.please_enter_the_correct_date_format'))
|
|
875
|
+
}
|
|
876
|
+
|
|
877
|
+
//verify date range
|
|
866
878
|
let today = new Date()
|
|
879
|
+
let manufactureDate = new Date(changeRecord.manufactureDate)
|
|
867
880
|
|
|
868
881
|
if (manufactureDate > today) {
|
|
869
882
|
delete event.detail.after[event.detail.column.name]
|
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.465",
|
|
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": "8aaa13591defd6c8cee9cf68f1e4bdd82a216d68"
|
|
121
121
|
}
|
package/translations/en.json
CHANGED
|
@@ -1552,6 +1552,7 @@
|
|
|
1552
1552
|
"text.please_attach_the_file": "please attach the file",
|
|
1553
1553
|
"text.please_check_your_setting": "please check your setting",
|
|
1554
1554
|
"text.please_check_your_vas_target": "please check your vas target",
|
|
1555
|
+
"text.please_enter_the_correct_date_format": "please enter the correct date format",
|
|
1555
1556
|
"text.please_enter_transfer_qty": "please enter transfer quantity",
|
|
1556
1557
|
"text.please_fill_in_the_shipping_information_in_shipment_tab": "please fill in the shipping information in shipment tab.",
|
|
1557
1558
|
"text.please_insert_batch_no": "please insert batch no",
|
package/translations/ko.json
CHANGED
|
@@ -1541,6 +1541,7 @@
|
|
|
1541
1541
|
"text.please_attach_the_file": "[ko]please attach the file",
|
|
1542
1542
|
"text.please_check_your_setting": "설정을 확인해 주세요",
|
|
1543
1543
|
"text.please_check_your_vas_target": "[ko] please check your vas target",
|
|
1544
|
+
"text.please_enter_the_correct_date_format": "[ko] please enter the correct date format",
|
|
1544
1545
|
"text.please_enter_transfer_qty": "[ko] please enter transfer quantity",
|
|
1545
1546
|
"text.please_fill_in_the_shipping_information_in_shipment_tab": "[ko] please fill in the shipping information in shipment tab.",
|
|
1546
1547
|
"text.please_insert_batch_no": "[ko]please insert batch no",
|
package/translations/ms.json
CHANGED
|
@@ -1493,6 +1493,7 @@
|
|
|
1493
1493
|
"text.please_attach_the_file": "[ms]please attach the file",
|
|
1494
1494
|
"text.please_check_your_setting": "tolong semak tetapan anda",
|
|
1495
1495
|
"text.please_check_your_vas_target": "sila semak sasaran vas anda",
|
|
1496
|
+
"text.please_enter_the_correct_date_format": "[ms] please enter the correct date format",
|
|
1496
1497
|
"text.please_enter_transfer_qty": "[ms] please enter transfer quantity",
|
|
1497
1498
|
"text.please_fill_in_the_shipping_information_in_shipment_tab": "[ms] please fill in the shipping information in shipment tab.",
|
|
1498
1499
|
"text.please_insert_batch_no": "[ms]please insert batch no",
|
package/translations/zh.json
CHANGED
|
@@ -1460,6 +1460,7 @@
|
|
|
1460
1460
|
"text.please_attach_the_file": "[zh]please attach the file",
|
|
1461
1461
|
"text.please_check_your_setting": "please check your setting",
|
|
1462
1462
|
"text.please_check_your_vas_target": "[zh] please check your vas target",
|
|
1463
|
+
"text.please_enter_the_correct_date_format": "[zh] please enter the correct date format",
|
|
1463
1464
|
"text.please_enter_transfer_qty": "[zh] please enter transfer quantity",
|
|
1464
1465
|
"text.please_fill_in_the_shipping_information_in_shipment_tab": "[zh] please fill in the shipping information in shipment tab.",
|
|
1465
1466
|
"text.please_insert_batch_no": "[zh]please insert batch no",
|