@feedmepos/mf-inventory-portal 0.0.23-dev.2 → 0.0.23-dev.21
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-DRE3c1lJ.js → App-CvIvF0fg.js} +59 -51
- package/dist/{ApprovalView-B4ZYcS3B.js → ApprovalView-BOn2HDVY.js} +20 -23
- package/dist/{BindingsDialog-Df1yrWHU.js → BindingsDialog-9qfADiSA.js} +7 -7
- package/dist/{BindingsPicker-BERMWh4w.js → BindingsPicker-CpV9uOqj.js} +7 -8
- package/dist/{BindingsTable-DRIapOWW.js → BindingsTable-BYScxUTj.js} +16 -20
- package/dist/ClosingDraftView-DM7-3zOd.js +1116 -0
- package/dist/{ClosingTemplateView-CbFn3Sdy.js → ClosingTemplateView-Cye5VPAM.js} +66 -76
- package/dist/{FmDroppableField-8RzKjEdL.js → FmDroppableField-AIKfZo3H.js} +1 -1
- package/dist/FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-CQUsooGm.js +282 -0
- package/dist/{FmUnitInput.vue_vue_type_script_setup_true_lang-BHSGZyJL.js → FmUnitInput.vue_vue_type_script_setup_true_lang-CFQc-CBX.js} +121 -119
- package/dist/{IngredientBindedItem.vue_vue_type_script_setup_true_lang-DH5IQchQ.js → IngredientBindedItem.vue_vue_type_script_setup_true_lang-2r8mut0B.js} +7 -7
- package/dist/{IngredientGroupView-DoETcEvV.js → IngredientGroupView-RNokzPJa.js} +30 -36
- package/dist/IngredientsView-M7K_GAEO.js +1660 -0
- package/dist/{IntegrationView-D1HeBiGF.js → IntegrationView-D9a8d1sO.js} +18 -20
- package/dist/{InventoryBindingForm-Dmz9BQ37.js → InventoryBindingForm-B0Gx5N1p.js} +1 -1
- package/dist/{InventoryBindingForm.vue_vue_type_script_setup_true_lang-DoyqVBOd.js → InventoryBindingForm.vue_vue_type_script_setup_true_lang-DEOudgKD.js} +15 -17
- package/dist/{InventoryBindingSummary-DrpwiRGZ.js → InventoryBindingSummary-C16Nc5aN.js} +1 -1
- package/dist/{NumberPrecisionInput.vue_vue_type_script_setup_true_lang-yNEswIEI.js → NumberPrecisionInput.vue_vue_type_script_setup_true_lang-CZiypEex.js} +1 -1
- package/dist/{PremiumBadge.vue_vue_type_script_setup_true_lang-Br4_VUza.js → PremiumBadge.vue_vue_type_script_setup_true_lang-BbYZwclN.js} +8 -8
- package/dist/{PurchaseOrderPrintPreview-cp671yWE.js → PurchaseOrderPrintPreview-DdKF8g0J.js} +13 -14
- package/dist/ReceiveRequestView-DBPRR6fz.js +4186 -0
- package/dist/{RecipeView-CD_dAWLo.js → RecipeView-CzUgVxKz.js} +58 -63
- package/dist/{StockView-DfUzFC1b.js → StockView-DCO3N1FS.js} +1338 -1446
- package/dist/{SupplierView-DB-zrNxh.js → SupplierView-CzV6DYSj.js} +2345 -783
- package/dist/TransferDetails.vue_vue_type_script_setup_true_lang-00pcY0qu.js +1228 -0
- package/dist/TransferTemplateView-uL5PId9-.js +1265 -0
- package/dist/{UnitView-BlC9-WOA.js → UnitView-d-mCs-cS.js} +40 -44
- package/dist/{WarehouseView-CgEY87Lo.js → WarehouseView-B7z8m-Hv.js} +67 -73
- package/dist/api/adjustment-template.d.ts +23 -0
- package/dist/api/bill.d.ts +2 -2
- package/dist/api/closing-draft.d.ts +6 -0
- package/dist/api/closing.d.ts +1 -0
- package/dist/api/netsuite.d.ts +69 -0
- package/dist/app-CTCC1zfY.js +58871 -0
- package/dist/app.d.ts +56 -0
- package/dist/app.js +2 -2
- package/dist/components/FmMinMaxInputRules.d.ts +4 -1
- package/dist/components/FmMultiselectDialogProps.d.ts +1 -0
- package/dist/components/row-action.enum.d.ts +1 -0
- package/dist/composable/defineDeepModel.d.ts +1 -1
- package/dist/{decimal-D7BCubZO.js → decimal-DhUR6QsF.js} +1 -1
- package/dist/{feature-BR-MsGYt.js → feature-DiGS5Fa4.js} +23 -9
- package/dist/format-unit-display-MRARpSlY.js +1210 -0
- package/dist/index-BSN3RnCl.js +12087 -0
- package/dist/netsuite-CIibMNer.js +251 -0
- package/dist/router/name.d.ts +2 -0
- package/dist/stock-COHpOTJk.js +110 -0
- package/dist/stores/feature.d.ts +2 -0
- package/dist/stores/integration/netsuite.d.ts +81 -0
- package/dist/stores/inventory.d.ts +1 -4
- package/dist/style.css +1 -1
- package/dist/{supplier-aBuwVukl.js → supplier-csNwTHYl.js} +15 -15
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/dist/{use-inventory-binding-dialog-CLQ0LUmW.js → use-inventory-binding-dialog-172A48Xx.js} +10 -11
- package/dist/views/adjustment-template/wastage-template/WastageTemplateDetails.vue.d.ts +2 -0
- package/dist/views/adjustment-template/wastage-template/WastageTemplateDialog.vue.d.ts +22 -0
- package/dist/views/adjustment-template/wastage-template/WastageTemplatePublish.vue.d.ts +6 -0
- package/dist/views/adjustment-template/wastage-template/WastageTemplateView.vue.d.ts +2 -0
- package/dist/views/adjustment-template/wastage-template/actions.d.ts +1295 -0
- package/dist/views/adjustment-template/wastage-template/form/WastageTemplateForm.vue.d.ts +16 -0
- package/dist/views/adjustment-template/wastage-template/form/WastageTemplateItemTable.vue.d.ts +35 -0
- package/dist/views/adjustment-template/wastage-template/form/useAdjustmentTemplateItems.d.ts +20 -0
- package/dist/views/adjustment-template/wastage-template/props.d.ts +29 -0
- package/dist/views/adjustment-template/wastage-template/table.d.ts +1273 -0
- package/dist/views/closing-draft/ClosingDraftView.vue.d.ts +2 -0
- package/dist/views/closing-draft/components/closing-draft-action/ClosingDraftAction.vue.d.ts +22 -0
- package/dist/views/closing-draft/components/closing-draft-dialog/ClosingDraftDialog.vue.d.ts +451 -0
- package/dist/views/closing-draft/composables/use-closing-draft-actions.d.ts +25 -0
- package/dist/views/closing-draft/composables/use-closing-draft-table.d.ts +2601 -0
- package/dist/views/closing-draft/helpers/draft-status-to-class-name.helper.d.ts +1 -0
- package/dist/views/closing-draft/helpers/export-draft.helper.d.ts +19 -0
- package/dist/views/closing-draft/helpers/get-calculated-total.helper.d.ts +4 -0
- package/dist/views/closing-template/composables/use-closing-template-actions.d.ts +24 -192
- package/dist/views/closing-template/composables/use-closing-template-table.d.ts +24 -192
- package/dist/views/receive-request/components/transfer-form/TransferForm.vue.d.ts +34 -34
- package/dist/views/receive-request/components/transfer-form/composables/use-transfer-items.d.ts +1 -0
- package/dist/views/receive-request/composables/use-receive-request-form.d.ts +54 -54
- package/dist/views/receive-request/composables/use-receive-request-table.d.ts +54 -54
- package/dist/views/receive-request/helper/check-netsuite-subsidiary.helper.d.ts +1 -0
- package/dist/views/stock/components/StockRecordCard.vue.d.ts +1 -1
- package/dist/views/stock/components/dialog/AdjustedItemForm.vue.d.ts +2 -2
- package/dist/views/stock/helper/compute-summary-total.d.ts +2 -2
- package/dist/views/transfer-template/components/transfer-template-form/composables/use-transfer-template-items.d.ts +8 -8
- package/dist/views/transfer-template/composables/use-transfer-template-actions.d.ts +96 -96
- package/dist/views/transfer-template/composables/use-transfer-template-table.d.ts +96 -96
- package/dist/{xlsx-BbtURTDy.js → xlsx-CH-bhcOL.js} +1 -1
- package/dist/{xlsx.util-zYS4OJFi.js → xlsx.util-4aHI7W-Z.js} +1 -1
- package/package.json +3 -3
- package/dist/FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-7JYNssTm.js +0 -267
- package/dist/FmInventoryTableToolbar.vue_vue_type_script_setup_true_lang-KbYSywk2.js +0 -436
- package/dist/FmMultiselectDialog-Da9JMCYa.js +0 -415
- package/dist/IngredientsView-DHAhj9pV.js +0 -1613
- package/dist/ReceiveRequestView-C1WBlpho.js +0 -4082
- package/dist/TableActionableRow.vue_vue_type_script_setup_true_lang-DlNJ6kRg.js +0 -135
- package/dist/TransferDetails.vue_vue_type_script_setup_true_lang-2mzqFGCz.js +0 -1144
- package/dist/TransferTemplateView-CaAJrqU6.js +0 -1262
- package/dist/_plugin-vue_export-helper-CHgC5LLL.js +0 -9
- package/dist/app-CAyFhmAz.js +0 -33457
- package/dist/date2-D9i5izMt.js +0 -117
- package/dist/dayjs.min-SJKP9zBL.js +0 -282
- package/dist/defineDeepModel-DS4Shctf.js +0 -13
- package/dist/format-time-from-id-CUby60uW.js +0 -15
- package/dist/format-unit-display-D25Al2JZ.js +0 -1198
- package/dist/fuzzy-BryBtMz_.js +0 -41
- package/dist/index-ByJbUSIQ.js +0 -45
- package/dist/index-CFA_VFyX.js +0 -10545
- package/dist/index-CTvgBOum.js +0 -22280
- package/dist/netsuite-D0G4B60k.js +0 -146
- package/dist/normalizeArguments-DP7Hrren.js +0 -1552
- package/dist/row-action.enum-PMKMRrZR.js +0 -50
- package/dist/rules-DxVY0b7F.js +0 -198
- package/dist/use-template-enabled-locations-2-BgTiwy_3.js +0 -86
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
import { ref as
|
|
2
|
-
import { u as
|
|
3
|
-
import { useCoreStore as
|
|
4
|
-
import { useRouter as
|
|
5
|
-
import { u as
|
|
6
|
-
import { u as $ } from "./netsuite-
|
|
1
|
+
import { ref as w, onUnmounted as F, defineComponent as h, watch as I, onMounted as G, computed as g, resolveComponent as R, openBlock as S, createElementBlock as b, unref as v, createVNode as E, createElementVNode as p, toDisplayString as x, createBlock as U, createCommentVNode as M } from "vue";
|
|
2
|
+
import { u as k, a as D, R as e, g as s, _ as H, b as K } from "./app-CTCC1zfY.js";
|
|
3
|
+
import { useCoreStore as A, useI18n as B } from "@feedmepos/mf-common";
|
|
4
|
+
import { useRouter as C, useRoute as W } from "vue-router";
|
|
5
|
+
import { u as O } from "./feature-DiGS5Fa4.js";
|
|
6
|
+
import { u as $ } from "./netsuite-CIibMNer.js";
|
|
7
7
|
import { u as Q } from "./useTabStorage-BkIVScW_.js";
|
|
8
|
-
import { _ as W } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
9
8
|
import { u as j } from "./googlemap-Dm8ERVai.js";
|
|
10
9
|
import "./array-hChJVZLE.js";
|
|
11
10
|
function z() {
|
|
@@ -14,9 +13,9 @@ function z() {
|
|
|
14
13
|
isLoading: !1
|
|
15
14
|
};
|
|
16
15
|
}
|
|
17
|
-
const _ =
|
|
16
|
+
const _ = w(z());
|
|
18
17
|
function q() {
|
|
19
|
-
const l =
|
|
18
|
+
const l = C();
|
|
20
19
|
if (!_.value.loadingHookInstalled) {
|
|
21
20
|
_.value.loadingHookInstalled = !0;
|
|
22
21
|
const n = l.beforeEach(() => {
|
|
@@ -24,7 +23,7 @@ function q() {
|
|
|
24
23
|
}), i = l.afterEach(() => {
|
|
25
24
|
_.value.isLoading = !1;
|
|
26
25
|
});
|
|
27
|
-
|
|
26
|
+
F(() => {
|
|
28
27
|
_.value.loadingHookInstalled = !1, n(), i();
|
|
29
28
|
});
|
|
30
29
|
}
|
|
@@ -43,50 +42,51 @@ const J = {
|
|
|
43
42
|
}, Y = { class: "flex flex-col gap-12 items-center text-center px-24 max-w-[1000px]" }, Z = { class: "fm-typo-en-title-lg-600" }, ee = { class: "text-fm-color-typo-secondary fm-typo-en-body-md-400" }, te = { class: "flex gap-16" }, oe = { href: "https://feedme.ai/product/inventory/features?tab=plans_%26_prices" }, ne = { href: "https://feedme.ai/form" }, re = /* @__PURE__ */ h({
|
|
44
43
|
__name: "InventoryView",
|
|
45
44
|
setup(l) {
|
|
46
|
-
const n =
|
|
47
|
-
|
|
45
|
+
const n = k(), i = D(), u = $(), a = A(), c = C(), o = q(), y = O(), { t: d } = B();
|
|
46
|
+
I(
|
|
48
47
|
[() => a.sessionUser.value, () => a.currentBusiness.value],
|
|
49
48
|
([t, r]) => {
|
|
50
|
-
|
|
49
|
+
f(t, r);
|
|
51
50
|
}
|
|
52
|
-
),
|
|
51
|
+
), G(async () => {
|
|
52
|
+
await a.readBusinesses();
|
|
53
53
|
const t = a.sessionUser.value, r = a.currentBusiness.value;
|
|
54
|
-
|
|
54
|
+
f(t, r);
|
|
55
55
|
});
|
|
56
|
-
function
|
|
57
|
-
!t || !r ||
|
|
56
|
+
function f(t, r) {
|
|
57
|
+
!t || !r || T();
|
|
58
58
|
}
|
|
59
|
-
async function
|
|
59
|
+
async function T() {
|
|
60
60
|
return await n.init(), await u.readSetting().catch((t) => {
|
|
61
61
|
console.error("error on reading netsuite store", t);
|
|
62
62
|
}), await i.init();
|
|
63
63
|
}
|
|
64
|
-
const N =
|
|
64
|
+
const N = g(() => c.currentRoute.value.name === e.TRANSFER_TEMPLATE ? y.enablePoTemplate : !0);
|
|
65
65
|
return (t, r) => {
|
|
66
|
-
const m =
|
|
67
|
-
return S(),
|
|
68
|
-
v(o).isLoading ? (S(),
|
|
66
|
+
const m = R("FmSpacer"), P = R("FmCircularProgress"), L = R("FmButton"), V = R("RouterView");
|
|
67
|
+
return S(), b("div", null, [
|
|
68
|
+
v(o).isLoading ? (S(), b("div", J, [
|
|
69
69
|
E(m),
|
|
70
70
|
p("div", null, [
|
|
71
71
|
E(P, { size: "xl" })
|
|
72
72
|
]),
|
|
73
73
|
r[0] || (r[0] = p("div", { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary pl-8" }, "Loading page...", -1)),
|
|
74
74
|
E(m)
|
|
75
|
-
])) : N.value ? v(a).sessionUser.value ? (S(),
|
|
75
|
+
])) : N.value ? v(a).sessionUser.value ? (S(), U(V, { key: 2 })) : M("", !0) : (S(), b("div", X, [
|
|
76
76
|
p("div", Y, [
|
|
77
|
-
p("div", Z,
|
|
78
|
-
p("div", ee,
|
|
77
|
+
p("div", Z, x(v(d)("inventory.common.proPlan.title")), 1),
|
|
78
|
+
p("div", ee, x(v(d)("inventory.common.proPlan.subtitle")), 1)
|
|
79
79
|
]),
|
|
80
80
|
p("div", te, [
|
|
81
81
|
p("a", oe, [
|
|
82
|
-
E(
|
|
83
|
-
label: v(
|
|
82
|
+
E(L, {
|
|
83
|
+
label: v(d)("inventory.common.proPlan.comparePlans"),
|
|
84
84
|
variant: "secondary"
|
|
85
85
|
}, null, 8, ["label"])
|
|
86
86
|
]),
|
|
87
87
|
p("a", ne, [
|
|
88
|
-
E(
|
|
89
|
-
label: v(
|
|
88
|
+
E(L, {
|
|
89
|
+
label: v(d)("inventory.common.proPlan.callUs"),
|
|
90
90
|
"prepend-icon": "call"
|
|
91
91
|
}, null, 8, ["label"])
|
|
92
92
|
])
|
|
@@ -98,11 +98,11 @@ const J = {
|
|
|
98
98
|
}), se = { class: "h-full flex flex-col overflow-auto py-16" }, ae = /* @__PURE__ */ h({
|
|
99
99
|
__name: "NavigationTab",
|
|
100
100
|
setup(l) {
|
|
101
|
-
const n =
|
|
102
|
-
|
|
101
|
+
const n = W(), i = C(), u = A(), a = O(), c = Q(), { t: o } = B();
|
|
102
|
+
I([() => u.currentBusiness.value, () => n.name], ([t, r]) => {
|
|
103
103
|
(t == null ? void 0 : t.menuVersion) === "v3" && (r === e.INGREDIENTS || r === e.RECIPE || r === e.UNIT) && i.push({ name: e.STOCK });
|
|
104
104
|
});
|
|
105
|
-
const y =
|
|
105
|
+
const y = g(() => {
|
|
106
106
|
var r;
|
|
107
107
|
const t = [
|
|
108
108
|
{
|
|
@@ -116,6 +116,14 @@ const J = {
|
|
|
116
116
|
{
|
|
117
117
|
label: s(e.CLOSING_TEMPLATE, o),
|
|
118
118
|
value: e.CLOSING_TEMPLATE
|
|
119
|
+
},
|
|
120
|
+
{
|
|
121
|
+
label: s(e.CLOSING_DRAFT, o),
|
|
122
|
+
value: e.CLOSING_DRAFT
|
|
123
|
+
},
|
|
124
|
+
{
|
|
125
|
+
label: s(e.WASTAGE_TEMPLATE, o),
|
|
126
|
+
value: e.WASTAGE_TEMPLATE
|
|
119
127
|
}
|
|
120
128
|
]
|
|
121
129
|
},
|
|
@@ -178,7 +186,7 @@ const J = {
|
|
|
178
186
|
return ((r = u.currentBusiness.value) == null ? void 0 : r.menuVersion) === "v3" ? t.filter(
|
|
179
187
|
(m) => m.value !== e.INGREDIENTS && m.value !== e.RECIPE && m.value !== e.UNIT
|
|
180
188
|
) : t;
|
|
181
|
-
}),
|
|
189
|
+
}), d = g({
|
|
182
190
|
get() {
|
|
183
191
|
if (n.name)
|
|
184
192
|
return String(n.name);
|
|
@@ -186,35 +194,35 @@ const J = {
|
|
|
186
194
|
set(t) {
|
|
187
195
|
t && i.push({ name: t });
|
|
188
196
|
}
|
|
189
|
-
}),
|
|
197
|
+
}), f = g(
|
|
190
198
|
() => {
|
|
191
199
|
var t;
|
|
192
200
|
return `NavigationTab.${(t = u.currentBusiness.value) == null ? void 0 : t._id}`;
|
|
193
201
|
}
|
|
194
|
-
),
|
|
202
|
+
), T = w(!1), N = g({
|
|
195
203
|
get() {
|
|
196
|
-
return
|
|
204
|
+
return T.value;
|
|
197
205
|
},
|
|
198
206
|
set(t) {
|
|
199
|
-
|
|
207
|
+
T.value = t, t || c.setItem(f.value, "true");
|
|
200
208
|
}
|
|
201
209
|
});
|
|
202
|
-
return
|
|
203
|
-
|
|
204
|
-
N.value = !c.getItem(
|
|
210
|
+
return I([() => f.value], () => {
|
|
211
|
+
T.value = !1, setTimeout(() => {
|
|
212
|
+
N.value = !c.getItem(f.value);
|
|
205
213
|
}, 2e3);
|
|
206
214
|
}), (t, r) => {
|
|
207
|
-
const m =
|
|
208
|
-
return S(),
|
|
215
|
+
const m = R("FmCollapsibleTabs");
|
|
216
|
+
return S(), b("div", se, [
|
|
209
217
|
E(m, {
|
|
210
|
-
modelValue:
|
|
211
|
-
"onUpdate:modelValue": r[0] || (r[0] = (P) =>
|
|
218
|
+
modelValue: d.value,
|
|
219
|
+
"onUpdate:modelValue": r[0] || (r[0] = (P) => d.value = P),
|
|
212
220
|
items: y.value
|
|
213
221
|
}, null, 8, ["modelValue", "items"])
|
|
214
222
|
]);
|
|
215
223
|
};
|
|
216
224
|
}
|
|
217
|
-
}), le = /* @__PURE__ */
|
|
225
|
+
}), le = /* @__PURE__ */ H(ae, [["__scopeId", "data-v-fb8b7488"]]);
|
|
218
226
|
typeof Promise.withResolvers > "u" && (Promise.withResolvers = () => {
|
|
219
227
|
let l, n;
|
|
220
228
|
return { promise: new Promise((u, a) => {
|
|
@@ -224,11 +232,11 @@ typeof Promise.withResolvers > "u" && (Promise.withResolvers = () => {
|
|
|
224
232
|
typeof Promise.prototype.delayed > "u" && (Promise.prototype.delayed = async function(l) {
|
|
225
233
|
return await new Promise((n) => setTimeout(n, l)), Promise.resolve(this);
|
|
226
234
|
});
|
|
227
|
-
const
|
|
235
|
+
const Ee = /* @__PURE__ */ h({
|
|
228
236
|
__name: "App",
|
|
229
237
|
setup(l) {
|
|
230
|
-
const n =
|
|
231
|
-
|
|
238
|
+
const n = A(), i = j(), u = K();
|
|
239
|
+
G(() => {
|
|
232
240
|
if (window.location.href.includes("print-preview")) {
|
|
233
241
|
n.setEmbedded(!0);
|
|
234
242
|
return;
|
|
@@ -236,7 +244,7 @@ const Se = /* @__PURE__ */ h({
|
|
|
236
244
|
n.registerSidebarComponent(le), i.initGoogleMap(u.appApi.googleMap).catch(() => {
|
|
237
245
|
console.error("Google map cannot be loaded");
|
|
238
246
|
});
|
|
239
|
-
}),
|
|
247
|
+
}), I([() => n.currentCountry.value], () => {
|
|
240
248
|
a();
|
|
241
249
|
});
|
|
242
250
|
async function a() {
|
|
@@ -247,9 +255,9 @@ const Se = /* @__PURE__ */ h({
|
|
|
247
255
|
console.error("error when trying to reset businesses:", o);
|
|
248
256
|
}
|
|
249
257
|
}
|
|
250
|
-
return (c, o) => (S(),
|
|
258
|
+
return (c, o) => (S(), U(re));
|
|
251
259
|
}
|
|
252
260
|
});
|
|
253
261
|
export {
|
|
254
|
-
|
|
262
|
+
Ee as default
|
|
255
263
|
};
|
|
@@ -1,18 +1,15 @@
|
|
|
1
|
-
import { defineComponent as ae, ref as g, watch as oe, computed as b, resolveComponent as re, openBlock as
|
|
2
|
-
import { u as me,
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import { _ as be, F as _ } from "./TableActionableRow.vue_vue_type_script_setup_true_lang-DlNJ6kRg.js";
|
|
7
|
-
import { useBreakpoints as xe } from "@feedmepos/ui-library";
|
|
8
|
-
import { useI18n as ye } from "@feedmepos/mf-common";
|
|
1
|
+
import { defineComponent as ae, ref as g, watch as oe, computed as b, resolveComponent as re, openBlock as y, createBlock as J, unref as e, withCtx as x, createElementVNode as s, normalizeClass as ne, createVNode as n, normalizeStyle as se, toDisplayString as le, createElementBlock as ce, createCommentVNode as ie, Teleport as pe, mergeProps as ue } from "vue";
|
|
2
|
+
import { u as me, aq as v, ay as de, a5 as K, p as fe, q as ve, r as _e, s as he, v as _ } from "./app-CTCC1zfY.js";
|
|
3
|
+
import { a as De, b as ge, _ as be } from "./TransferDetails.vue_vue_type_script_setup_true_lang-00pcY0qu.js";
|
|
4
|
+
import { useBreakpoints as ye } from "@feedmepos/ui-library";
|
|
5
|
+
import { useI18n as xe } from "@feedmepos/mf-common";
|
|
9
6
|
const we = { class: "flex flex-col py-8" }, Re = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, ke = { class: "fm-typo-en-body-lg-600 text-fm-color-typo-primary line-clamp-1" }, Oe = { class: "fm-typo-en-body-md-400 text-fm-color-typo-primary line-clamp-1" }, Se = {
|
|
10
7
|
key: 0,
|
|
11
8
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-primary line-clamp-1"
|
|
12
|
-
}, Te = { class: "pt-8" },
|
|
9
|
+
}, Te = { class: "pt-8" }, Ve = /* @__PURE__ */ ae({
|
|
13
10
|
__name: "ApprovalView",
|
|
14
11
|
setup(Ce) {
|
|
15
|
-
const o =
|
|
12
|
+
const o = De("approval"), { columnDefs: Q } = ge("approval", o), W = me();
|
|
16
13
|
v.object({
|
|
17
14
|
name: v.string().optional().nullable(),
|
|
18
15
|
start: v.date().optional().nullable(),
|
|
@@ -38,7 +35,7 @@ const we = { class: "flex flex-col py-8" }, Re = { class: "fm-typo-en-body-md-40
|
|
|
38
35
|
return;
|
|
39
36
|
}
|
|
40
37
|
});
|
|
41
|
-
const h = g(""), { breakpoints: R } =
|
|
38
|
+
const h = g(""), { breakpoints: R } = ye(), D = b(() => R.value.xs || R.value.sm), X = b(() => D.value ? 10 : 20), Z = fe(), { t: k } = xe(), B = b(() => [
|
|
42
39
|
{
|
|
43
40
|
label: k("common.refresh"),
|
|
44
41
|
value: "refresh"
|
|
@@ -52,12 +49,12 @@ const we = { class: "flex flex-col py-8" }, Re = { class: "fm-typo-en-body-md-40
|
|
|
52
49
|
}
|
|
53
50
|
return (c, l) => {
|
|
54
51
|
const ee = re("FmTable");
|
|
55
|
-
return
|
|
52
|
+
return y(), J(ve, {
|
|
56
53
|
title: e(k)("inventory.transfer.approval.title"),
|
|
57
54
|
actions: B.value,
|
|
58
55
|
"onClick:action": I
|
|
59
56
|
}, {
|
|
60
|
-
default:
|
|
57
|
+
default: x(() => [
|
|
61
58
|
s("div", {
|
|
62
59
|
class: ne([
|
|
63
60
|
"flex flex-col gap-8 max-h-full",
|
|
@@ -82,13 +79,13 @@ const we = { class: "flex flex-col py-8" }, Re = { class: "fm-typo-en-body-md-40
|
|
|
82
79
|
onRowClick: l[1] || (l[1] = (r) => e(o).promptShowTransferDetails(r.original.purchaseOrder, r.original)),
|
|
83
80
|
"page-size": X.value
|
|
84
81
|
}, {
|
|
85
|
-
"list-row":
|
|
86
|
-
n(
|
|
82
|
+
"list-row": x((r) => [
|
|
83
|
+
n(he, {
|
|
87
84
|
row: r,
|
|
88
85
|
onRowClick: (t) => e(o).promptShowTransferDetails(t.purchaseOrder, t)
|
|
89
86
|
}, {
|
|
90
|
-
default:
|
|
91
|
-
var O, S, T, i, C,
|
|
87
|
+
default: x((t) => {
|
|
88
|
+
var O, S, T, i, C, q, z, M, p, $, F, u, V, m, Y, L, N, P, j, d, A, E, H, U, f, G;
|
|
92
89
|
return [
|
|
93
90
|
s("div", we, [
|
|
94
91
|
s("div", Re, [
|
|
@@ -99,12 +96,12 @@ const we = { class: "flex flex-col py-8" }, Re = { class: "fm-typo-en-body-md-40
|
|
|
99
96
|
]),
|
|
100
97
|
s("div", ke, [
|
|
101
98
|
n(e(_), {
|
|
102
|
-
render: (M = (
|
|
99
|
+
render: (M = (z = (q = t.to_name) == null ? void 0 : q.column) == null ? void 0 : z.columnDef) == null ? void 0 : M.cell,
|
|
103
100
|
props: ($ = (p = t.to_name) == null ? void 0 : p.getContext) == null ? void 0 : $.call(p)
|
|
104
101
|
}, null, 8, ["render", "props"])
|
|
105
102
|
]),
|
|
106
|
-
s("div", Oe, le((
|
|
107
|
-
(L = r.original.purchaseOrder) != null && L.ref ? (
|
|
103
|
+
s("div", Oe, le((Y = (m = (V = (u = (F = r.original.purchaseOrder) == null ? void 0 : F.items) == null ? void 0 : u.map) == null ? void 0 : V.call(u, (te) => `${te.name}`)) == null ? void 0 : m.join) == null ? void 0 : Y.call(m, ", ")), 1),
|
|
104
|
+
(L = r.original.purchaseOrder) != null && L.ref ? (y(), ce("div", Se, [
|
|
108
105
|
n(e(_), {
|
|
109
106
|
render: (j = (P = (N = t.purchaseOrder_ref) == null ? void 0 : N.column) == null ? void 0 : P.columnDef) == null ? void 0 : j.cell,
|
|
110
107
|
props: (A = (d = t.purchaseOrder_ref) == null ? void 0 : d.getContext) == null ? void 0 : A.call(d)
|
|
@@ -125,8 +122,8 @@ const we = { class: "flex flex-col py-8" }, Re = { class: "fm-typo-en-body-md-40
|
|
|
125
122
|
_: 1
|
|
126
123
|
}, 8, ["style", "column-defs", "row-data", "search-value", "loading", "page-size"])
|
|
127
124
|
], 2),
|
|
128
|
-
(
|
|
129
|
-
n(
|
|
125
|
+
(y(), J(pe, { to: "body" }, [
|
|
126
|
+
n(be, ue(e(o).transferDetailsProps.value, {
|
|
130
127
|
onSubmitted: e(o).fetchData
|
|
131
128
|
}), null, 16, ["onSubmitted"])
|
|
132
129
|
]))
|
|
@@ -137,5 +134,5 @@ const we = { class: "flex flex-col py-8" }, Re = { class: "fm-typo-en-body-md-40
|
|
|
137
134
|
}
|
|
138
135
|
});
|
|
139
136
|
export {
|
|
140
|
-
|
|
137
|
+
Ve as default
|
|
141
138
|
};
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import { defineComponent as C, ref as o, onMounted as M, onUnmounted as F, watch as x, resolveComponent as l, openBlock as i, createElementBlock as c, createBlock as I, withCtx as R, createVNode as a, createCommentVNode as z, createElementVNode as P } from "vue";
|
|
2
|
-
import { _ as V } from "./InventoryBindingForm.vue_vue_type_script_setup_true_lang-
|
|
3
|
-
import { a as
|
|
4
|
-
const
|
|
2
|
+
import { _ as V } from "./InventoryBindingForm.vue_vue_type_script_setup_true_lang-DEOudgKD.js";
|
|
3
|
+
import { a as E, aE as L } from "./app-CTCC1zfY.js";
|
|
4
|
+
const S = {
|
|
5
5
|
key: 0,
|
|
6
6
|
class: "flex justify-end gap-8 items-center"
|
|
7
|
-
},
|
|
7
|
+
}, U = {
|
|
8
8
|
key: 1,
|
|
9
9
|
class: "p-24 flex items-center justify-center gap-16"
|
|
10
10
|
}, D = /* @__PURE__ */ C({
|
|
11
11
|
__name: "BindingsDialog",
|
|
12
12
|
setup(N) {
|
|
13
|
-
const p =
|
|
13
|
+
const p = E(), d = o(!0), s = o(new Array()), u = o(), t = L(y);
|
|
14
14
|
async function y() {
|
|
15
15
|
await p.readInventory(), u.value = t.onMessage("props:inventory-bindings", (e) => {
|
|
16
16
|
d.value = !1, s.value = e;
|
|
@@ -53,7 +53,7 @@ const U = {
|
|
|
53
53
|
ref_key: "resizeableRef",
|
|
54
54
|
ref: m
|
|
55
55
|
}, [
|
|
56
|
-
d.value ? (i(), c("div",
|
|
56
|
+
d.value ? (i(), c("div", U, [
|
|
57
57
|
a(h, { size: "md" }),
|
|
58
58
|
n[2] || (n[2] = P("div", null, "Loading bindings dialog...", -1))
|
|
59
59
|
])) : (i(), I(B, {
|
|
@@ -70,7 +70,7 @@ const U = {
|
|
|
70
70
|
"iframe-mode": "",
|
|
71
71
|
"onClick:pickInventoryBindings": k
|
|
72
72
|
}, null, 8, ["model-value"]),
|
|
73
|
-
r.value ? z("", !0) : (i(), c("div",
|
|
73
|
+
r.value ? z("", !0) : (i(), c("div", S, [
|
|
74
74
|
a(g, {
|
|
75
75
|
type: "button",
|
|
76
76
|
variant: "tertiary",
|
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
import { defineComponent as S, computed as r, ref as l, onMounted as U, onUnmounted as V, resolveComponent as E, openBlock as p, createElementBlock as f, createVNode as u, createElementVNode as k } from "vue";
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
const z = {
|
|
2
|
+
import { a as x, aE as M, x as z } from "./app-CTCC1zfY.js";
|
|
3
|
+
const F = {
|
|
5
4
|
key: 0,
|
|
6
5
|
class: "flex flex-col gap-16"
|
|
7
6
|
}, K = { class: "flex justify-end gap-8 items-center" }, w = {
|
|
8
7
|
key: 1,
|
|
9
8
|
class: "p-24 flex items-center justify-center gap-16"
|
|
10
|
-
},
|
|
9
|
+
}, N = /* @__PURE__ */ S({
|
|
11
10
|
__name: "BindingsPicker",
|
|
12
11
|
setup(L) {
|
|
13
12
|
const d = x(), C = r(() => d.recipes), I = r(() => d.skus), g = l(!0), i = l(new Array()), a = l("RECIPE"), c = r(() => a.value === "SKU" ? I.value.map((s) => ({
|
|
@@ -63,7 +62,7 @@ const z = {
|
|
|
63
62
|
];
|
|
64
63
|
}
|
|
65
64
|
}
|
|
66
|
-
}), _ = l(), o =
|
|
65
|
+
}), _ = l(), o = M(B);
|
|
67
66
|
async function B() {
|
|
68
67
|
await d.readInventory(), _.value = o.onMessage(
|
|
69
68
|
"props:binding-items",
|
|
@@ -97,8 +96,8 @@ const z = {
|
|
|
97
96
|
g.value ? (p(), f("div", w, [
|
|
98
97
|
u(t, { size: "md" }),
|
|
99
98
|
s[1] || (s[1] = k("div", null, "Loading bindings dialog...", -1))
|
|
100
|
-
])) : (p(), f("div",
|
|
101
|
-
u(
|
|
99
|
+
])) : (p(), f("div", F, [
|
|
100
|
+
u(z, {
|
|
102
101
|
"model-value": b.value,
|
|
103
102
|
"onUpdate:modelValue": s[0] || (s[0] = (m) => b.value = m),
|
|
104
103
|
items: c.value
|
|
@@ -120,5 +119,5 @@ const z = {
|
|
|
120
119
|
}
|
|
121
120
|
});
|
|
122
121
|
export {
|
|
123
|
-
|
|
122
|
+
N as default
|
|
124
123
|
};
|
|
@@ -1,11 +1,7 @@
|
|
|
1
|
-
import { defineComponent as _, ref as c, provide as C, computed as f, resolveComponent as b, openBlock as p, createBlock as h, h as z, onMounted as B, onUnmounted as I, createElementBlock as y, createVNode as N, createElementVNode as
|
|
2
|
-
import { F as v, a as
|
|
3
|
-
import "./index-CTvgBOum.js";
|
|
1
|
+
import { defineComponent as _, ref as c, provide as C, computed as f, resolveComponent as b, openBlock as p, createBlock as h, h as z, onMounted as B, onUnmounted as I, createElementBlock as y, createVNode as N, createElementVNode as E } from "vue";
|
|
2
|
+
import { F as v, a as x, aE as F } from "./app-CTCC1zfY.js";
|
|
4
3
|
import { components as L } from "@feedmepos/ui-library";
|
|
5
|
-
import "./fuzzy-BryBtMz_.js";
|
|
6
|
-
/* empty css */
|
|
7
4
|
import "@feedmepos/mf-common";
|
|
8
|
-
import "./dayjs.min-SJKP9zBL.js";
|
|
9
5
|
const P = /* @__PURE__ */ _({
|
|
10
6
|
__name: "binding-ui",
|
|
11
7
|
props: {
|
|
@@ -26,17 +22,17 @@ const P = /* @__PURE__ */ _({
|
|
|
26
22
|
C("closeDialog", () => {
|
|
27
23
|
u.value.isOpen = !u.value.isOpen;
|
|
28
24
|
});
|
|
29
|
-
const
|
|
25
|
+
const o = k, m = d, a = f(() => o.items.map((e) => ({
|
|
30
26
|
key: e.key,
|
|
31
27
|
name: e.name,
|
|
32
28
|
_skuLinked: e.bindings.filter(
|
|
33
|
-
({ type: n, id:
|
|
29
|
+
({ type: n, id: s }) => n === v.enum.SKU && o.skus.some((l) => l._id === s)
|
|
34
30
|
).length,
|
|
35
31
|
_recipeLinked: e.bindings.filter(
|
|
36
|
-
({ type: n, id:
|
|
32
|
+
({ type: n, id: s }) => n === v.enum.RECIPE && o.recipes.some((l) => l._id === s)
|
|
37
33
|
).length,
|
|
38
34
|
onUpdate: async () => {
|
|
39
|
-
|
|
35
|
+
o.editable && m("click:open-binding-dialog", o.type, e);
|
|
40
36
|
}
|
|
41
37
|
}))), g = [
|
|
42
38
|
{
|
|
@@ -49,7 +45,7 @@ const P = /* @__PURE__ */ _({
|
|
|
49
45
|
header: "Ingredient",
|
|
50
46
|
size: 200,
|
|
51
47
|
cell(i) {
|
|
52
|
-
const e = a.value.find((
|
|
48
|
+
const e = a.value.find((s) => s.key === i.row.original.key), n = e == null ? void 0 : e._skuLinked;
|
|
53
49
|
return n === 1 ? "1 item" : n ? `${n} items` : "Not set";
|
|
54
50
|
}
|
|
55
51
|
},
|
|
@@ -58,7 +54,7 @@ const P = /* @__PURE__ */ _({
|
|
|
58
54
|
header: "Recipe",
|
|
59
55
|
size: 200,
|
|
60
56
|
cell(i) {
|
|
61
|
-
const e = a.value.find((
|
|
57
|
+
const e = a.value.find((s) => s.key === i.row.original.key), n = e == null ? void 0 : e._recipeLinked;
|
|
62
58
|
return n === 1 ? "1 item" : n ? `${n} items` : "Not set";
|
|
63
59
|
}
|
|
64
60
|
},
|
|
@@ -94,19 +90,19 @@ const P = /* @__PURE__ */ _({
|
|
|
94
90
|
}), R = {
|
|
95
91
|
key: 1,
|
|
96
92
|
class: "p-24 flex items-center justify-center gap-16"
|
|
97
|
-
},
|
|
93
|
+
}, D = /* @__PURE__ */ _({
|
|
98
94
|
__name: "BindingsTable",
|
|
99
95
|
setup(k) {
|
|
100
|
-
const d =
|
|
96
|
+
const d = x(), u = c(!0), o = c(new Array()), m = f(() => d.recipes), a = f(() => d.skus), g = c(""), i = F(n), e = c();
|
|
101
97
|
async function n() {
|
|
102
98
|
await d.readInventory(), e.value = i.onMessage(
|
|
103
99
|
"props:grouped-bindings",
|
|
104
100
|
(t) => {
|
|
105
|
-
u.value = !1,
|
|
101
|
+
u.value = !1, o.value = t;
|
|
106
102
|
}
|
|
107
103
|
), i.sendMessage("props:grouped-bindings");
|
|
108
104
|
}
|
|
109
|
-
async function
|
|
105
|
+
async function s(t, r) {
|
|
110
106
|
i.sendMessage("@click:open-binding-dialog", {
|
|
111
107
|
key: t,
|
|
112
108
|
binding: r
|
|
@@ -130,20 +126,20 @@ const P = /* @__PURE__ */ _({
|
|
|
130
126
|
}, [
|
|
131
127
|
u.value ? (p(), y("div", R, [
|
|
132
128
|
N(w, { size: "md" }),
|
|
133
|
-
r[0] || (r[0] =
|
|
129
|
+
r[0] || (r[0] = E("div", null, "Loading bindings table...", -1))
|
|
134
130
|
])) : (p(), h(P, {
|
|
135
131
|
key: 0,
|
|
136
|
-
items:
|
|
132
|
+
items: o.value,
|
|
137
133
|
recipes: m.value,
|
|
138
134
|
skus: a.value,
|
|
139
135
|
type: g.value,
|
|
140
136
|
editable: "",
|
|
141
|
-
"onClick:openBindingDialog":
|
|
137
|
+
"onClick:openBindingDialog": s
|
|
142
138
|
}, null, 8, ["items", "recipes", "skus", "type"]))
|
|
143
139
|
], 512);
|
|
144
140
|
};
|
|
145
141
|
}
|
|
146
142
|
});
|
|
147
143
|
export {
|
|
148
|
-
|
|
144
|
+
D as default
|
|
149
145
|
};
|