@feedmepos/mf-inventory-portal 0.0.23-dev.37 → 0.0.23-dev.38
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.
- package/dist/{App-CocJ-ge2.js → App-DQgtWkQj.js} +20 -20
- package/dist/{ApprovalView-BwoVumaD.js → ApprovalView-CvSK9fGA.js} +10 -10
- package/dist/{BindingsDialog-ChGPGBfA.js → BindingsDialog-BAC0_xCP.js} +8 -8
- package/dist/{BindingsPicker-DlQ4Y-_S.js → BindingsPicker-ecWMwsNp.js} +3 -3
- package/dist/{BindingsTable-BViS1Vbk.js → BindingsTable-D5kQydOU.js} +10 -10
- package/dist/{ClosingDraftView-0s7elpJE.js → ClosingDraftView-CnHQ59rX.js} +46 -46
- package/dist/{ClosingTemplateView-ijUARoMf.js → ClosingTemplateView-vRTsVZ0c.js} +21 -21
- package/dist/{FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-f3zAXx0v.js → FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-CpIzIvkU.js} +17 -17
- package/dist/{FmUnitInput.vue_vue_type_script_setup_true_lang-B_VkK2l-.js → FmUnitInput.vue_vue_type_script_setup_true_lang-CNzEHF-R.js} +37 -37
- package/dist/{IngredientBindedItem.vue_vue_type_script_setup_true_lang-DaOZl7x7.js → IngredientBindedItem.vue_vue_type_script_setup_true_lang-DBhBaRrd.js} +1 -1
- package/dist/{IngredientGroupView-sBJJcpUH.js → IngredientGroupView-BLsABZ3h.js} +1 -1
- package/dist/IngredientsView-Cs4TIf6V.js +1794 -0
- package/dist/{IntegrationView-BCnyd5ZT.js → IntegrationView-BqAqngtM.js} +137 -137
- package/dist/{InventoryBindingForm-vNrC4UVe.js → InventoryBindingForm-D54V_qZQ.js} +1 -1
- package/dist/{InventoryBindingForm.vue_vue_type_script_setup_true_lang-CAKAtpAv.js → InventoryBindingForm.vue_vue_type_script_setup_true_lang-KIW9J7Xn.js} +106 -96
- package/dist/{InventoryBindingSummary-BV-mteuK.js → InventoryBindingSummary-htT7GNto.js} +1 -1
- package/dist/{NumberPrecisionInput.vue_vue_type_script_setup_true_lang-CLJq06wA.js → NumberPrecisionInput.vue_vue_type_script_setup_true_lang-BlEgALMj.js} +1 -1
- package/dist/{PremiumBadge.vue_vue_type_script_setup_true_lang-DGMYtoSD.js → PremiumBadge.vue_vue_type_script_setup_true_lang-DHbxXDGy.js} +9 -9
- package/dist/{PurchaseOrderPrintPreview-Dw9MTN87.js → PurchaseOrderPrintPreview-hmzxKuIa.js} +5 -5
- package/dist/{ReceiveRequestView-DA1y32Ri.js → ReceiveRequestView-_YioyWqU.js} +182 -182
- package/dist/{RecipeView-CUJ8JTg4.js → RecipeView-88KJ0nvU.js} +3 -3
- package/dist/StockView-R4cnEbHQ.js +1818 -0
- package/dist/{SupplierView-B25JfCjl.js → SupplierView-CevGG507.js} +4 -4
- package/dist/{TransferDetails.vue_vue_type_script_setup_true_lang-CaHSzoOL.js → TransferDetails.vue_vue_type_script_setup_true_lang-CeWP9msS.js} +52 -52
- package/dist/{TransferTemplateView-B-NHZD3a.js → TransferTemplateView-QDniAq8o.js} +114 -114
- package/dist/{UnitView-BwyqEvF5.js → UnitView-SjwJ3lZ0.js} +14 -14
- package/dist/{WarehouseView-DKN9oNF0.js → WarehouseView-55LiPQXG.js} +70 -70
- package/dist/api/bill.d.ts +240 -84
- package/dist/api/inventory.d.ts +15 -6
- package/dist/{app-pBbFb2kn.js → app-UTiudUUR.js} +351 -336
- package/dist/app.d.ts +6 -0
- package/dist/app.js +1 -1
- package/dist/components/FmCustomAttribute.vue.d.ts +23 -0
- package/dist/components/FmLockableField.vue.d.ts +37 -0
- package/dist/components/inventory-binding/InventoryBinding.vue.d.ts +3 -1
- package/dist/components/shell/inventory/binding-ui.vue.d.ts +3 -1
- package/dist/{decimal-DlS5ULFC.js → decimal-tyBgHJ47.js} +1 -1
- package/dist/feature-z7inw9y6.js +946 -0
- package/dist/{format-unit-display-pWImoMk4.js → format-unit-display-DN0KtCh2.js} +61 -61
- package/dist/index-Dj2Ccgp1.js +29202 -0
- package/dist/{StockView-C8uDlvit.js → index-DlhdTaa8.js} +2218 -3854
- package/dist/{stock-Pgzh63s3.js → stock-CxRxidDu.js} +1 -1
- package/dist/stores/feature.d.ts +5 -0
- package/dist/stores/inventory.d.ts +20 -8
- package/dist/stores/supplier.d.ts +1 -1
- package/dist/{supplier-B_UGrq8S.js → supplier-BhyiTwSJ.js} +1 -1
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/dist/{use-inventory-binding-dialog-DcCaNUdQ.js → use-inventory-binding-dialog-DwSvUvRl.js} +1 -1
- package/dist/views/closing-draft/components/closing-draft-dialog/ClosingDraftDialog.vue.d.ts +8 -4
- package/dist/views/closing-draft/composables/use-closing-draft-table.d.ts +48 -24
- package/dist/views/closing-template/components/closing-template-form/composables/use-closing-template-items.d.ts +2 -1
- package/dist/views/closing-template/composables/use-closing-template-actions.d.ts +24 -12
- package/dist/views/closing-template/composables/use-closing-template-table.d.ts +24 -12
- package/dist/views/ingredient-group/composables/use-ingredient-group-table.d.ts +6 -3
- package/dist/views/ingredients/components/convert/ConvertFormProps.d.ts +1 -0
- package/dist/views/ingredients/components/ingredient-form/IngredientForm.vue.d.ts +4 -2
- package/dist/views/ingredients/components/inventory-binding/InventoryBindingForm.vue.d.ts +1 -0
- package/dist/views/ingredients/composables/use-ingredient-table.d.ts +2 -1
- package/dist/views/receive-request/components/transfer-form/SparkIcon.vue.d.ts +1 -1
- package/dist/views/receive-request/components/transfer-form/TransferForm.vue.d.ts +34 -17
- package/dist/views/receive-request/components/transfer-form/components/ForecastStock.vue.d.ts +4 -2
- package/dist/views/receive-request/components/transfer-form/composables/use-transfer-items.d.ts +2 -1
- package/dist/views/receive-request/composables/use-receive-request-form.d.ts +48 -24
- package/dist/views/receive-request/composables/use-receive-request-table.d.ts +48 -24
- package/dist/views/recipe/components/recipe-form/RecipeForm.vue.d.ts +2 -0
- package/dist/views/stock/components/StockRecordCard.vue.d.ts +120 -42
- package/dist/views/stock/components/dialog/AdjustedItemForm.vue.d.ts +4 -2
- package/dist/views/transfer-template/components/transfer-template-form/composables/use-transfer-template-items.d.ts +2 -1
- package/dist/views/transfer-template/composables/use-transfer-template-actions.d.ts +24 -12
- package/dist/views/transfer-template/composables/use-transfer-template-table.d.ts +24 -12
- package/package.json +7 -6
- package/dist/IngredientsView-F25fK95q.js +0 -1657
- package/dist/feature-j9EM4xzR.js +0 -92
- package/dist/index-BILt4nGV.js +0 -12087
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ref as D, h as F, defineComponent as O, resolveComponent as R, openBlock as k, createElementBlock as I, createElementVNode as _, normalizeClass as Y, createTextVNode as Fe, toDisplayString as C, unref as v, createCommentVNode as K, createVNode as T, withCtx as P, Fragment as H, renderList as
|
|
2
|
-
import {
|
|
1
|
+
import { ref as D, h as F, defineComponent as O, resolveComponent as R, openBlock as k, createElementBlock as I, createElementVNode as _, normalizeClass as Y, createTextVNode as Fe, toDisplayString as C, unref as v, createCommentVNode as K, createVNode as T, withCtx as P, Fragment as H, renderList as J, computed as E, watch as Re, createSlots as Pe, createBlock as V, isRef as je, normalizeStyle as Ye, Teleport as Ge, normalizeProps as Ke, guardReactiveProps as Je, mergeProps as We } from "vue";
|
|
2
|
+
import { X as qe, u as le, a9 as Xe, D as Se, h as N, f as Qe, e as Ae, aa as oe, q as Ze, ab as Ee, r as Ue, a as ae, b as et, s as tt, v as Ve, w as nt, x as ot, d as z, G as j, H as st, ac as lt, l as at, E as Ne, A as rt, J as it, _ as ct, ad as ne, y as mt, z as ut, B as dt } from "./app-UTiudUUR.js";
|
|
3
3
|
import { useCoreStore as re, useI18n as B } from "@feedmepos/mf-common";
|
|
4
4
|
import { useDialogChild as pt, useSnackbar as Z, useDialog as ie, FmButtonVariant as De, components as L, useProxiedModel as ft, useBreakpoints as vt } from "@feedmepos/ui-library";
|
|
5
5
|
import { defineStore as Be, storeToRefs as Le } from "pinia";
|
|
@@ -95,7 +95,7 @@ const ee = qe((r, s) => {
|
|
|
95
95
|
accessorKey: "_id",
|
|
96
96
|
header: () => s("inventory.closing.table.createdAt"),
|
|
97
97
|
cell(y) {
|
|
98
|
-
return
|
|
98
|
+
return Xe(`${y.getValue()}`);
|
|
99
99
|
},
|
|
100
100
|
enableSorting: !0
|
|
101
101
|
},
|
|
@@ -170,7 +170,7 @@ const ee = qe((r, s) => {
|
|
|
170
170
|
Se[N.Edit],
|
|
171
171
|
Se[N.Delete]
|
|
172
172
|
];
|
|
173
|
-
return
|
|
173
|
+
return Qe(u, (n) => d(n, h));
|
|
174
174
|
},
|
|
175
175
|
enableSorting: !1,
|
|
176
176
|
size: 40,
|
|
@@ -553,7 +553,7 @@ const Tt = { class: "flex items-center gap-12 pl-8" }, $t = { class: "flex flex-
|
|
|
553
553
|
T(t, { "z-index": 50 }, {
|
|
554
554
|
content: P(() => [
|
|
555
555
|
_("ol", null, [
|
|
556
|
-
(k(!0), I(H, null,
|
|
556
|
+
(k(!0), I(H, null, J(o.errors, (i, d) => (k(), I("li", { key: d }, C(i), 1))), 128))
|
|
557
557
|
])
|
|
558
558
|
]),
|
|
559
559
|
default: P(() => [
|
|
@@ -710,7 +710,7 @@ const Tt = { class: "flex items-center gap-12 pl-8" }, $t = { class: "flex flex-
|
|
|
710
710
|
]))
|
|
711
711
|
], 2),
|
|
712
712
|
g.value.length ? (k(), I("div", Ut, [
|
|
713
|
-
(k(!0), I(H, null,
|
|
713
|
+
(k(!0), I(H, null, J(g.value, ($, b) => (k(), I("div", {
|
|
714
714
|
key: b,
|
|
715
715
|
class: "flex gap-8 items-center"
|
|
716
716
|
}, [
|
|
@@ -729,7 +729,7 @@ const Tt = { class: "flex items-center gap-12 pl-8" }, $t = { class: "flex flex-
|
|
|
729
729
|
]), 1032, ["class", "label", "button-label"]),
|
|
730
730
|
d.value ? (k(), I("div", Nt, [
|
|
731
731
|
_("div", Bt, C(v(m)("inventory.ingredient.import.summary")), 1),
|
|
732
|
-
(k(!0), I(H, null,
|
|
732
|
+
(k(!0), I(H, null, J(f.value, (c, $) => (k(), V(Me, {
|
|
733
733
|
key: $,
|
|
734
734
|
name: c.template.name,
|
|
735
735
|
locations: c.template.locations,
|
|
@@ -737,7 +737,7 @@ const Tt = { class: "flex items-center gap-12 pl-8" }, $t = { class: "flex flex-
|
|
|
737
737
|
errors: c.errors,
|
|
738
738
|
type: "create"
|
|
739
739
|
}, null, 8, ["name", "locations", "items", "errors"]))), 128)),
|
|
740
|
-
(k(!0), I(H, null,
|
|
740
|
+
(k(!0), I(H, null, J(p.value, (c) => (k(), V(Me, {
|
|
741
741
|
key: c.template._id,
|
|
742
742
|
name: c.template.name,
|
|
743
743
|
locations: c.template.locations,
|
|
@@ -1135,7 +1135,7 @@ function zt(r) {
|
|
|
1135
1135
|
})
|
|
1136
1136
|
};
|
|
1137
1137
|
}
|
|
1138
|
-
const Ht = { class: "flex flex-col gap-16 py-12" }, Ot = { class: "flex" }, jt = { class: "flex-1 flex flex-col" }, Yt = { class: "fm-typo-en-title-sm-600 text-fm-color-typo-primary" }, Gt = { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, Kt = { class: "flex flex-col gap-4" },
|
|
1138
|
+
const Ht = { class: "flex flex-col gap-16 py-12" }, Ot = { class: "flex" }, jt = { class: "flex-1 flex flex-col" }, Yt = { class: "fm-typo-en-title-sm-600 text-fm-color-typo-primary" }, Gt = { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, Kt = { class: "flex flex-col gap-4" }, Jt = /* @__PURE__ */ O({
|
|
1139
1139
|
__name: "ClosingTemplateItem",
|
|
1140
1140
|
props: {
|
|
1141
1141
|
cellByColId: {},
|
|
@@ -1162,7 +1162,7 @@ const Ht = { class: "flex flex-col gap-16 py-12" }, Ot = { class: "flex" }, jt =
|
|
|
1162
1162
|
]),
|
|
1163
1163
|
_("div", Kt, [
|
|
1164
1164
|
t[0] || (t[0] = _("div", { class: "fm-typo-en-body-lg-600 text-fm-color-typo-primary" }, null, -1)),
|
|
1165
|
-
(k(!0), I(H, null,
|
|
1165
|
+
(k(!0), I(H, null, J(l.value, (m) => {
|
|
1166
1166
|
var y, h, u;
|
|
1167
1167
|
return k(), I("div", {
|
|
1168
1168
|
key: m.id
|
|
@@ -1177,7 +1177,7 @@ const Ht = { class: "flex flex-col gap-16 py-12" }, Ot = { class: "flex" }, jt =
|
|
|
1177
1177
|
]);
|
|
1178
1178
|
};
|
|
1179
1179
|
}
|
|
1180
|
-
}),
|
|
1180
|
+
}), Wt = { class: "flex flex-col gap-16" }, qt = { class: "flex flex-col gap-24" }, Xt = { class: "flex flex-col gap-16" }, Qt = { class: "flex items-center" }, Zt = { class: "flex-1 fm-typo-en-title-sm-600" }, en = { class: "flex flex-col gap-16" }, tn = { class: "flex items-center" }, nn = { class: "flex-1 gap-8 fm-typo-en-title-sm-600" }, on = /* @__PURE__ */ O({
|
|
1181
1181
|
__name: "ClosingTemplateForm",
|
|
1182
1182
|
props: {
|
|
1183
1183
|
modelValue: {},
|
|
@@ -1270,7 +1270,7 @@ const Ht = { class: "flex flex-col gap-16 py-12" }, Ot = { class: "flex" }, jt =
|
|
|
1270
1270
|
disabled: n.disabled
|
|
1271
1271
|
}, {
|
|
1272
1272
|
default: P(() => [
|
|
1273
|
-
_("div",
|
|
1273
|
+
_("div", Wt, [
|
|
1274
1274
|
_("div", qt, [
|
|
1275
1275
|
T(x, {
|
|
1276
1276
|
label: v(e)("inventory.closing.form.name"),
|
|
@@ -1287,8 +1287,8 @@ const Ht = { class: "flex flex-col gap-16 py-12" }, Ot = { class: "flex" }, jt =
|
|
|
1287
1287
|
}, null, 8, ["label", "modelValue"])
|
|
1288
1288
|
])
|
|
1289
1289
|
]),
|
|
1290
|
-
_("div",
|
|
1291
|
-
_("div",
|
|
1290
|
+
_("div", Xt, [
|
|
1291
|
+
_("div", Qt, [
|
|
1292
1292
|
_("div", Zt, C(v(e)("inventory.closing.form.locations")), 1),
|
|
1293
1293
|
T(c, {
|
|
1294
1294
|
disabled: n.disabled,
|
|
@@ -1351,7 +1351,7 @@ const Ht = { class: "flex flex-col gap-16 py-12" }, Ot = { class: "flex" }, jt =
|
|
|
1351
1351
|
key: v(l).items.map((S) => S.sku._id).join(".")
|
|
1352
1352
|
}, {
|
|
1353
1353
|
default: P((S) => [
|
|
1354
|
-
T(
|
|
1354
|
+
T(Jt, {
|
|
1355
1355
|
row: M,
|
|
1356
1356
|
"cell-by-col-id": S
|
|
1357
1357
|
}, null, 8, ["row", "cell-by-col-id"])
|
|
@@ -1756,14 +1756,14 @@ const un = /* @__PURE__ */ ct(cn, [["render", mn]]), dn = { class: "flex flex-co
|
|
|
1756
1756
|
onRowClick: (U) => v(l)(U)
|
|
1757
1757
|
}, {
|
|
1758
1758
|
default: P((U) => {
|
|
1759
|
-
var me, ue, de,
|
|
1759
|
+
var me, ue, de, W, pe, fe, ve, ge, q, ye, he, be, _e, xe, we, X, ke, Te, $e, Ce, Q, Ie;
|
|
1760
1760
|
return [
|
|
1761
1761
|
_("div", $n, [
|
|
1762
1762
|
_("div", Cn, [
|
|
1763
1763
|
_("div", In, [
|
|
1764
1764
|
T(v(j), {
|
|
1765
1765
|
render: (de = (ue = (me = U._id) == null ? void 0 : me.column) == null ? void 0 : ue.columnDef) == null ? void 0 : de.cell,
|
|
1766
|
-
props: (pe = (
|
|
1766
|
+
props: (pe = (W = U._id) == null ? void 0 : W.getContext) == null ? void 0 : pe.call(W)
|
|
1767
1767
|
}, null, 8, ["render", "props"])
|
|
1768
1768
|
]),
|
|
1769
1769
|
_("div", Sn, [
|
|
@@ -1782,14 +1782,14 @@ const un = /* @__PURE__ */ ct(cn, [["render", mn]]), dn = { class: "flex flex-co
|
|
|
1782
1782
|
_("div", Mn, [
|
|
1783
1783
|
T(v(j), {
|
|
1784
1784
|
render: (we = (xe = (_e = U.ref) == null ? void 0 : _e.column) == null ? void 0 : xe.columnDef) == null ? void 0 : we.cell,
|
|
1785
|
-
props: (ke = (
|
|
1785
|
+
props: (ke = (X = U.ref) == null ? void 0 : X.getContext) == null ? void 0 : ke.call(X)
|
|
1786
1786
|
}, null, 8, ["render", "props"])
|
|
1787
1787
|
])
|
|
1788
1788
|
]),
|
|
1789
1789
|
_("div", null, [
|
|
1790
1790
|
T(v(j), {
|
|
1791
1791
|
render: (Ce = ($e = (Te = U.status) == null ? void 0 : Te.column) == null ? void 0 : $e.columnDef) == null ? void 0 : Ce.cell,
|
|
1792
|
-
props: (Ie = (
|
|
1792
|
+
props: (Ie = (Q = U.status) == null ? void 0 : Q.getContext) == null ? void 0 : Ie.call(Q)
|
|
1793
1793
|
}, null, 8, ["render", "props"])
|
|
1794
1794
|
])
|
|
1795
1795
|
])
|
|
@@ -1805,8 +1805,8 @@ const un = /* @__PURE__ */ ct(cn, [["render", mn]]), dn = { class: "flex flex-co
|
|
|
1805
1805
|
_: 1
|
|
1806
1806
|
}, 8, ["title", "actions"]),
|
|
1807
1807
|
(k(), V(Ge, { to: "body" }, [
|
|
1808
|
-
T(un, Ke(
|
|
1809
|
-
T(rn,
|
|
1808
|
+
T(un, Ke(Je(v(f))), null, 16),
|
|
1809
|
+
T(rn, We(v(g), {
|
|
1810
1810
|
onSubmitted: A[2] || (A[2] = (S) => v(d).fetchTemplates())
|
|
1811
1811
|
}), null, 16)
|
|
1812
1812
|
]))
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { i as k, t as
|
|
2
|
-
import { u as j } from "./supplier-
|
|
3
|
-
import { P as S } from "./format-unit-display-
|
|
4
|
-
import { computed as y, defineComponent as $, mergeModels as W, useModel as J, resolveComponent as U, openBlock as T, createElementBlock as A, normalizeStyle as K, createElementVNode as
|
|
1
|
+
import { i as k, t as B, an as w, u as H, as as I, aC as R, aD as M } from "./app-UTiudUUR.js";
|
|
2
|
+
import { u as j } from "./supplier-BhyiTwSJ.js";
|
|
3
|
+
import { P as S } from "./format-unit-display-DN0KtCh2.js";
|
|
4
|
+
import { computed as y, defineComponent as $, mergeModels as W, useModel as J, resolveComponent as U, openBlock as T, createElementBlock as A, normalizeStyle as K, createElementVNode as D, createVNode as Q, withCtx as X, createBlock as x, createCommentVNode as N, Fragment as Y, renderList as Z, unref as V } from "vue";
|
|
5
5
|
function z(l, r, e) {
|
|
6
6
|
var s;
|
|
7
7
|
if (!!r.measurement === !!e && ((s = r.measurement) == null ? void 0 : s.id) === e)
|
|
@@ -26,12 +26,12 @@ function oe(l, r, e, n) {
|
|
|
26
26
|
(a) => a.skuId === l._id
|
|
27
27
|
)) == null ? void 0 : u.defaultCost, o = l.defaultCost ? z(l.unit, l.defaultCost, l.trackingMeasurement) : void 0, s = t ?? o, i = s == null ? void 0 : s.costPerUnit, c = i ? s != null && s.measurement ? +k(i) / +k(s == null ? void 0 : s.measurement.conversion) : +k(i) : void 0, p = c ? e ? c * +k(e.conversion) : c : void 0, f = p ? +k(r) * p : void 0;
|
|
28
28
|
return f ? {
|
|
29
|
-
...
|
|
30
|
-
currency:
|
|
29
|
+
...B(f ?? 0, 2),
|
|
30
|
+
currency: w()
|
|
31
31
|
} : {
|
|
32
32
|
amount: 0,
|
|
33
33
|
precision: 0,
|
|
34
|
-
currency:
|
|
34
|
+
currency: w()
|
|
35
35
|
};
|
|
36
36
|
}
|
|
37
37
|
function F(l) {
|
|
@@ -56,7 +56,7 @@ function C(l) {
|
|
|
56
56
|
};
|
|
57
57
|
}
|
|
58
58
|
function re(l, r, e = !1, n = !1) {
|
|
59
|
-
const t = j(), o =
|
|
59
|
+
const t = j(), o = H();
|
|
60
60
|
o.watchLocation(async () => {
|
|
61
61
|
var v;
|
|
62
62
|
await t.readSuppliers();
|
|
@@ -236,36 +236,36 @@ const G = { class: "sticky top-0 bg-white mb-8" }, q = { class: "overflow-y-auto
|
|
|
236
236
|
class: "relative",
|
|
237
237
|
style: K({ maxHeight: `${o.maxHeight}px`, width: o.width })
|
|
238
238
|
}, [
|
|
239
|
-
|
|
239
|
+
D("div", G, [
|
|
240
240
|
Q(c, {
|
|
241
241
|
modelValue: e.value,
|
|
242
242
|
"onUpdate:modelValue": s[1] || (s[1] = (f) => e.value = f),
|
|
243
243
|
placeholder: "Filter options"
|
|
244
244
|
}, {
|
|
245
245
|
append: X(() => [
|
|
246
|
-
e.value ? (T(),
|
|
246
|
+
e.value ? (T(), x(i, {
|
|
247
247
|
key: 0,
|
|
248
248
|
variant: "tertiary",
|
|
249
249
|
"prepend-icon": "close",
|
|
250
250
|
onClick: s[0] || (s[0] = (f) => e.value = "")
|
|
251
|
-
})) :
|
|
251
|
+
})) : N("", !0)
|
|
252
252
|
]),
|
|
253
253
|
_: 1
|
|
254
254
|
}, 8, ["modelValue"])
|
|
255
255
|
]),
|
|
256
|
-
|
|
257
|
-
(T(!0), A(Y, null, Z(t.value, (f, L) => (T(),
|
|
256
|
+
D("div", q, [
|
|
257
|
+
(T(!0), A(Y, null, Z(t.value, (f, L) => (T(), x(p, {
|
|
258
258
|
key: L,
|
|
259
259
|
label: f.label,
|
|
260
260
|
sublabel: f.sublabel,
|
|
261
|
-
"model-value":
|
|
262
|
-
onClick: () => o.handleItemChange(
|
|
261
|
+
"model-value": V(M)(o.modelValue, f.value),
|
|
262
|
+
onClick: () => o.handleItemChange(V(M)(o.modelValue, f.value), f),
|
|
263
263
|
onVnodeMounted: (b) => {
|
|
264
264
|
var g;
|
|
265
|
-
return
|
|
265
|
+
return V(M)(o.modelValue, f.value) && ((g = b.el) == null || g.scrollIntoView({ behavior: "smooth", block: "center" }), console.log("scrollTo", b.el)), void 0;
|
|
266
266
|
}
|
|
267
267
|
}, null, 8, ["label", "sublabel", "model-value", "onClick", "onVnodeMounted"]))), 128)),
|
|
268
|
-
t.value.length ?
|
|
268
|
+
t.value.length ? N("", !0) : (T(), x(p, {
|
|
269
269
|
key: 0,
|
|
270
270
|
disabled: "",
|
|
271
271
|
label: "No options available"
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { defineComponent as oe, mergeModels as
|
|
2
|
-
import {
|
|
1
|
+
import { defineComponent as oe, mergeModels as O, useModel as se, computed as v, ref as P, watch as z, inject as ie, resolveComponent as b, openBlock as f, createElementBlock as y, createElementVNode as u, createVNode as M, withCtx as h, renderSlot as T, normalizeClass as V, toDisplayString as x, withDirectives as le, vModelText as ae, createCommentVNode as q, createTextVNode as ue, createBlock as W, Fragment as re, renderList as me } from "vue";
|
|
2
|
+
import { $ as I, I as k, P as L, L as ce, i as g, aA as de, t as pe, K as fe, ag as ve, ay as be, ax as ye } from "./app-UTiudUUR.js";
|
|
3
3
|
import "@feedmepos/ui-library";
|
|
4
4
|
function E() {
|
|
5
5
|
return {
|
|
@@ -27,7 +27,7 @@ function G(l, d = !1) {
|
|
|
27
27
|
if (s != !0)
|
|
28
28
|
return d ? s : !0;
|
|
29
29
|
const F = typeof l == "number" ? l : L(l, r.modelValue.measurement);
|
|
30
|
-
return ce(+r.amountAsString).precision > F ? `Cannot exceed precision more than ${
|
|
30
|
+
return ce(+r.amountAsString).precision > F ? `Cannot exceed precision more than ${g({
|
|
31
31
|
amount: 1,
|
|
32
32
|
precision: F
|
|
33
33
|
})}` : !0;
|
|
@@ -39,7 +39,7 @@ function Le(l) {
|
|
|
39
39
|
return d(r.modelValue.amount);
|
|
40
40
|
};
|
|
41
41
|
}
|
|
42
|
-
const Me = { class: "flex flex-col" },
|
|
42
|
+
const Me = { class: "flex flex-col" }, ge = { class: "flex flex-col" }, he = { class: "flex-1" }, xe = { class: "flex items-center gap-4" }, Fe = { class: "flex-1 flex gap-4" }, Ae = { class: "shrink-0 grow basis-2/5" }, _e = {
|
|
43
43
|
key: 0,
|
|
44
44
|
class: "text-fm-color-typo-secondary"
|
|
45
45
|
}, Pe = {
|
|
@@ -51,12 +51,12 @@ const Me = { class: "flex flex-col" }, he = { class: "flex flex-col" }, ge = { c
|
|
|
51
51
|
}, Re = {
|
|
52
52
|
class: "flex items-center",
|
|
53
53
|
style: { "pointer-events": "none" }
|
|
54
|
-
},
|
|
54
|
+
}, Ue = {
|
|
55
55
|
class: "flex items-center",
|
|
56
56
|
style: { "pointer-events": "none" }
|
|
57
|
-
},
|
|
57
|
+
}, $e = /* @__PURE__ */ oe({
|
|
58
58
|
__name: "FmUnitInput",
|
|
59
|
-
props: /* @__PURE__ */
|
|
59
|
+
props: /* @__PURE__ */ O({
|
|
60
60
|
modelValue: {},
|
|
61
61
|
unit: {},
|
|
62
62
|
rules: {},
|
|
@@ -103,7 +103,7 @@ const Me = { class: "flex flex-col" }, he = { class: "flex flex-col" }, ge = { c
|
|
|
103
103
|
modelValue: {},
|
|
104
104
|
modelModifiers: {}
|
|
105
105
|
}),
|
|
106
|
-
emits: /* @__PURE__ */
|
|
106
|
+
emits: /* @__PURE__ */ O(["update:amount", "update:measurement"], ["update:modelValue"]),
|
|
107
107
|
setup(l, { emit: d }) {
|
|
108
108
|
const t = l, r = d, s = se(l, "modelValue"), F = k(), B = v(() => {
|
|
109
109
|
var n;
|
|
@@ -111,7 +111,7 @@ const Me = { class: "flex flex-col" }, he = { class: "flex flex-col" }, ge = { c
|
|
|
111
111
|
}), c = P((() => {
|
|
112
112
|
var o;
|
|
113
113
|
const e = ((o = s.value) == null ? void 0 : o.amount) ?? I.reset(), n = be(e), i = t.formatMinimumPrecision ?? n.precision, a = ye(n, i);
|
|
114
|
-
return
|
|
114
|
+
return g(a);
|
|
115
115
|
})());
|
|
116
116
|
z(c, (e) => {
|
|
117
117
|
const n = F(e), i = t.precision ?? B.value, o = typeof t.formatMinimumPrecision == "number" && t.formatMinimumPrecision > i ? t.formatMinimumPrecision : i;
|
|
@@ -120,10 +120,10 @@ const Me = { class: "flex flex-col" }, he = { class: "flex flex-col" }, ge = { c
|
|
|
120
120
|
amount: pe(+e, o)
|
|
121
121
|
}), r("update:amount", e);
|
|
122
122
|
});
|
|
123
|
-
const
|
|
123
|
+
const Z = Symbol.for("fm:form-state"), D = ie(Z, null), A = v(() => t.disabled ?? (D == null ? void 0 : D.getDisabled()) ?? !1), J = P(), R = P(!1), $ = P(!1), Q = v(() => R.value || $.value), X = v(() => {
|
|
124
124
|
var a;
|
|
125
|
-
const i = [...t.unit.measurements.filter((o) => !o.name.toLocaleLowerCase().includes("inactive")).filter((o) => o.abbrev !== t.unit.abbrev || +
|
|
126
|
-
(o) => `${o.abbrev}${
|
|
125
|
+
const i = [...t.unit.measurements.filter((o) => !o.name.toLocaleLowerCase().includes("inactive")).filter((o) => o.abbrev !== t.unit.abbrev || +g(o.conversion) != 1).groupBy(
|
|
126
|
+
(o) => `${o.abbrev}${g(o.conversion)}`
|
|
127
127
|
).values()].map((o) => o[0]).flat();
|
|
128
128
|
return [
|
|
129
129
|
{
|
|
@@ -135,7 +135,7 @@ const Me = { class: "flex flex-col" }, he = { class: "flex flex-col" }, ge = { c
|
|
|
135
135
|
value: o.id
|
|
136
136
|
}))
|
|
137
137
|
];
|
|
138
|
-
}),
|
|
138
|
+
}), U = v({
|
|
139
139
|
get() {
|
|
140
140
|
var e, n;
|
|
141
141
|
return ((n = (e = s.value) == null ? void 0 : e.measurement) == null ? void 0 : n.id) ?? null;
|
|
@@ -155,7 +155,7 @@ const Me = { class: "flex flex-col" }, he = { class: "flex flex-col" }, ge = { c
|
|
|
155
155
|
}
|
|
156
156
|
}
|
|
157
157
|
});
|
|
158
|
-
z(
|
|
158
|
+
z(U, (e, n) => {
|
|
159
159
|
var m;
|
|
160
160
|
if (!t.convertAmountOnChangeUnit)
|
|
161
161
|
return;
|
|
@@ -163,9 +163,9 @@ const Me = { class: "flex flex-col" }, he = { class: "flex flex-col" }, ge = { c
|
|
|
163
163
|
value: w,
|
|
164
164
|
precision: N
|
|
165
165
|
});
|
|
166
|
-
c.value =
|
|
166
|
+
c.value = g(S);
|
|
167
167
|
});
|
|
168
|
-
const
|
|
168
|
+
const C = v(() => {
|
|
169
169
|
var e, n;
|
|
170
170
|
return ((n = (e = s.value) == null ? void 0 : e.measurement) == null ? void 0 : n.abbrev) ?? t.unit.abbrev;
|
|
171
171
|
}), Y = v(
|
|
@@ -179,27 +179,27 @@ const Me = { class: "flex flex-col" }, he = { class: "flex flex-col" }, ge = { c
|
|
|
179
179
|
H(),
|
|
180
180
|
typeof t.precision == "number" ? G(t.precision) : G(t.unit)
|
|
181
181
|
] : [], ...Y.value]);
|
|
182
|
-
function
|
|
182
|
+
function j(e) {
|
|
183
183
|
const n = t.precision ?? B.value, a = typeof t.formatMinimumPrecision == "number" && t.formatMinimumPrecision > n ? t.formatMinimumPrecision : n, o = e.toFixed(a), p = o.includes(".") ? o.replace(/0+$/, "") : o;
|
|
184
184
|
return p.endsWith(".") ? p.slice(0, p.length - 1) : p;
|
|
185
185
|
}
|
|
186
186
|
function te() {
|
|
187
187
|
if (!t.stepper)
|
|
188
188
|
return;
|
|
189
|
-
const e = +c.value + +
|
|
190
|
-
c.value =
|
|
189
|
+
const e = +c.value + +g(t.stepper);
|
|
190
|
+
c.value = j(e);
|
|
191
191
|
}
|
|
192
192
|
function ne() {
|
|
193
193
|
if (!t.stepper)
|
|
194
194
|
return;
|
|
195
|
-
const e = +c.value - +
|
|
196
|
-
c.value =
|
|
195
|
+
const e = +c.value - +g(t.stepper);
|
|
196
|
+
c.value = j(e);
|
|
197
197
|
}
|
|
198
198
|
return (e, n) => {
|
|
199
199
|
const i = b("FmLabel"), a = b("FmIcon"), o = b("FmMenuItem"), p = b("FmMenu"), w = b("FmTooltip"), N = b("FmField"), S = b("FmFormGroup");
|
|
200
200
|
return f(), y("div", Me, [
|
|
201
|
-
u("div",
|
|
202
|
-
u("div",
|
|
201
|
+
u("div", ge, [
|
|
202
|
+
u("div", he, [
|
|
203
203
|
M(i, {
|
|
204
204
|
label: e.label,
|
|
205
205
|
disabled: e.disabled,
|
|
@@ -208,7 +208,7 @@ const Me = { class: "flex flex-col" }, he = { class: "flex flex-col" }, ge = { c
|
|
|
208
208
|
}, null, 8, ["label", "disabled", "required", "optional"])
|
|
209
209
|
]),
|
|
210
210
|
M(N, { focused: Q.value }, {
|
|
211
|
-
default:
|
|
211
|
+
default: h(() => [
|
|
212
212
|
u("div", xe, [
|
|
213
213
|
T(e.$slots, "prepend"),
|
|
214
214
|
u("div", Fe, [
|
|
@@ -224,7 +224,7 @@ const Me = { class: "flex flex-col" }, he = { class: "flex flex-col" }, ge = { c
|
|
|
224
224
|
key: 1,
|
|
225
225
|
type: "text",
|
|
226
226
|
ref_key: "inputRef",
|
|
227
|
-
ref:
|
|
227
|
+
ref: J,
|
|
228
228
|
onFocus: n[0] || (n[0] = () => R.value = !0),
|
|
229
229
|
onBlur: n[1] || (n[1] = () => R.value = !1),
|
|
230
230
|
"onUpdate:modelValue": n[2] || (n[2] = (m) => c.value = m),
|
|
@@ -242,30 +242,30 @@ const Me = { class: "flex flex-col" }, he = { class: "flex flex-col" }, ge = { c
|
|
|
242
242
|
class: V([e.disabled ? "text-fm-color-typo-disabled" : "text-fm-color-typo-secondary"])
|
|
243
243
|
}, [
|
|
244
244
|
M(w, { "z-index": 51 }, {
|
|
245
|
-
content:
|
|
246
|
-
ue(x(
|
|
245
|
+
content: h(() => [
|
|
246
|
+
ue(x(C.value), 1)
|
|
247
247
|
]),
|
|
248
|
-
default:
|
|
249
|
-
e.disableUnit ? (f(), y("div", Pe, x(
|
|
248
|
+
default: h(() => [
|
|
249
|
+
e.disableUnit ? (f(), y("div", Pe, x(C.value), 1)) : (f(), W(p, {
|
|
250
250
|
key: 1,
|
|
251
|
-
onMenuChanged: n[3] || (n[3] = (m) =>
|
|
251
|
+
onMenuChanged: n[3] || (n[3] = (m) => $.value = m),
|
|
252
252
|
"z-index": 500,
|
|
253
253
|
placement: e.placement,
|
|
254
254
|
disabled: e.disabled
|
|
255
255
|
}, {
|
|
256
|
-
"menu-button":
|
|
256
|
+
"menu-button": h(() => [
|
|
257
257
|
u("div", Ie, [
|
|
258
|
-
u("div", ke, x(
|
|
258
|
+
u("div", ke, x(C.value), 1),
|
|
259
259
|
M(a, { name: "keyboard_arrow_down" })
|
|
260
260
|
])
|
|
261
261
|
]),
|
|
262
|
-
default:
|
|
262
|
+
default: h(() => [
|
|
263
263
|
u("div", Be, [
|
|
264
264
|
(f(!0), y(re, null, me(X.value, (m) => (f(), W(o, {
|
|
265
265
|
key: m.value ?? void 0,
|
|
266
266
|
label: m.label,
|
|
267
|
-
"model-value": m.value ==
|
|
268
|
-
onClick: (_) =>
|
|
267
|
+
"model-value": m.value == U.value,
|
|
268
|
+
onClick: (_) => U.value = m.value
|
|
269
269
|
}, null, 8, ["label", "model-value", "onClick"]))), 128))
|
|
270
270
|
])
|
|
271
271
|
]),
|
|
@@ -291,7 +291,7 @@ const Me = { class: "flex flex-col" }, he = { class: "flex flex-col" }, ge = { c
|
|
|
291
291
|
class: "w-24 h-12 flex items-center justify-center fm-corner-radius-sm bg-fm-color-neutral-gray-100 hover:bg-fm-color-neutral-gray-200",
|
|
292
292
|
onClick: ne
|
|
293
293
|
}, [
|
|
294
|
-
u("div",
|
|
294
|
+
u("div", Ue, [
|
|
295
295
|
M(a, {
|
|
296
296
|
name: "expand_more",
|
|
297
297
|
size: "md"
|
|
@@ -320,7 +320,7 @@ const Me = { class: "flex flex-col" }, he = { class: "flex flex-col" }, ge = { c
|
|
|
320
320
|
});
|
|
321
321
|
export {
|
|
322
322
|
Se as F,
|
|
323
|
-
|
|
323
|
+
$e as _,
|
|
324
324
|
Ve as a,
|
|
325
325
|
Le as b,
|
|
326
326
|
H as c,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineComponent as p, openBlock as s, createElementBlock as n, createElementVNode as r, toDisplayString as o, unref as l, Fragment as d, renderList as x } from "vue";
|
|
2
|
-
import { i as a,
|
|
2
|
+
import { i as a, K as y } from "./app-UTiudUUR.js";
|
|
3
3
|
import { useI18n as _ } from "@feedmepos/mf-common";
|
|
4
4
|
const v = { class: "flex flex-col" }, g = { class: "flex flex-row fm-typo-en-body-md-600 bg-fm-color-neutral-gray-100 text-fm-color-typo-secondary h-48 items-center" }, h = { class: "flex-1 py-8 px-16" }, b = {
|
|
5
5
|
class: "flex-0 py-8 px-16",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ref as C, computed as F, defineComponent as Y, resolveComponent as S, openBlock as M, createBlock as O, withCtx as R, createElementVNode as x, createVNode as g, unref as l, createElementBlock as ee, toDisplayString as j, createTextVNode as te, watch as ue, isRef as ce, normalizeClass as de, normalizeStyle as me, createSlots as pe, Teleport as fe, normalizeProps as ve, guardReactiveProps as ge } from "vue";
|
|
2
|
-
import { a as J, d as h, e as B, f as ye, D as oe, h as Q,
|
|
2
|
+
import { a as J, d as h, e as B, f as ye, D as oe, h as Q, H as be, l as _e, A as xe, J as ne, o as se, u as ke, y as he, z as we, B as Se, E as Ie, G as ae } from "./app-UTiudUUR.js";
|
|
3
3
|
import { useDialog as le, useSnackbar as Z, useProxiedModel as Fe, useBreakpoints as Ce } from "@feedmepos/ui-library";
|
|
4
4
|
import { useI18n as W } from "@feedmepos/mf-common";
|
|
5
5
|
import { defineStore as ie, storeToRefs as re } from "pinia";
|