@feedmepos/mf-inventory-portal 1.2.50-dev.2 → 1.2.50

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 (90) hide show
  1. package/dist/{App-DAO7XF9h.js → App-DssF0b6P.js} +68 -72
  2. package/dist/{ApprovalView-BUHefc15.js → ApprovalView-DTCayLqE.js} +34 -34
  3. package/dist/{BindingsDialog-Cx9ngX7X.js → BindingsDialog-C2-THIG0.js} +2 -2
  4. package/dist/{BindingsPicker-CIZ9FVgv.js → BindingsPicker-Q9W92GzO.js} +2 -2
  5. package/dist/{BindingsTable-CMyZkvyn.js → BindingsTable-BQo8HpbF.js} +4 -4
  6. package/dist/{ClosingDraftView-D4CMfSvf.js → ClosingDraftView-B0spMbZd.js} +18 -19
  7. package/dist/{ClosingHistoryView-J_2EA-F4.js → ClosingHistoryView-DDVibMzL.js} +3 -3
  8. package/dist/{ClosingTemplateView-Bz21bJLn.js → ClosingTemplateView-BSiNTpkH.js} +17 -18
  9. package/dist/{DeliveryOrderPrintPreview-D9xRJSBT.js → DeliveryOrderPrintPreview-P9JASYcM.js} +1 -1
  10. package/dist/{FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-ifkxhq6-.js → FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-DkvLYf5A.js} +4 -4
  11. package/dist/{FmInventoryTableToolbar.vue_vue_type_script_setup_true_lang-BcJ1ydJ1.js → FmInventoryTableToolbar.vue_vue_type_script_setup_true_lang-CaQq9jpc.js} +12 -12
  12. package/dist/FmMultiselectDialog-BgLyRNeD.js +598 -0
  13. package/dist/{FmMultiselectDialog-Cxj6_Bbq.js → FmMultiselectDialog-DKEGwdyz.js} +1 -1
  14. package/dist/{FmUnitInput.vue_vue_type_script_setup_true_lang-CJsg-6qm.js → FmUnitInput.vue_vue_type_script_setup_true_lang-H5xYFc6B.js} +3 -3
  15. package/dist/{ImportView-mq9p_YKN.js → ImportView-CKg0Z3Bz.js} +7 -7
  16. package/dist/{IngredientBindedItem.vue_vue_type_script_setup_true_lang-CvdNblLJ.js → IngredientBindedItem.vue_vue_type_script_setup_true_lang-y1qeqeUV.js} +1 -1
  17. package/dist/{IngredientGroupView-1YQdweWW.js → IngredientGroupView-DntDNlVX.js} +107 -108
  18. package/dist/{IngredientsView-rZZDO37M.js → IngredientsView-B93tavZW.js} +125 -126
  19. package/dist/{IntegrationView-0KCNTL9w.js → IntegrationView-CqEe7SWR.js} +80 -80
  20. package/dist/{InventoryBindingForm-Cz6tMVlQ.js → InventoryBindingForm-9E3VsD4v.js} +1 -1
  21. package/dist/{InventoryBindingForm.vue_vue_type_script_setup_true_lang-9jHxMOEn.js → InventoryBindingForm.vue_vue_type_script_setup_true_lang-Dgy_eFxJ.js} +4 -4
  22. package/dist/{InventoryBindingSummary-DarjH7Dn.js → InventoryBindingSummary-DTcoWk_n.js} +1 -1
  23. package/dist/{NumberPrecisionInput.vue_vue_type_script_setup_true_lang-BR6U0SpT.js → NumberPrecisionInput.vue_vue_type_script_setup_true_lang-CIDw4WOz.js} +1 -1
  24. package/dist/{PremiumBadge.vue_vue_type_script_setup_true_lang-C9ffyR0d.js → PremiumBadge.vue_vue_type_script_setup_true_lang-Dao7XifY.js} +2 -2
  25. package/dist/{PublishView-Bam4W7ko.js → PublishView-GDJsOfeY.js} +3 -3
  26. package/dist/{PurchaseOrderPrintPreview-DEKkUMB6.js → PurchaseOrderPrintPreview-DFeZT5Zi.js} +1 -1
  27. package/dist/ReceiveRequestView-BvYpGKEB.js +2913 -0
  28. package/dist/{RecipeView-CwwKtDRg.js → RecipeView-DyJs2lsk.js} +82 -83
  29. package/dist/{StockView-CVN5MKbj.js → StockView-Cvwfcsf7.js} +112 -113
  30. package/dist/{SubsidiaryTreeDialog.vue_vue_type_script_setup_true_lang-Bm1MxmBR.js → SubsidiaryTreeDialog.vue_vue_type_script_setup_true_lang-CMFiW6FL.js} +1 -1
  31. package/dist/{SupplierView-BhnmPv7N.js → SupplierView-C6rIxQOg.js} +27 -28
  32. package/dist/{SystemTrailDialog.vue_vue_type_script_setup_true_lang-DdPVsOZY.js → SystemTrailDialog.vue_vue_type_script_setup_true_lang-6C5vAumx.js} +2 -2
  33. package/dist/TableActionableRow.vue_vue_type_script_setup_true_lang-cfFHDIwQ.js +162 -0
  34. package/dist/{TemplatePublishDialog.vue_vue_type_script_setup_true_lang-Bp49G_dV.js → TemplatePublishDialog.vue_vue_type_script_setup_true_lang-Bc0MVyK_.js} +13 -13
  35. package/dist/{TransferDetails.vue_vue_type_script_setup_true_lang-BQFBZ0CH.js → TransferDetails.vue_vue_type_script_setup_true_lang-BSNIRZx3.js} +15 -15
  36. package/dist/{TransferTemplateView-7AJGTAAy.js → TransferTemplateView-BVRXLZGK.js} +16 -16
  37. package/dist/{UnitView-Dz4bgzmW.js → UnitView-B9n1vDtN.js} +19 -20
  38. package/dist/{WarehouseView-DEYOa_Ol.js → WarehouseView-oyEVpI9M.js} +20 -21
  39. package/dist/{WastageTemplateView-DdPkFfyQ.js → WastageTemplateView-DCdR4fhu.js} +164 -165
  40. package/dist/api/netsuite.d.ts +0 -8
  41. package/dist/{app-kim0oKgm.js → app-_hCz0958.js} +4408 -4511
  42. package/dist/app-uBuHtW8m.js +8127 -0
  43. package/dist/app.d.ts +0 -52
  44. package/dist/app.js +1 -1
  45. package/dist/{closing-template-MLHUWgwA.js → closing-template-y0kvKjaN.js} +1 -1
  46. package/dist/components/FmInventoryTableToolbar.vue.d.ts +0 -8
  47. package/dist/components/FmMultiselectDialogProps.d.ts +0 -5
  48. package/dist/{date2-Ck1fxOS1.js → date2-Ct3mwV73.js} +1 -1
  49. package/dist/{dayjs.min-CgHxLw1P.js → dayjs.min-iDh15Qvq.js} +1 -1
  50. package/dist/{decimal-DVjzMCmx.js → decimal-DliTT0vp.js} +2 -2
  51. package/dist/{defineDeepModel-CLo1ie3w.js → defineDeepModel-DmVg-VGa.js} +1 -1
  52. package/dist/{duplicate-template-B_f_fYhs.js → duplicate-template-BO8LvPWq.js} +1 -1
  53. package/dist/{feature-D4HcMaGK.js → feature-Dk3_0hiC.js} +2810 -3440
  54. package/dist/{format-time-from-id-CwtHJpC0.js → format-time-from-id-DOmxxVYQ.js} +1 -1
  55. package/dist/{format-unit-display-DRIOlVir.js → format-unit-display-BuliV6Fn.js} +11 -11
  56. package/dist/{import-export.helper-BrcydEPI.js → import-export.helper-DpWf4zh7.js} +5 -5
  57. package/dist/{index-D9dtwK1d.js → index-BZ9fyZbO.js} +1 -1
  58. package/dist/{index-ChruXaud.js → index-C6nEuFpg.js} +1 -1
  59. package/dist/{index-Wd74fJNj.js → index-CY6-px7W.js} +3 -3
  60. package/dist/{lodash-MkfFbMhZ.js → lodash-DDMf37Aw.js} +1 -1
  61. package/dist/netsuite-CVg13Lx5.js +5131 -0
  62. package/dist/{purchase-order-template-BdKUiSPI.js → purchase-order-template-C9GqlQL3.js} +1 -1
  63. package/dist/router/name.d.ts +0 -1
  64. package/dist/{rules-KSzt3qOJ.js → rules-9-OxHCjJ.js} +3 -3
  65. package/dist/{stock-DZliLQNR.js → stock-CjJKvKsB.js} +3 -3
  66. package/dist/{stock-BHWNLsBc.js → stock-D7gYQHth.js} +1 -1
  67. package/dist/stores/integration/netsuite.d.ts +0 -5
  68. package/dist/style.css +1 -1
  69. package/dist/{supplier-CiMOpHKx.js → supplier-z1X1B4yZ.js} +2 -2
  70. package/dist/tsconfig.app.tsbuildinfo +1 -1
  71. package/dist/{use-ingredient-select-dialog-CK_Ldhwm.js → use-ingredient-select-dialog-B4u8ttOK.js} +2 -2
  72. package/dist/{use-inventory-binding-dialog-jfME3m3c.js → use-inventory-binding-dialog-CaFu9DlH.js} +2 -2
  73. package/dist/{use-template-enabled-locations-2-Dbk_RoRj.js → use-template-enabled-locations-2-KQU0hLX3.js} +2 -2
  74. package/dist/views/receive-request/components/transfer-form/TransferFormWithController.vue.d.ts +0 -714
  75. package/dist/views/receive-request/components/transfer-form/composables/use-transfer-items.d.ts +0 -5
  76. package/dist/{vue-i18n-DUlOMRWF.js → vue-i18n-UG5lCeUG.js} +533 -533
  77. package/dist/{xlsx-CiNXr9Ie.js → xlsx-INrtkMe5.js} +1 -1
  78. package/dist/{xlsx.util-D81JjCsx.js → xlsx.util-OqI8IJfw.js} +1 -1
  79. package/package.json +4 -4
  80. package/dist/FmMultiselectDialog-B5F93-xV.js +0 -621
  81. package/dist/ReceiveRequestView-DDfHVcG2.js +0 -3028
  82. package/dist/SurchargeView-nlkL3YIK.js +0 -460
  83. package/dist/TableActionableRow.vue_vue_type_script_setup_true_lang-Ca_eYa8-.js +0 -84
  84. package/dist/api/surcharge.d.ts +0 -31
  85. package/dist/app-DiX-EfV6.js +0 -8167
  86. package/dist/component-DpCUABT3.js +0 -82
  87. package/dist/netsuite-D4cXyIr7.js +0 -5402
  88. package/dist/stores/surcharge.d.ts +0 -18
  89. package/dist/surcharge-CjdNdcm1.js +0 -71
  90. package/dist/views/surcharge/SurchargeView.vue.d.ts +0 -2
