@feedmepos/mf-inventory-portal 1.2.5-dev.1 → 1.2.6
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-plHMDZk7.js → App-B2pFxU6Q.js} +1 -1
- package/dist/{ApprovalView-CChHxp4X.js → ApprovalView-MLCuBCV2.js} +49 -50
- package/dist/{BindingsDialog-CU-u0hJx.js → BindingsDialog-CL68c1d8.js} +2 -2
- package/dist/{BindingsPicker-BpbNVNQQ.js → BindingsPicker-C1PiRtoM.js} +1 -1
- package/dist/{BindingsTable-v1QcskCd.js → BindingsTable-B4VyAoNq.js} +1 -1
- package/dist/ClosingDraftView-bLQW2std.js +1739 -0
- package/dist/{ClosingTemplateView-ancesrdQ.js → ClosingTemplateView-CABbUEYU.js} +2 -2
- package/dist/{DeliveryOrderPrintPreview-DLSzR6HB.js → DeliveryOrderPrintPreview-BybM2hq8.js} +8 -8
- package/dist/{FmAdminBadge-Cb9aT29U.js → FmAdminBadge-iN9PJ5nY.js} +1 -1
- package/dist/FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-1G6EEocg.js +227 -0
- package/dist/{FmMultiselectDialog-SoaYz3_K.js → FmMultiselectDialog-nsl8cwzo.js} +1 -1
- package/dist/{FmUnitInput.vue_vue_type_script_setup_true_lang-D5k7Xk3M.js → FmUnitInput.vue_vue_type_script_setup_true_lang-COw0sQLE.js} +15 -15
- package/dist/{IngredientBindedItem.vue_vue_type_script_setup_true_lang-NY7TPnoY.js → IngredientBindedItem.vue_vue_type_script_setup_true_lang-BYcFWA7r.js} +1 -1
- package/dist/{IngredientGroupView-DmbPHuWG.js → IngredientGroupView-oIBLqCBm.js} +2 -2
- package/dist/{IngredientsView-Bxb_BeyP.js → IngredientsView-DfGezD1v.js} +61 -71
- package/dist/{IntegrationView-B8mnGO1_.js → IntegrationView-jcuZnZ67.js} +84 -84
- package/dist/{InventoryBindingForm-B2tlc3uk.js → InventoryBindingForm-CQlTv-66.js} +1 -1
- package/dist/{InventoryBindingForm.vue_vue_type_script_setup_true_lang-C-qi9Mri.js → InventoryBindingForm.vue_vue_type_script_setup_true_lang-CevEjjIF.js} +3 -3
- package/dist/{InventoryBindingSummary-BUkLwuPN.js → InventoryBindingSummary-DRJn6ORe.js} +1 -1
- package/dist/{NumberPrecisionInput.vue_vue_type_script_setup_true_lang-4W5T_8W7.js → NumberPrecisionInput.vue_vue_type_script_setup_true_lang-CwwxbHy9.js} +1 -1
- package/dist/{PremiumBadge.vue_vue_type_script_setup_true_lang-DCtPbVFp.js → PremiumBadge.vue_vue_type_script_setup_true_lang-O2GL2zkX.js} +7 -7
- package/dist/{PublishView-Dkq9VZOG.js → PublishView-CY3Gvt3-.js} +7 -7
- package/dist/{PurchaseOrderPrintPreview-C-jyn09w.js → PurchaseOrderPrintPreview-Ck5HQc6r.js} +8 -8
- package/dist/{ReceiveRequestView-V4YNI_Jd.js → ReceiveRequestView-Da8bRntN.js} +79 -82
- package/dist/{RecipeView-Ck3RZRhC.js → RecipeView-B0_ddeT-.js} +3 -3
- package/dist/{StockView-nstUyEXe.js → StockView-BetJ_LZd.js} +7 -7
- package/dist/{SupplierView-eXyZsmHQ.js → SupplierView-DpDWVeHg.js} +831 -862
- package/dist/TransferDetails.vue_vue_type_script_setup_true_lang-AIFutKLT.js +2494 -0
- package/dist/{TransferTemplateView-DZG_UCWg.js → TransferTemplateView-L0NONcqq.js} +57 -57
- package/dist/{UnitView-COiitpcS.js → UnitView-DSTeDI8u.js} +3 -3
- package/dist/WarehouseView-DGJhvS_u.js +1034 -0
- package/dist/api/inventory.d.ts +0 -8
- package/dist/api/warehouse.d.ts +1 -3
- package/dist/{app-DayXXH4q.js → app-B7cGGPpZ.js} +15279 -15838
- package/dist/app.d.ts +9 -24
- package/dist/app.js +1 -1
- package/dist/{decimal-CFYWiBC2.js → decimal-DYg5n_FX.js} +1 -1
- package/dist/{format-unit-display-DIr9pTFo.js → format-unit-display-DHgB2J8m.js} +21 -21
- package/dist/{index-DLOpJmH-.js → index-C6Wn55RU.js} +1 -1
- package/dist/{index-tQKFc6GI.js → index-C9zJBvXv.js} +1 -1
- package/dist/{stock-DeAkNJnm.js → stock-BcEKPJrt.js} +1 -1
- package/dist/stores/feature.d.ts +0 -2
- package/dist/stores/inventory.d.ts +0 -1
- package/dist/stores/location.d.ts +1 -57
- package/dist/stores/supplier.d.ts +0 -96
- package/dist/stores/warehouse.d.ts +0 -4
- package/dist/{supplier-C4DAoZrI.js → supplier-DFoYi5-b.js} +1 -1
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/dist/{use-ingredient-select-dialog-CV7X8z4O.js → use-ingredient-select-dialog-C7mHdhdS.js} +1 -1
- package/dist/{use-inventory-binding-dialog-nuT-Ptlx.js → use-inventory-binding-dialog-CPjMBzhD.js} +1 -1
- package/dist/views/closing-draft/composables/use-closing-draft-actions.d.ts +3 -3
- package/dist/views/closing-draft/helpers/export-draft.helper.d.ts +2 -2
- package/dist/views/receive-request/components/transfer-details/TransferDetailsProps.d.ts +0 -1
- package/dist/views/receive-request/components/transfer-form/TransferForm.vue.d.ts +0 -60
- package/dist/views/receive-request/composables/use-process-purchase-order.d.ts +0 -10
- package/dist/views/receive-request/composables/use-receive-request-form.d.ts +0 -94
- package/dist/views/receive-request/composables/use-receive-request-table.d.ts +1 -72
- package/dist/views/supplier/components/SupplierForm.vue.d.ts +0 -8
- package/dist/views/supplier/composables/use-supplier-table.d.ts +0 -4
- package/dist/views/transfer-template/components/transfer-template-dialog/TransferTemplateDialog.vue.d.ts +0 -8
- package/dist/views/transfer-template/components/transfer-template-form/composables/use-transfer-locations.d.ts +0 -16
- package/dist/views/transfer-template/composables/use-transfer-template-actions.d.ts +0 -48
- package/dist/views/transfer-template/composables/use-transfer-template-table.d.ts +0 -48
- package/dist/views/warehouse/components/WarehouseForm.vue.d.ts +0 -8
- package/package.json +2 -2
- package/dist/ClosingDraftView-D9HwfK7e.js +0 -1687
- package/dist/FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-Cp0j6Sx0.js +0 -230
- package/dist/TransferDetails.vue_vue_type_script_setup_true_lang-OCR95cDM.js +0 -2578
- package/dist/WarehouseView-DhBpkfGm.js +0 -1066
- package/dist/api/shipment.d.ts +0 -11
|
@@ -1,230 +0,0 @@
|
|
|
1
|
-
import { j as C, t as N, aA as M, u as R, aE as B, aQ as D, l as H, aR as U } from "./app-DayXXH4q.js";
|
|
2
|
-
import { u as z } from "./supplier-C4DAoZrI.js";
|
|
3
|
-
import { P as T } from "./format-unit-display-DIr9pTFo.js";
|
|
4
|
-
import { computed as f, defineComponent as j, mergeModels as q, useModel as x, ref as W, resolveComponent as w, openBlock as L, createElementBlock as O, normalizeStyle as $, createElementVNode as A, createVNode as Q, withCtx as J, createBlock as V, createCommentVNode as E, Fragment as K, renderList as X, unref as g } from "vue";
|
|
5
|
-
function Y(e, a, r) {
|
|
6
|
-
var o;
|
|
7
|
-
if (!!a.measurement === !!r && ((o = a.measurement) == null ? void 0 : o.id) === r)
|
|
8
|
-
return a;
|
|
9
|
-
if (!r)
|
|
10
|
-
return {
|
|
11
|
-
costPerUnit: a.costPerUnit
|
|
12
|
-
};
|
|
13
|
-
const n = e.measurements.find((p) => p.id === r);
|
|
14
|
-
return n ? {
|
|
15
|
-
costPerUnit: a.costPerUnit,
|
|
16
|
-
measurement: n
|
|
17
|
-
} : {
|
|
18
|
-
costPerUnit: a.costPerUnit
|
|
19
|
-
};
|
|
20
|
-
}
|
|
21
|
-
function oe(e, a, r, u) {
|
|
22
|
-
var P, _, s;
|
|
23
|
-
const l = (s = (_ = (P = u == null ? void 0 : u.supplier) == null ? void 0 : P.supplyItems) == null ? void 0 : _.find(
|
|
24
|
-
(t) => t.skuId === e._id
|
|
25
|
-
)) == null ? void 0 : s.defaultCost;
|
|
26
|
-
if (u != null && u.manualTotalCost)
|
|
27
|
-
return {
|
|
28
|
-
cost: u.manualTotalCost,
|
|
29
|
-
skuDefaultCost: e.defaultCost ?? void 0,
|
|
30
|
-
supplierOverrideCost: l ?? void 0
|
|
31
|
-
};
|
|
32
|
-
const n = e.defaultCost ? Y(e.unit, e.defaultCost, e.trackingMeasurement) : void 0, o = l ?? n, p = o == null ? void 0 : o.costPerUnit, v = p ? o != null && o.measurement ? +C(p) / +C(o == null ? void 0 : o.measurement.conversion) : +C(p) : void 0, b = v ? r ? v * +C(r.conversion) : v : void 0, h = b ? +C(a) * b : void 0;
|
|
33
|
-
return {
|
|
34
|
-
cost: h ? {
|
|
35
|
-
...N(h ?? 0, 2),
|
|
36
|
-
currency: M()
|
|
37
|
-
} : {
|
|
38
|
-
amount: 0,
|
|
39
|
-
precision: 0,
|
|
40
|
-
currency: M()
|
|
41
|
-
},
|
|
42
|
-
skuDefaultCost: e.defaultCost ?? void 0,
|
|
43
|
-
supplierOverrideCost: l ?? void 0
|
|
44
|
-
};
|
|
45
|
-
}
|
|
46
|
-
function k(e) {
|
|
47
|
-
const a = D.safeParse(e);
|
|
48
|
-
if (a.success) return a.data;
|
|
49
|
-
throw new Error("Invalid supplier data");
|
|
50
|
-
}
|
|
51
|
-
function F(e) {
|
|
52
|
-
return {
|
|
53
|
-
_id: e.doc._id,
|
|
54
|
-
internal: e.type,
|
|
55
|
-
contactName: e.doc.profile.name,
|
|
56
|
-
name: e.doc.profile.name ?? "",
|
|
57
|
-
email: e.doc.profile.email,
|
|
58
|
-
phoneNumber: e.doc.profile.phoneNo,
|
|
59
|
-
registrationNumber: e.doc.profile.regNo,
|
|
60
|
-
address: e.doc.profile.address ?? {
|
|
61
|
-
line1: "",
|
|
62
|
-
state: "",
|
|
63
|
-
city: "",
|
|
64
|
-
postcode: "",
|
|
65
|
-
country: ""
|
|
66
|
-
},
|
|
67
|
-
preparationTime: e.preparationTime
|
|
68
|
-
};
|
|
69
|
-
}
|
|
70
|
-
function ne(e, a, r = !1, u = !1) {
|
|
71
|
-
const l = z(), n = R();
|
|
72
|
-
n.watchLocation(async () => {
|
|
73
|
-
var y;
|
|
74
|
-
await l.readSuppliers();
|
|
75
|
-
const s = e();
|
|
76
|
-
if ((y = s.supplier) != null && y._id) return;
|
|
77
|
-
const t = u ? l.suppliers[0] : l.businessSuppliers[0], i = (r ? n.locations.filter((d) => d.doc._id !== n.currentLocation.doc._id) : n.locations)[0];
|
|
78
|
-
a({
|
|
79
|
-
...s,
|
|
80
|
-
supplier: t ? k(t) : i ? F(i) : s.supplier
|
|
81
|
-
});
|
|
82
|
-
});
|
|
83
|
-
const o = f(
|
|
84
|
-
() => {
|
|
85
|
-
var s, t;
|
|
86
|
-
return typeof ((t = (s = e()) == null ? void 0 : s.supplier) == null ? void 0 : t.internal) == "string" ? T.TRANSFER : T.PURCHASE;
|
|
87
|
-
}
|
|
88
|
-
), p = f({
|
|
89
|
-
get() {
|
|
90
|
-
var s, t;
|
|
91
|
-
return (t = (s = e()) == null ? void 0 : s.supplier) == null ? void 0 : t._id;
|
|
92
|
-
},
|
|
93
|
-
set(s) {
|
|
94
|
-
const t = e() ?? {};
|
|
95
|
-
if (o.value === T.PURCHASE) {
|
|
96
|
-
const S = (u ? l.suppliers : l.businessSuppliers).find((I) => I._id === s);
|
|
97
|
-
a({
|
|
98
|
-
...t,
|
|
99
|
-
supplier: S ? k(S) : t.supplier
|
|
100
|
-
});
|
|
101
|
-
return;
|
|
102
|
-
}
|
|
103
|
-
const y = (r ? n.allLocations.filter(
|
|
104
|
-
(d) => d.doc._id !== n.currentLocation.doc._id
|
|
105
|
-
) : n.allLocations).find((d) => d.doc._id === s);
|
|
106
|
-
a({
|
|
107
|
-
...t,
|
|
108
|
-
supplier: y ? F(y) : t.supplier
|
|
109
|
-
});
|
|
110
|
-
}
|
|
111
|
-
}), v = f(() => l.locationSuppliers.map(k)), b = f(() => l.businessSuppliers.map(k)), h = f(() => {
|
|
112
|
-
const s = [...v.value], t = [...b.value];
|
|
113
|
-
return u ? [...t, ...s] : t;
|
|
114
|
-
}), c = f(() => {
|
|
115
|
-
var m;
|
|
116
|
-
const s = ((m = n._currentLocation) == null ? void 0 : m.type) === B.warehouse;
|
|
117
|
-
return (r ? n.allLocations.filter(
|
|
118
|
-
(i) => i.doc._id !== n.currentLocation.doc._id
|
|
119
|
-
) : n.allLocations).filter((i) => s || i.acceptRequest).map(F);
|
|
120
|
-
}), P = f(() => {
|
|
121
|
-
if (o.value === T.PURCHASE) {
|
|
122
|
-
const t = v.value.map((i) => ({
|
|
123
|
-
label: i.name,
|
|
124
|
-
value: i._id
|
|
125
|
-
})), m = b.value.map((i) => ({
|
|
126
|
-
label: i.name,
|
|
127
|
-
sublabel: "Business supplier",
|
|
128
|
-
value: i._id
|
|
129
|
-
}));
|
|
130
|
-
return u ? [...t, ...m] : m;
|
|
131
|
-
}
|
|
132
|
-
return c.value.map((t) => ({
|
|
133
|
-
label: t.name,
|
|
134
|
-
sublabel: t.internal ? `${t.internal}` : void 0,
|
|
135
|
-
value: t._id
|
|
136
|
-
}));
|
|
137
|
-
}), _ = f(() => {
|
|
138
|
-
var i, y;
|
|
139
|
-
const s = (y = (i = e()) == null ? void 0 : i.supplier) == null ? void 0 : y._id;
|
|
140
|
-
if (o.value === T.PURCHASE) {
|
|
141
|
-
const d = l.suppliers.find((S) => S._id === s);
|
|
142
|
-
return d ? k(d) : null;
|
|
143
|
-
}
|
|
144
|
-
const m = n.allLocations.find((d) => d.doc._id);
|
|
145
|
-
return m ? F(m) : null;
|
|
146
|
-
});
|
|
147
|
-
return {
|
|
148
|
-
transferLocationModel: p,
|
|
149
|
-
transferLocationOptions: P,
|
|
150
|
-
locationOptionsTypePurchase: h,
|
|
151
|
-
locationOptionsTypePurchaseLocationLevel: v,
|
|
152
|
-
locationOptionsTypeTransfer: c,
|
|
153
|
-
selectedLocation: _
|
|
154
|
-
};
|
|
155
|
-
}
|
|
156
|
-
const Z = { class: "overflow-y-auto h-full pb-8" }, ae = /* @__PURE__ */ j({
|
|
157
|
-
__name: "FmFilterableMenuOptions",
|
|
158
|
-
props: /* @__PURE__ */ q({
|
|
159
|
-
modelValue: {},
|
|
160
|
-
maxHeight: {},
|
|
161
|
-
width: {},
|
|
162
|
-
handleItemChange: { type: Function },
|
|
163
|
-
items: {},
|
|
164
|
-
options: {}
|
|
165
|
-
}, {
|
|
166
|
-
search: {},
|
|
167
|
-
searchModifiers: {}
|
|
168
|
-
}),
|
|
169
|
-
emits: ["update:search"],
|
|
170
|
-
setup(e) {
|
|
171
|
-
const a = e, r = x(e, "search"), u = f(
|
|
172
|
-
() => new H(a.items, ["label", "sublabel"], {
|
|
173
|
-
caseSensitive: !1,
|
|
174
|
-
sort: !0
|
|
175
|
-
})
|
|
176
|
-
), l = f(() => u.value.search(r.value)), n = W();
|
|
177
|
-
return console.log({ stickyRef: n }), (o, p) => {
|
|
178
|
-
const v = w("FmButton"), b = w("FmTextField"), h = w("FmMenuItem");
|
|
179
|
-
return L(), O("div", {
|
|
180
|
-
class: "relative",
|
|
181
|
-
style: $({ width: o.width })
|
|
182
|
-
}, [
|
|
183
|
-
A("div", {
|
|
184
|
-
class: "sticky top-0 bg-white mb-8",
|
|
185
|
-
ref_key: "stickyRef",
|
|
186
|
-
ref: n
|
|
187
|
-
}, [
|
|
188
|
-
Q(b, {
|
|
189
|
-
modelValue: r.value,
|
|
190
|
-
"onUpdate:modelValue": p[1] || (p[1] = (c) => r.value = c),
|
|
191
|
-
placeholder: "Filter options"
|
|
192
|
-
}, {
|
|
193
|
-
append: J(() => [
|
|
194
|
-
r.value ? (L(), V(v, {
|
|
195
|
-
key: 0,
|
|
196
|
-
variant: "tertiary",
|
|
197
|
-
"prepend-icon": "close",
|
|
198
|
-
onClick: p[0] || (p[0] = (c) => r.value = "")
|
|
199
|
-
})) : E("", !0)
|
|
200
|
-
]),
|
|
201
|
-
_: 1
|
|
202
|
-
}, 8, ["modelValue"])
|
|
203
|
-
], 512),
|
|
204
|
-
A("div", Z, [
|
|
205
|
-
(L(!0), O(K, null, X(l.value, (c, P) => (L(), V(h, {
|
|
206
|
-
key: P,
|
|
207
|
-
label: c.label,
|
|
208
|
-
sublabel: c.sublabel,
|
|
209
|
-
"model-value": g(U)(o.modelValue, c.value),
|
|
210
|
-
onClick: () => o.handleItemChange(g(U)(o.modelValue, c.value), c),
|
|
211
|
-
onVnodeMounted: (_) => {
|
|
212
|
-
var s, t;
|
|
213
|
-
return g(U)(o.modelValue, c.value) && ((s = _.el) == null || s.scrollIntoView({ behavior: "instant", block: "end" }), (t = _.el) == null || t.scrollIntoView({ behavior: "smooth", block: "center" })), void 0;
|
|
214
|
-
}
|
|
215
|
-
}, null, 8, ["label", "sublabel", "model-value", "onClick", "onVnodeMounted"]))), 128)),
|
|
216
|
-
l.value.length ? E("", !0) : (L(), V(h, {
|
|
217
|
-
key: 0,
|
|
218
|
-
disabled: "",
|
|
219
|
-
label: "No options available"
|
|
220
|
-
}))
|
|
221
|
-
])
|
|
222
|
-
], 4);
|
|
223
|
-
};
|
|
224
|
-
}
|
|
225
|
-
});
|
|
226
|
-
export {
|
|
227
|
-
ae as _,
|
|
228
|
-
oe as c,
|
|
229
|
-
ne as u
|
|
230
|
-
};
|