@feedmepos/mf-inventory-portal 1.2.7 → 1.2.8

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 (86) hide show
  1. package/dist/{App-BtLCesbn.js → App-D1IJlQS8.js} +1 -1
  2. package/dist/{ApprovalView-Ba4XBhGf.js → ApprovalView-GnDYWZHY.js} +69 -68
  3. package/dist/{BindingsDialog-BbBUniCu.js → BindingsDialog-Bs00N9mp.js} +2 -2
  4. package/dist/{BindingsPicker-C3q3ROku.js → BindingsPicker-LO15pMdZ.js} +1 -1
  5. package/dist/{BindingsTable-BTxWMif_.js → BindingsTable-g27KG9q4.js} +1 -1
  6. package/dist/{ClosingDraftView-DGITBnaY.js → ClosingDraftView-Ddsgcrmg.js} +203 -203
  7. package/dist/ClosingTemplateView-G8Ya81UZ.js +1862 -0
  8. package/dist/{DeliveryOrderPrintPreview-CUaHpblV.js → DeliveryOrderPrintPreview-qq1rhFKV.js} +8 -8
  9. package/dist/{FmAdminBadge-BdwGZY-f.js → FmAdminBadge-B2NpMmJi.js} +6 -6
  10. package/dist/FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-C1i9CHE1.js +230 -0
  11. package/dist/{FmMultiselectDialog-BETfHs3j.js → FmMultiselectDialog-u2dbuZUp.js} +1 -1
  12. package/dist/{FmUnitInput.vue_vue_type_script_setup_true_lang-BNdbeRQp.js → FmUnitInput.vue_vue_type_script_setup_true_lang-vpiiv6C1.js} +23 -23
  13. package/dist/{IngredientBindedItem.vue_vue_type_script_setup_true_lang-VYMMcwLl.js → IngredientBindedItem.vue_vue_type_script_setup_true_lang-3T-d1pIb.js} +1 -1
  14. package/dist/{IngredientGroupView-C4d9b3Td.js → IngredientGroupView-CqB73-e4.js} +12 -12
  15. package/dist/IngredientsView-Cq42ytcN.js +2291 -0
  16. package/dist/{IntegrationView-CWFzRDWO.js → IntegrationView-OHnUGZst.js} +4 -4
  17. package/dist/{InventoryBindingForm-Cx0Prlq8.js → InventoryBindingForm-DorgxR-Y.js} +1 -1
  18. package/dist/{InventoryBindingForm.vue_vue_type_script_setup_true_lang-cpR3Sf2Y.js → InventoryBindingForm.vue_vue_type_script_setup_true_lang-CZy77tY7.js} +41 -41
  19. package/dist/{InventoryBindingSummary-l8XvpxVU.js → InventoryBindingSummary-B_YavyPb.js} +1 -1
  20. package/dist/{NumberPrecisionInput.vue_vue_type_script_setup_true_lang-BjRvIX-v.js → NumberPrecisionInput.vue_vue_type_script_setup_true_lang-XuEDo134.js} +1 -1
  21. package/dist/{PremiumBadge.vue_vue_type_script_setup_true_lang-gjuZveKy.js → PremiumBadge.vue_vue_type_script_setup_true_lang-Blq1oE5l.js} +11 -11
  22. package/dist/{PublishView-D2iUnDan.js → PublishView-Ds_ztGcV.js} +14 -14
  23. package/dist/{PurchaseOrderPrintPreview-DdLvM-wt.js → PurchaseOrderPrintPreview-DnyqN_xE.js} +11 -11
  24. package/dist/{ReceiveRequestView-DpF5ZzvH.js → ReceiveRequestView-ChpKsDaF.js} +148 -145
  25. package/dist/{RecipeView-Dvtm8o1Y.js → RecipeView-Dyp9Xcme.js} +49 -49
  26. package/dist/StockView-D-iP52Zw.js +2089 -0
  27. package/dist/{SupplierView-7GtIJ3Fz.js → SupplierView-BaEK3C8q.js} +1133 -1015
  28. package/dist/TransferDetails.vue_vue_type_script_setup_true_lang-B_ravTwn.js +3058 -0
  29. package/dist/{TransferTemplateView-Cmvg-yvW.js → TransferTemplateView-3zS7hNZz.js} +131 -130
  30. package/dist/{UnitView-DjVm1iVX.js → UnitView-BP5eztAG.js} +59 -59
  31. package/dist/WarehouseView-DMY7Lgwq.js +1066 -0
  32. package/dist/api/inventory.d.ts +8 -0
  33. package/dist/api/netsuite.d.ts +3 -0
  34. package/dist/api/purchase-order-template.d.ts +1 -0
  35. package/dist/api/purchase-order.d.ts +2 -0
  36. package/dist/api/shipment.d.ts +11 -0
  37. package/dist/api/warehouse.d.ts +3 -1
  38. package/dist/{app-Z-ylwRmy.js → app-P6XaUzjP.js} +17877 -17113
  39. package/dist/app.d.ts +96 -9
  40. package/dist/app.js +3 -3
  41. package/dist/closing-template-BGYZPBty.js +53 -0
  42. package/dist/components/FmInventoryTableToolbar.vue.d.ts +9 -2
  43. package/dist/components/netsuite/SubsidiaryTreeDialog.vue.d.ts +2 -0
  44. package/dist/{decimal-D1pJ2776.js → decimal-wz5HXhQ8.js} +1 -1
  45. package/dist/{format-unit-display-9BMm-8A4.js → format-unit-display-DOOJqLop.js} +372 -404
  46. package/dist/{index-BOl10vcm.js → index-CHTB43Wl.js} +1 -1
  47. package/dist/{index-rEIM0AVC.js → index-oR0svfBM.js} +1 -1
  48. package/dist/purchase-order-template-BGunGekw.js +41 -0
  49. package/dist/{stock-B8ewk80v.js → stock-TJayQnag.js} +1 -1
  50. package/dist/stores/feature.d.ts +10 -0
  51. package/dist/stores/integration/netsuite.d.ts +19 -0
  52. package/dist/stores/inventory.d.ts +1 -0
  53. package/dist/stores/location.d.ts +57 -1
  54. package/dist/stores/supplier.d.ts +96 -0
  55. package/dist/stores/warehouse.d.ts +4 -0
  56. package/dist/{supplier-DLSXYY1o.js → supplier-C_vqpE92.js} +1 -1
  57. package/dist/tsconfig.app.tsbuildinfo +1 -1
  58. package/dist/{use-ingredient-select-dialog-CTjwdY3T.js → use-ingredient-select-dialog-CIahwuTX.js} +5 -5
  59. package/dist/{use-inventory-binding-dialog-zXJB7MQY.js → use-inventory-binding-dialog-BiKRXVhY.js} +8 -8
  60. package/dist/views/ingredients/components/ingredient-form/IngredientForm.vue.d.ts +24 -0
  61. package/dist/views/ingredients/components/ingredient-form/IngredientFormProps.d.ts +6 -0
  62. package/dist/views/integration/components/netsuite/business/BusinessNetSuiteSideSheet.vue.d.ts +2 -0
  63. package/dist/views/receive-request/components/delivery-order-form/CreateForm.vue.d.ts +16 -0
  64. package/dist/views/receive-request/components/delivery-order-form/CreateFormProps.d.ts +4 -0
  65. package/dist/views/receive-request/components/delivery-order-form/EditForm.vue.d.ts +16 -0
  66. package/dist/views/receive-request/components/delivery-order-form/EditFormProps.d.ts +4 -0
  67. package/dist/views/receive-request/components/transfer-details/TransferDetailsProps.d.ts +1 -0
  68. package/dist/views/receive-request/components/transfer-form/TransferForm.vue.d.ts +60 -0
  69. package/dist/views/receive-request/composables/use-process-purchase-order.d.ts +10 -0
  70. package/dist/views/receive-request/composables/use-receive-request-form.d.ts +94 -0
  71. package/dist/views/receive-request/composables/use-receive-request-table.d.ts +72 -1
  72. package/dist/views/supplier/components/SupplierForm.vue.d.ts +8 -0
  73. package/dist/views/supplier/components/SupplierSupplyItemField.vue.d.ts +3 -0
  74. package/dist/views/supplier/composables/use-supplier-table.d.ts +4 -0
  75. package/dist/views/transfer-template/components/transfer-template-dialog/TransferTemplateDialog.vue.d.ts +8 -0
  76. package/dist/views/transfer-template/components/transfer-template-form/composables/use-transfer-locations.d.ts +16 -0
  77. package/dist/views/transfer-template/composables/use-transfer-template-actions.d.ts +48 -0
  78. package/dist/views/transfer-template/composables/use-transfer-template-table.d.ts +48 -0
  79. package/dist/views/warehouse/components/WarehouseForm.vue.d.ts +8 -0
  80. package/package.json +3 -3
  81. package/dist/ClosingTemplateView-eRvwxXBq.js +0 -1908
  82. package/dist/FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-lDkElrkF.js +0 -227
  83. package/dist/IngredientsView-BvqWuIVT.js +0 -1876
  84. package/dist/StockView-CRDu_GQ_.js +0 -2086
  85. package/dist/TransferDetails.vue_vue_type_script_setup_true_lang-DbmLtbZt.js +0 -2494
  86. package/dist/WarehouseView-CBso3SXT.js +0 -1034