@@ -1,22 +1,21 @@
1
1
  import { defineComponent as Y, ref as E, onMounted as ie, resolveComponent as F, openBlock as k, createElementBlock as B, Fragment as ue, createElementVNode as x, toDisplayString as ce, createVNode as y, createCommentVNode as q, computed as I, watch as de, createBlock as G, withCtx as U, unref as g, isRef as te, normalizeClass as me, normalizeStyle as pe, Teleport as fe, normalizeProps as ve, guardReactiveProps as ye } from "vue";
2
- import { a as A, c as Q, S as ge, F as H, j as ne, u as be } from "./app-kim0oKgm.js";
3
- import { useDialog as re, useSnackbar as W, useProxiedModel as oe, useBreakpoints as _e } from "@feedmepos/ui-library";
2
+ import { a as A, c as Q, S as ge, F as H, j as ne, u as be } from "./app-_hCz0958.js";
3
+ import { useDialog as le, useSnackbar as W, useProxiedModel as oe, useBreakpoints as _e } from "@feedmepos/ui-library";
4
4
  import { i as Re, _ as he } from "./is-linked-ingredient-error-fJ2TJb3z.js";
5
5
  import { F as C } from "./form-mode.enum-BKiNVH6A.js";
6
- import { _ as le } from "./IngredientBindedItem.vue_vue_type_script_setup_true_lang-CvdNblLJ.js";
6
+ import { _ as re } from "./IngredientBindedItem.vue_vue_type_script_setup_true_lang-y1qeqeUV.js";
7
7
  import { defineStore as we, storeToRefs as Se } from "pinia";
