@feedmepos/mf-inventory-portal 0.0.23-dev.9 → 0.0.24-dev.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/App-D3sNH2MR.js +276 -0
- package/dist/{ApprovalView-e85YmdZN.js → ApprovalView-DHnRx0hJ.js} +17 -20
- package/dist/{BindingsDialog-giBUD0IH.js → BindingsDialog-oTeg2Dai.js} +6 -6
- package/dist/{BindingsPicker-CC4MmPbF.js → BindingsPicker-CWdjmMJ3.js} +8 -9
- package/dist/{BindingsTable-WphZdzrA.js → BindingsTable-bKLR1OKX.js} +18 -22
- package/dist/ClosingDraftView-CIQVz7lY.js +1225 -0
- package/dist/{ClosingTemplateView-1lzoDyet.js → ClosingTemplateView-D5pLzQwU.js} +259 -274
- package/dist/FmCustomAttribute.vue_vue_type_script_setup_true_lang-ClLDcchC.js +142 -0
- package/dist/{FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-Cv-vvzr5.js → FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-B_c6Vn6P.js} +23 -24
- package/dist/{FmUnitInput.vue_vue_type_script_setup_true_lang-DIFQcrc0.js → FmUnitInput.vue_vue_type_script_setup_true_lang-DhpHOaRH.js} +50 -51
- package/dist/{IngredientGroupView-UegBM_JK.js → IngredientGroupView-4C437mso.js} +63 -70
- package/dist/IngredientsView-DoiGgjre.js +1706 -0
- package/dist/{IntegrationView-FYNNzKia.js → IntegrationView-8ZKE7MAM.js} +123 -126
- package/dist/{InventoryBindingForm-DsHv_IHG.js → InventoryBindingForm-CcnfliYQ.js} +1 -1
- package/dist/{InventoryBindingForm.vue_vue_type_script_setup_true_lang-BURSXafS.js → InventoryBindingForm.vue_vue_type_script_setup_true_lang-B_J-6C9x.js} +116 -108
- package/dist/{InventoryBindingSummary-BLb4MRPZ.js → InventoryBindingSummary-CRdHCzNE.js} +1 -1
- package/dist/{NumberPrecisionInput.vue_vue_type_script_setup_true_lang-BG78-DHs.js → NumberPrecisionInput.vue_vue_type_script_setup_true_lang-B2-TypU0.js} +1 -1
- package/dist/{PremiumBadge.vue_vue_type_script_setup_true_lang-CqID5_7v.js → PremiumBadge.vue_vue_type_script_setup_true_lang-BuQde75S.js} +20 -21
- package/dist/PublishView-t5gjGmK_.js +192 -0
- package/dist/{PurchaseOrderPrintPreview-BBMU3teq.js → PurchaseOrderPrintPreview-6i53Y-v1.js} +13 -14
- package/dist/ReceiveRequestView-uOeSh0Mr.js +1866 -0
- package/dist/RecipeView-BTWywckD.js +609 -0
- package/dist/StockView-DN2xk8ei.js +1817 -0
- package/dist/{SupplierView-B2aObtwK.js → SupplierView-l0XUg3J4.js} +185 -196
- package/dist/TransferDetails.vue_vue_type_script_setup_true_lang-CWMn6fFf.js +1327 -0
- package/dist/TransferTemplateView-wDKXpCWZ.js +1263 -0
- package/dist/UnitView-CUI-k-tS.js +648 -0
- package/dist/{WarehouseView-G8pej6Y2.js → WarehouseView-WsI_eG5r.js} +190 -197
- package/dist/api/adjustment-template.d.ts +25 -0
- package/dist/api/bill.d.ts +240 -84
- package/dist/api/inventory.d.ts +19 -6
- package/dist/api/netsuite.d.ts +3 -3
- package/dist/app-DntcWR3_.js +85558 -0
- package/dist/app.d.ts +85 -0
- package/dist/app.js +2 -2
- package/dist/components/FmCustomAttribute.vue.d.ts +23 -0
- package/dist/components/FmLockableField.vue.d.ts +37 -0
- package/dist/components/FmMultiselectDialogProps.d.ts +1 -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/composable/defineDeepModel.d.ts +1 -1
- package/dist/{decimal-DC07xoJW.js → decimal-DTCTnMwO.js} +1 -1
- package/dist/format-unit-display-Hy48Iw5j.js +1215 -0
- package/dist/index-Bv9RYyTZ.js +29202 -0
- package/dist/{StockView-C5btudss.js → index-D4yJP9I2.js} +2220 -3863
- package/dist/layout/SingleColumnLayout.vue.d.ts +1 -0
- package/dist/router/name.d.ts +2 -0
- package/dist/stock-BsdmfT-b.js +125 -0
- package/dist/stores/feature.d.ts +41 -1
- package/dist/stores/integration/netsuite.d.ts +3 -2
- package/dist/stores/inventory.d.ts +20 -8
- package/dist/stores/location.d.ts +29 -1
- package/dist/stores/supplier.d.ts +1 -1
- package/dist/style.css +1 -1
- package/dist/supplier-CXhkgC4M.js +77 -0
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/dist/{use-inventory-binding-dialog-B0G2XYSw.js → use-inventory-binding-dialog-DPMJmBCr.js} +10 -11
- package/dist/views/adjustment-template/import/AdjustmentTemplateImport.vue.d.ts +2 -0
- package/dist/views/adjustment-template/import/AdjustmentTemplateImportItem.vue.d.ts +18 -0
- package/dist/views/adjustment-template/import/export.d.ts +60 -0
- 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/WastageTemplateReason.vue.d.ts +18 -0
- package/dist/views/adjustment-template/wastage-template/WastageTemplateView.vue.d.ts +2 -0
- package/dist/views/adjustment-template/wastage-template/actions.d.ts +1377 -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 +36 -0
- package/dist/views/adjustment-template/wastage-template/table.d.ts +1351 -0
- package/dist/views/closing-draft/components/closing-draft-dialog/ClosingDraftDialog.vue.d.ts +198 -12
- package/dist/views/closing-draft/composables/use-closing-draft-actions.d.ts +7 -4
- package/dist/views/closing-draft/composables/use-closing-draft-table.d.ts +1559 -467
- 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/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 +72 -12
- package/dist/views/closing-template/composables/use-closing-template-table.d.ts +73 -13
- 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/publish/PublishView.vue.d.ts +2 -0
- package/dist/views/receive-request/components/netsuite/NetSuiteInfo.vue.d.ts +12 -0
- package/dist/views/receive-request/components/netsuite/NetSuiteProps.d.ts +13 -0
- package/dist/views/receive-request/components/netsuite/NetSuiteSync.vue.d.ts +12 -0
- package/dist/views/receive-request/components/transfer-form/NetSuiteField.vue.d.ts +13 -0
- 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 +86 -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 +126 -24
- package/dist/views/receive-request/composables/use-receive-request-table.d.ts +126 -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 +6 -4
- package/dist/views/stock/helper/compute-summary-total.d.ts +2 -2
- package/dist/views/transfer-template/components/transfer-template-form/composables/use-template-enabled-locations.d.ts +4 -0
- 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 +72 -12
- package/dist/views/transfer-template/composables/use-transfer-template-table.d.ts +72 -12
- package/dist/views/transfer-template/helpers/import-export.helper.d.ts +2 -1
- package/dist/vue-i18n-ByVzHsI7.js +2365 -0
- package/package.json +5 -4
- package/dist/App-ByLgARNp.js +0 -259
- package/dist/ClosingDraftView-CQM1Sx45.js +0 -755
- package/dist/FmDroppableField-8RzKjEdL.js +0 -154
- package/dist/FmInventoryTableToolbar.vue_vue_type_script_setup_true_lang-BvkN-71q.js +0 -436
- package/dist/FmMultiselectDialog-DScMA6iG.js +0 -415
- package/dist/IngredientBindedItem.vue_vue_type_script_setup_true_lang-t4pim_k9.js +0 -51
- package/dist/IngredientsView-BfW-jZLM.js +0 -1666
- package/dist/ReceiveRequestView-vbANEzne.js +0 -4165
- package/dist/RecipeView-DW4DY0C0.js +0 -598
- package/dist/TableActionableRow.vue_vue_type_script_setup_true_lang-DlNJ6kRg.js +0 -135
- package/dist/TransferDetails.vue_vue_type_script_setup_true_lang-B2LOvVef.js +0 -1229
- package/dist/TransferTemplateView-BKumN_p6.js +0 -1262
- package/dist/UnitView-CHLucv9s.js +0 -648
- package/dist/_plugin-vue_export-helper-CHgC5LLL.js +0 -9
- package/dist/app-BXjk74IB.js +0 -33538
- package/dist/date2-CWAt9bRf.js +0 -117
- package/dist/dayjs.min-D3jPOnu6.js +0 -282
- package/dist/defineDeepModel-CiD4GtOw.js +0 -13
- package/dist/feature-6tcLMotY.js +0 -92
- package/dist/form-mode.enum-BKiNVH6A.js +0 -4
- package/dist/format-time-from-id-CYU5Z9Mt.js +0 -15
- package/dist/format-unit-display-CY-0bznr.js +0 -1217
- package/dist/fuzzy-BMkhNYLR.js +0 -41
- package/dist/index-BXwQa14X.js +0 -45
- package/dist/index-CRLd5xyg.js +0 -22283
- package/dist/index-DqwAtOgI.js +0 -12087
- package/dist/netsuite-fYUUk_ss.js +0 -225
- package/dist/row-action.enum-7rGLGZ5v.js +0 -55
- package/dist/rules-BmRGm3yv.js +0 -203
- package/dist/stock-CEX0DP2B.js +0 -111
- package/dist/supplier-CdJmZr7w.js +0 -77
- package/dist/use-template-enabled-locations-2-xbPJWHCs.js +0 -86
- package/dist/xlsx-CTOKp7SQ.js +0 -24004
- package/dist/xlsx.util-D5NFSfDg.js +0 -78
|
@@ -1,16 +1,9 @@
|
|
|
1
|
-
import { ref as C, computed as
|
|
2
|
-
import { a as J,
|
|
3
|
-
import { useDialog as le, useSnackbar as Z, useProxiedModel as
|
|
4
|
-
import { F as h } from "./form-mode.enum-BKiNVH6A.js";
|
|
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, e as h, f as B, h as ye, D as oe, i as Q, H as be, m as _e, A as xe, J as ne, p as se, u as ke, z as he, _ as we, B as Se, E as Ie, G as ae } from "./app-DntcWR3_.js";
|
|
3
|
+
import { useDialog as le, useSnackbar as Z, useProxiedModel as Fe, useBreakpoints as Ce } from "@feedmepos/ui-library";
|
|
5
4
|
import { useI18n as W } from "@feedmepos/mf-common";
|
|
6
|
-
import { defineStore as ie, storeToRefs as
|
|
7
|
-
import { D as se, R as Q } from "./row-action.enum-7rGLGZ5v.js";
|
|
8
|
-
import { c as xe, _ as ke, F as ae } from "./TableActionableRow.vue_vue_type_script_setup_true_lang-DlNJ6kRg.js";
|
|
9
|
-
import { u as he, _ as we, a as Se } from "./FmInventoryTableToolbar.vue_vue_type_script_setup_true_lang-BvkN-71q.js";
|
|
5
|
+
import { defineStore as ie, storeToRefs as re } from "pinia";
|
|
10
6
|
import "./array-hChJVZLE.js";
|
|
11
|
-
import { d as Fe } from "./defineDeepModel-CiD4GtOw.js";
|
|
12
|
-
import { R as Ie, A as Ce } from "./rules-BmRGm3yv.js";
|
|
13
|
-
import { F as re } from "./FmMultiselectDialog-DScMA6iG.js";
|
|
14
7
|
const X = ie(
|
|
15
8
|
"ingredientGroupactions",
|
|
16
9
|
function() {
|
|
@@ -71,7 +64,7 @@ const X = ie(
|
|
|
71
64
|
}
|
|
72
65
|
}).onPrimary(() => f(d, a, s));
|
|
73
66
|
}
|
|
74
|
-
function
|
|
67
|
+
function G() {
|
|
75
68
|
}
|
|
76
69
|
function b() {
|
|
77
70
|
}
|
|
@@ -79,12 +72,12 @@ const X = ie(
|
|
|
79
72
|
createIngredientGroup: p,
|
|
80
73
|
updateIngredientGroup: v,
|
|
81
74
|
deleteIngredientGroup: y,
|
|
82
|
-
importIngredientGroups:
|
|
75
|
+
importIngredientGroups: G,
|
|
83
76
|
exportIngredientGroups: b,
|
|
84
77
|
ingredientGroupDialogProps: i
|
|
85
78
|
};
|
|
86
79
|
}
|
|
87
|
-
),
|
|
80
|
+
), Ge = ie(
|
|
88
81
|
"ingredientGroupTable",
|
|
89
82
|
function() {
|
|
90
83
|
const c = C(!1), w = Z(), o = J(), r = X();
|
|
@@ -114,7 +107,7 @@ const X = ie(
|
|
|
114
107
|
);
|
|
115
108
|
}
|
|
116
109
|
}
|
|
117
|
-
const v =
|
|
110
|
+
const v = F(() => [
|
|
118
111
|
{
|
|
119
112
|
accessorKey: "name",
|
|
120
113
|
header: () => "Name"
|
|
@@ -131,8 +124,8 @@ const X = ie(
|
|
|
131
124
|
id: "action",
|
|
132
125
|
header: "",
|
|
133
126
|
cell(f) {
|
|
134
|
-
return
|
|
135
|
-
[
|
|
127
|
+
return ye(
|
|
128
|
+
[oe[Q.Edit], oe[Q.Delete]],
|
|
136
129
|
(y) => {
|
|
137
130
|
p(y, f.row.original);
|
|
138
131
|
}
|
|
@@ -152,7 +145,7 @@ const X = ie(
|
|
|
152
145
|
columnDefs: v
|
|
153
146
|
};
|
|
154
147
|
}
|
|
155
|
-
),
|
|
148
|
+
), Ae = { class: "flex flex-col gap-16" }, De = { class: "flex flex-col gap-8 cursor-pointer" }, Ve = {
|
|
156
149
|
key: 0,
|
|
157
150
|
class: "text-fm-color-typo-primary fm-typo-en-body-lg-400 line-clamp-1 break-all"
|
|
158
151
|
}, Ee = { class: "text-fm-color-typo-secondary" }, Re = {
|
|
@@ -167,7 +160,7 @@ const X = ie(
|
|
|
167
160
|
},
|
|
168
161
|
emits: ["validation-success"],
|
|
169
162
|
setup(U, { expose: c, emit: w }) {
|
|
170
|
-
const o =
|
|
163
|
+
const o = be("modelValue"), r = w, i = J(), p = le(), { t: v } = W(), f = C();
|
|
171
164
|
c({
|
|
172
165
|
validateInputs: () => {
|
|
173
166
|
var a;
|
|
@@ -182,8 +175,8 @@ const X = ie(
|
|
|
182
175
|
return (a = f.value) == null ? void 0 : a.resetInputs();
|
|
183
176
|
}
|
|
184
177
|
});
|
|
185
|
-
const y =
|
|
186
|
-
function
|
|
178
|
+
const y = F(() => i.skus.groupBy((a) => a.unit._id));
|
|
179
|
+
function G() {
|
|
187
180
|
var s;
|
|
188
181
|
const a = i.skus.filter((n) => {
|
|
189
182
|
var t;
|
|
@@ -199,7 +192,7 @@ const X = ie(
|
|
|
199
192
|
p.open({
|
|
200
193
|
title: v("inventory.closing.form.items.selectItem"),
|
|
201
194
|
closeButton: !0,
|
|
202
|
-
contentComponent:
|
|
195
|
+
contentComponent: ne,
|
|
203
196
|
contentComponentProps: {
|
|
204
197
|
modelValue: [(s = o.skus) == null ? void 0 : s[0]],
|
|
205
198
|
items: a,
|
|
@@ -238,7 +231,7 @@ const X = ie(
|
|
|
238
231
|
p.open({
|
|
239
232
|
title: v("inventory.closing.form.items.selectItem"),
|
|
240
233
|
closeButton: !0,
|
|
241
|
-
contentComponent:
|
|
234
|
+
contentComponent: ne,
|
|
242
235
|
contentComponentProps: {
|
|
243
236
|
modelValue: s,
|
|
244
237
|
items: a,
|
|
@@ -256,8 +249,8 @@ const X = ie(
|
|
|
256
249
|
}).onPrimary((n) => {
|
|
257
250
|
var u, _;
|
|
258
251
|
const t = ((u = o.skus) == null ? void 0 : u.slice(1)) ?? [], e = n.map((m) => {
|
|
259
|
-
const
|
|
260
|
-
return
|
|
252
|
+
const A = t.find((D) => (D == null ? void 0 : D._id) === m._id);
|
|
253
|
+
return A || B(m, ["unit"]);
|
|
261
254
|
});
|
|
262
255
|
o.skus = [(_ = o.skus) == null ? void 0 : _[0], ...e];
|
|
263
256
|
});
|
|
@@ -275,21 +268,21 @@ const X = ie(
|
|
|
275
268
|
}
|
|
276
269
|
];
|
|
277
270
|
return (a, s) => {
|
|
278
|
-
const n = S("FmTextField"), t = S("FmLabel"), e = S("FmField"), u = S("FmFormGroup"), _ = S("FmButton"), m = S("FmTable"),
|
|
279
|
-
return M(), O(
|
|
280
|
-
onValidationSuccess: s[5] || (s[5] = (
|
|
271
|
+
const n = S("FmTextField"), t = S("FmLabel"), e = S("FmField"), u = S("FmFormGroup"), _ = S("FmButton"), m = S("FmTable"), A = S("FmForm");
|
|
272
|
+
return M(), O(A, {
|
|
273
|
+
onValidationSuccess: s[5] || (s[5] = (I) => r("validation-success")),
|
|
281
274
|
ref_key: "formRef",
|
|
282
275
|
ref: f,
|
|
283
276
|
class: "flex flex-col gap-32"
|
|
284
277
|
}, {
|
|
285
278
|
default: R(() => {
|
|
286
|
-
var
|
|
279
|
+
var I, D, V, T, z;
|
|
287
280
|
return [
|
|
288
|
-
x("div",
|
|
281
|
+
x("div", Ae, [
|
|
289
282
|
g(n, {
|
|
290
283
|
label: "Name",
|
|
291
284
|
"label-mark": "required",
|
|
292
|
-
rules: [l(
|
|
285
|
+
rules: [l(_e)()],
|
|
293
286
|
modelValue: l(o).name,
|
|
294
287
|
"onUpdate:modelValue": s[0] || (s[0] = (k) => l(o).name = k)
|
|
295
288
|
}, null, 8, ["rules", "modelValue"]),
|
|
@@ -299,30 +292,30 @@ const X = ie(
|
|
|
299
292
|
modelValue: l(o).ref,
|
|
300
293
|
"onUpdate:modelValue": s[1] || (s[1] = (k) => l(o).ref = k)
|
|
301
294
|
}, null, 8, ["modelValue"]),
|
|
302
|
-
x("div",
|
|
295
|
+
x("div", De, [
|
|
303
296
|
g(t, {
|
|
304
297
|
label: "Main ingredient",
|
|
305
298
|
required: ""
|
|
306
299
|
}),
|
|
307
300
|
g(e, {
|
|
308
|
-
onClick: s[2] || (s[2] = (k) =>
|
|
301
|
+
onClick: s[2] || (s[2] = (k) => G())
|
|
309
302
|
}, {
|
|
310
303
|
default: R(() => {
|
|
311
|
-
var k, E, $,
|
|
304
|
+
var k, E, $, L, N, K, q, P, H;
|
|
312
305
|
return [
|
|
313
306
|
($ = (E = (k = l(o)) == null ? void 0 : k.skus) == null ? void 0 : E[0]) != null && $.name ? (M(), ee("span", Ve, [
|
|
314
|
-
x("span", Ee, "[" +
|
|
315
|
-
te(" " +
|
|
316
|
-
])) : (M(), ee("span", Re,
|
|
307
|
+
x("span", Ee, "[" + j((K = (N = (L = l(o)) == null ? void 0 : L.skus) == null ? void 0 : N[0]) == null ? void 0 : K.code) + "]", 1),
|
|
308
|
+
te(" " + j((H = (P = (q = l(o)) == null ? void 0 : q.skus) == null ? void 0 : P[0]) == null ? void 0 : H.name), 1)
|
|
309
|
+
])) : (M(), ee("span", Re, j("Click to select main item")))
|
|
317
310
|
];
|
|
318
311
|
}),
|
|
319
312
|
_: 1
|
|
320
313
|
}),
|
|
321
314
|
x("div", Te, [
|
|
322
|
-
s[6] || (s[6] = te(
|
|
315
|
+
s[6] || (s[6] = te(j("Select a main item to filter out substitutable items with same unit.") + " ")),
|
|
323
316
|
g(u, {
|
|
324
|
-
"model-value": ((
|
|
325
|
-
rules: [l(
|
|
317
|
+
"model-value": ((I = l(o)) == null ? void 0 : I.skus) ?? [],
|
|
318
|
+
rules: [l(xe)(1, "Required")]
|
|
326
319
|
}, null, 8, ["model-value", "rules"])
|
|
327
320
|
])
|
|
328
321
|
])
|
|
@@ -333,7 +326,7 @@ const X = ie(
|
|
|
333
326
|
x("div", null, [
|
|
334
327
|
g(_, {
|
|
335
328
|
label: "Add items",
|
|
336
|
-
disabled: (((V = (
|
|
329
|
+
disabled: (((V = (D = l(o)) == null ? void 0 : D.skus) == null ? void 0 : V.length) ?? 0) < 1,
|
|
337
330
|
onClick: s[3] || (s[3] = (k) => b()),
|
|
338
331
|
"prepend-icon": "add",
|
|
339
332
|
variant: "secondary",
|
|
@@ -353,7 +346,7 @@ const X = ie(
|
|
|
353
346
|
}),
|
|
354
347
|
draggable: "",
|
|
355
348
|
"hide-footer": "",
|
|
356
|
-
"page-size": ((
|
|
349
|
+
"page-size": ((z = l(o).skus) == null ? void 0 : z.length) ?? 0
|
|
357
350
|
}, null, 8, ["row-data", "page-size"])
|
|
358
351
|
])
|
|
359
352
|
];
|
|
@@ -371,7 +364,7 @@ const X = ie(
|
|
|
371
364
|
},
|
|
372
365
|
emits: ["update:show"],
|
|
373
366
|
setup(U) {
|
|
374
|
-
const c = U, w = J(), o = Z(), { t: r } = W(), i =
|
|
367
|
+
const c = U, w = J(), o = Z(), { t: r } = W(), i = Fe(c, "show"), p = C({}), v = C(`${Math.random()}`);
|
|
375
368
|
ue(
|
|
376
369
|
() => c.show,
|
|
377
370
|
(t) => {
|
|
@@ -383,7 +376,7 @@ const X = ie(
|
|
|
383
376
|
}), v.value = `${Math.random()}`);
|
|
384
377
|
}
|
|
385
378
|
);
|
|
386
|
-
const f =
|
|
379
|
+
const f = F(() => {
|
|
387
380
|
switch (c.mode) {
|
|
388
381
|
case h.READ:
|
|
389
382
|
return "";
|
|
@@ -393,7 +386,7 @@ const X = ie(
|
|
|
393
386
|
return r("inventory.ingredient.create.title");
|
|
394
387
|
}
|
|
395
388
|
return "";
|
|
396
|
-
}), y =
|
|
389
|
+
}), y = F(() => {
|
|
397
390
|
switch (c.mode) {
|
|
398
391
|
case h.READ:
|
|
399
392
|
return "";
|
|
@@ -403,7 +396,7 @@ const X = ie(
|
|
|
403
396
|
return r("common.add");
|
|
404
397
|
}
|
|
405
398
|
return "";
|
|
406
|
-
}),
|
|
399
|
+
}), G = C(), b = C(!1);
|
|
407
400
|
async function d() {
|
|
408
401
|
b.value = !0;
|
|
409
402
|
const t = B(p.value);
|
|
@@ -414,7 +407,7 @@ const X = ie(
|
|
|
414
407
|
type: "success"
|
|
415
408
|
});
|
|
416
409
|
} catch (e) {
|
|
417
|
-
e instanceof
|
|
410
|
+
e instanceof se || o.open({
|
|
418
411
|
title: r("inventory.ingredient.create.error.title"),
|
|
419
412
|
message: r("inventory.ingredient.create.error.message"),
|
|
420
413
|
type: "error"
|
|
@@ -433,7 +426,7 @@ const X = ie(
|
|
|
433
426
|
type: "success"
|
|
434
427
|
});
|
|
435
428
|
} catch (e) {
|
|
436
|
-
e instanceof
|
|
429
|
+
e instanceof se || o.open({
|
|
437
430
|
title: r("inventory.ingredient.update.error.title"),
|
|
438
431
|
message: r("inventory.ingredient.update.error.message"),
|
|
439
432
|
type: "error"
|
|
@@ -444,7 +437,7 @@ const X = ie(
|
|
|
444
437
|
}
|
|
445
438
|
function s() {
|
|
446
439
|
var t, e;
|
|
447
|
-
(e = (t =
|
|
440
|
+
(e = (t = G.value) == null ? void 0 : t.validateInputs) == null || e.call(t);
|
|
448
441
|
}
|
|
449
442
|
function n() {
|
|
450
443
|
switch (c.mode) {
|
|
@@ -485,7 +478,7 @@ const X = ie(
|
|
|
485
478
|
(M(), O(Me, {
|
|
486
479
|
class: "w-full",
|
|
487
480
|
ref_key: "hasValidationExpose",
|
|
488
|
-
ref:
|
|
481
|
+
ref: G,
|
|
489
482
|
key: v.value,
|
|
490
483
|
"model-value": p.value,
|
|
491
484
|
"onUpdate:modelValue": e[0] || (e[0] = (m) => p.value = m),
|
|
@@ -498,17 +491,17 @@ const X = ie(
|
|
|
498
491
|
}, 8, ["model-value", "header"]);
|
|
499
492
|
};
|
|
500
493
|
}
|
|
501
|
-
}),
|
|
494
|
+
}), ze = { class: "flex flex-col py-8" }, Le = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Ne = { class: "fm-typo-en-body-lg-600 text-fm-color-typo-primary" }, Qe = /* @__PURE__ */ Y({
|
|
502
495
|
__name: "IngredientGroupView",
|
|
503
496
|
setup(U) {
|
|
504
|
-
const c = J(), w =
|
|
497
|
+
const c = J(), w = F(() => c.skuGroups), o = ke(), { t: r } = W(), {
|
|
505
498
|
createIngredientGroup: i,
|
|
506
499
|
updateIngredientGroup: p,
|
|
507
500
|
importIngredientGroups: v,
|
|
508
501
|
exportIngredientGroups: f
|
|
509
|
-
} = X(), { columnDefs: y, loading:
|
|
510
|
-
function d(
|
|
511
|
-
switch (
|
|
502
|
+
} = X(), { columnDefs: y, loading: G } = re(Ge()), { ingredientGroupDialogProps: b } = re(X());
|
|
503
|
+
function d(A) {
|
|
504
|
+
switch (A) {
|
|
512
505
|
case "add":
|
|
513
506
|
return i();
|
|
514
507
|
case "import":
|
|
@@ -517,7 +510,7 @@ const X = ie(
|
|
|
517
510
|
return f();
|
|
518
511
|
}
|
|
519
512
|
}
|
|
520
|
-
const a = C(""), s = C(!1), n =
|
|
513
|
+
const a = C(""), s = C(!1), n = F(() => s.value || G.value), { breakpoints: t } = Ce(), e = F(() => t.value.xs || t.value.sm), u = F(() => e.value ? 10 : 20), _ = he(), m = F(() => [
|
|
521
514
|
{
|
|
522
515
|
label: r("inventory.ingredient.create.title"),
|
|
523
516
|
value: "add",
|
|
@@ -527,8 +520,8 @@ const X = ie(
|
|
|
527
520
|
{ label: r("common.import"), value: "import" },
|
|
528
521
|
{ label: r("common.export"), value: "export" }
|
|
529
522
|
]);
|
|
530
|
-
return (
|
|
531
|
-
const
|
|
523
|
+
return (A, I) => {
|
|
524
|
+
const D = S("FmTable");
|
|
532
525
|
return M(), O(we, {
|
|
533
526
|
title: l(r)("inventory.ingredientGroup.title"),
|
|
534
527
|
actions: m.value,
|
|
@@ -547,37 +540,37 @@ const X = ie(
|
|
|
547
540
|
g(Se, {
|
|
548
541
|
searchable: "",
|
|
549
542
|
search: a.value,
|
|
550
|
-
"onUpdate:search":
|
|
543
|
+
"onUpdate:search": I[0] || (I[0] = (V) => a.value = V)
|
|
551
544
|
}, null, 8, ["search"]),
|
|
552
|
-
g(
|
|
545
|
+
g(D, {
|
|
553
546
|
style: me(l(_).tableHeight),
|
|
554
547
|
"column-defs": l(y),
|
|
555
548
|
"row-data": w.value,
|
|
556
549
|
"search-value": a.value,
|
|
557
550
|
loading: !l(o)._currentLocation || n.value,
|
|
558
551
|
"loading-text": "Loading",
|
|
559
|
-
onRowClick:
|
|
552
|
+
onRowClick: I[1] || (I[1] = (V) => l(p)(V.original)),
|
|
560
553
|
"page-size": u.value
|
|
561
554
|
}, {
|
|
562
555
|
"list-row": R((V) => [
|
|
563
|
-
g(
|
|
556
|
+
g(Ie, {
|
|
564
557
|
row: V,
|
|
565
558
|
onRowClick: l(p)
|
|
566
559
|
}, pe({
|
|
567
560
|
default: R((T) => {
|
|
568
|
-
var
|
|
561
|
+
var z, k, E, $, L, N, K, q, P, H;
|
|
569
562
|
return [
|
|
570
|
-
x("div",
|
|
571
|
-
x("div",
|
|
563
|
+
x("div", ze, [
|
|
564
|
+
x("div", Le, [
|
|
572
565
|
g(l(ae), {
|
|
573
|
-
render: (E = (k = (
|
|
574
|
-
props: (
|
|
566
|
+
render: (E = (k = (z = T.code) == null ? void 0 : z.column) == null ? void 0 : k.columnDef) == null ? void 0 : E.cell,
|
|
567
|
+
props: (L = ($ = T.code) == null ? void 0 : $.getContext) == null ? void 0 : L.call($)
|
|
575
568
|
}, null, 8, ["render", "props"])
|
|
576
569
|
]),
|
|
577
570
|
x("div", Ne, [
|
|
578
571
|
g(l(ae), {
|
|
579
572
|
render: (q = (K = (N = T.name) == null ? void 0 : N.column) == null ? void 0 : K.columnDef) == null ? void 0 : q.cell,
|
|
580
|
-
props: (
|
|
573
|
+
props: (H = (P = T.name) == null ? void 0 : P.getContext) == null ? void 0 : H.call(P)
|
|
581
574
|
}, null, 8, ["render", "props"])
|
|
582
575
|
])
|
|
583
576
|
])
|
|
@@ -588,7 +581,7 @@ const X = ie(
|
|
|
588
581
|
s.value ? {
|
|
589
582
|
name: "loading-text",
|
|
590
583
|
fn: R(() => [
|
|
591
|
-
x("div", null,
|
|
584
|
+
x("div", null, j(l(r)("inventory.ingredient.table.importing")), 1)
|
|
592
585
|
]),
|
|
593
586
|
key: "0"
|
|
594
587
|
} : void 0
|
|
@@ -607,5 +600,5 @@ const X = ie(
|
|
|
607
600
|
}
|
|
608
601
|
});
|
|
609
602
|
export {
|
|
610
|
-
|
|
603
|
+
Qe as default
|
|
611
604
|
};
|