@@ -1,9 +1,9 @@
1
- import { defineComponent as Te, ref as H, computed as L, onMounted as Le, resolveComponent as P, openBlock as w, createElementBlock as U, Fragment as J, createTextVNode as Z, createBlock as X, withCtx as O, createElementVNode as o, toDisplayString as W, unref as F, createVNode as k, createCommentVNode as ee, h as T, reactive as nt, watch as ot, isRef as Ye, normalizeClass as be, renderList as _e, normalizeStyle as Ke, Teleport as st, mergeProps as rt } from "vue";
2
- import { a4 as lt, u as Ie, aq as E, ai as Ge, ar as qe, n as ct, Q as Ee, j as N, t as it, V as he, s as ut, v as dt, w as mt, as as We, at as Ze, ad as Je, au as re, aj as ft, a6 as Me, a5 as le, a1 as Ue, D as Oe, i as Se, h as pt, f as vt, a as yt, T as Fe, C as gt, _ as bt, E as At, G as Dt, J as je } from "./app-Z-ylwRmy.js";
3
- import { useCoreStore as kt, useI18n as Qe } from "@feedmepos/mf-common";
4
- import { useSnackbar as Ve, useDialog as _t, useProxiedModel as ht, components as ge, useBreakpoints as xt } from "@feedmepos/ui-library";
5
- import { defineStore as Xe, storeToRefs as wt } from "pinia";
6
- import { a as He, u as et } from "./stock-B8ewk80v.js";
1
+ import { defineComponent as Te, ref as V, computed as U, onMounted as Ue, resolveComponent as P, openBlock as w, createElementBlock as L, Fragment as X, createTextVNode as Z, createBlock as Q, withCtx as O, createElementVNode as o, toDisplayString as W, unref as F, createVNode as D, createCommentVNode as ee, h as T, reactive as nt, watch as ot, isRef as Ye, normalizeClass as be, renderList as _e, normalizeStyle as Ke, Teleport as st, mergeProps as rt } from "vue";
2
+ import { a6 as lt, u as Ie, as as E, ak as Ge, at as qe, o as ct, X as Ee, k as N, t as it, Z as he, y as ut, z as dt, B as mt, au as We, av as Ze, af as Xe, aw as re, al as ft, a8 as Me, a7 as le, a4 as Le, D as Oe, i as Se, h as pt, f as vt, a as yt, Y as Fe, K as gt, _ as bt, L as At, O as kt, P as Be } from "./app-P6XaUzjP.js";
3
+ import { useCoreStore as Dt, useI18n as Je } from "@feedmepos/mf-common";
4
+ import { useSnackbar as He, useDialog as _t, useProxiedModel as ht, components as ge, useBreakpoints as xt } from "@feedmepos/ui-library";
5
+ import { defineStore as Qe, storeToRefs as wt } from "pinia";
6
+ import { a as Ve, u as et } from "./stock-TJayQnag.js";
7
7
  import { E as Ct } from "./empty-placeholder-wf6-BWE8.js";
