@things-factory/operato-wms 4.3.637 → 4.3.639

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.
Files changed (97) hide show
  1. package/client/pages/adjustment/transfer-inventory.js +7 -12
  2. package/client/pages/bulk-operation/bulk-operation.js +24 -22
  3. package/client/pages/bulk-operation/validate-b2c-ro-popup.js +14 -4
  4. package/client/pages/bulk-operation/validate-gan-popup.js +26 -11
  5. package/client/pages/bulk-operation/validate-ro-popup.js +16 -6
  6. package/client/pages/components/list-view/product-list-view.js +1 -1
  7. package/client/pages/components/select-inventory-popup.js +1 -5
  8. package/client/pages/components/select-product-popup.js +4 -9
  9. package/client/pages/inbound/putaway/putaway-product.js +92 -70
  10. package/client/pages/inbound/putaway/putaway-replenishment-same-product-popup.js +10 -3
  11. package/client/pages/inbound/putaway/putaway-same-carton-popup.js +1 -1
  12. package/client/pages/inbound/putaway/putaway-worksheet-generate-popup.js +1 -1
  13. package/client/pages/inbound/putaway/undo-putaway-popup.js +19 -16
  14. package/client/pages/inbound/putaway/worksheet-putaway-return.js +1 -1
  15. package/client/pages/inbound/putaway/worksheet-putaway.js +3 -3
  16. package/client/pages/inbound/undo-unload-popup.js +1 -1
  17. package/client/pages/inbound/unload-product.js +33 -37
  18. package/client/pages/inbound/unloaded-inventories-popup.js +1 -1
  19. package/client/pages/inbound/worksheet-unloading-return.js +1 -1
  20. package/client/pages/inbound/worksheet-unloading.js +2 -2
  21. package/client/pages/inventory/inventory-adjustment.js +5 -20
  22. package/client/pages/inventory/inventory-by-product.js +43 -43
  23. package/client/pages/inventory/onhand-inventory.js +2 -2
  24. package/client/pages/inventory-check/add-extra-inventory-popup.js +2 -10
  25. package/client/pages/inventory-check/cycle-count-recheck-popup.js +2 -2
  26. package/client/pages/inventory-check/cycle-count-report.js +19 -14
  27. package/client/pages/inventory-check/inspecting-product.js +2 -14
  28. package/client/pages/order/arrival-notice/arrival-notice-detail.js +27 -23
  29. package/client/pages/order/arrival-notice/assign-buffer-location.js +2 -2
  30. package/client/pages/order/arrival-notice/check-arrived-notice.js +2 -2
  31. package/client/pages/order/arrival-notice/create-arrival-notice.js +29 -33
  32. package/client/pages/order/arrival-notice/duplicate-arrival-notice.js +8 -8
  33. package/client/pages/order/arrival-notice/edit-product-popup.js +27 -29
  34. package/client/pages/order/arrival-notice/proceed-edit-product-popup.js +3 -3
  35. package/client/pages/order/arrival-notice/receive-arrival-notice.js +1 -1
  36. package/client/pages/order/arrival-notice/rejected-arrival-notice.js +1 -1
  37. package/client/pages/order/arrival-notice/view-product-changes-popup.js +3 -3
  38. package/client/pages/order/draft-release-good/draft-release-good-detail.js +2 -2
  39. package/client/pages/order/release-order/b2c/b2c-release-order-detail.js +91 -92
  40. package/client/pages/order/release-order/b2c/create-b2c-release-order.js +56 -61
  41. package/client/pages/order/release-order/create-release-order.js +55 -64
  42. package/client/pages/order/release-order/receive-release-order-request.js +1 -1
  43. package/client/pages/order/release-order/rejected-release-order.js +2 -2
  44. package/client/pages/order/release-order/release-extra-product-popup.js +7 -11
  45. package/client/pages/order/release-order/release-order-detail.js +116 -158
  46. package/client/pages/order/return-order/create-return-order.js +3 -16
  47. package/client/pages/order/return-order/return-order-inventory-popup.js +1 -2
  48. package/client/pages/outbound/inventory-assign-popup.js +2 -2
  49. package/client/pages/outbound/inventory-auto-assign-popup.js +1 -1
  50. package/client/pages/outbound/inventory-reassign-popup.js +6 -6
  51. package/client/pages/outbound/loading-product.js +3 -3
  52. package/client/pages/outbound/loading-v2/load-by-qty.js +2 -2
  53. package/client/pages/outbound/loading-v2/loading-execution-base.js +4 -4
  54. package/client/pages/outbound/packing-product.js +26 -7
  55. package/client/pages/outbound/picking-product.js +16 -36
  56. package/client/pages/outbound/picking-replacement-popup.js +4 -4
  57. package/client/pages/outbound/picking-v2/picking-execution-base.js +4 -8
  58. package/client/pages/outbound/sorting-product.js +7 -5
  59. package/client/pages/outbound/worksheet-batch-picking.js +43 -30
  60. package/client/pages/outbound/worksheet-loading.js +2 -2
  61. package/client/pages/outbound/worksheet-packing.js +1 -1
  62. package/client/pages/outbound/worksheet-picking.js +19 -23
  63. package/client/pages/outbound/worksheet-return.js +1 -1
  64. package/client/pages/outbound/worksheet-sorting.js +23 -12
  65. package/client/pages/outbound/worksheet-zone-picking.js +3 -3
  66. package/client/pages/report/replenishment-report.js +14 -5
  67. package/client/pages/report/volume-summary-report.js +6 -6
  68. package/dist-server/graphql/resolvers/other/add-release-good-products.js +9 -3
  69. package/dist-server/graphql/resolvers/other/add-release-good-products.js.map +1 -1
  70. package/dist-server/graphql/resolvers/outbound/complete-load.js +15 -3
  71. package/dist-server/graphql/resolvers/outbound/complete-load.js.map +1 -1
  72. package/dist-server/graphql/resolvers/outbound/sort-item.js +1 -1
  73. package/dist-server/graphql/resolvers/outbound/sort-item.js.map +1 -1
  74. package/dist-server/graphql/resolvers/reports/cycle-count-report.js +1 -2
  75. package/dist-server/graphql/resolvers/reports/cycle-count-report.js.map +1 -1
  76. package/dist-server/graphql/resolvers/zone-worksheet/zone-picking.js +7 -18
  77. package/dist-server/graphql/resolvers/zone-worksheet/zone-picking.js.map +1 -1
  78. package/dist-server/graphql/types/outbound/index.js +1 -1
  79. package/dist-server/graphql/types/reports/cycle-count-report.js +1 -1
  80. package/dist-server/graphql/types/reports/inbound-order-details-report.js +1 -1
  81. package/dist-server/graphql/types/reports/outbound-order-details-report.js +2 -2
  82. package/dist-server/graphql/types/zone-worksheet/index.js +1 -1
  83. package/package.json +16 -16
  84. package/server/graphql/resolvers/other/add-release-good-products.ts +9 -2
  85. package/server/graphql/resolvers/outbound/complete-load.ts +27 -10
  86. package/server/graphql/resolvers/outbound/sort-item.ts +1 -1
  87. package/server/graphql/resolvers/reports/cycle-count-report.ts +1 -2
  88. package/server/graphql/resolvers/zone-worksheet/zone-picking.ts +8 -20
  89. package/server/graphql/types/outbound/index.ts +1 -1
  90. package/server/graphql/types/reports/cycle-count-report.ts +1 -1
  91. package/server/graphql/types/reports/inbound-order-details-report.ts +1 -1
  92. package/server/graphql/types/reports/outbound-order-details-report.ts +2 -2
  93. package/server/graphql/types/zone-worksheet/index.ts +1 -1
  94. package/translations/en.json +259 -265
  95. package/translations/ko.json +0 -1
  96. package/translations/ms.json +1463 -1580
  97. package/translations/zh.json +2150 -2354
