@feedmepos/mf-inventory-portal 1.2.1 → 1.2.2-5.dev-1

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 (147) hide show
  1. package/dist/App-DMkUg806.js +297 -0
  2. package/dist/{ApprovalView-DwRrbVDo.js → ApprovalView-DWJh2K6W.js} +65 -64
  3. package/dist/{BindingsDialog-DUVKv10-.js → BindingsDialog-EmHCvqJI.js} +2 -2
  4. package/dist/{BindingsPicker-Daib_iq4.js → BindingsPicker-h_9jm1s0.js} +3 -3
  5. package/dist/{BindingsTable-Bv9UmcJP.js → BindingsTable-BAVWGUoa.js} +1 -1
  6. package/dist/ClosingDraftView-Du4kOwIg.js +1899 -0
  7. package/dist/ClosingHistoryView-DuW2Vtrs.js +355 -0
  8. package/dist/ClosingTemplateView-CfPY8R5M.js +2001 -0
  9. package/dist/{DeliveryOrderPrintPreview-DZPcRAja.js → DeliveryOrderPrintPreview-C6Cj8mOp.js} +9 -9
  10. package/dist/FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-WWIrybw_.js +230 -0
  11. package/dist/{FmMultiselectDialog-CZmwOkrb.js → FmMultiselectDialog-BzWrQOS4.js} +1 -1
  12. package/dist/{FmUnitInput.vue_vue_type_script_setup_true_lang-C-2V2bGc.js → FmUnitInput.vue_vue_type_script_setup_true_lang-DwqVRUFz.js} +36 -36
  13. package/dist/ImportView-lKlYeLay.js +1291 -0
  14. package/dist/{IngredientBindedItem.vue_vue_type_script_setup_true_lang-BGnoF1Zz.js → IngredientBindedItem.vue_vue_type_script_setup_true_lang-_2WZMZU2.js} +5 -5
  15. package/dist/{IngredientGroupView-CAVYpEj3.js → IngredientGroupView-CrmwR2Xt.js} +34 -35
  16. package/dist/IngredientsView-1bAsyz-b.js +2254 -0
  17. package/dist/{IntegrationView-DdLFyZ4H.js → IntegrationView-D16qeEc_.js} +1773 -1635
  18. package/dist/{InventoryBindingForm-C7BdEDtM.js → InventoryBindingForm-BRwOXV_P.js} +1 -1
  19. package/dist/{InventoryBindingForm.vue_vue_type_script_setup_true_lang-B7DND2dQ.js → InventoryBindingForm.vue_vue_type_script_setup_true_lang-NDbtbtqK.js} +28 -28
  20. package/dist/{InventoryBindingSummary-IZ7F-Lti.js → InventoryBindingSummary-DKM2gX8_.js} +1 -1
  21. package/dist/{NumberPrecisionInput.vue_vue_type_script_setup_true_lang-sgqVSlUB.js → NumberPrecisionInput.vue_vue_type_script_setup_true_lang-CdaiYTdf.js} +4 -4
  22. package/dist/{PremiumBadge.vue_vue_type_script_setup_true_lang-DeF32bHu.js → PremiumBadge.vue_vue_type_script_setup_true_lang-B0OKeK5O.js} +7 -7
  23. package/dist/{PublishView-DkgfYneI.js → PublishView-D0NnU22l.js} +73 -63
  24. package/dist/{PurchaseOrderPrintPreview-CltLC4o4.js → PurchaseOrderPrintPreview-BmuwNbeL.js} +4 -4
  25. package/dist/{ReceiveRequestView-Dj7ji0DY.js → ReceiveRequestView-j79m7TKk.js} +343 -333
  26. package/dist/RecipeView-D_fNQQ-C.js +636 -0
  27. package/dist/StockView-DX_xeFBT.js +2385 -0
  28. package/dist/SubsidiaryTreeDialog.vue_vue_type_script_setup_true_lang-Bg49isUy.js +172 -0
  29. package/dist/{SupplierView-DE_M_9kd.js → SupplierView-DuFTqbOg.js} +1193 -1073
  30. package/dist/TransferDetails.vue_vue_type_script_setup_true_lang-c428GXwc.js +3233 -0
  31. package/dist/{TransferTemplateView-gWGBCF3u.js → TransferTemplateView-Ccsfcetz.js} +104 -103
  32. package/dist/UnitView-BklpNsFN.js +674 -0
  33. package/dist/WarehouseView-BrURbU67.js +1066 -0
  34. package/dist/api/adjustment-template.d.ts +1 -0
  35. package/dist/api/bill.d.ts +140 -2
  36. package/dist/api/closing-template.d.ts +1 -0
  37. package/dist/api/closing.d.ts +1 -0
  38. package/dist/api/inventory.d.ts +405 -0
  39. package/dist/api/netsuite.d.ts +5 -1
  40. package/dist/api/purchase-order-template.d.ts +1 -0
  41. package/dist/api/purchase-order.d.ts +3 -0
  42. package/dist/api/shipment.d.ts +11 -0
  43. package/dist/api/stock.d.ts +2 -44
  44. package/dist/api/warehouse.d.ts +3 -1
  45. package/dist/{app-CruHLH1e.js → app-a9r50k3U.js} +68551 -67573
  46. package/dist/app.d.ts +643 -15
  47. package/dist/app.js +6 -6
  48. package/dist/components/FmAdminBadge.vue.d.ts +1 -4
  49. package/dist/components/FmEnhancedSelect.vue.d.ts +30 -0
  50. package/dist/components/FmInventoryTableToolbar.vue.d.ts +16 -2
  51. package/dist/components/FmLockableField.vue.d.ts +3 -0
  52. package/dist/components/netsuite/ItemSubsidiaryTreeDialog.vue.d.ts +16 -0
  53. package/dist/components/netsuite/SubsidiaryTreeDialog.vue.d.ts +2 -0
  54. package/dist/composable/defineApi.d.ts +1 -1
  55. package/dist/composable/useIframe.d.ts +2 -2
  56. package/dist/{decimal-izbvCC1j.js → decimal-AusUnA1W.js} +1 -1
  57. package/dist/{format-unit-display-4SAdfyZB.js → format-unit-display-BqkHL-ph.js} +397 -429
  58. package/dist/helper/array.d.ts +1 -0
  59. package/dist/helper/core/country/utils.d.ts +3 -4
  60. package/dist/helper/country.d.ts +6 -255
  61. package/dist/helper/number.d.ts +1 -0
  62. package/dist/import-export.helper-PIyNeHfa.js +238 -0
  63. package/dist/{index-B6GGthLw.js → index-CjxirPvn.js} +283 -268
  64. package/dist/{index-CnQloOEo.js → index-Dj9-pdT9.js} +1 -1
  65. package/dist/layout/SingleColumnLayout.vue.d.ts +6 -3
  66. package/dist/purchase-order-template-CQikvY1p.js +41 -0
  67. package/dist/router/name.d.ts +2 -0
  68. package/dist/stock-CDZ2uWSF.js +83 -0
  69. package/dist/stock-Dw908dIC.js +74 -0
  70. package/dist/stores/feature.d.ts +12 -0
  71. package/dist/stores/integration/netsuite.d.ts +42 -0
  72. package/dist/stores/inventory.d.ts +28 -199
  73. package/dist/stores/location.d.ts +331 -1
  74. package/dist/stores/supplier.d.ts +96 -0
  75. package/dist/stores/warehouse.d.ts +4 -0
  76. package/dist/style.css +1 -1
  77. package/dist/{supplier-CTVE1lHO.js → supplier-BPPBUudN.js} +1 -1
  78. package/dist/tsconfig.app.tsbuildinfo +1 -1
  79. package/dist/{use-ingredient-select-dialog-CM80TfX0.js → use-ingredient-select-dialog-C_fSKN3_.js} +5 -5
  80. package/dist/{use-inventory-binding-dialog-D_omdhgn.js → use-inventory-binding-dialog-ClAkJ864.js} +8 -8
  81. package/dist/views/adjustment-template/wastage-template/actions.d.ts +60 -0
  82. package/dist/views/adjustment-template/wastage-template/table.d.ts +60 -0
  83. package/dist/views/closing-draft/components/closing-draft-dialog/ClosingDraftDialog.vue.d.ts +56 -0
  84. package/dist/views/closing-draft/composables/use-closing-draft-actions.d.ts +3 -3
  85. package/dist/views/closing-draft/composables/use-closing-draft-table.d.ts +468 -0
  86. package/dist/views/closing-draft/helpers/export-draft.helper.d.ts +9 -2
  87. package/dist/views/closing-history/ClosingHistoryView.vue.d.ts +2 -0
  88. package/dist/views/closing-template/composables/use-closing-template-actions.d.ts +4 -1
  89. package/dist/views/closing-template/helpers/import-export.helper.d.ts +5 -0
  90. package/dist/views/import/ImportView.vue.d.ts +3 -0
  91. package/dist/views/import/components/ImportDialog.vue.d.ts +2 -0
  92. package/dist/views/import/helper/import-export.helper.d.ts +4 -0
  93. package/dist/views/ingredients/components/ingredient-dialog/IngredientDialogProps.d.ts +1 -1
  94. package/dist/views/ingredients/components/ingredient-form/IngredientForm.vue.d.ts +181 -12
  95. package/dist/views/ingredients/components/ingredient-form/IngredientFormProps.d.ts +6 -0
  96. package/dist/views/ingredients/helper/import-export.helper.d.ts +4 -1
  97. package/dist/views/integration/components/netsuite/business/BusinessNetSuiteSideSheet.vue.d.ts +2 -0
  98. package/dist/views/receive-request/components/delivery-order-form/CreateForm.vue.d.ts +16 -0
  99. package/dist/views/receive-request/components/delivery-order-form/CreateFormProps.d.ts +4 -0
  100. package/dist/views/receive-request/components/delivery-order-form/EditForm.vue.d.ts +16 -0
  101. package/dist/views/receive-request/components/delivery-order-form/EditFormProps.d.ts +4 -0
  102. package/dist/views/receive-request/components/delivery-order-form/SystemTrailDialog.vue.d.ts +21 -0
  103. package/dist/views/receive-request/components/netsuite/NetSuiteTransactionChangeLog.vue.d.ts +15 -0
  104. package/dist/views/receive-request/components/transfer-details/TransferDetailsProps.d.ts +1 -0
  105. package/dist/views/receive-request/components/transfer-form/TransferForm.vue.d.ts +420 -2
  106. package/dist/views/receive-request/composables/use-process-purchase-order.d.ts +99 -0
  107. package/dist/views/receive-request/composables/use-receive-request-form.d.ts +644 -13
  108. package/dist/views/receive-request/composables/use-receive-request-table.d.ts +711 -14
  109. package/dist/views/recipe/RecipeView.vue.d.ts +1 -0
  110. package/dist/views/recipe/components/import-recipes/ImportRecipeItem.vue.d.ts +16 -0
  111. package/dist/views/recipe/components/import-recipes/ImportRecipes.vue.d.ts +2 -0
  112. package/dist/views/recipe/helper/import-recipe.d.ts +48 -0
  113. package/dist/views/stock/components/StockRecordCard.vue.d.ts +70 -1
  114. package/dist/views/stock/components/dialog/RecalculationDialog.vue.d.ts +11 -0
  115. package/dist/views/stock/components/dialog/RecalculationDialogProps.d.ts +3 -0
  116. package/dist/views/stock/components/dialog/StockAdjustmentSideSheet.vue.d.ts +20 -0
  117. package/dist/views/supplier/components/SupplierForm.vue.d.ts +8 -0
  118. package/dist/views/supplier/components/SupplierSupplyItemField.vue.d.ts +3 -0
  119. package/dist/views/supplier/composables/use-supplier-table.d.ts +4 -0
  120. package/dist/views/transfer-template/components/transfer-template-dialog/TransferTemplateDialog.vue.d.ts +8 -0
  121. package/dist/views/transfer-template/components/transfer-template-form/components/NetSuiteCustomCodeSelection.vue.d.ts +2 -0
  122. package/dist/views/transfer-template/components/transfer-template-form/composables/use-transfer-locations.d.ts +16 -0
  123. package/dist/views/transfer-template/composables/use-transfer-template-actions.d.ts +48 -0
  124. package/dist/views/transfer-template/composables/use-transfer-template-table.d.ts +48 -0
  125. package/dist/views/unit/UnitView.vue.d.ts +1 -0
  126. package/dist/views/unit/components/import-units/ImportUnitItem.vue.d.ts +12 -0
  127. package/dist/views/unit/components/import-units/ImportUnitItemProps.d.ts +6 -0
  128. package/dist/views/unit/components/import-units/ImportUnits.vue.d.ts +9 -0
  129. package/dist/views/unit/components/import-units/ImportUnitsProps.d.ts +5 -0
  130. package/dist/views/unit/helper/import-export.helper.d.ts +40 -0
  131. package/dist/views/warehouse/components/WarehouseForm.vue.d.ts +8 -0
  132. package/package.json +3 -3
  133. package/dist/App-BqaRC0Sb.js +0 -276
  134. package/dist/ClosingDraftView-sJ_zRPeo.js +0 -1687
  135. package/dist/ClosingTemplateView-cNgXHq1r.js +0 -1908
  136. package/dist/FmAdminBadge-oCnz8SW6.js +0 -34
  137. package/dist/FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-BKR8C4p_.js +0 -224
  138. package/dist/IngredientsView-CHHeAJH_.js +0 -1858
  139. package/dist/RecipeView-BukmKdVG.js +0 -621
  140. package/dist/StockForecast.vue_vue_type_style_index_0_lang-KLXSWvo5.js +0 -59
  141. package/dist/StockView-wxRCw_w-.js +0 -2087
  142. package/dist/TransferDetails.vue_vue_type_script_setup_true_lang-eqUOnJoM.js +0 -2336
  143. package/dist/UnitView-BgwDmGZo.js +0 -667
  144. package/dist/WarehouseView-BdccenhO.js +0 -1034
  145. package/dist/array-Ca8T3f_G.js +0 -44
  146. package/dist/helper/core/country/codes.d.ts +0 -255
  147. package/dist/stock-BJP5BB5b.js +0 -146