8
8
  import { D as ae, R as K } from "./row-action.enum-BcW_L_nE.js";
9
- import { c as xe } from "./component-DpCUABT3.js";
10
- import { a as P, R as Ve, U as Ce, A as Ee } from "./rules-KSzt3qOJ.js";
9
+ import { c as xe, _ as Ve, F as se } from "./TableActionableRow.vue_vue_type_script_setup_true_lang-cfFHDIwQ.js";
10
+ import { a as P, R as Ce, U as Ee, A as ke } from "./rules-9-OxHCjJ.js";
11
11
  import { useI18n as O } from "@feedmepos/mf-common";
12
- import { u as ke, _ as Fe } from "./SingleColumnLayout.vue_vue_type_script_setup_true_lang-CWZkVCAj.js";
13
- import { _ as Ie } from "./InventoryBindingForm.vue_vue_type_script_setup_true_lang-9jHxMOEn.js";
14
- import { _ as $e } from "./FmCustomAttribute.vue_vue_type_script_setup_true_lang-D-IWRjRD.js";
15
- import { u as De } from "./feature-D4HcMaGK.js";
16
- import { _ as Ae, F as se } from "./TableActionableRow.vue_vue_type_script_setup_true_lang-Ca_eYa8-.js";
17
- import { b as Be, d as Pe } from "./xlsx.util-D81JjCsx.js";
18
- import { f as Ue } from "./date2-Ck1fxOS1.js";
19
- import { _ as Te } from "./FmInventoryTableToolbar.vue_vue_type_script_setup_true_lang-BcJ1ydJ1.js";
12
+ import { u as Fe, _ as Ie } from "./SingleColumnLayout.vue_vue_type_script_setup_true_lang-CWZkVCAj.js";
13
+ import { _ as $e } from "./InventoryBindingForm.vue_vue_type_script_setup_true_lang-Dgy_eFxJ.js";
14
+ import { _ as De } from "./FmCustomAttribute.vue_vue_type_script_setup_true_lang-D-IWRjRD.js";
15
+ import { u as Ae } from "./feature-Dk3_0hiC.js";
16
+ import { b as Be, d as Pe } from "./xlsx.util-OqI8IJfw.js";
17
+ import { f as Ue } from "./date2-Ct3mwV73.js";
18
+ import { _ as Te } from "./FmInventoryTableToolbar.vue_vue_type_script_setup_true_lang-CaQq9jpc.js";
20
19
  const Me = {
21
20
  key: 0,
22
21
  class: "flex flex-col items-center w-full h-full gap-24"
@@ -31,20 +30,20 @@ const Me = {
31
30
  setup(b) {
32
31
  const f = b, v = E(f.bindedItems || []), s = E(!1);
33
32
  ie(() => {
34
- r();
33
+ l();
35
34
  });
36
- async function r() {
35
+ async function l() {
37
36
  var c, m;
38
37
  !s.value && ((c = f.data) != null && c._id) && (s.value = !0, v.value = await A().getAffectedMenu((m = f.data) == null ? void 0 : m._id), s.value = !1);
39
38
  }
40
39
  return (c, m) => {
41
- const w = F("FmSpacer"), l = F("FmCircularProgress");
40
+ const w = F("FmSpacer"), r = F("FmCircularProgress");
42
41
  return k(), B(ue, null, [
43
42
  x("p", null, ce(c.message), 1),
44
43
  s.value ? (k(), B("div", Me, [
45
44
  y(w),
46
45
  x("div", null, [
47
- y(l, { size: "xl" })
46
+ y(r, { size: "xl" })
48
47
  ]),
49
48
  m[0] || (m[0] = x("div", { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary pl-8" }, "Loading...", -1)),
50
49
  y(w)
@@ -52,7 +51,7 @@ const Me = {
52
51
  m[2] || (m[2] = x("br", null, null, -1)),
53
52
  v.value.length > 0 ? (k(), B("div", Ne, [
54
53
  m[1] || (m[1] = x("p", { class: "fm-typo-en-body-lg-600" }, "Affected menu items:", -1)),
55
- y(le, {
54
+ y(re, {
56
55
  name: "Menu",
57
56
  bindings: v.value
58
57
  }, null, 8, ["bindings"])
@@ -62,7 +61,7 @@ const Me = {
62
61
  };
63
62
  }
64
63
  }), J = we("recipeForm", function() {
65
- const f = re(), v = W(), s = A(), r = E(!1), c = E();
64
+ const f = le(), v = W(), s = A(), l = E(!1), c = E();
66
65
  function m() {
67
66
  const n = {
68
67
  recipe: {},
@@ -85,8 +84,8 @@ const Me = {
85
84
  };
86
85
  c.value = o;
87
86
  }
88
- async function l(n) {
89
- r.value = !0;
87
+ async function r(n) {
88
+ l.value = !0;
90
89
  try {
91
90
  await s.deleteRecipe(n), v.open({
92
91
  title: "Success",
@@ -111,7 +110,7 @@ const Me = {
111
110
  type: "error"
112
111
  }), console.error("failed to delete recipe", o);
113
112
  } finally {
114
- r.value = !1;
113
+ l.value = !1;
115
114
  }
116
115
  }
117
116
  function p(n) {
@@ -133,33 +132,33 @@ const Me = {
133
132
  data: n,
134
133
  message: "You may not be able to delete this recipe if it is linked in any of the inventory modules."
135
134
  }
136
- }).onPrimary(() => l(n));
135
+ }).onPrimary(() => r(n));
137
136
  }
138
137
  return {
139
138
  createRecipe: m,
140
139
  updateRecipe: w,
141
140
  deleteRecipe: p,
142
141
  recipeDialogProps: c,
143
- recipeViewLoading: r
142
+ recipeViewLoading: l
144
143
  };
145
144
  });
146
145
  function ze() {
147
146
  const { updateRecipe: b, deleteRecipe: f } = J(), v = A(), { t: s } = O();
148
- async function r(l, p) {
147
+ async function l(r, p) {
149
148
  const n = Q(p);
150
- if (l === K.Edit) {
149
+ if (r === K.Edit) {
151
150
  await b(n);
152
151
  return;
153
152
  }
154
- if (l === K.Delete) {
153
+ if (r === K.Delete) {
155
154
  await f(n);
156
155
  return;
157
156
  }
158
157
  }
159
- function c(l, p) {
160
- const n = l.filter((i) => i.type === H.enum.SKU), o = l.filter(
158
+ function c(r, p) {
159
+ const n = r.filter((i) => i.type === H.enum.SKU), o = r.filter(
161
160
  (i) => i.type === H.enum.SKU_GROUP
162
- ), u = l.filter((i) => i.type === H.enum.RECIPE);
161
+ ), u = r.filter((i) => i.type === H.enum.RECIPE);
163
162
  return [
164
163
  ...n.map((i) => ({ ...i, recipeIds: [...p] })),
165
164
  ...o.map((i) => ({ ...i, isGroup: !0, recipeIds: [...p] })),
@@ -182,11 +181,11 @@ function ze() {
182
181
  {
183
182
  id: "action",
184
183
  header: "",
185
- cell(l) {
184
+ cell(r) {
186
185
  return xe(
187
186
  [ae[K.Edit], ae[K.Delete]],
188
187
  (p) => {
189
- r(p, l.row.original.original);
188
+ l(p, r.row.original.original);
190
189
  }
191
190
  );
192
191
  },
@@ -198,9 +197,9 @@ function ze() {
198
197
  }
199
198
  }
200
199
  ];
201
- function w(l) {
200
+ function w(r) {
202
201
  const p = A();
203
- return l.map((n) => ({
202
+ return r.map((n) => ({
204
203
  recipe: n.name,
205
204
  ingredients: c(n.contains, /* @__PURE__ */ new Set([n._id])).map((o) => {
206
205
  var i, S, e, d, _, h;
@@ -232,23 +231,23 @@ const je = { class: "flex flex-col gap-40" }, Ke = {
232
231
  emits: ["update:modelValue", "click:submit"],
233
232
  setup(b, { expose: f, emit: v }) {
234
233
  var R;
235
- const s = b, r = v, c = De(), { t: m } = O(), w = I({
234
+ const s = b, l = v, c = Ae(), { t: m } = O(), w = I({
236
235
  get() {
237
236
  var t;
238
237
  return ((t = s.modelValue) == null ? void 0 : t.name) ?? "";
239
238
  },
240
239
  set(t) {
241
240
  const a = s.modelValue ?? {};
242
- a.name = t, r("update:modelValue", a);
241
+ a.name = t, l("update:modelValue", a);
243
242
  }
244
- }), l = I({
243
+ }), r = I({
245
244
  get() {
246
245
  var t;
247
246
  return ((t = s.modelValue) == null ? void 0 : t.contains) ?? [];
248
247
  },
249
248
  set(t) {
250
249
  const a = s.modelValue ?? {};
251
- a.contains = t, r("update:modelValue", a);
250
+ a.contains = t, l("update:modelValue", a);
252
251
  }
253
252
  }), p = I({
254
253
  get() {
@@ -259,11 +258,11 @@ const je = { class: "flex flex-col gap-40" }, Ke = {
259
258
  const a = s.modelValue ? {
260
259
  ...s.modelValue
261
260
  } : {};
262
- a.customAttributes = t, r("update:modelValue", a);
261
+ a.customAttributes = t, l("update:modelValue", a);
263
262
  }
264
263
  });
265
264
  function n() {
266
- r("click:submit");
265
+ l("click:submit");
267
266
  }
268
267
  const o = E();
269
268
  f({
@@ -306,8 +305,8 @@ const je = { class: "flex flex-col gap-40" }, Ke = {
306
305
  "model-value": w.value,
307
306
  "onUpdate:modelValue": a[0] || (a[0] = (V) => w.value = V),
308
307
  rules: [
309
- g(Ve)(),
310
- g(Ce)(_.value, h.value, (V) => `[${V.value}] already exists`)
308
+ g(Ce)(),
309
+ g(Ee)(_.value, h.value, (V) => `[${V.value}] already exists`)
311
310
  ],
312
311
  "label-mark": "required"
313
312
  }, null, 8, ["disabled", "label", "model-value", "rules"]),
@@ -318,12 +317,12 @@ const je = { class: "flex flex-col gap-40" }, Ke = {
318
317
  default: U(() => {
319
318
  var V;
320
319
  return [
321
- y(Ie, {
320
+ y($e, {
322
321
  id: (V = t.modelValue) == null ? void 0 : V._id,
323
322
  disabled: t.disabled,
324
- "model-value": l.value,
325
- "onUpdate:modelValue": a[1] || (a[1] = (z) => l.value = z),
326
- rules: [g(Ee)(1)],
323
+ "model-value": r.value,
324
+ "onUpdate:modelValue": a[1] || (a[1] = (z) => r.value = z),
325
+ rules: [g(ke)(1)],
327
326
  "enable-ingredient-group": g(c).enableIngredientGroup
328
327
  }, null, 8, ["id", "disabled", "model-value", "rules", "enable-ingredient-group"])
329
328
  ];
@@ -347,14 +346,14 @@ const je = { class: "flex flex-col gap-40" }, Ke = {
347
346
  a[4] || (a[4] = x("div", { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary pl-8" }, "Loading...", -1)),
348
347
  y(M)
349
348
  ])) : S.value && i.value.length ? (k(), B("div", Oe, [
350
- y(le, {
349
+ y(re, {
351
350
  name: "Menu",
352
351
  bindings: i.value
353
352
  }, null, 8, ["bindings"])
354
353
  ])) : q("", !0)
355
354
  ])) : q("", !0),
356
355
  x("div", He, [
357
- y($e, {
356
+ y(De, {
358
357
  entity: "inventoryRecipe",
359
358
  modelValue: p.value,
360
359
  "onUpdate:modelValue": a[3] || (a[3] = (V) => p.value = V)
@@ -374,24 +373,24 @@ const je = { class: "flex flex-col gap-40" }, Ke = {
374
373
  },
375
374
  emits: ["update:show"],
376
375
  setup(b) {
377
- const f = b, v = A(), s = W(), { t: r } = O(), c = oe(f, "show"), m = oe(f, "recipe"), w = I(() => {
376
+ const f = b, v = A(), s = W(), { t: l } = O(), c = oe(f, "show"), m = oe(f, "recipe"), w = I(() => {
378
377
  switch (f.mode) {
379
378
  case C.READ:
380
379
  return "";
381
380
  case C.UPDATE:
382
- return r("inventory.recipe.update.title");
381
+ return l("inventory.recipe.update.title");
383
382
  case C.CREATE:
384
- return r("inventory.recipe.create.title");
383
+ return l("inventory.recipe.create.title");
385
384
  }
386
385
  return "";
387
- }), l = I(() => {
386
+ }), r = I(() => {
388
387
  switch (f.mode) {
389
388
  case C.READ:
390
389
  return "";
391
390
  case C.UPDATE:
392
- return r("common.save");
391
+ return l("common.save");
393
392
  case C.CREATE:
394
- return r("common.add");
393
+ return l("common.add");
395
394
  }
396
395
  return "";
397
396
  }), p = E(), n = E(!1);
@@ -400,14 +399,14 @@ const je = { class: "flex flex-col gap-40" }, Ke = {
400
399
  try {
401
400
  const e = Q(m.value);
402
401
  e.precision ?? (e.precision = 0), e.measurements ?? (e.measurements = []), await v.createRecipe(e), c.value = !1, s.open({
403
- title: r("inventory.common.success"),
404
- message: r("inventory.recipe.create.success", { name: m.value.name }),
402
+ title: l("inventory.common.success"),
403
+ message: l("inventory.recipe.create.success", { name: m.value.name }),
405
404
  type: "success"
406
405
  });
407
406
  } catch (e) {
408
407
  e instanceof ne || s.open({
409
- title: r("inventory.recipe.create.error.title"),
410
- message: r("inventory.recipe.create.error.message"),
408
+ title: l("inventory.recipe.create.error.title"),
409
+ message: l("inventory.recipe.create.error.message"),
411
410
  type: "error"
412
411
  });
413
412
  } finally {
@@ -418,14 +417,14 @@ const je = { class: "flex flex-col gap-40" }, Ke = {
418
417
  n.value = !0;
419
418
  try {
420
419
  await v.updateRecipe(m.value), c.value = !1, s.open({
421
- title: r("inventory.common.success"),
422
- message: r("inventory.recipe.update.success", { name: m.value.name }),
420
+ title: l("inventory.common.success"),
421
+ message: l("inventory.recipe.update.success", { name: m.value.name }),
423
422
  type: "success"
424
423
  });
425
424
  } catch (e) {
426
425
  e instanceof ne || s.open({
427
- title: r("inventory.recipe.update.error.title"),
428
- message: r("inventory.recipe.update.error.message"),
426
+ title: l("inventory.recipe.update.error.title"),
427
+ message: l("inventory.recipe.update.error.message"),
429
428
  type: "error"
430
429
  });
431
430
  } finally {
@@ -460,12 +459,12 @@ const je = { class: "flex flex-col gap-40" }, Ke = {
460
459
  x("div", Je, [
461
460
  y(_, {
462
461
  loading: n.value,
463
- label: l.value,
462
+ label: r.value,
464
463
  onClick: i
465
464
  }, null, 8, ["loading", "label"]),
466
465
  y(_, {
467
466
  disabled: n.value,
468
- label: g(r)("common.close"),
467
+ label: g(l)("common.close"),
469
468
  variant: "tertiary",
470
469
  onClick: d[2] || (d[2] = (R) => c.value = !1)
471
470
  }, null, 8, ["disabled", "label"])
@@ -492,18 +491,18 @@ function We(b) {
492
491
  return !b || Object.keys(b).length === 0 ? "" : Object.entries(b).map(([f, v]) => `${f}: ${v}`).join(", ");
493
492
  }
494
493
  function Xe() {
495
- const b = A(), f = b.recipes, v = b.recipeById, s = b.skuById, r = b.skuGroupById, c = f.flatMap((l, p) => {
494
+ const b = A(), f = b.recipes, v = b.recipeById, s = b.skuById, l = b.skuGroupById, c = f.flatMap((r, p) => {
496
495
  var o;
497
- const n = We(l.customAttributes);
498
- if ((o = l.contains) != null && o.length) {
499
- const u = l.contains.filter((e) => e.type === "RECIPE"), i = l.contains.filter((e) => e.type === "SKU"), S = l.contains.filter((e) => e.type === "SKU_GROUP");
496
+ const n = We(r.customAttributes);
497
+ if ((o = r.contains) != null && o.length) {
498
+ const u = r.contains.filter((e) => e.type === "RECIPE"), i = r.contains.filter((e) => e.type === "SKU"), S = r.contains.filter((e) => e.type === "SKU_GROUP");
500
499
  return [
501
500
  ...p === 0 ? [] : [["", "", "", "", "", "", ""]],
502
501
  ...u.map(
503
502
  (e, d) => {
504
503
  var _;
505
504
  return [
506
- d === 0 ? l.name : "",
505
+ d === 0 ? r.name : "",
507
506
  "RECIPE",
508
507
  "",
509
508
  (_ = v[e.id]) == null ? void 0 : _.name,
@@ -517,7 +516,7 @@ function Xe() {
517
516
  (e, d) => {
518
517
  var _, h, R, t;
519
518
  return [
520
- !u.length && d === 0 ? l.name : "",
519
+ !u.length && d === 0 ? r.name : "",
521
520
  "INGREDIENT",
522
521
  (_ = s[e.id]) == null ? void 0 : _.code,
523
522
  (h = s[e.id]) == null ? void 0 : h.name,
@@ -531,10 +530,10 @@ function Xe() {
531
530
  (e, d) => {
532
531
  var _, h;
533
532
  return [
534
- u.length === 0 && i.length === 0 && d === 0 ? l.name : "",
533
+ u.length === 0 && i.length === 0 && d === 0 ? r.name : "",
535
534
  "SKU_GROUP",
536
- ((_ = r[e.id]) == null ? void 0 : _.ref) || "",
537
- (h = r[e.id]) == null ? void 0 : h.name,
535
+ ((_ = l[e.id]) == null ? void 0 : _.ref) || "",
536
+ (h = l[e.id]) == null ? void 0 : h.name,
538
537
  P(e.amount),
539
538
  "UNIT",
540
539
  u.length === 0 && i.length === 0 && d === 0 ? n : ""
@@ -545,26 +544,26 @@ function Xe() {
545
544
  }
546
545
  return [
547
546
  ...p === 0 ? [] : [["", "", "", "", "", "", ""]],
548
- [l.name, "No bindings", "", "", "", "", n]
547
+ [r.name, "No bindings", "", "", "", "", n]
549
548
  ];
550
549
  }), w = Be(c, ["Name", "Type", "Code", "Item", "Amount", "Unit", "Custom Attributes"]);
551
550
  Pe(w, `RECIPE_${Ue(/* @__PURE__ */ new Date(), "-", "-")}.xlsx`);
552
551
  }
553
- const Ze = { class: "flex flex-col py-8" }, et = { class: "fm-typo-en-body-lg-600 text-fm-color-typo-primary" }, tt = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, ht = /* @__PURE__ */ Y({
552
+ const Ze = { class: "flex flex-col py-8" }, et = { class: "fm-typo-en-body-lg-600 text-fm-color-typo-primary" }, tt = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Rt = /* @__PURE__ */ Y({
554
553
  __name: "RecipeView",
555
554
  setup(b) {
556
- const f = A(), v = I(() => f.recipes), s = be(), { createRecipe: r, updateRecipe: c } = J(), { recipeDialogProps: m, recipeViewLoading: w } = Se(J()), { columnDefs: l, formatRowData: p } = ze(), n = I(() => p(v.value));
557
- re(), W(), E(!1);
555
+ const f = A(), v = I(() => f.recipes), s = be(), { createRecipe: l, updateRecipe: c } = J(), { recipeDialogProps: m, recipeViewLoading: w } = Se(J()), { columnDefs: r, formatRowData: p } = ze(), n = I(() => p(v.value));
556
+ le(), W(), E(!1);
558
557
  function o(R) {
559
558
  if (R === "add")
560
- return r();
559
+ return l();
561
560
  if (R === "export")
562
561
  return Xe();
563
562
  }
564
- const u = E(""), i = I(() => w.value), { breakpoints: S } = _e(), e = I(() => S.value.xs || S.value.sm), d = I(() => e.value ? 10 : 20), _ = ke(), { t: h } = O();
563
+ const u = E(""), i = I(() => w.value), { breakpoints: S } = _e(), e = I(() => S.value.xs || S.value.sm), d = I(() => e.value ? 10 : 20), _ = Fe(), { t: h } = O();
565
564
  return (R, t) => {
566
565
  const a = F("FmTable");
567
- return k(), G(Fe, {
566
+ return k(), G(Ie, {
568
567
  title: g(h)("inventory.recipe.title"),
569
568
  actions: [
570
569
  {
@@ -594,7 +593,7 @@ const Ze = { class: "flex flex-col py-8" }, et = { class: "fm-typo-en-body-lg-60
594
593
  }, null, 8, ["search"]),
595
594
  (k(), G(a, {
596
595
  style: pe(g(_).tableHeight),
597
- "column-defs": g(l),
596
+ "column-defs": g(r),
598
597
  "row-data": n.value,
599
598
  "search-value": u.value,
600
599
  loading: !g(s)._currentLocation || i.value,
@@ -603,7 +602,7 @@ const Ze = { class: "flex flex-col py-8" }, et = { class: "fm-typo-en-body-lg-60
603
602
  "page-size": d.value
604
603
  }, {
605
604
  "list-row": U(($) => [
606
- y(Ae, {
605
+ y(Ve, {
607
606
  row: $,
608
607
  onRowClick: (D) => g(c)(D.original)
609
608
  }, {
@@ -642,5 +641,5 @@ const Ze = { class: "flex flex-col py-8" }, et = { class: "fm-typo-en-body-lg-60
642
641
  }
643
642
  });
644
643
  export {
645
- ht as default
644
+ Rt as default
646
645
  };