@@ -192,10 +192,11 @@ class ArrivalNoticeDetail extends localize(i18next)(PageView) {
192
192
  }
193
193
  ]
194
194
 
195
+
195
196
  if (
196
197
  this._status === ORDER_STATUS.PENDING.value &&
197
198
  this.userRoles?.find(itm => itm.name.toLowerCase().includes('admin'))
198
- ) {
199
+ ){
199
200
  actions.push({
200
201
  title: i18next.t('button.edit_product'),
201
202
  action: this.openEditProductPopup.bind(this),
@@ -204,11 +205,13 @@ class ArrivalNoticeDetail extends localize(i18next)(PageView) {
204
205
  }
205
206
 
206
207
  if (this._status === ORDER_STATUS.PENDING.value) {
207
- actions.push({
208
- title: i18next.t('button.update_order_details'),
209
- action: this._updateArrivalNotice.bind(this),
210
- ...CommonButtonStyles.add
211
- })
208
+ actions.push(
209
+ {
210
+ title: i18next.t('button.update_order_details'),
211
+ action: this._updateArrivalNotice.bind(this),
212
+ ...CommonButtonStyles.add
213
+ }
214
+ )
212
215
 
213
216
  actions.push({
214
217
  title: i18next.t('button.delete'),
@@ -520,7 +523,7 @@ class ArrivalNoticeDetail extends localize(i18next)(PageView) {
520
523
 
521
524
  <label>${i18next.t('label.eta_date')}</label>
522
525
  <input name="etaDate" type="date" disabled />
523
-
526
+
524
527
  <label ?hidden="${!this._warehouseTransport}">${i18next.t('label.transport_vehicle')}</label>
525
528
  <input name="transportVehicle" ?hidden="${!this._warehouseTransport}" ?readonly=${this.determineStatus()} />
526
529
 
@@ -849,13 +852,13 @@ class ArrivalNoticeDetail extends localize(i18next)(PageView) {
849
852
  width: 80
850
853
  },
851
854
  {
852
- type: 'float',
855
+ type: 'integer',
853
856
  name: 'packQty',
854
857
  header: i18next.t('field.pack_qty'),
855
858
  width: 80
856
859
  },
857
860
  {
858
- type: 'float',
861
+ type: 'integer',
859
862
  name: 'totalUomValue',
860
863
  header: i18next.t('field.total_uom_value'),
861
864
  width: 120
@@ -990,7 +993,6 @@ class ArrivalNoticeDetail extends localize(i18next)(PageView) {
990
993
  description
991
994
  sku
992
995
  brand
993
- isInventoryDecimal
994
996
  }
995
997
  productDetail {
996
998
  id
@@ -1143,28 +1145,30 @@ class ArrivalNoticeDetail extends localize(i18next)(PageView) {
1143
1145
  field.checked = data[key]
1144
1146
 
1145
1147
  if (field.name === 'ownTransport') {
1146
- this._ownTransport = data[key]
1148
+ this._ownTransport = data[key];
1147
1149
  if (data[key] === true) {
1148
1150
  // If ownTransp ort is true, set warehouseTransport to false
1149
- this._ownTransport = true
1150
- this._ownTransportInput.checked = true
1151
- this._warehouseTransport = false
1152
- this._warehouseTransportInput.checked = false
1153
- }
1151
+ this._ownTransport = true;
1152
+ this._ownTransportInput.checked = true;
1153
+ this._warehouseTransport = false;
1154
+ this._warehouseTransportInput.checked = false;
1155
+ }
1154
1156
 
1155
1157
  // If ownTransport is true, warehouseTransport must be false
1156
1158
  if (!this._ownTransport) {
1157
- this._warehouseTransport = true
1158
- this._warehouseTransportInput.checked = true
1159
+ this._warehouseTransport = true;
1160
+ this._warehouseTransportInput.checked = true;
1159
1161
  // If ownTransport is true, set warehouseTransport to false
1160
- this._ownTransport = false
1161
- this._ownTransportInput.checked = false
1162
- }
1162
+ this._ownTransport = false;
1163
+ this._ownTransportInput.checked = false;
1163
1164
  }
1165
+ }
1166
+
1167
+
1164
1168
  } else if (field.name === key) {
1165
- field.value = data[key]
1169
+ field.value = data[key];
1166
1170
  }
1167
- })
1171
+ });
1168
1172
  }
1169
1173
  }
1170
1174
 
@@ -619,13 +619,13 @@ class AssignBufferLocation extends localize(i18next)(PageView) {
619
619
  width: 80
620
620
  },
621
621
  {
622
- type: 'float',
622
+ type: 'integer',
623
623
  name: 'packQty',
624
624
  header: i18next.t('field.pack_qty'),
625
625
  width: 80
626
626
  },
627
627
  {
628
- type: 'float',
628
+ type: 'integer',
629
629
  name: 'totalUomValue',
630
630
  header: i18next.t('field.total_uom_value'),
631
631
  width: 120
@@ -360,13 +360,13 @@ class CheckArrivedNotice extends localize(i18next)(PageView) {
360
360
  width: 80
361
361
  },
362
362
  {
363
- type: 'float',
363
+ type: 'integer',
364
364
  name: 'packQty',
365
365
  header: i18next.t('field.pack_qty'),
366
366
  width: 80
367
367
  },
368
368
  {
369
- type: 'float',
369
+ type: 'integer',
370
370
  name: 'totalUomValue',
371
371
  header: i18next.t('field.total_uom_value'),
372
372
  width: 120
@@ -693,7 +693,7 @@ class CreateArrivalNotice extends localize(i18next)(PageView) {
693
693
  width: 100
694
694
  },
695
695
  {
696
- type: 'float',
696
+ type: 'integer',
697
697
  name: 'packQty',
698
698
  header: i18next.t('field.pack_qty'),
699
699
  imex: { header: i18next.t('field.pack_qty'), key: 'packQty', width: 25, type: 'float' },
@@ -715,16 +715,14 @@ class CreateArrivalNotice extends localize(i18next)(PageView) {
715
715
  width: 80
716
716
  },
717
717
  ...(this._enableLotIdInput
718
- ? [
719
- {
720
- type: 'string',
721
- name: 'palletId',
722
- header: i18next.t('field.lot_id'),
723
- imex: { header: i18next.t('field.lot_id'), key: 'palletId', width: 25, type: 'string' },
724
- record: { editable: editable },
725
- width: 150
726
- }
727
- ]
718
+ ? [{
719
+ type: 'string',
720
+ name: 'palletId',
721
+ header: i18next.t('field.lot_id'),
722
+ imex: { header: i18next.t('field.lot_id'), key: 'palletId', width: 25, type: 'string' },
723
+ record: { editable: editable },
724
+ width: 150
725
+ }]
728
726
  : []),
729
727
  {
730
728
  type: 'date',
@@ -853,7 +851,7 @@ class CreateArrivalNotice extends localize(i18next)(PageView) {
853
851
  item?.packQty > 0
854
852
  ? item?.totalUomValue
855
853
  ? item.totalUomValue
856
- : `${parseFloat(item.packQty * e.detail.uomValue).toFixed(3)} ${e.detail.uom}`
854
+ : `${parseFloat(item.packQty * e.detail.uomValue).toFixed(2)} ${e.detail.uom}`
857
855
  : null
858
856
  }
859
857
  })
@@ -995,7 +993,7 @@ class CreateArrivalNotice extends localize(i18next)(PageView) {
995
993
  throw new Error(i18next.t('text.x_is_empty', { state: { x: i18next.t('label.uom') } }))
996
994
 
997
995
  if (uomValue && uom && packQty) {
998
- calcedRecord.totalUomValue = `${(uomValue * packQty).toFixed(3)} ${uom}`
996
+ calcedRecord.totalUomValue = `${(uomValue * packQty).toFixed(2)} ${uom}`
999
997
  } else {
1000
998
  calcedRecord.totalUomValue = ''
1001
999
  }
@@ -1395,7 +1393,6 @@ class CreateArrivalNotice extends localize(i18next)(PageView) {
1395
1393
  if (record.unitPrice) {
1396
1394
  record.unitPrice = parseFloat(record.unitPrice)
1397
1395
  }
1398
-
1399
1396
  let orderProduct = {
1400
1397
  batchId: record.batchId,
1401
1398
  batchIdRef: record?.batchIdRef ? record.batchIdRef : null,
@@ -1405,7 +1402,7 @@ class CreateArrivalNotice extends localize(i18next)(PageView) {
1405
1402
  packingSize: record.packingSize || record.product.packingSize,
1406
1403
  uomValue: record?.uomValue ? record.uomValue : 0,
1407
1404
  uom: record.uom,
1408
- packQty: parseFloat(record.packQty.toFixed(3)),
1405
+ packQty: record.packQty,
1409
1406
  totalUomValue: record?.totalUomValue ? record?.totalUomValue : 0,
1410
1407
  unitPrice: record?.unitPrice ? record.unitPrice : 0,
1411
1408
  remark: record?.remark ? record.remark : null,
@@ -1654,7 +1651,7 @@ class CreateArrivalNotice extends localize(i18next)(PageView) {
1654
1651
  width: 100
1655
1652
  },
1656
1653
  {
1657
- type: 'float',
1654
+ type: 'integer',
1658
1655
  name: 'packQty',
1659
1656
  header: i18next.t('field.pack_qty'),
1660
1657
  imex: { header: i18next.t('field.pack_qty'), key: 'packQty', width: 25, type: 'float' },
@@ -1668,15 +1665,13 @@ class CreateArrivalNotice extends localize(i18next)(PageView) {
1668
1665
  width: 100
1669
1666
  },
1670
1667
  ...(this._enableLotIdInput
1671
- ? [
1672
- {
1673
- type: 'string',
1674
- name: 'palletId',
1675
- header: i18next.t('field.lot_id'),
1676
- imex: { header: i18next.t('field.lot_id'), key: 'palletId', width: 25, type: 'string' },
1677
- width: 100
1678
- }
1679
- ]
1668
+ ? [{
1669
+ type: 'string',
1670
+ name: 'palletId',
1671
+ header: i18next.t('field.lot_id'),
1672
+ imex: { header: i18next.t('field.lot_id'), key: 'palletId', width: 25, type: 'string' },
1673
+ width: 100
1674
+ }]
1680
1675
  : []),
1681
1676
  {
1682
1677
  type: 'date',
@@ -1778,14 +1773,15 @@ class CreateArrivalNotice extends localize(i18next)(PageView) {
1778
1773
  if (this._enableLotIdInput) {
1779
1774
  let palletIds = response.data.bulkUploadValidateOrderProducts
1780
1775
  .map(item => item.palletId)
1781
- .filter(palletId => palletId !== null)
1782
-
1783
- let uniquePalletIds = new Set(palletIds)
1784
- let isDuplicated = uniquePalletIds.size !== palletIds.length
1776
+ .filter(palletId => palletId !== null);
1777
+
1778
+ let uniquePalletIds = new Set(palletIds);
1779
+ let isDuplicated = uniquePalletIds.size !== palletIds.length;
1785
1780
  if (isDuplicated) {
1786
1781
  return this._showToast({ message: i18next.t('text.duplicated_lot_id') })
1787
1782
  }
1788
1783
  }
1784
+
1789
1785
 
1790
1786
  if (!foundErrors) {
1791
1787
  if (!response.errors) {
@@ -1801,7 +1797,7 @@ class CreateArrivalNotice extends localize(i18next)(PageView) {
1801
1797
  ...item,
1802
1798
  productName: item?.productName,
1803
1799
  unitPrice: (item?.unitPrice || 0).toFixed(2),
1804
- packQty: parseFloat(item.packQty).toFixed(3) || '',
1800
+ packQty: parseFloat(item.packQty) || '',
1805
1801
  palletQty: parseFloat(item.palletQty) || '',
1806
1802
  productDetail: { id: item?.productDetail?.id || null }
1807
1803
  }
@@ -1835,7 +1831,7 @@ class CreateArrivalNotice extends localize(i18next)(PageView) {
1835
1831
  delete itm.manufactureDate
1836
1832
  }
1837
1833
  itm.uomValue = parseFloat(itm.uomValue) || ''
1838
- itm.packQty = parseFloat(itm.packQty).toFixed(3) || ''
1834
+ itm.packQty = parseInt(itm.packQty) || ''
1839
1835
  itm.palletQty = parseInt(itm.palletQty) || ''
1840
1836
  })
1841
1837
 
@@ -1845,7 +1841,7 @@ class CreateArrivalNotice extends localize(i18next)(PageView) {
1845
1841
  ...patch,
1846
1842
  unitPrice: patch.unitPrice ? parseFloat(patch.unitPrice) : null,
1847
1843
  uomValue: parseFloat(patch.uomValue) || 0,
1848
- packQty: parseFloat(patch.packQty).toFixed(3) || 0,
1844
+ packQty: parseInt(patch.packQty) || 0,
1849
1845
  palletQty: parseInt(patch.palletQty) || 0
1850
1846
  }
1851
1847
  })
@@ -1880,7 +1876,7 @@ class CreateArrivalNotice extends localize(i18next)(PageView) {
1880
1876
  ? '0'
1881
1877
  : record.packQty === undefined
1882
1878
  ? null
1883
- : parseFloat(record.packQty).toFixed(3),
1879
+ : parseInt(record.packQty),
1884
1880
  palletQty:
1885
1881
  record.palletQty == null && record.palletQty !== undefined
1886
1882
  ? '0'
@@ -691,7 +691,7 @@ class DuplicateArrivalNotice extends localize(i18next)(PageView) {
691
691
  width: 80
692
692
  },
693
693
  {
694
- type: 'float',
694
+ type: 'integer',
695
695
  name: 'packQty',
696
696
  header: i18next.t('field.pack_qty'),
697
697
  record: { editable: editable, options: { min: 0 } },
@@ -808,7 +808,7 @@ class DuplicateArrivalNotice extends localize(i18next)(PageView) {
808
808
  item?.packQty > 0
809
809
  ? item?.totalUomValue
810
810
  ? item.totalUomValue
811
- : `${parseFloat(item.packQty * e.detail.uomValue).toFixed(3)} ${e.detail.uom}`
811
+ : `${parseFloat(item.packQty * e.detail.uomValue).toFixed(2)} ${e.detail.uom}`
812
812
  : null
813
813
  }
814
814
  })
@@ -909,7 +909,7 @@ class DuplicateArrivalNotice extends localize(i18next)(PageView) {
909
909
 
910
910
  _calcTotalUomValue(uomValue, unit, packQty) {
911
911
  if (uomValue && unit && packQty) {
912
- return `${(uomValue * packQty).toFixed(3)} ${unit}`
912
+ return `${(uomValue * packQty).toFixed(2)} ${unit}`
913
913
  } else {
914
914
  return null
915
915
  }
@@ -1434,7 +1434,7 @@ class DuplicateArrivalNotice extends localize(i18next)(PageView) {
1434
1434
  packingSize: record?.product?.packingSize ? record.product.packingSize : record.packingSize,
1435
1435
  uomValue: record?.uomValue ? record.uomValue : 0,
1436
1436
  uom: record.uom,
1437
- packQty: parseFloat(record.packQty).toFixed(3),
1437
+ packQty: record.packQty,
1438
1438
  totalUomValue: record.totalUomValue,
1439
1439
  totalUomValue: record?.totalUomValue ? record?.totalUomValue : 0,
1440
1440
  unitPrice: record?.unitPrice ? record.unitPrice : 0,
@@ -1666,7 +1666,7 @@ class DuplicateArrivalNotice extends localize(i18next)(PageView) {
1666
1666
  width: 100
1667
1667
  },
1668
1668
  {
1669
- type: 'float',
1669
+ type: 'integer',
1670
1670
  name: 'packQty',
1671
1671
  header: i18next.t('field.pack_qty'),
1672
1672
  imex: { header: i18next.t('field.pack_qty'), key: 'packQty', width: 25, type: 'float' },
@@ -1770,7 +1770,7 @@ class DuplicateArrivalNotice extends localize(i18next)(PageView) {
1770
1770
  ...item,
1771
1771
  productName: item?.productName,
1772
1772
  unitPrice: parseFloat(item.unitPrice) || '',
1773
- packQty: parseFloat(item.packQty).toFixed(3) || '',
1773
+ packQty: parseFloat(item.packQty) || '',
1774
1774
  palletQty: parseFloat(item.palletQty) || ''
1775
1775
  }
1776
1776
  })
@@ -1800,7 +1800,7 @@ class DuplicateArrivalNotice extends localize(i18next)(PageView) {
1800
1800
  } else {
1801
1801
  delete itm.manufactureDate
1802
1802
  }
1803
- itm.packQty = parseFloat(itm.packQty).toFixed(3) || ''
1803
+ itm.packQty = parseFloat(itm.packQty) || ''
1804
1804
  itm.palletQty = parseFloat(itm.palletQty) || ''
1805
1805
  })
1806
1806
 
@@ -1813,7 +1813,7 @@ class DuplicateArrivalNotice extends localize(i18next)(PageView) {
1813
1813
  return {
1814
1814
  ...patch,
1815
1815
  unitPrice: parseFloat(patch.unitPrice) || 0,
1816
- packQty: parseFloat(patch.packQty).toFixed(3) || 0,
1816
+ packQty: parseFloat(patch.packQty) || 0,
1817
1817
  palletQty: parseFloat(patch.palletQty) || 0
1818
1818
  }
1819
1819
  })
@@ -132,7 +132,7 @@ export class EditProductPopup extends localize(i18next)(LitElement) {
132
132
  raised
133
133
  @click="${this._addEditProducts.bind(this, true)}"
134
134
  label="${i18next.t('button.submit')}"
135
- class="${this.status !== 'PENDING'
135
+ class="${this.status !== 'PENDING' && this.userRole?.find(itm => !itm.name.toLowerCase().includes('admin'))
136
136
  ? 'hidden'
137
137
  : ''}"
138
138
  ></mwc-button>
@@ -225,7 +225,7 @@ export class EditProductPopup extends localize(i18next)(LitElement) {
225
225
  width: 80
226
226
  },
227
227
  {
228
- type: 'float',
228
+ type: 'integer',
229
229
  name: 'packQty',
230
230
  header: i18next.t('field.pack_qty'),
231
231
  record: { editable: true, options: { min: 0 } },
@@ -373,7 +373,7 @@ export class EditProductPopup extends localize(i18next)(LitElement) {
373
373
  width: 80
374
374
  },
375
375
  {
376
- type: 'float',
376
+ type: 'integer',
377
377
  name: 'packQty',
378
378
  header: i18next.t('field.pack_qty'),
379
379
  record: { editable: true, options: { min: 0 } },
@@ -501,7 +501,7 @@ export class EditProductPopup extends localize(i18next)(LitElement) {
501
501
  if (changedColumn === 'uom' && !uom)
502
502
  throw new Error(i18next.t('text.x_is_empty', { state: { x: i18next.t('label.uom') } }))
503
503
  if (uomValue && uom) {
504
- if (packQty !== 0) calcedRecord.totalUomValue = `${(uomValue * packQty).toFixed(3)} ${uom}`
504
+ if (packQty !== 0) calcedRecord.totalUomValue = `${(uomValue * packQty).toFixed(2)} ${uom}`
505
505
  if (packQty === 0) calcedRecord.totalUomValue = `0 ${uom}`
506
506
  } else {
507
507
  calcedRecord.totalUomValue = ''
@@ -583,33 +583,33 @@ export class EditProductPopup extends localize(i18next)(LitElement) {
583
583
  if (isDuplicated) {
584
584
  throw new Error(i18next.t('text.duplicated_lot_id'))
585
585
  }
586
- } else if (this.enableLotIdInput) {
586
+ }else if (this.enableLotIdInput) {
587
587
  const addedNewRows = this.addProductGrist.dirtyData.records
588
- .filter(record => record.palletId)
589
- .map(record => `${record.palletId}`)
588
+ .filter(record => record.palletId)
589
+ .map(record => `${record.palletId}`)
590
590
 
591
- addedNewRows.forEach((row, idx, rows) => {
592
- if (rows.lastIndexOf(row) !== idx) {
593
- isDuplicated = true
594
- }
595
- })
591
+ addedNewRows.forEach((row, idx, rows) => {
592
+ if (rows.lastIndexOf(row) !== idx) {
593
+ isDuplicated = true
594
+ }
595
+ })
596
596
 
597
- const existingRows = this.editProductGrist.dirtyData.records
598
- .filter(record => record.palletId)
599
- .map(record => `${record.palletId}`)
597
+ const existingRows = this.editProductGrist.dirtyData.records
598
+ .filter(record => record.palletId )
599
+ .map(record => `${record.palletId}`)
600
600
 
601
- existingRows.forEach((row, idx, rows) => {
602
- if (rows.lastIndexOf(row) !== idx) {
603
- isDuplicated = true
604
- }
605
- })
601
+ existingRows.forEach((row, idx, rows) => {
602
+ if (rows.lastIndexOf(row) !== idx) {
603
+ isDuplicated = true
604
+ }
605
+ })
606
606
 
607
- const matchingRow = addedNewRows.filter(newRow => existingRows.includes(newRow))
608
- if (matchingRow?.length > 0) isDuplicated = true
607
+ const matchingRow = addedNewRows.filter(newRow => existingRows.includes(newRow))
608
+ if (matchingRow?.length > 0) isDuplicated = true
609
609
 
610
- if (isDuplicated) {
611
- throw new Error(i18next.t('text.there_is_duplicated_lot_id'))
612
- }
610
+ if (isDuplicated) {
611
+ throw new Error(i18next.t('text.there_is_duplicated_lot_id'))
612
+ }
613
613
  }
614
614
  }
615
615
 
@@ -717,8 +717,7 @@ export class EditProductPopup extends localize(i18next)(LitElement) {
717
717
  _getNewOrderProducts() {
718
718
  const isStatusPending = this.status === 'PENDING' ? true : false
719
719
  return this.addProductGrist.dirtyData.records.map(record => {
720
- record.unitPrice = parseFloat(record.unitPrice) || 0
721
-
720
+ record.unitPrice = parseFloat(record.unitPrice)
722
721
  return {
723
722
  batchId: isStatusPending ? record.batchId : `N/A`,
724
723
  adjustedBatchId: !isStatusPending ? record.batchId : null,
@@ -734,7 +733,7 @@ export class EditProductPopup extends localize(i18next)(LitElement) {
734
733
  adjustedUomValue: !isStatusPending ? (record?.uomValue ? record.uomValue : 0) : null,
735
734
  uom: isStatusPending ? record.uom : 'N/A',
736
735
  adjustedUom: !isStatusPending ? record.uom : null,
737
- packQty: isStatusPending ? (record.packQty ? parseFloat(record.packQty).toFixed(3) : 0) : 0,
736
+ packQty: isStatusPending ? (record.packQty ? record.packQty : 0) : 0,
738
737
  adjustedPackQty: !isStatusPending ? record.packQty : null,
739
738
  totalUomValue: isStatusPending ? record.totalUomValue : 'N/A',
740
739
  adjustedTotalUomValue: record?.totalUomValue && !isStatusPending ? record.totalUomValue : 'N/A',
@@ -755,7 +754,6 @@ export class EditProductPopup extends localize(i18next)(LitElement) {
755
754
  if (this.editProductGrist.dirtyData.records.some(record => record.__dirty__)) {
756
755
  this.editProductGrist.dirtyData.records.map(record => {
757
756
  record.unitPrice = parseFloat(record.unitPrice)
758
-
759
757
  editedOrderProducts.push({
760
758
  id: record.id,
761
759
  adjustedBatchId: !isStatusPending
@@ -236,19 +236,19 @@ export class ProceedEditProductPopup extends localize(i18next)(LitElement) {
236
236
  width: 80
237
237
  },
238
238
  {
239
- type: 'float',
239
+ type: 'integer',
240
240
  name: 'packQty',
241
241
  header: i18next.t('field.pack_qty'),
242
242
  width: 80
243
243
  },
244
244
  {
245
- type: 'float',
245
+ type: 'integer',
246
246
  name: 'adjustedPackQty',
247
247
  header: i18next.t('field.adjusted_pack_qty'),
248
248
  width: 80
249
249
  },
250
250
  {
251
- type: 'float',
251
+ type: 'integer',
252
252
  name: 'totalUomValue',
253
253
  header: i18next.t('field.total_uom_value'),
254
254
  width: 120
@@ -609,7 +609,7 @@ class ReceiveArrivalNotice extends localize(i18next)(PageView) {
609
609
  width: 80
610
610
  },
611
611
  {
612
- type: 'float',
612
+ type: 'integer',
613
613
  name: 'packQty',
614
614
  header: i18next.t('field.pack_qty'),
615
615
  width: 80
@@ -470,7 +470,7 @@ class RejectedArrivalNotice extends localize(i18next)(PageView) {
470
470
  width: 80
471
471
  },
472
472
  {
473
- type: 'float',
473
+ type: 'integer',
474
474
  name: 'packQty',
475
475
  header: i18next.t('field.pack_qty'),
476
476
  width: 80
@@ -211,19 +211,19 @@ export class ViewProductChangesPopup extends localize(i18next)(LitElement) {
211
211
  width: 80
212
212
  },
213
213
  {
214
- type: 'float',
214
+ type: 'integer',
215
215
  name: 'packQty',
216
216
  header: i18next.t('field.pack_qty'),
217
217
  width: 80
218
218
  },
219
219
  {
220
- type: 'float',
220
+ type: 'integer',
221
221
  name: 'adjustedPackQty',
222
222
  header: i18next.t('field.adjusted_pack_qty'),
223
223
  width: 80
224
224
  },
225
225
  {
226
- type: 'float',
226
+ type: 'integer',
227
227
  name: 'totalUomValue',
228
228
  header: i18next.t('field.total_uom_value'),
229
229
  width: 120
@@ -678,7 +678,7 @@ class DraftReleaseGoodDetail extends connect(store)(localize(i18next)(PageView))
678
678
  width: 100
679
679
  },
680
680
  {
681
- type: 'float',
681
+ type: 'integer',
682
682
  name: 'remainQty',
683
683
  header: i18next.t('field.available_qty'),
684
684
  width: 140
@@ -690,7 +690,7 @@ class DraftReleaseGoodDetail extends connect(store)(localize(i18next)(PageView))
690
690
  width: 140
691
691
  },
692
692
  {
693
- type: 'float',
693
+ type: 'integer',
694
694
  name: 'releaseQty',
695
695
  header: i18next.t('field.release_qty'),
696
696
  imex: { header: i18next.t('field.release_qty'), key: 'releaseQty', width: 25, type: 'float' },