@@ -1,4 +1,4 @@
1
- import { _ as f } from "./InventoryBindingForm.vue_vue_type_script_setup_true_lang-B7DND2dQ.js";
1
+ import { _ as f } from "./InventoryBindingForm.vue_vue_type_script_setup_true_lang-NDbtbtqK.js";
2
2
  export {
3
3
  f as default
4
4
  };
@@ -1,7 +1,7 @@
1
1
  import { defineComponent as ee, computed as _, reactive as ne, resolveComponent as k, openBlock as r, createElementBlock as p, createVNode as y, withCtx as U, createElementVNode as n, toDisplayString as m, unref as i, createBlock as B, createCommentVNode as v, Fragment as E, renderList as C, nextTick as oe } from "vue";
2
- import { a as te, X as le, b4 as ie, j as h, b5 as N, V as G, T as se, F as de } from "./app-CruHLH1e.js";
3
- import { u as re } from "./use-inventory-binding-dialog-D_omdhgn.js";
4
- import { _ as ae, c as ue, d as me } from "./FmUnitInput.vue_vue_type_script_setup_true_lang-C-2V2bGc.js";
2
+ import { a as te, a3 as le, bd as ie, n as h, be as T, a1 as G, a0 as se, F as de } from "./app-a9r50k3U.js";
3
+ import { u as re } from "./use-inventory-binding-dialog-ClAkJ864.js";
4
+ import { _ as ae, c as ue, d as me } from "./FmUnitInput.vue_vue_type_script_setup_true_lang-DwqVRUFz.js";
5
5
  import { useI18n as ce } from "@feedmepos/mf-common";