8
8
  const Re = lt((l, s) => {
9
9
  function e() {
@@ -27,10 +27,10 @@ const Re = lt((l, s) => {
27
27
  return s.post(_, u);
28
28
  }
29
29
  };
30
- }), St = { class: "fm-typo-en-body-lg-400" }, Ft = { class: "fm-typo-en-body-lg-600" }, jt = {
30
+ }), St = { class: "fm-typo-en-body-lg-400" }, Ft = { class: "fm-typo-en-body-lg-600" }, Bt = {
31
31
  key: 0,
32
32
  class: "flex flex-col"
33
- }, Bt = { class: "flex gap-12 py-8 justify-end w-full" }, Pe = /* @__PURE__ */ Te({
33
+ }, jt = { class: "flex gap-12 py-8 justify-end w-full" }, Pe = /* @__PURE__ */ Te({
34
34
  __name: "ClosingDraftAction",
35
35
  props: {
36
36
  draft: {},
@@ -39,7 +39,7 @@ const Re = lt((l, s) => {
39
39
  onFinished: { type: Function }
40
40
  },
41
41
  setup(l) {
42
- const s = l, e = H(), u = Re(), p = Ve(), _ = H(!1), m = H(null), R = H(!1), C = L(() => {
42
+ const s = l, e = V(), u = Re(), p = He(), _ = V(!1), m = V(null), R = V(!1), C = U(() => {
43
43
  switch (s.action) {
44
44
  case E.enum.approveDraft:
45
45
  return "Approve";
@@ -49,7 +49,7 @@ const Re = lt((l, s) => {
49
49
  return "Mark as Failed";
50
50
  }
51
51
  throw new Error(`Unknown action: ${s.action}`);
52
- }), x = L(() => {
52
+ }), x = U(() => {
53
53
  switch (s.action) {
54
54
  case E.enum.approveDraft:
55
55
  return "primary";
@@ -60,7 +60,7 @@ const Re = lt((l, s) => {
60
60
  }
61
61
  throw new Error(`Unknown action: ${s.action}`);
62
62
  });
63
- Le(() => {
63
+ Ue(() => {
64
64
  if (s.draft.effectiveAt)
65
65
  m.value = new Date(s.draft.effectiveAt);
66
66
  else {
@@ -69,7 +69,7 @@ const Re = lt((l, s) => {
69
69
  }
70
70
  R.value = !0;
71
71
  });
72
- const v = L({
72
+ const v = U({
73
73
  get() {
74
74
  return m.value === null ? "" : Ge(m.value);
75
75
  },
@@ -80,7 +80,7 @@ const Re = lt((l, s) => {
80
80
  } else
81
81
  m.value = null;
82
82
  }
83
- }), I = L({
83
+ }), I = U({
84
84
  get() {
85
85
  return m.value === null ? "" : qe(m.value);
86
86
  },
@@ -119,8 +119,8 @@ const Re = lt((l, s) => {
119
119
  }
120
120
  }
121
121
  return (n, a) => {
122
- const j = P("FmLabel"), M = P("FmDatePicker"), f = P("FmTimePicker"), g = P("FmTextField"), b = P("FmButton"), $ = P("FmForm");
123
- return R.value ? (w(), X($, {
122
+ const B = P("FmLabel"), M = P("FmDatePicker"), f = P("FmTimePicker"), g = P("FmTextField"), b = P("FmButton"), $ = P("FmForm");
123
+ return R.value ? (w(), Q($, {
124
124
  key: 1,
125
125
  onValidationSuccess: Y,
126
126
  class: "flex flex-col gap-32",
@@ -132,42 +132,42 @@ const Re = lt((l, s) => {
132
132
  o("span", Ft, W(C.value), 1),
133
133
  a[5] || (a[5] = Z(" this draft. Please provide a remark to justify this action. "))
134
134
  ]),
135
- n.action === F(E).enum.approveDraft ? (w(), U("div", jt, [
136
- k(j, { class: "fm-typo-en-body-lg-600" }, {
135
+ n.action === F(E).enum.approveDraft ? (w(), L("div", Bt, [
136
+ D(B, { class: "fm-typo-en-body-lg-600" }, {
137
137
  default: O(() => a[6] || (a[6] = [
138
138
  Z("Closing Date")
139
139
  ])),
140
140
  _: 1
141
141
  }),
142
- k(M, {
142
+ D(M, {
143
143
  modelValue: v.value,
144
- "onUpdate:modelValue": a[0] || (a[0] = (V) => v.value = V)
144
+ "onUpdate:modelValue": a[0] || (a[0] = (H) => v.value = H)
145
145
  }, null, 8, ["modelValue"]),
146
- k(j, { class: "fm-typo-en-body-lg-600" }, {
146
+ D(B, { class: "fm-typo-en-body-lg-600" }, {
147
147
  default: O(() => a[7] || (a[7] = [
148
148
  Z("Closing Time")
149
149
  ])),
150
150
  _: 1
151
151
  }),
152
- k(f, {
152
+ D(f, {
153
153
  modelValue: I.value,
154
- "onUpdate:modelValue": a[1] || (a[1] = (V) => I.value = V)
154
+ "onUpdate:modelValue": a[1] || (a[1] = (H) => I.value = H)
155
155
  }, null, 8, ["modelValue"])
156
156
  ])) : ee("", !0),
157
- k(g, {
157
+ D(g, {
158
158
  modelValue: e.value,
159
- "onUpdate:modelValue": a[2] || (a[2] = (V) => e.value = V),
159
+ "onUpdate:modelValue": a[2] || (a[2] = (H) => e.value = H),
160
160
  label: "Remark",
161
161
  "label-mark": "required",
162
162
  rules: [F(ct)()]
163
163
  }, null, 8, ["modelValue", "rules"]),
164
- o("div", Bt, [
165
- k(b, {
164
+ o("div", jt, [
165
+ D(b, {
166
166
  label: "Cancel",
167
167
  variant: "tertiary",
168
- onClick: a[3] || (a[3] = (V) => n.onCancel())
168
+ onClick: a[3] || (a[3] = (H) => n.onCancel())
169
169
  }),
170
- k(b, {
170
+ D(b, {
171
171
  label: C.value,
172
172
  type: "submit",
173
173
  variant: x.value,
@@ -176,7 +176,7 @@ const Re = lt((l, s) => {
176
176
  ])
177
177
  ]),
178
178
  _: 1
179
- }, 8, ["disabled"])) : (w(), U(J, { key: 0 }, [
179
+ }, 8, ["disabled"])) : (w(), L(X, { key: 0 }, [
180
180
  Z("Loading")
181
181
  ], 64));
182
182
  };
@@ -210,7 +210,7 @@ function Rt(l, s, e, u) {
210
210
  systemBalance: +N(s),
211
211
  physicalBalance: +N(_),
212
212
  adjustedAmount: +N(m),
213
- adjustedDiffPercentage: C ? +N(Je(C, 2)) : null
213
+ adjustedDiffPercentage: C ? +N(Xe(C, 2)) : null
214
214
  };
215
215
  }
216
216
  function Pt(l) {
@@ -232,7 +232,7 @@ function at(l) {
232
232
  (s) => s.measurementsAmounts.filter((e) => !e.measurement.abbrev.toLocaleLowerCase().includes("inactive")).map((e) => e.measurement.id)
233
233
  );
234
234
  }
235
- function Ut(l) {
235
+ function Lt(l) {
236
236
  return [
237
237
  {
238
238
  id: "code",
@@ -278,24 +278,24 @@ function Ut(l) {
278
278
  ])
279
279
  ];
280
280
  }
281
- function Lt(l, s, e) {
282
- var M, f, g, b, $, V, te;
281
+ function Ut(l, s, e) {
282
+ var M, f, g, b, $, H, te;
283
283
  const u = s.groupBy(
284
- (B) => B.id,
285
- (B) => B.balance
284
+ (j) => j.id,
285
+ (j) => j.balance
286
286
  ), p = e.groupBy(
287
- (B) => B.id,
288
- (B) => B.balance
289
- ), _ = [...l.items, ...l.negativeStockItems ?? []], m = at(_), R = _.map((B) => {
287
+ (j) => j.id,
288
+ (j) => j.balance
289
+ ), _ = [...l.items, ...l.negativeStockItems ?? []], m = at(_), R = _.map((j) => {
290
290
  var ie, ue, de;
291
- const Q = ((ie = u.get(B.sku._id)) == null ? void 0 : ie[0]) ?? Tt, ce = ((ue = m == null ? void 0 : m.get(B.sku._id)) == null ? void 0 : ue[0]) ?? [];
291
+ const J = ((ie = u.get(j.sku._id)) == null ? void 0 : ie[0]) ?? Tt, ce = ((ue = m == null ? void 0 : m.get(j.sku._id)) == null ? void 0 : ue[0]) ?? [];
292
292
  return Rt(
293
- B,
294
- Q,
293
+ j,
294
+ J,
295
295
  ce,
296
- (de = p.get(B.sku._id)) == null ? void 0 : de[0]
296
+ (de = p.get(j.sku._id)) == null ? void 0 : de[0]
297
297
  );
298
- }), C = Mt(_), v = kt().currentBusiness.value, I = Ut(C), Y = [
298
+ }), C = Mt(_), v = Dt().currentBusiness.value, I = Lt(C), Y = [
299
299
  ["Business name:", v == null ? void 0 : v.name],
300
300
  ["Business ID:", v == null ? void 0 : v._id],
301
301
  ["Menu version", v == null ? void 0 : v.menuVersion],
@@ -310,19 +310,19 @@ function Lt(l, s, e) {
310
310
  ],
311
311
  [
312
312
  "Action at",
313
- l.approvedAt ? new Date(l.approvedAt) : l.rejectionHistory ? new Date((V = l.rejectionHistory[0]) == null ? void 0 : V.rejectedAt) : ""
313
+ l.approvedAt ? new Date(l.approvedAt) : l.rejectionHistory ? new Date((H = l.rejectionHistory[0]) == null ? void 0 : H.rejectedAt) : ""
314
314
  ],
315
315
  [
316
316
  "Action remark",
317
317
  l.approvedAt ? l.approveRemark : l.rejectionHistory ? new Date((te = l.rejectionHistory[0]) == null ? void 0 : te.rejectRemark) : ""
318
318
  ],
319
319
  [],
320
- I.map((B) => B.name),
321
- ...R.map((B) => I.map((Q) => B[Q.id]))
322
- ], n = I.map((B) => `system:${B.id}`), a = ut(Y, n), j = `[${v == null ? void 0 : v.name}] closing draft (${dt(new Date(l.updatedAt))}).xlsx`;
323
- return mt(a, j), j;
320
+ I.map((j) => j.name),
321
+ ...R.map((j) => I.map((J) => j[J.id]))
322
+ ], n = I.map((j) => `system:${j.id}`), a = ut(Y, n), B = `[${v == null ? void 0 : v.name}] closing draft (${dt(new Date(l.updatedAt))}).xlsx`;
323
+ return mt(a, B), B;
324
324
  }
325
- const Et = { class: "flex flex-col" }, Vt = { class: "flex gap-12 py-8 justify-end w-full" }, Ht = /* @__PURE__ */ Te({
325
+ const Et = { class: "flex flex-col" }, Ht = { class: "flex gap-12 py-8 justify-end w-full" }, Vt = /* @__PURE__ */ Te({
326
326
  __name: "RefreshBalanceAction",
327
327
  props: {
328
328
  draft: {},
@@ -331,9 +331,9 @@ const Et = { class: "flex flex-col" }, Vt = { class: "flex gap-12 py-8 justify-e
331
331
  },
332
332
  setup(l) {
333
333
  const s = l;
334
- He();
335
- const e = H(!1), u = H(null), p = H(!1);
336
- Le(() => {
334
+ Ve();
335
+ const e = V(!1), u = V(null), p = V(!1);
336
+ Ue(() => {
337
337
  if (s.draft.effectiveAt)
338
338
  u.value = new Date(s.draft.effectiveAt);
339
339
  else {
@@ -342,7 +342,7 @@ const Et = { class: "flex flex-col" }, Vt = { class: "flex gap-12 py-8 justify-e
342
342
  }
343
343
  p.value = !0;
344
344
  });
345
- const _ = L({
345
+ const _ = U({
346
346
  get() {
347
347
  return u.value === null ? "" : Ge(u.value);
348
348
  },
@@ -353,7 +353,7 @@ const Et = { class: "flex flex-col" }, Vt = { class: "flex gap-12 py-8 justify-e
353
353
  } else
354
354
  u.value = null;
355
355
  }
356
- }), m = L({
356
+ }), m = U({
357
357
  get() {
358
358
  return u.value === null ? "" : qe(u.value);
359
359
  },
@@ -370,7 +370,7 @@ const Et = { class: "flex flex-col" }, Vt = { class: "flex gap-12 py-8 justify-e
370
370
  }
371
371
  return (C, x) => {
372
372
  const v = P("FmLabel"), I = P("FmDatePicker"), Y = P("FmTimePicker"), n = P("FmButton"), a = P("FmForm");
373
- return p.value ? (w(), X(a, {
373
+ return p.value ? (w(), Q(a, {
374
374
  key: 1,
375
375
  onValidationSuccess: R,
376
376
  class: "flex flex-col gap-32",
@@ -390,34 +390,34 @@ const Et = { class: "flex flex-col" }, Vt = { class: "flex gap-12 py-8 justify-e
390
390
  ])
391
391
  ], -1)),
392
392
  o("div", Et, [
393
- k(v, { class: "fm-typo-en-body-lg-600" }, {
393
+ D(v, { class: "fm-typo-en-body-lg-600" }, {
394
394
  default: O(() => x[3] || (x[3] = [
395
395
  Z("Closing Date")
396
396
  ])),
397
397
  _: 1
398
398
  }),
399
- k(I, {
399
+ D(I, {
400
400
  modelValue: _.value,
401
- "onUpdate:modelValue": x[0] || (x[0] = (j) => _.value = j)
401
+ "onUpdate:modelValue": x[0] || (x[0] = (B) => _.value = B)
402
402
  }, null, 8, ["modelValue"]),
403
- k(v, { class: "fm-typo-en-body-lg-600" }, {
403
+ D(v, { class: "fm-typo-en-body-lg-600" }, {
404
404
  default: O(() => x[4] || (x[4] = [
405
405
  Z("Closing Time")
406
406
  ])),
407
407
  _: 1
408
408
  }),
409
- k(Y, {
409
+ D(Y, {
410
410
  modelValue: m.value,
411
- "onUpdate:modelValue": x[1] || (x[1] = (j) => m.value = j)
411
+ "onUpdate:modelValue": x[1] || (x[1] = (B) => m.value = B)
412
412
  }, null, 8, ["modelValue"])
413
413
  ]),
414
- o("div", Vt, [
415
- k(n, {
414
+ o("div", Ht, [
415
+ D(n, {
416
416
  label: "Cancel",
417
417
  variant: "tertiary",
418
- onClick: x[2] || (x[2] = (j) => C.onCancel())
418
+ onClick: x[2] || (x[2] = (B) => C.onCancel())
419
419
  }),
420
- k(n, {
420
+ D(n, {
421
421
  label: "Refresh balance",
422
422
  type: "submit",
423
423
  variant: "primary",
@@ -426,15 +426,15 @@ const Et = { class: "flex flex-col" }, Vt = { class: "flex gap-12 py-8 justify-e
426
426
  ])
427
427
  ]),
428
428
  _: 1
429
- }, 8, ["disabled"])) : (w(), U(J, { key: 0 }, [
429
+ }, 8, ["disabled"])) : (w(), L(X, { key: 0 }, [
430
430
  Z("Loading")
431
431
  ], 64));
432
432
  };
433
433
  }
434
- }), $e = Xe(
434
+ }), $e = Qe(
435
435
  "closingDraftActions",
436
436
  function() {
437
- const s = _t(), e = Ve(), u = He(), p = Re(), _ = et(), m = H(!1), R = H();
437
+ const s = _t(), e = He(), u = Ve(), p = Re(), _ = et(), m = V(!1), R = V();
438
438
  function C(f) {
439
439
  const g = {
440
440
  draft: f
@@ -453,11 +453,11 @@ const Et = { class: "flex flex-col" }, Vt = { class: "flex gap-12 py-8 justify-e
453
453
  }), console.error("Closing draft is completed but closing document cannot be found.", {
454
454
  draftId: f._id
455
455
  }), [];
456
- const V = await u.readAdjustmentById($);
457
- return ((V == null ? void 0 : V.skus) ?? []).map((B) => ({
458
- id: B.sku._id,
459
- balance: B.fromBalance,
460
- costs: B.fromCostBalances
456
+ const H = await u.readAdjustmentById($);
457
+ return ((H == null ? void 0 : H.skus) ?? []).map((j) => ({
458
+ id: j.sku._id,
459
+ balance: j.fromBalance,
460
+ costs: j.fromCostBalances
461
461
  }));
462
462
  } else
463
463
  return await _.readStockBalance(), ((b = _.stockBalance) == null ? void 0 : b.skus) ?? [];
@@ -466,7 +466,7 @@ const Et = { class: "flex flex-col" }, Vt = { class: "flex gap-12 py-8 justify-e
466
466
  g || (e.open({
467
467
  title: "Exporting",
468
468
  message: "Fetching data..."
469
- }), g = await x(f)), Lt(f, g, b ?? []);
469
+ }), g = await x(f)), Ut(f, g, b ?? []);
470
470
  }
471
471
  function I(f, g) {
472
472
  s.open({
@@ -524,13 +524,13 @@ const Et = { class: "flex flex-col" }, Vt = { class: "flex gap-12 py-8 justify-e
524
524
  type: "success"
525
525
  }), g == null || g();
526
526
  }
527
- function j() {
527
+ function B() {
528
528
  m.value = !1;
529
529
  }
530
530
  async function M(f, g, b) {
531
531
  await s.open({
532
532
  title: "Refresh balance",
533
- contentComponent: Ht,
533
+ contentComponent: Vt,
534
534
  contentComponentProps: {
535
535
  draft: f,
536
536
  onFinished: ($) => {
@@ -544,7 +544,7 @@ const Et = { class: "flex flex-col" }, Vt = { class: "flex gap-12 py-8 justify-e
544
544
  }
545
545
  return {
546
546
  viewDraft: C,
547
- closeDraftDialog: j,
547
+ closeDraftDialog: B,
548
548
  approveDraft: I,
549
549
  rejectDraft: Y,
550
550
  markAsFailed: n,
@@ -556,7 +556,7 @@ const Et = { class: "flex flex-col" }, Vt = { class: "flex gap-12 py-8 justify-e
556
556
  };
557
557
  }
558
558
  );
559
- function Be(l) {
559
+ function je(l) {
560
560
  switch (l) {
561
561
  case "DRAFT":
562
562
  return "fm-status-badge-draft";
@@ -568,10 +568,10 @@ function Be(l) {
568
568
  return "fm-status-badge-complete";
569
569
  }
570
570
  }
571
- const Nt = Xe(
571
+ const Nt = Qe(
572
572
  "closingDraftTable",
573
573
  function() {
574
- const { t: s } = Qe(), e = $e(), u = H(new Array()), p = H(!1), _ = Ie(), m = Re();
574
+ const { t: s } = Je(), e = $e(), u = V(new Array()), p = V(!1), _ = Ie(), m = Re();
575
575
  async function R() {
576
576
  if (u.value = [], !!_._currentLocation) {
577
577
  p.value = !0;
@@ -591,7 +591,7 @@ const Nt = Xe(
591
591
  try {
592
592
  const [a] = await Promise.all([
593
593
  m.getDraft(n),
594
- new Promise((j) => setTimeout(j, 1e3))
594
+ new Promise((B) => setTimeout(B, 1e3))
595
595
  ]);
596
596
  u.value = [a];
597
597
  } catch (a) {
@@ -640,8 +640,8 @@ const Nt = Xe(
640
640
  header: () => "Effective at",
641
641
  cell(n) {
642
642
  const a = n.row.original;
643
- let j = n.getValue();
644
- return j || (j = Me(a._id)), le(j);
643
+ let B = n.getValue();
644
+ return B || (B = Me(a._id)), le(B);
645
645
  },
646
646
  enableSorting: !0,
647
647
  size: 200
@@ -677,7 +677,7 @@ const Nt = Xe(
677
677
  id: "recentRemark",
678
678
  accessorFn: (n) => {
679
679
  var a;
680
- return (n == null ? void 0 : n.approveRemark) ?? ((a = n == null ? void 0 : n.rejectionHistory) == null ? void 0 : a.computeFirst((j) => j.rejectRemark)) ?? n.remark;
680
+ return (n == null ? void 0 : n.approveRemark) ?? ((a = n == null ? void 0 : n.rejectionHistory) == null ? void 0 : a.computeFirst((B) => B.rejectRemark)) ?? n.remark;
681
681
  },
682
682
  header: () => "Recent remark"
683
683
  },
@@ -688,8 +688,8 @@ const Nt = Xe(
688
688
  enableSorting: !1,
689
689
  cell(n) {
690
690
  var b;
691
- const a = n.row.original, j = a.status, M = new Date(a.updatedAt), f = (b = a == null ? void 0 : a.rejectionHistory) == null ? void 0 : b.computeFirst(($) => $.rejectedAt), g = f ? new Date(f) : null;
692
- return j === "DRAFT" && g ? g.getTime() > M.getTime() ? T(
691
+ const a = n.row.original, B = a.status, M = new Date(a.updatedAt), f = (b = a == null ? void 0 : a.rejectionHistory) == null ? void 0 : b.computeFirst(($) => $.rejectedAt), g = f ? new Date(f) : null;
692
+ return B === "DRAFT" && g ? g.getTime() > M.getTime() ? T(
693
693
  "div",
694
694
  {
695
695
  class: "flex"
@@ -697,7 +697,7 @@ const Nt = Xe(
697
697
  T(
698
698
  "div",
699
699
  {
700
- class: ["fm-status-badge", Be("FAILED")]
700
+ class: ["fm-status-badge", je("FAILED")]
701
701
  },
702
702
  "Rejected"
703
703
  )
@@ -709,7 +709,7 @@ const Nt = Xe(
709
709
  T(
710
710
  "div",
711
711
  {
712
- class: ["fm-status-badge", Be("PROCESSING")]
712
+ class: ["fm-status-badge", je("PROCESSING")]
713
713
  },
714
714
  "Updated"
715
715
  )
@@ -721,9 +721,9 @@ const Nt = Xe(
721
721
  T(
722
722
  "div",
723
723
  {
724
- class: ["fm-status-badge", Be(j)]
724
+ class: ["fm-status-badge", je(B)]
725
725
  },
726
- Ue(j)
726
+ Le(B)
727
727
  )
728
728
  );
729
729
  }
@@ -731,7 +731,7 @@ const Nt = Xe(
731
731
  {
732
732
  id: "action",
733
733
  cell(n) {
734
- const a = n.row.original, j = [
734
+ const a = n.row.original, B = [
735
735
  Oe[Se.Details],
736
736
  Oe[Se.Export]
737
737
  ], M = [
@@ -753,7 +753,7 @@ const Nt = Xe(
753
753
  ];
754
754
  return pt(
755
755
  [
756
- ...j,
756
+ ...B,
757
757
  ...a.status === re.enum.DRAFT ? M : []
758
758
  ],
759
759
  (f) => I(f, a)
@@ -774,10 +774,10 @@ const Nt = Xe(
774
774
  updateDraftRef: x
775
775
  };
776
776
  }
777
- ), zt = { class: "w-full flex flex-col gap-32" }, Ot = { class: "flex justify-between" }, Yt = { class: "flex" }, Kt = { class: "grid grid-cols-[repeat(4,1fr)] xs:flex xs:flex-col sm:flex sm:flex-col gap-8" }, Gt = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, qt = { class: "flex gap-1" }, Wt = { class: "fm-typo-en-body-lg-600" }, Zt = { class: "flex flex-col gap-16" }, Jt = { class: "flex items-center" }, Qt = {
777
+ ), zt = { class: "w-full flex flex-col gap-32" }, Ot = { class: "flex justify-between" }, Yt = { class: "flex" }, Kt = { class: "grid grid-cols-[repeat(4,1fr)] xs:flex xs:flex-col sm:flex sm:flex-col gap-8" }, Gt = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, qt = { class: "flex gap-1" }, Wt = { class: "fm-typo-en-body-lg-600" }, Zt = { class: "flex flex-col gap-16" }, Xt = { class: "flex items-center" }, Jt = {
778
778
  key: 0,
779
779
  class: "flex gap-8"
780
- }, Xt = {
780
+ }, Qt = {
781
781
  key: 0,
782
782
  class: "w-full flex flex-col items-center"
783
783
  }, ea = { class: "flex items-center gap-8" }, ta = { class: "flex flex-col gap-8" }, aa = { class: "flex gap-8" }, na = {
@@ -804,7 +804,7 @@ const Nt = Xe(
804
804
  }, ba = { class: "flex-1 flex flex-col items-center" }, Aa = {
805
805
  class: "py-12 flex flex-col gap-4 flex-1",
806
806
  name: "delivery details"
807
- }, Da = { class: "flex flex-col gap-8" }, ka = { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, _a = { class: "flex flex-col gap-4" }, ha = { class: "flex gap-8" }, xa = /* @__PURE__ */ Te({
807
+ }, ka = { class: "flex flex-col gap-8" }, Da = { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, _a = { class: "flex flex-col gap-4" }, ha = { class: "flex gap-8" }, xa = /* @__PURE__ */ Te({
808
808
  __name: "ClosingDraftDialog",
809
809
  props: {
810
810
  show: { type: Boolean },
@@ -812,26 +812,26 @@ const Nt = Xe(
812
812
  },
813
813
  emits: ["submitted", "refresh"],
814
814
  setup(l, { emit: s }) {
815
- const e = l, u = et(), p = $e(), _ = ht(e, "show"), m = H(!1), R = H(!1), C = H(!1), x = H(new Array()), v = H(new Array()), I = He(), Y = Re(), n = Ve(), a = yt(), j = Ie(), M = nt({}), f = L(() => new Set(
815
+ const e = l, u = et(), p = $e(), _ = ht(e, "show"), m = V(!1), R = V(!1), C = V(!1), x = V(new Array()), v = V(new Array()), I = Ve(), Y = Re(), n = He(), a = yt(), B = Ie(), M = nt({}), f = U(() => new Set(
816
816
  a.skus.filter((r) => {
817
817
  var t;
818
818
  return M[(t = r.customAttributes) == null ? void 0 : t.tag];
819
819
  }).map((r) => r._id)
820
- )), g = s, b = H({
820
+ )), g = s, b = V({
821
821
  templateItem: !0,
822
822
  nonTemplateItem: !0
823
- }), $ = L(() => {
823
+ }), $ = U(() => {
824
824
  var t, y;
825
825
  const r = [...((t = e.draft) == null ? void 0 : t.items) ?? [], ...((y = e.draft) == null ? void 0 : y.negativeStockItems) ?? []];
826
826
  return f.value.size ? r.filter((d) => f.value.has(d.sku._id)) : r;
827
- }), V = L(() => {
827
+ }), H = U(() => {
828
828
  const r = $.value.map((t) => t.sku);
829
829
  return r.sort((t, y) => t.code.localeCompare(y.code)), r;
830
- }), te = L(() => $.value.groupBy(
830
+ }), te = U(() => $.value.groupBy(
831
831
  (t) => t.sku._id,
832
832
  (t) => t.measurementsAmounts.filter((y) => !y.measurement.abbrev.toLocaleLowerCase().includes("inactive")).map((y) => y.measurement.id)
833
833
  ));
834
- Le(ce), ot(
834
+ Ue(ce), ot(
835
835
  () => e.show,
836
836
  (r) => {
837
837
  r && (se.value = ve[0], ce(), b.value = {
@@ -840,10 +840,10 @@ const Nt = Xe(
840
840
  });
841
841
  }
842
842
  );
843
- const B = he(0), Q = he(100);
843
+ const j = he(0), J = he(100);
844
844
  async function ce() {
845
845
  var t, y, d;
846
- if (!j._currentLocation) return;
846
+ if (!B._currentLocation) return;
847
847
  m.value = !0;
848
848
  const r = ((t = e.draft) == null ? void 0 : t.status) === re.enum.COMPLETED;
849
849
  v.value = [];
@@ -862,7 +862,7 @@ const Nt = Xe(
862
862
  }
863
863
  const c = await I.readAdjustmentById(i), A = (c == null ? void 0 : c.skus) ?? [];
864
864
  for (const h of A) {
865
- const D = {
865
+ const k = {
866
866
  id: h.sku._id,
867
867
  balance: h.fromBalance,
868
868
  costs: h.fromCostBalances
@@ -871,7 +871,7 @@ const Nt = Xe(
871
871
  balance: h.toBalance,
872
872
  costs: h.toCostBalances
873
873
  };
874
- x.value.push(D), v.value.push(q);
874
+ x.value.push(k), v.value.push(q);
875
875
  }
876
876
  } else
877
877
  x.value = ((d = e.draft) == null ? void 0 : d.stockSnapshot) ?? [];
@@ -905,10 +905,10 @@ const Nt = Xe(
905
905
  const i = (h = e.draft) == null ? void 0 : h._rev, c = 30, A = 2e3;
906
906
  try {
907
907
  await I.recalculation.scheduleCalculateStockSnapshotAtDate(d, e.draft._id);
908
- let D = null;
909
- for (let q = 0; q < c && (D = await Y.getDraft(e.draft._id).delayed(A), D._rev === i); q++)
908
+ let k = null;
909
+ for (let q = 0; q < c && (k = await Y.getDraft(e.draft._id).delayed(A), k._rev === i); q++)
910
910
  ;
911
- if (!D || D._rev === i) {
911
+ if (!k || k._rev === i) {
912
912
  n.open({
913
913
  title: "Refresh failed",
914
914
  message: "Failed to refresh stock balance. Please try again.",
@@ -916,29 +916,29 @@ const Nt = Xe(
916
916
  }), console.error("error refreshing stock balances: there is no change in _rev");
917
917
  return;
918
918
  }
919
- g("refresh", D), x.value = D.stockSnapshot ?? [], n.open({
919
+ g("refresh", k), x.value = k.stockSnapshot ?? [], n.open({
920
920
  title: "Balance refreshed",
921
921
  message: "Stock balance has been recalculated.",
922
922
  type: "success"
923
923
  });
924
- } catch (D) {
924
+ } catch (k) {
925
925
  n.open({
926
926
  title: "Refresh failed",
927
927
  message: "Failed to refresh stock balance. Please try again.",
928
928
  type: "error"
929
- }), console.error("error refreshing stock balances", D);
929
+ }), console.error("error refreshing stock balances", k);
930
930
  } finally {
931
931
  R.value = !1;
932
932
  }
933
933
  }
934
934
  );
935
935
  }
936
- const ue = L(
936
+ const ue = U(
937
937
  () => x.value.groupBy(
938
938
  (r) => r.id,
939
939
  (r) => r.balance
940
940
  )
941
- ), de = L(() => $.value.groupBy((r) => r.sku._id));
941
+ ), de = U(() => $.value.groupBy((r) => r.sku._id));
942
942
  function oe(r) {
943
943
  return T(
944
944
  ge.FmTooltip,
@@ -953,8 +953,8 @@ const Nt = Xe(
953
953
  }
954
954
  );
955
955
  }
956
- const Ae = L(() => {
957
- const r = V.value.reduce((y, d) => {
956
+ const Ae = U(() => {
957
+ const r = H.value.reduce((y, d) => {
958
958
  var i, c;
959
959
  return Math.max(y, ((c = (i = te.value) == null ? void 0 : i.get(d._id)) == null ? void 0 : c[0].length) ?? 0);
960
960
  }, 0);
@@ -1019,10 +1019,10 @@ const Nt = Xe(
1019
1019
  },
1020
1020
  header: () => oe("Actual balance"),
1021
1021
  cell(y) {
1022
- var D;
1022
+ var k;
1023
1023
  const d = y.row.original, i = Fe.fromNumber(d.physicalBalance);
1024
1024
  let c = !0, A = d.physicalBalance;
1025
- const h = (D = v.value.find((q) => q.id === d.id)) == null ? void 0 : D.balance;
1025
+ const h = (k = v.value.find((q) => q.id === d.id)) == null ? void 0 : k.balance;
1026
1026
  return h && (Fe.equals({
1027
1027
  a: i,
1028
1028
  b: h
@@ -1137,8 +1137,8 @@ const Nt = Xe(
1137
1137
  let c = Array.from({ length: r }).map((A, h) => {
1138
1138
  if (!d[`measurementAmount${h}`])
1139
1139
  return null;
1140
- const D = d[`measurementAmount${h}`], q = d[`measurementAbbrev${h}`];
1141
- return i(D, q);
1140
+ const k = d[`measurementAmount${h}`], q = d[`measurementAbbrev${h}`];
1141
+ return i(k, q);
1142
1142
  }).filter((A) => A);
1143
1143
  return (d.baseUnitAmount || !c.length) && (c = [i(d.baseUnitAmount, d.baseUnit), ...c]), T(
1144
1144
  "div",
@@ -1153,15 +1153,15 @@ const Nt = Xe(
1153
1153
  }
1154
1154
  }
1155
1155
  ];
1156
- }), xe = L(() => Ae.value.map((r) => r.size ?? 0).reduce((r, t) => r + t)), fe = H(""), De = L(() => {
1156
+ }), xe = U(() => Ae.value.map((r) => r.size ?? 0).reduce((r, t) => r + t)), fe = V(""), ke = U(() => {
1157
1157
  var y, d;
1158
1158
  const r = ((d = (y = e.draft) == null ? void 0 : y.negativeStockItems) == null ? void 0 : d.reduce(
1159
1159
  (i, c) => (i[c.sku._id] = c, i),
1160
1160
  {}
1161
1161
  )) ?? {};
1162
- return V.value.map((i) => {
1162
+ return H.value.map((i) => {
1163
1163
  var Ce, S, z, K;
1164
- const c = (Ce = de.value.get(i._id)) == null ? void 0 : Ce[0], A = ((S = ue.value.get(i._id)) == null ? void 0 : S[0]) ?? B;
1164
+ const c = (Ce = de.value.get(i._id)) == null ? void 0 : Ce[0], A = ((S = ue.value.get(i._id)) == null ? void 0 : S[0]) ?? j;
1165
1165
  if (!c)
1166
1166
  return {
1167
1167
  id: i._id,
@@ -1175,15 +1175,15 @@ const Nt = Xe(
1175
1175
  adjustedDiffPercentage: -100,
1176
1176
  isTemplateItem: !r[i._id]
1177
1177
  };
1178
- const h = tt(c), D = (K = (z = v.value) == null ? void 0 : z.find(
1178
+ const h = tt(c), k = (K = (z = v.value) == null ? void 0 : z.find(
1179
1179
  (G) => G.id === i._id
1180
1180
  )) == null ? void 0 : K.balance, q = We(
1181
- D ?? h,
1181
+ k ?? h,
1182
1182
  A
1183
1183
  ), we = A.amount === 0 ? null : Ze(q, {
1184
1184
  ...A,
1185
1185
  amount: Math.abs(A.amount)
1186
- }), ye = we ? Ee(we, Q) : null;
1186
+ }), ye = we ? Ee(we, J) : null;
1187
1187
  return {
1188
1188
  id: i._id,
1189
1189
  code: i.code,
@@ -1197,11 +1197,11 @@ const Nt = Xe(
1197
1197
  systemBalance: +N(A),
1198
1198
  physicalBalance: +N(h),
1199
1199
  adjustedAmount: +N(q),
1200
- adjustedDiffPercentage: ye ? +N(Je(ye, 2)) : null,
1200
+ adjustedDiffPercentage: ye ? +N(Xe(ye, 2)) : null,
1201
1201
  isTemplateItem: !r[i._id]
1202
1202
  };
1203
1203
  }).filter((i) => !!(i.isTemplateItem && b.value.templateItem || !i.isTemplateItem && b.value.nonTemplateItem));
1204
- }), pe = L(() => {
1204
+ }), pe = U(() => {
1205
1205
  var t, y, d, i;
1206
1206
  if (!e.draft) return [];
1207
1207
  const r = e.draft.approvedAt ? {
@@ -1266,12 +1266,12 @@ const Nt = Xe(
1266
1266
  label: "Action history",
1267
1267
  value: "history"
1268
1268
  }
1269
- ], se = H(ve[0]), ae = L(() => {
1269
+ ], se = V(ve[0]), ae = U(() => {
1270
1270
  var d, i, c;
1271
1271
  const r = ((d = e.draft) == null ? void 0 : d.activityLogs) ?? [], t = ((i = e.draft) == null ? void 0 : i.rejectionHistory) ?? [];
1272
1272
  for (const A of t)
1273
1273
  r.find(
1274
- (D) => `${D.action}_${D.performedAt}` == `${E.enum.rejectDraft}_${A.rejectedAt}`
1274
+ (k) => `${k.action}_${k.performedAt}` == `${E.enum.rejectDraft}_${A.rejectedAt}`
1275
1275
  ) || r.push({
1276
1276
  action: E.enum.rejectDraft,
1277
1277
  performedAt: A.rejectedAt,
@@ -1280,8 +1280,8 @@ const Nt = Xe(
1280
1280
  });
1281
1281
  return (c = e.draft) != null && c.approvedAt && (r.find(
1282
1282
  (h) => {
1283
- var D;
1284
- return `${h.action}_${h.performedAt}` == `${E.enum.approveDraft}_${(D = e.draft) == null ? void 0 : D.approvedAt}`;
1283
+ var k;
1284
+ return `${h.action}_${h.performedAt}` == `${E.enum.approveDraft}_${(k = e.draft) == null ? void 0 : k.approvedAt}`;
1285
1285
  }
1286
1286
  ) || r.push({
1287
1287
  action: E.enum.approveDraft,
@@ -1290,7 +1290,7 @@ const Nt = Xe(
1290
1290
  remark: e.draft.approveRemark
1291
1291
  })), r.sort((A, h) => new Date(h.performedAt).getTime() - new Date(A.performedAt).getTime()).map(
1292
1292
  (A) => ({
1293
- header: Ue(A.action),
1293
+ header: Le(A.action),
1294
1294
  date: le(A.performedAt),
1295
1295
  info: [
1296
1296
  {
@@ -1304,19 +1304,19 @@ const Nt = Xe(
1304
1304
  ]
1305
1305
  })
1306
1306
  );
1307
- }), ke = L(() => {
1307
+ }), De = U(() => {
1308
1308
  var i, c, A, h;
1309
1309
  if ((i = e == null ? void 0 : e.draft) != null && i.approvedAt) return "Draft is already approved.";
1310
1310
  if (((c = e.draft) == null ? void 0 : c.status) !== re.enum.DRAFT) return "Status is not draft.";
1311
- const r = De.value.some((D) => D.physicalBalance < 0), t = ((h = (A = u.stockBalance.skus) == null ? void 0 : A.filter((D) => D.balance.amount < 0)) == null ? void 0 : h.map((D) => D.id)) ?? [], y = new Set(V.value.map((D) => D._id)), d = t.filter((D) => !y.has(D)).length;
1311
+ const r = ke.value.some((k) => k.physicalBalance < 0), t = ((h = (A = u.stockBalance.skus) == null ? void 0 : A.filter((k) => k.balance.amount < 0)) == null ? void 0 : h.map((k) => k.id)) ?? [], y = new Set(H.value.map((k) => k._id)), d = t.filter((k) => !y.has(k)).length;
1312
1312
  return [
1313
1313
  r ? "Negative total exist." : null,
1314
1314
  d ? "Negative stock is not included in this draft. Reopen draft in POS and apply changes." : null
1315
- ].filter((D) => D).join(" ");
1315
+ ].filter((k) => k).join(" ");
1316
1316
  });
1317
1317
  return (r, t) => {
1318
- const y = P("FmButtonGroup"), d = P("FmMenuDivider"), i = P("FmCard"), c = P("FmButton"), A = P("FmCircularProgress"), h = P("FmChip"), D = P("FmTextField"), q = P("FmIcon"), we = P("FmTable"), ye = P("FmSpacer"), Ne = P("FmTooltip"), Ce = P("FmSideSheet");
1319
- return w(), X(Ce, {
1318
+ const y = P("FmButtonGroup"), d = P("FmMenuDivider"), i = P("FmCard"), c = P("FmButton"), A = P("FmCircularProgress"), h = P("FmChip"), k = P("FmTextField"), q = P("FmIcon"), we = P("FmTable"), ye = P("FmSpacer"), Ne = P("FmTooltip"), Ce = P("FmSideSheet");
1319
+ return w(), Q(Ce, {
1320
1320
  "dismiss-away": "",
1321
1321
  "max-width": 9999,
1322
1322
  "model-value": F(_),
@@ -1327,16 +1327,16 @@ const Nt = Xe(
1327
1327
  var S, z, K, G;
1328
1328
  return [
1329
1329
  o("div", ha, [
1330
- ((S = e.draft) == null ? void 0 : S.status) === F(re).enum.DRAFT ? (w(), U(J, { key: 0 }, [
1331
- ke.value ? (w(), X(Ne, {
1330
+ ((S = e.draft) == null ? void 0 : S.status) === F(re).enum.DRAFT ? (w(), L(X, { key: 0 }, [
1331
+ De.value ? (w(), Q(Ne, {
1332
1332
  key: 0,
1333
1333
  "z-index": 51
1334
1334
  }, {
1335
1335
  content: O(() => [
1336
- Z(W(ke.value), 1)
1336
+ Z(W(De.value), 1)
1337
1337
  ]),
1338
1338
  default: O(() => [
1339
- k(c, {
1339
+ D(c, {
1340
1340
  disabled: "",
1341
1341
  key: "approve key",
1342
1342
  label: "Approve",
@@ -1344,19 +1344,19 @@ const Nt = Xe(
1344
1344
  })
1345
1345
  ]),
1346
1346
  _: 1
1347
- })) : (w(), X(c, {
1347
+ })) : (w(), Q(c, {
1348
1348
  key: "approve key",
1349
1349
  label: "Approve",
1350
1350
  onClick: t[6] || (t[6] = () => e.draft && F(p).approveDraft(e.draft, () => g("submitted")))
1351
1351
  }))
1352
1352
  ], 64)) : ee("", !0),
1353
- ((z = e.draft) == null ? void 0 : z.status) === F(re).enum.DRAFT ? (w(), X(c, {
1353
+ ((z = e.draft) == null ? void 0 : z.status) === F(re).enum.DRAFT ? (w(), Q(c, {
1354
1354
  key: 1,
1355
1355
  label: "Reject",
1356
1356
  variant: "destructive",
1357
1357
  onClick: t[7] || (t[7] = () => e.draft && F(p).rejectDraft(e.draft, () => g("submitted")))
1358
1358
  })) : ee("", !0),
1359
- (K = e.draft) != null && K.approvedAt && ((G = e.draft) == null ? void 0 : G.status) !== F(re).enum.COMPLETED ? (w(), X(c, {
1359
+ (K = e.draft) != null && K.approvedAt && ((G = e.draft) == null ? void 0 : G.status) !== F(re).enum.COMPLETED ? (w(), Q(c, {
1360
1360
  key: 2,
1361
1361
  label: "Sync",
1362
1362
  loading: C.value,
@@ -1366,7 +1366,7 @@ const Nt = Xe(
1366
1366
  }));
1367
1367
  })
1368
1368
  }, null, 8, ["loading"])) : ee("", !0),
1369
- k(c, {
1369
+ D(c, {
1370
1370
  label: "Close",
1371
1371
  variant: "tertiary",
1372
1372
  onClick: t[9] || (t[9] = (ne) => _.value = !1)
@@ -1377,14 +1377,14 @@ const Nt = Xe(
1377
1377
  default: O(() => [
1378
1378
  o("div", zt, [
1379
1379
  o("div", null, [
1380
- k(y, {
1380
+ D(y, {
1381
1381
  items: ve,
1382
1382
  modelValue: se.value,
1383
1383
  "onUpdate:modelValue": t[0] || (t[0] = (S) => se.value = S)
1384
1384
  }, null, 8, ["modelValue"])
1385
1385
  ]),
1386
- se.value.value === "overview" ? (w(), U(J, { key: 0 }, [
1387
- k(i, {
1386
+ se.value.value === "overview" ? (w(), L(X, { key: 0 }, [
1387
+ D(i, {
1388
1388
  variant: "outlined",
1389
1389
  class: "flex flex-col gap-8 px-12 py-16"
1390
1390
  }, {
@@ -1395,13 +1395,13 @@ const Nt = Xe(
1395
1395
  t[11] || (t[11] = o("div", { class: "fm-typo-en-body-lg-600" }, "Closing summary", -1)),
1396
1396
  o("div", Yt, [
1397
1397
  o("div", {
1398
- class: be(["fm-status-badge", F(Be)(((S = r.draft) == null ? void 0 : S.status) ?? "DRAFT")])
1399
- }, W(F(Ue)(((z = r.draft) == null ? void 0 : z.status) ?? "")), 3)
1398
+ class: be(["fm-status-badge", F(je)(((S = r.draft) == null ? void 0 : S.status) ?? "DRAFT")])
1399
+ }, W(F(Le)(((z = r.draft) == null ? void 0 : z.status) ?? "")), 3)
1400
1400
  ])
1401
1401
  ]),
1402
- k(d),
1402
+ D(d),
1403
1403
  o("div", Kt, [
1404
- (w(!0), U(J, null, _e(pe.value, (K, G) => (w(), U("div", {
1404
+ (w(!0), L(X, null, _e(pe.value, (K, G) => (w(), L("div", {
1405
1405
  class: "flex flex-col gap-4",
1406
1406
  key: G
1407
1407
  }, [
@@ -1416,10 +1416,10 @@ const Nt = Xe(
1416
1416
  _: 1
1417
1417
  }),
1418
1418
  o("div", Zt, [
1419
- o("div", Jt, [
1419
+ o("div", Xt, [
1420
1420
  t[12] || (t[12] = o("div", { class: "flex-1 fm-typo-en-title-sm-600 text-fm-color-typo-primary" }, " Closing items ", -1)),
1421
- m.value ? ee("", !0) : (w(), U("div", Qt, [
1422
- r.draft && r.draft.status !== F(re).enum.COMPLETED ? (w(), X(c, {
1421
+ m.value ? ee("", !0) : (w(), L("div", Jt, [
1422
+ r.draft && r.draft.status !== F(re).enum.COMPLETED ? (w(), Q(c, {
1423
1423
  key: 0,
1424
1424
  label: "Refresh balance",
1425
1425
  "prepend-icon": "refresh",
@@ -1430,7 +1430,7 @@ const Nt = Xe(
1430
1430
  loading: R.value,
1431
1431
  onClick: ie
1432
1432
  }, null, 8, ["loading"])) : ee("", !0),
1433
- k(c, {
1433
+ D(c, {
1434
1434
  label: "Export data",
1435
1435
  "prepend-icon": "download",
1436
1436
  variant: "secondary",
@@ -1445,37 +1445,37 @@ const Nt = Xe(
1445
1445
  })
1446
1446
  ]))
1447
1447
  ]),
1448
- m.value ? (w(), U("div", Xt, [
1448
+ m.value ? (w(), L("div", Qt, [
1449
1449
  t[14] || (t[14] = o("div", { class: "h-80" }, null, -1)),
1450
1450
  o("div", ea, [
1451
1451
  o("div", null, [
1452
- k(A, { size: "md" })
1452
+ D(A, { size: "md" })
1453
1453
  ]),
1454
1454
  t[13] || (t[13] = o("div", { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, " Fetching info... ", -1))
1455
1455
  ]),
1456
1456
  t[15] || (t[15] = o("div", { class: "h-80" }, null, -1))
1457
- ])) : (w(), U(J, { key: 1 }, [
1457
+ ])) : (w(), L(X, { key: 1 }, [
1458
1458
  o("div", ta, [
1459
1459
  o("div", aa, [
1460
- k(h, {
1460
+ D(h, {
1461
1461
  label: "Template Item(s)",
1462
1462
  selected: b.value.templateItem,
1463
1463
  onClick: t[2] || (t[2] = (S) => b.value.templateItem = !b.value.templateItem)
1464
1464
  }, null, 8, ["selected"]),
1465
- k(h, {
1465
+ D(h, {
1466
1466
  label: "Non-template Item(s)",
1467
1467
  selected: b.value.nonTemplateItem,
1468
1468
  onClick: t[3] || (t[3] = (S) => b.value.nonTemplateItem = !b.value.nonTemplateItem)
1469
1469
  }, null, 8, ["selected"])
1470
1470
  ]),
1471
- k(D, {
1471
+ D(k, {
1472
1472
  modelValue: fe.value,
1473
1473
  "onUpdate:modelValue": t[4] || (t[4] = (S) => fe.value = S),
1474
1474
  placeholder: "Filter items"
1475
1475
  }, null, 8, ["modelValue"])
1476
1476
  ]),
1477
- F(a).skuTags.size ? (w(), U("div", na, [
1478
- (w(!0), U(J, null, _e(F(a).skuTags.keys(), (S) => (w(), X(h, {
1477
+ F(a).skuTags.size ? (w(), L("div", na, [
1478
+ (w(!0), L(X, null, _e(F(a).skuTags.keys(), (S) => (w(), Q(h, {
1479
1479
  key: `${S}`,
1480
1480
  label: `${S}`,
1481
1481
  selectable: "",
@@ -1483,7 +1483,7 @@ const Nt = Xe(
1483
1483
  onClick: (z) => M[`${S}`] = !M[`${S}`]
1484
1484
  }, {
1485
1485
  default: O(() => [
1486
- M[`${S}`] ? (w(), X(q, {
1486
+ M[`${S}`] ? (w(), Q(q, {
1487
1487
  key: 0,
1488
1488
  name: "check",
1489
1489
  class: "text-white",
@@ -1506,9 +1506,9 @@ const Nt = Xe(
1506
1506
  o("div", {
1507
1507
  style: Ke({ minWidth: `${xe.value}px` })
1508
1508
  }, [
1509
- k(we, {
1509
+ D(we, {
1510
1510
  "column-defs": Ae.value,
1511
- "row-data": De.value,
1511
+ "row-data": ke.value,
1512
1512
  "search-value": fe.value
1513
1513
  }, null, 8, ["column-defs", "row-data", "search-value"])
1514
1514
  ], 4)
@@ -1516,9 +1516,9 @@ const Nt = Xe(
1516
1516
  ], 64))
1517
1517
  ])
1518
1518
  ], 64)) : ee("", !0),
1519
- se.value.value === "history" ? (w(), U("div", sa, [
1520
- ae.value.length ? (w(), U("div", ca, [
1521
- (w(!0), U(J, null, _e(ae.value, (S, z) => (w(), U(J, { key: z }, [
1519
+ se.value.value === "history" ? (w(), L("div", sa, [
1520
+ ae.value.length ? (w(), L("div", ca, [
1521
+ (w(!0), L(X, null, _e(ae.value, (S, z) => (w(), L(X, { key: z }, [
1522
1522
  o("div", ia, [
1523
1523
  o("div", ua, [
1524
1524
  o("div", da, [
@@ -1565,19 +1565,19 @@ const Nt = Xe(
1565
1565
  ])
1566
1566
  ]),
1567
1567
  o("div", Aa, [
1568
- k(i, {
1568
+ D(i, {
1569
1569
  variant: "outlined",
1570
1570
  class: "py-12 px-16"
1571
1571
  }, {
1572
1572
  default: O(() => [
1573
- o("div", Da, [
1574
- (w(!0), U(J, null, _e(S.info, (K, G) => (w(), U("div", {
1573
+ o("div", ka, [
1574
+ (w(!0), L(X, null, _e(S.info, (K, G) => (w(), L("div", {
1575
1575
  key: G,
1576
1576
  class: "flex flex-col gap-4"
1577
1577
  }, [
1578
- o("div", ka, W(K == null ? void 0 : K.label), 1),
1578
+ o("div", Da, W(K == null ? void 0 : K.label), 1),
1579
1579
  o("div", _a, [
1580
- (w(!0), U(J, null, _e(K == null ? void 0 : K.values, (ne, me) => (w(), U("div", {
1580
+ (w(!0), L(X, null, _e(K == null ? void 0 : K.values, (ne, me) => (w(), L("div", {
1581
1581
  key: me,
1582
1582
  class: "fm-typo-en-body-lg-600"
1583
1583
  }, W(ne), 1))), 128))
@@ -1590,8 +1590,8 @@ const Nt = Xe(
1590
1590
  ])
1591
1591
  ])
1592
1592
  ], 64))), 128))
1593
- ])) : (w(), U("div", ra, [
1594
- k(ye),
1593
+ ])) : (w(), L("div", ra, [
1594
+ D(ye),
1595
1595
  o("div", null, [
1596
1596
  o("img", {
1597
1597
  src: F(Ct),
@@ -1600,8 +1600,8 @@ const Nt = Xe(
1600
1600
  ]),
1601
1601
  t[16] || (t[16] = o("div", { class: "fm-typo-en-body-lg-600" }, W("No records found"), -1)),
1602
1602
  t[17] || (t[17] = o("div", { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary px-16" }, W("You can track approval and rejection history here"), -1)),
1603
- k(ye),
1604
- k(ye)
1603
+ D(ye),
1604
+ D(ye)
1605
1605
  ]))
1606
1606
  ])) : ee("", !0)
1607
1607
  ])
@@ -1610,12 +1610,12 @@ const Nt = Xe(
1610
1610
  }, 8, ["model-value"]);
1611
1611
  };
1612
1612
  }
1613
- }), wa = { class: "flex-1 flex flex-col gap-8" }, Ca = { class: "flex flex-col" }, Sa = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Fa = { class: "fm-typo-en-body-lg-600 text-fm-color-typo-primary" }, ja = { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary line-clamp-2" }, Ba = { class: "fm-typo-en-body-lg-400 line-clamp-2" }, La = /* @__PURE__ */ Te({
1613
+ }), wa = { class: "flex-1 flex flex-col gap-8" }, Ca = { class: "flex flex-col" }, Sa = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Fa = { class: "fm-typo-en-body-lg-600 text-fm-color-typo-primary" }, Ba = { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary line-clamp-2" }, ja = { class: "fm-typo-en-body-lg-400 line-clamp-2" }, Ua = /* @__PURE__ */ Te({
1614
1614
  __name: "ClosingDraftView",
1615
1615
  setup(l) {
1616
- const { t: s } = Qe(), { viewDraft: e } = $e(), { viewClosingDraftProps: u, viewClosingDraftShow: p } = wt($e()), _ = Ie(), m = Nt(), R = gt(), { breakpoints: C } = xt();
1616
+ const { t: s } = Je(), { viewDraft: e } = $e(), { viewClosingDraftProps: u, viewClosingDraftShow: p } = wt($e()), _ = Ie(), m = Nt(), R = gt(), { breakpoints: C } = xt();
1617
1617
  _.watchLocation(m.fetchDrafts);
1618
- const x = L(() => m.loading), v = H(""), I = L(() => C.value.xs || C.value.sm), Y = L(() => I.value ? 10 : 20);
1618
+ const x = U(() => m.loading), v = V(""), I = U(() => C.value.xs || C.value.sm), Y = U(() => I.value ? 10 : 20);
1619
1619
  function n(M) {
1620
1620
  switch (M) {
1621
1621
  case "refresh":
@@ -1625,7 +1625,7 @@ const Nt = Xe(
1625
1625
  function a(M) {
1626
1626
  return M;
1627
1627
  }
1628
- const j = L(() => I.value ? [
1628
+ const B = U(() => I.value ? [
1629
1629
  {
1630
1630
  label: s("inventory.common.refresh"),
1631
1631
  value: "refresh",
@@ -1640,10 +1640,10 @@ const Nt = Xe(
1640
1640
  ]);
1641
1641
  return (M, f) => {
1642
1642
  const g = P("FmTable");
1643
- return w(), U(J, null, [
1644
- k(bt, {
1643
+ return w(), L(X, null, [
1644
+ D(bt, {
1645
1645
  title: F(s)("inventory.closing.draft.title"),
1646
- actions: j.value,
1646
+ actions: B.value,
1647
1647
  "onClick:action": n
1648
1648
  }, {
1649
1649
  default: O(() => [
@@ -1656,13 +1656,13 @@ const Nt = Xe(
1656
1656
  }
1657
1657
  ])
1658
1658
  }, [
1659
- k(At, {
1659
+ D(At, {
1660
1660
  "change-location": "",
1661
1661
  searchable: "",
1662
1662
  search: v.value,
1663
1663
  "onUpdate:search": f[0] || (f[0] = (b) => v.value = b)
1664
1664
  }, null, 8, ["search"]),
1665
- k(g, {
1665
+ D(g, {
1666
1666
  style: Ke(F(R).tableHeight),
1667
1667
  "column-defs": F(m).columnDefs,
1668
1668
  "row-data": F(m).drafts,
@@ -1672,41 +1672,41 @@ const Nt = Xe(
1672
1672
  "page-size": Y.value
1673
1673
  }, {
1674
1674
  "list-row": O((b) => [
1675
- k(Dt, {
1675
+ D(kt, {
1676
1676
  row: b,
1677
1677
  onRowClick: ($) => F(e)($)
1678
1678
  }, {
1679
1679
  default: O(($) => {
1680
- var V, te, B, Q, ce, ie, ue, de, oe, Ae, xe, fe, De, pe, ve, se, ae, ke, r, t;
1680
+ var H, te, j, J, ce, ie, ue, de, oe, Ae, xe, fe, ke, pe, ve, se, ae, De, r, t;
1681
1681
  return [
1682
1682
  o("div", wa, [
1683
1683
  o("div", Ca, [
1684
1684
  o("div", Sa, [
1685
- k(F(je), {
1686
- render: (B = (te = (V = $._id) == null ? void 0 : V.column) == null ? void 0 : te.columnDef) == null ? void 0 : B.cell,
1687
- props: (ce = (Q = $._id) == null ? void 0 : Q.getContext) == null ? void 0 : ce.call(Q)
1685
+ D(F(Be), {
1686
+ render: (j = (te = (H = $._id) == null ? void 0 : H.column) == null ? void 0 : te.columnDef) == null ? void 0 : j.cell,
1687
+ props: (ce = (J = $._id) == null ? void 0 : J.getContext) == null ? void 0 : ce.call(J)
1688
1688
  }, null, 8, ["render", "props"])
1689
1689
  ]),
1690
1690
  o("div", Fa, [
1691
- k(F(je), {
1691
+ D(F(Be), {
1692
1692
  render: (de = (ue = (ie = $.name) == null ? void 0 : ie.column) == null ? void 0 : ue.columnDef) == null ? void 0 : de.cell,
1693
1693
  props: (Ae = (oe = $.name) == null ? void 0 : oe.getContext) == null ? void 0 : Ae.call(oe)
1694
1694
  }, null, 8, ["render", "props"])
1695
1695
  ]),
1696
- o("div", ja, W([
1696
+ o("div", Ba, W([
1697
1697
  ...b.original.items.slice(0, 3).map((y) => y.sku.name),
1698
1698
  ...b.original.items.length >= 3 ? [`and ${b.original.items.length - 3} more items`] : []
1699
1699
  ].join(", ")), 1),
1700
- o("div", Ba, [
1701
- k(F(je), {
1702
- render: (De = (fe = (xe = $.ref) == null ? void 0 : xe.column) == null ? void 0 : fe.columnDef) == null ? void 0 : De.cell,
1700
+ o("div", ja, [
1701
+ D(F(Be), {
1702
+ render: (ke = (fe = (xe = $.ref) == null ? void 0 : xe.column) == null ? void 0 : fe.columnDef) == null ? void 0 : ke.cell,
1703
1703
  props: (ve = (pe = $.ref) == null ? void 0 : pe.getContext) == null ? void 0 : ve.call(pe)
1704
1704
  }, null, 8, ["render", "props"])
1705
1705
  ])
1706
1706
  ]),
1707
1707
  o("div", null, [
1708
- k(F(je), {
1709
- render: (ke = (ae = (se = $.status) == null ? void 0 : se.column) == null ? void 0 : ae.columnDef) == null ? void 0 : ke.cell,
1708
+ D(F(Be), {
1709
+ render: (De = (ae = (se = $.status) == null ? void 0 : se.column) == null ? void 0 : ae.columnDef) == null ? void 0 : De.cell,
1710
1710
  props: (t = (r = $.status) == null ? void 0 : r.getContext) == null ? void 0 : t.call(r)
1711
1711
  }, null, 8, ["render", "props"])
1712
1712
  ])
@@ -1722,8 +1722,8 @@ const Nt = Xe(
1722
1722
  ]),
1723
1723
  _: 1
1724
1724
  }, 8, ["title", "actions"]),
1725
- (w(), X(st, { to: "body" }, [
1726
- k(xa, rt(F(u), {
1725
+ (w(), Q(st, { to: "body" }, [
1726
+ D(xa, rt(F(u), {
1727
1727
  show: F(p),
1728
1728
  "onUpdate:show": f[2] || (f[2] = (b) => Ye(p) ? p.value = b : null),
1729
1729
  onSubmitted: f[3] || (f[3] = () => (p.value = !1, F(m).fetchDrafts())),
@@ -1735,5 +1735,5 @@ const Nt = Xe(
1735
1735
  }
1736
1736
  });
1737
1737
  export {
1738
- La as default
1738
+ Ua as default
1739
1739
  };