6
6
  const pe = { class: "flex flex-col gap-24" }, ye = { class: "flex flex-col gap-16" }, fe = { class: "flex items-center" }, ve = { class: "flex-1 fm-typo-en-title-sm-600" }, be = { class: "flex flex-col" }, ge = { class: "flex py-8 px-12 border-b border-fm-color-neutral-gray-200 bg-fm-color-neutral-gray-100 h-[44px] items-center" }, _e = { class: "fm-typo-en-body-md-600 text-fm-color-typo-secondary" }, xe = { class: "flex flex-col w-full border-b border-fm-color-neutral-gray-100" }, he = {
7
7
  class: "flex items-center",
@@ -21,16 +21,16 @@ const pe = { class: "flex flex-col gap-24" }, ye = { class: "flex flex-col gap-1
21
21
  }, Pe = {
22
22
  class: "flex items-center",
23
23
  style: { "min-height": "48px" }
24
- }, Te = { class: "flex-1 fm-typo-en-body-md-400 py-8 px-12" }, Ne = { class: "flex flex-col" }, Me = { class: "w-[200px]" }, De = {
24
+ }, Ne = { class: "flex-1 fm-typo-en-body-md-400 py-8 px-12" }, Te = { class: "flex flex-col" }, Me = { class: "w-[200px]" }, De = {
25
25
  key: 0,
26
26
  class: "w-[52px]"
27
27
  }, Ke = { class: "flex flex-col gap-16" }, $e = { class: "flex items-center" }, je = { class: "flex-1 fm-typo-en-title-sm-600" }, ze = { class: "flex flex-col" }, Le = { class: "flex py-8 px-12 border-b border-fm-color-neutral-gray-200 bg-fm-color-neutral-gray-100 h-[44px] items-center" }, Oe = { class: "flex-1 fm-typo-en-body-md-600 text-fm-color-typo-secondary" }, Ye = { class: "fm-typo-en-body-md-600 text-fm-color-typo-secondary w-[150px] px-16" }, We = {
28
28
  class: "flex items-center w-full",
29
29
  style: { "min-height": "48px" }
30
- }, Xe = { class: "flex-1 fm-typo-en-body-md-400 py-8 px-12" }, qe = { class: "line-clamp-1" }, He = { class: "w-[150px]" }, Je = {
30
+ }, qe = { class: "flex-1 fm-typo-en-body-md-400 py-8 px-12" }, He = { class: "line-clamp-1" }, Je = { class: "w-[150px]" }, Qe = {
31
31
  key: 0,
32
32
  class: "w-[52px]"
33
- }, Qe = { class: "flex flex-col px-12 pb-4" }, ln = /* @__PURE__ */ ee({
33
+ }, Xe = { class: "flex flex-col px-12 pb-4" }, ln = /* @__PURE__ */ ee({
34
34
  __name: "InventoryBindingForm",
35
35
  props: {
36
36
  id: {},
@@ -76,7 +76,7 @@ const pe = { class: "flex flex-col gap-24" }, ye = { class: "flex flex-col gap-1
76
76
  );
77
77
  }
78
78
  const W = _(() => s.modelValue.filter((e) => e.type === "SKU_GROUP"));
79
- async function X() {
79
+ async function q() {
80
80
  O(
81
81
  s.modelValue,
82
82
  (e) => b("update:modelValue", e),
@@ -84,7 +84,7 @@ const pe = { class: "flex flex-col gap-24" }, ye = { class: "flex flex-col gap-1
84
84
  );
85
85
  }
86
86
  const R = _(() => s.modelValue.filter((e) => e.type === "SKU") ?? []);
87
- async function q() {
87
+ async function H() {
88
88
  if (s.iframeMode) {
89
89
  b("click:pick-inventory-bindings", "SKU");
90
90
  return;
@@ -113,10 +113,10 @@ const pe = { class: "flex flex-col gap-24" }, ye = { class: "flex flex-col gap-1
113
113
  throw new Error(`Cannot find ingredient: ${e.id}`);
114
114
  return (d = I.value[e.id]) == null ? void 0 : d.unit;
115
115
  }
116
- function H(e) {
116
+ function J(e) {
117
117
  return { amount: e.amount, measurement: e.measurement };
118
118
  }
119
- function J(e, t, o) {
119
+ function Q(e, t, o) {
120
120
  const d = o.map((f) => f.id !== e ? f : {
121
121
  ...f,
122
122
  amount: t.amount,
@@ -124,9 +124,9 @@ const pe = { class: "flex flex-col gap-24" }, ye = { class: "flex flex-col gap-1
124
124
  });
125
125
  b("update:modelValue", d);
126
126
  }
127
- const T = ne({});
128
- function Q(e) {
129
- return T[e.id] ?? {
127
+ const N = ne({});
128
+ function X(e) {
129
+ return N[e.id] ?? {
130
130
  modelValue: {
131
131
  amount: e.amount,
132
132
  measurement: e.measurement
@@ -136,7 +136,7 @@ const pe = { class: "flex flex-col gap-24" }, ye = { class: "flex flex-col gap-1
136
136
  }
137
137
  function Z(e, t) {
138
138
  oe(() => {
139
- T[e.id] = {
139
+ N[e.id] = {
140
140
  modelValue: {
141
141
  amount: e.amount,
142
142
  measurement: e.measurement
@@ -184,7 +184,7 @@ const pe = { class: "flex flex-col gap-24" }, ye = { class: "flex flex-col gap-1
184
184
  key: l.id,
185
185
  disabled: e.disabled,
186
186
  modelValue: +i(h)(l.amount ?? { amount: 1, precision: 0 }),
187
- rules: [i(N)(0), i(G)(0)]
187
+ rules: [i(T)(0), i(G)(0)]
188
188
  }, {
189
189
  default: U(({ invalid: V }) => {
190
190
  var g;
@@ -239,7 +239,7 @@ const pe = { class: "flex flex-col gap-24" }, ye = { class: "flex flex-col gap-1
239
239
  "border-color": "primary",
240
240
  label: i(a)("inventory.inventoryBindings.linkIngredientGroup"),
241
241
  "prepend-icon": "link",
242
- onClick: X
242
+ onClick: q
243
243
  }, null, 8, ["label"]))
244
244
  ]),
245
245
  n("div", Ce, [
@@ -252,7 +252,7 @@ const pe = { class: "flex flex-col gap-24" }, ye = { class: "flex flex-col gap-1
252
252
  key: l.id,
253
253
  disabled: e.disabled,
254
254
  modelValue: +i(h)(l.amount ?? { amount: 1, precision: 0 }),
255
- rules: [i(N)(0), i(G)(0)]
255
+ rules: [i(T)(0), i(G)(0)]
256
256
  }, {
257
257
  default: U(({ invalid: V }) => {
258
258
  var g;
@@ -267,8 +267,8 @@ const pe = { class: "flex flex-col gap-24" }, ye = { class: "flex flex-col gap-1
267
267
  n("div", null, m(i(a)("inventory.inventoryBindings.circularError")), 1)
268
268
  ])) : v("", !0),
269
269
  n("div", Pe, [
270
- n("div", Te, [
271
- n("div", Ne, m((g = $.value[l.id]) == null ? void 0 : g.name), 1)
270
+ n("div", Ne, [
271
+ n("div", Te, m((g = $.value[l.id]) == null ? void 0 : g.name), 1)
272
272
  ]),
273
273
  n("div", Me, [
274
274
  y(f, {
@@ -307,7 +307,7 @@ const pe = { class: "flex flex-col gap-24" }, ye = { class: "flex flex-col gap-1
307
307
  "border-color": "primary",
308
308
  label: i(a)("inventory.inventoryBindings.linkIngredient"),
309
309
  "prepend-icon": "link",
310
- onClick: q
310
+ onClick: H
311
311
  }, null, 8, ["label"]))
312
312
  ]),
313
313
  n("div", ze, [
@@ -323,13 +323,13 @@ const pe = { class: "flex flex-col gap-24" }, ye = { class: "flex flex-col gap-1
323
323
  class: "flex flex-col border-b border-fm-color-neutral-gray-100"
324
324
  }, [
325
325
  n("div", We, [
326
- n("div", Xe, [
327
- n("span", qe, m((g = I.value[l.id]) == null ? void 0 : g.name), 1)
326
+ n("div", qe, [
327
+ n("span", He, m((g = I.value[l.id]) == null ? void 0 : g.name), 1)
328
328
  ]),
329
- n("div", He, [
329
+ n("div", Je, [
330
330
  y(ae, {
331
- "model-value": H(l),
332
- "onUpdate:modelValue": (c) => c && J(l.id, c, e.modelValue),
331
+ "model-value": J(l),
332
+ "onUpdate:modelValue": (c) => c && Q(l.id, c, e.modelValue),
333
333
  "onUpdate:amount": (c) => Z(l, c),
334
334
  unit: P(l),
335
335
  placement: V === R.value.length - 1 ? "top" : "bottom",
@@ -337,7 +337,7 @@ const pe = { class: "flex flex-col gap-24" }, ye = { class: "flex flex-col gap-1
337
337
  disabled: e.readonly
338
338
  }, null, 8, ["model-value", "onUpdate:modelValue", "onUpdate:amount", "unit", "placement", "disabled"])
339
339
  ]),
340
- e.readonly ? v("", !0) : (r(), p("div", Je, [
340
+ e.readonly ? v("", !0) : (r(), p("div", Qe, [
341
341
  y(d, {
342
342
  disabled: e.disabled,
343
343
  type: "button",
@@ -347,13 +347,13 @@ const pe = { class: "flex flex-col gap-24" }, ye = { class: "flex flex-col gap-1
347
347
  }, null, 8, ["disabled", "onClick"])
348
348
  ]))
349
349
  ]),
350
- n("div", Qe, [
350
+ n("div", Xe, [
351
351
  y(o, {
352
352
  modelValue: +i(h)(l.amount ?? { amount: 1, precision: 0 }),
353
353
  rules: [i(G)(0)]
354
354
  }, null, 8, ["modelValue", "rules"]),
355
355
  y(o, {
356
- modelValue: Q(l),
356
+ modelValue: X(l),
357
357
  rules: [
358
358
  i(ue)(),
359
359
  i(me)(P(l)),
@@ -1,7 +1,7 @@
1
1
  import { defineComponent as l, resolveComponent as m, openBlock as c, createBlock as d, h as g } from "vue";
2
2
  import { useI18n as p } from "@feedmepos/mf-common";
3
3
  import { components as u } from "@feedmepos/ui-library";
4
- import { F as r } from "./app-CruHLH1e.js";
4
+ import { F as r } from "./app-a9r50k3U.js";
5
5
  const w = /* @__PURE__ */ l({
6
6
  __name: "InventoryBindingSummary",
7
7
  props: {
@@ -1,6 +1,6 @@
1
1
  import { defineComponent as V, computed as w, ref as h, watch as u, resolveComponent as i, openBlock as F, createBlock as g, withCtx as d, createVNode as A, createElementVNode as k, normalizeClass as K } from "vue";
2
- import { T as s } from "./app-CruHLH1e.js";
3
- const T = ["value", "disabled"], B = /* @__PURE__ */ V({
2
+ import { a0 as s } from "./app-a9r50k3U.js";
3
+ const _ = ["value", "disabled"], C = /* @__PURE__ */ V({
4
4
  __name: "NumberPrecisionInput",
5
5
  props: {
6
6
  modelValue: {},
@@ -57,7 +57,7 @@ const T = ["value", "disabled"], B = /* @__PURE__ */ V({
57
57
  "text-fm-color-typo-disabled": e.disabled
58
58
  }),
59
59
  disabled: e.disabled
60
- }, null, 42, T)
60
+ }, null, 42, _)
61
61
  ]),
62
62
  _: 2
63
63
  }, 1032, ["invalid"])
@@ -68,5 +68,5 @@ const T = ["value", "disabled"], B = /* @__PURE__ */ V({
68
68
  }
69
69
  });
70
70
  export {
71
- B as _
71
+ C as _
72
72
  };
@@ -1,17 +1,17 @@
1
- import { aH as u, aI as _, a3 as h, u as F } from "./app-CruHLH1e.js";
1
+ import { aR as u, aS as _, aa as h, u as F } from "./app-a9r50k3U.js";
2
2
  import { useCoreStore as y } from "@feedmepos/mf-common";
3
- import { ref as v, defineComponent as k, resolveComponent as l, openBlock as g, createElementBlock as S, renderSlot as x, createVNode as m, withCtx as I } from "vue";
4
- function O(e, t) {
3
+ import { ref as v, defineComponent as k, resolveComponent as l, openBlock as g, createElementBlock as S, renderSlot as x, createVNode as m, withCtx as O } from "vue";
4
+ function w(e, t) {
5
5
  return t.map((r) => typeof r.selector == "function" ? r.selector(e) : e[r.selector]);
6
6
  }
7
- function w(e, t) {
8
- const r = t.map((o) => o.name), n = e.map((o) => O(o, t));
7
+ function I(e, t) {
8
+ const r = t.map((o) => o.name), n = e.map((o) => w(o, t));
9
9
  return u.aoa_to_sheet([r, ...n]);
10
10
  }
11
11
  async function C(e, t) {
12
12
  const r = u.book_new();
13
13
  for (const n of e) {
14
- const o = w(
14
+ const o = I(
15
15
  n.data,
16
16
  n.columns.map((a) => typeof a == "string" ? {
17
17
  name: a,
@@ -98,7 +98,7 @@ const b = { class: "flex items-center gap-8" }, B = "Experience enhanced invento
98
98
  content: B,
99
99
  "z-index": t.zIndex
100
100
  }, {
101
- default: I(() => [
101
+ default: O(() => [
102
102
  m(n, { variant: "premium" })
103
103
  ]),
104
104
  _: 1
@@ -1,10 +1,20 @@
1
- import { defineComponent as Q, ref as z, computed as r, resolveComponent as s, openBlock as B, createBlock as I, unref as v, createSlots as X, withCtx as c, createElementVNode as h, normalizeClass as Z, createVNode as n, normalizeStyle as ee, Teleport as te, h as f } from "vue";
2
- import { aB as oe, u as ne, a as ae, a$ as se, B as le, _ as ie, a4 as H } from "./app-CruHLH1e.js";
3
- import { useBreakpoints as re, useDialog as ce, useSnackbar as ue, components as R } from "@feedmepos/ui-library";
4
- const me = { class: "flex flex-col py-8" }, pe = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, de = { class: "fm-typo-en-body-lg-600 text-fm-color-typo-primary" }, fe = /* @__PURE__ */ Q({
1
+ import { defineComponent as Q, ref as D, computed as c, watch as X, resolveComponent as l, openBlock as W, createBlock as z, unref as h, createSlots as Z, withCtx as u, createElementVNode as f, normalizeClass as ee, createVNode as a, normalizeStyle as te, Teleport as oe, h as g } from "vue";
2
+ import { aM as ne, u as ae, a as se, b7 as le, G as ie, I as re, ab as B } from "./app-a9r50k3U.js";
3
+ import { useBreakpoints as ce, useDialog as ue, useSnackbar as me, components as H } from "@feedmepos/ui-library";
4
+ const pe = { class: "flex flex-col py-8" }, de = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, ye = { class: "fm-typo-en-body-lg-600 text-fm-color-typo-primary" }, ge = /* @__PURE__ */ Q({
5
5
  __name: "PublishView",
6
- setup(ye) {
7
- const { t } = oe(), { breakpoints: x } = re(), l = ne(), A = ae(), S = se(), g = z(!1), u = r(() => A.state.inventory.updatedAt ? A.state.inventory.updatedAt : null), Y = le(), C = ce(), $ = ue(), N = r(() => l.locations), _ = r(() => x.value.xs || x.value.sm), U = r(() => _.value ? 10 : 20), q = r(() => [
6
+ setup(be) {
7
+ const { t } = ne(), { breakpoints: x } = ce(), n = ae(), A = se(), S = le(), i = D(!1), m = c(() => A.state.inventory.updatedAt ? A.state.inventory.updatedAt : null), R = ie(), I = ue(), Y = me(), N = c(() => n.locationsWithInventory), _ = c(() => x.value.xs || x.value.sm), $ = c(() => _.value ? 10 : 20);
8
+ X(
9
+ () => n._locations,
10
+ async () => {
11
+ var e;
12
+ i.value = !0, (!n._locationWithInventory || ((e = n._locationWithInventory) == null ? void 0 : e.length) === 0) && await n.readLocationsWithInventory(), i.value = !1;
13
+ },
14
+ { immediate: !0 }
15
+ // Optional: triggers the watcher immediately on mount
16
+ );
17
+ const U = c(() => [
8
18
  {
9
19
  label: t("inventory.common.refresh"),
10
20
  value: "refresh",
@@ -12,42 +22,42 @@ const me = { class: "flex flex-col py-8" }, pe = { class: "fm-typo-en-body-md-40
12
22
  },
13
23
  { label: t("inventory.publish.actions.publishAll"), value: "publish", isPrimary: !0 }
14
24
  ]);
15
- async function E(e) {
25
+ async function q(e) {
16
26
  switch (e) {
17
27
  case "publish":
18
- C.open({
28
+ I.open({
19
29
  title: t("inventory.common.publish"),
20
30
  message: "Are you sure you want to publish to all locations?",
21
31
  primaryActions: { text: t("inventory.common.publish"), close: !0 },
22
32
  secondaryActions: { text: "Cancel", close: !0 }
23
33
  }).onPrimary(async () => {
24
- await S.publishAllInventory(), await l.readLocations();
34
+ await S.publishAllInventory(), await n.readLocationsWithInventory();
25
35
  });
26
36
  break;
27
37
  case "refresh":
28
- g.value = !0, await l.readLocations(), g.value = !1;
38
+ i.value = !0, await n.readLocationsWithInventory(), i.value = !1;
29
39
  break;
30
40
  }
31
41
  }
32
- const w = z(!1), K = [
42
+ const w = D(!1), E = [
33
43
  {
34
44
  value: "publish",
35
45
  label: t("inventory.publish.actions.publishAll")
36
46
  }
37
47
  ];
38
- function W(e) {
48
+ function G(e) {
39
49
  switch (w.value = !1, e) {
40
50
  case "publish":
41
51
  console.log("publish all");
42
52
  }
43
53
  }
44
- const j = [
54
+ const K = [
45
55
  {
46
56
  id: "type",
47
57
  header: () => t("inventory.publish.columns.type"),
48
58
  enableSorting: !0,
49
59
  cell(e) {
50
- return f(R.FmChip, {
60
+ return g(H.FmChip, {
51
61
  color: "primary",
52
62
  label: e.row.original.type
53
63
  });
@@ -64,8 +74,8 @@ const me = { class: "flex flex-col py-8" }, pe = { class: "fm-typo-en-body-md-40
64
74
  header: () => t("inventory.publish.columns.version"),
65
75
  enableSorting: !0,
66
76
  cell(e) {
67
- var o, a;
68
- return (o = e.row.original.inventory) != null && o.updatedAt ? H((a = e.row.original.inventory) == null ? void 0 : a.updatedAt) : "";
77
+ var o, s;
78
+ return (o = e.row.original.inventory) != null && o.updatedAt ? B((s = e.row.original.inventory) == null ? void 0 : s.updatedAt) : "";
69
79
  }
70
80
  },
71
81
  {
@@ -73,17 +83,17 @@ const me = { class: "flex flex-col py-8" }, pe = { class: "fm-typo-en-body-md-40
73
83
  header: () => t("inventory.publish.columns.status"),
74
84
  enableSorting: !0,
75
85
  cell(e) {
76
- var p;
77
- if (!u.value)
86
+ var d;
87
+ if (!m.value)
78
88
  return "";
79
- const o = ((p = e.row.original.inventory) == null ? void 0 : p.updatedAt) == u.value, a = e.row.original.dbName, m = e.row.original.type === "warehouse";
80
- return f(
89
+ const o = ((d = e.row.original.inventory) == null ? void 0 : d.updatedAt) == m.value, s = e.row.original.dbName, p = e.row.original.type === "warehouse";
90
+ return g(
81
91
  "div",
82
92
  {
83
93
  class: "flex items-center gap-8"
84
94
  },
85
95
  [
86
- f(
96
+ g(
87
97
  "div",
88
98
  {
89
99
  class: [
@@ -93,18 +103,18 @@ const me = { class: "flex flex-col py-8" }, pe = { class: "fm-typo-en-body-md-40
93
103
  },
94
104
  t(o ? "inventory.publish.status.published" : "inventory.publish.status.outdated")
95
105
  ),
96
- !o && !m ? f(R.FmButton, {
106
+ !o && !p ? g(H.FmButton, {
97
107
  class: "tertiary",
98
108
  variant: "secondary",
99
109
  icon: "sync",
100
110
  onClick: () => {
101
- C.open({
111
+ I.open({
102
112
  title: t("inventory.common.publish"),
103
113
  message: `Are you sure you want to publish this location "${e.row.original.name}"?`,
104
114
  primaryActions: { text: t("inventory.common.publish"), close: !0 },
105
115
  secondaryActions: { text: "Cancel", close: !0 }
106
116
  }).onPrimary(async () => {
107
- await S.publishInventory(a.split("_")[1]), await l.readLocations(), $.open({ message: "Publish request submitted", type: "success" });
117
+ await S.publishInventory(s.split("_")[1]), await n.readLocations(), Y.open({ message: "Publish request submitted", type: "success" });
108
118
  });
109
119
  }
110
120
  }) : null
@@ -132,15 +142,15 @@ const me = { class: "flex flex-col py-8" }, pe = { class: "fm-typo-en-body-md-40
132
142
  // }
133
143
  ];
134
144
  return (e, o) => {
135
- const a = s("FmChip"), m = s("FlexRender"), p = s("TableActionableRow"), G = s("FmTable"), J = s("FmCollapsibleTabs"), O = s("FmBottomSheet");
136
- return B(), I(ie, {
137
- title: v(t)("inventory.publish.title"),
138
- actions: q.value,
139
- "onClick:action": E
140
- }, X({
141
- default: c(() => [
142
- h("div", {
143
- class: Z([
145
+ const s = l("FmChip"), p = l("FlexRender"), d = l("TableActionableRow"), j = l("FmTable"), J = l("FmCollapsibleTabs"), O = l("FmBottomSheet");
146
+ return W(), z(re, {
147
+ title: h(t)("inventory.publish.title"),
148
+ actions: U.value,
149
+ "onClick:action": q
150
+ }, Z({
151
+ default: u(() => [
152
+ f("div", {
153
+ class: ee([
144
154
  "flex flex-col gap-8 max-h-full",
145
155
  {
146
156
  "p-0": _.value,
@@ -148,30 +158,30 @@ const me = { class: "flex flex-col py-8" }, pe = { class: "fm-typo-en-body-md-40
148
158
  }
149
159
  ])
150
160
  }, [
151
- n(G, {
152
- style: ee(v(Y).tableHeight),
153
- "column-defs": j,
161
+ a(j, {
162
+ style: te(h(R).tableHeight),
163
+ "column-defs": K,
154
164
  "row-data": N.value,
155
- loading: !v(l)._currentLocation || g.value,
165
+ loading: !h(n)._currentLocation || i.value,
156
166
  "loading-text": "Loading",
157
- "page-size": U.value
167
+ "page-size": $.value
158
168
  }, {
159
- "list-row": c((i) => [
160
- n(p, { row: i }, {
161
- default: c((d) => {
162
- var F, k, M, y, P, L, T, V, b, D;
169
+ "list-row": u((r) => [
170
+ a(d, { row: r }, {
171
+ default: u((y) => {
172
+ var C, F, k, b, M, L, P, T, v, V;
163
173
  return [
164
- h("div", me, [
165
- h("div", pe, [
166
- n(m, {
167
- render: (M = (k = (F = d.code) == null ? void 0 : F.column) == null ? void 0 : k.columnDef) == null ? void 0 : M.cell,
168
- props: (P = (y = d.code) == null ? void 0 : y.getContext) == null ? void 0 : P.call(y)
174
+ f("div", pe, [
175
+ f("div", de, [
176
+ a(p, {
177
+ render: (k = (F = (C = y.code) == null ? void 0 : C.column) == null ? void 0 : F.columnDef) == null ? void 0 : k.cell,
178
+ props: (M = (b = y.code) == null ? void 0 : b.getContext) == null ? void 0 : M.call(b)
169
179
  }, null, 8, ["render", "props"])
170
180
  ]),
171
- h("div", de, [
172
- n(m, {
173
- render: (V = (T = (L = d.name) == null ? void 0 : L.column) == null ? void 0 : T.columnDef) == null ? void 0 : V.cell,
174
- props: (D = (b = d.name) == null ? void 0 : b.getContext) == null ? void 0 : D.call(b)
181
+ f("div", ye, [
182
+ a(p, {
183
+ render: (T = (P = (L = y.name) == null ? void 0 : L.column) == null ? void 0 : P.columnDef) == null ? void 0 : T.cell,
184
+ props: (V = (v = y.name) == null ? void 0 : v.getContext) == null ? void 0 : V.call(v)
175
185
  }, null, 8, ["render", "props"])
176
186
  ])
177
187
  ])
@@ -183,17 +193,17 @@ const me = { class: "flex flex-col py-8" }, pe = { class: "fm-typo-en-body-md-40
183
193
  _: 1
184
194
  }, 8, ["style", "row-data", "loading", "page-size"])
185
195
  ], 2),
186
- (B(), I(te, { to: "body" }, [
187
- n(O, {
196
+ (W(), z(oe, { to: "body" }, [
197
+ a(O, {
188
198
  "dismiss-away": "",
189
199
  modelValue: w.value,
190
- "onUpdate:modelValue": o[1] || (o[1] = (i) => w.value = i)
200
+ "onUpdate:modelValue": o[1] || (o[1] = (r) => w.value = r)
191
201
  }, {
192
- default: c(() => [
193
- n(J, {
202
+ default: u(() => [
203
+ a(J, {
194
204
  class: "pb-8",
195
- items: K,
196
- "onUpdate:modelValue": o[0] || (o[0] = (i) => W(i))
205
+ items: E,
206
+ "onUpdate:modelValue": o[0] || (o[0] = (r) => G(r))
197
207
  })
198
208
  ]),
199
209
  _: 1
@@ -202,12 +212,12 @@ const me = { class: "flex flex-col py-8" }, pe = { class: "fm-typo-en-body-md-40
202
212
  ]),
203
213
  _: 2
204
214
  }, [
205
- u.value ? {
215
+ m.value ? {
206
216
  name: "headerInfo",
207
- fn: c(() => [
208
- n(a, {
217
+ fn: u(() => [
218
+ a(s, {
209
219
  variant: "info",
210
- label: `Latest: ${v(H)(u.value)}`
220
+ label: `Latest: ${h(B)(m.value)}`
211
221
  }, null, 8, ["label"])
212
222
  ]),
213
223
  key: "0"
@@ -217,5 +227,5 @@ const me = { class: "flex flex-col py-8" }, pe = { class: "fm-typo-en-body-md-40
217
227
  }
218
228
  });
219
229
  export {
220
- fe as default
230
+ ge as default
221
231
  };
@@ -1,7 +1,7 @@
1
1
  import { defineComponent as b, computed as m, ref as x, onMounted as f, openBlock as u, createElementBlock as n, createElementVNode as t, toDisplayString as e, normalizeStyle as g, createTextVNode as i, Fragment as o, createCommentVNode as p, renderList as v } from "vue";
2
2
  import { useRoute as w } from "vue-router";
3
- import { aA as y, ao as k } from "./app-CruHLH1e.js";
4
- const A = { class: "purchase-box" }, C = { valign: "bottom" }, R = { class: "title" }, N = { class: "text-right" }, O = { class: "header" }, P = { class: "sub-header" }, D = { class: "caption" }, E = { class: "address" }, S = { class: "text-right" }, T = { class: "sub-header" }, F = { class: "address" }, q = { class: "purchase-body" }, L = { class: "text-left" }, U = { class: "text-left" }, V = { class: "text-right" }, B = { class: "text-right" }, H = { class: "text-right" }, I = { style: { "padding-top": "30px" } }, M = { valign: "bottom" }, z = { class: "header" }, J = { class: "caption" }, Q = {
3
+ import { aL as y, aw as k } from "./app-a9r50k3U.js";
4
+ const A = { class: "purchase-box" }, C = { valign: "bottom" }, R = { class: "title" }, N = { class: "text-right" }, O = { class: "header" }, P = { class: "sub-header" }, D = { class: "caption" }, E = { class: "address" }, S = { class: "text-right" }, T = { class: "sub-header" }, F = { class: "address" }, L = { class: "purchase-body" }, q = { class: "text-left" }, U = { class: "text-left" }, V = { class: "text-right" }, B = { class: "text-right" }, H = { class: "text-right" }, I = { style: { "padding-top": "30px" } }, M = { valign: "bottom" }, z = { class: "header" }, J = { class: "caption" }, Q = {
5
5
  class: "text-left",
6
6
  style: { width: "20%" }
7
7
  }, j = { class: "text-left" }, G = {
@@ -79,7 +79,7 @@ const A = { class: "purchase-box" }, C = { valign: "bottom" }, R = { class: "tit
79
79
  ])
80
80
  ])
81
81
  ]),
82
- t("div", q, [
82
+ t("div", L, [
83
83
  t("table", null, [
84
84
  l[10] || (l[10] = t("thead", { class: "item-header" }, [
85
85
  t("tr", null, [
@@ -104,7 +104,7 @@ const A = { class: "purchase-box" }, C = { valign: "bottom" }, R = { class: "tit
104
104
  ], -1)),
105
105
  t("tbody", null, [
106
106
  (u(!0), n(o, null, v(s.value.items, (r, a) => (u(), n("tr", { key: a }, [
107
- t("td", L, e(r.code), 1),
107
+ t("td", q, e(r.code), 1),
108
108
  t("td", U, e(r.description), 1),
109
109
  t("td", V, e(r.quantity), 1),
110
110
  t("td", B, e(r.unit), 1),