@feedmepos/mf-inventory-portal 0.0.23-dev.36 → 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-CRVwCmFX.js → App-DQgtWkQj.js} +20 -20
- package/dist/{ApprovalView-CfJQdSRz.js → ApprovalView-CvSK9fGA.js} +10 -10
- package/dist/{BindingsDialog-BKL8E0Ni.js → BindingsDialog-BAC0_xCP.js} +8 -8
- package/dist/{BindingsPicker-M9-ARPgB.js → BindingsPicker-ecWMwsNp.js} +3 -3
- package/dist/{BindingsTable-BUs8wO0p.js → BindingsTable-D5kQydOU.js} +10 -10
- package/dist/{ClosingDraftView-BI3P4oS4.js → ClosingDraftView-CnHQ59rX.js} +46 -46
- package/dist/{ClosingTemplateView-D732hJJj.js → ClosingTemplateView-vRTsVZ0c.js} +21 -21
- package/dist/{FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-DzXJBW2r.js → FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-CpIzIvkU.js} +17 -17
- package/dist/{FmUnitInput.vue_vue_type_script_setup_true_lang-BPOPaW5x.js → FmUnitInput.vue_vue_type_script_setup_true_lang-CNzEHF-R.js} +37 -37
- package/dist/{IngredientBindedItem.vue_vue_type_script_setup_true_lang-DCYtyGvl.js → IngredientBindedItem.vue_vue_type_script_setup_true_lang-DBhBaRrd.js} +1 -1
- package/dist/{IngredientGroupView-CnnqKFGA.js → IngredientGroupView-BLsABZ3h.js} +1 -1
- package/dist/IngredientsView-Cs4TIf6V.js +1794 -0
- package/dist/{IntegrationView-6-Qvhwbr.js → IntegrationView-BqAqngtM.js} +137 -137
- package/dist/{InventoryBindingForm-F3o3dWhJ.js → InventoryBindingForm-D54V_qZQ.js} +1 -1
- package/dist/{InventoryBindingForm.vue_vue_type_script_setup_true_lang-B1hTEubD.js → InventoryBindingForm.vue_vue_type_script_setup_true_lang-KIW9J7Xn.js} +106 -96
- package/dist/{InventoryBindingSummary-B9ziVhZr.js → InventoryBindingSummary-htT7GNto.js} +1 -1
- package/dist/{NumberPrecisionInput.vue_vue_type_script_setup_true_lang-BquI8s88.js → NumberPrecisionInput.vue_vue_type_script_setup_true_lang-BlEgALMj.js} +1 -1
- package/dist/{PremiumBadge.vue_vue_type_script_setup_true_lang-BHRxlIxi.js → PremiumBadge.vue_vue_type_script_setup_true_lang-DHbxXDGy.js} +9 -9
- package/dist/{PurchaseOrderPrintPreview-DyjA8BsV.js → PurchaseOrderPrintPreview-hmzxKuIa.js} +5 -5
- package/dist/{ReceiveRequestView-BQoADy5j.js → ReceiveRequestView-_YioyWqU.js} +182 -182
- package/dist/{RecipeView-DOEPiT-V.js → RecipeView-88KJ0nvU.js} +3 -3
- package/dist/StockView-R4cnEbHQ.js +1818 -0
- package/dist/{SupplierView-BX6T3B40.js → SupplierView-CevGG507.js} +4 -4
- package/dist/{TransferDetails.vue_vue_type_script_setup_true_lang-C-8uS9KA.js → TransferDetails.vue_vue_type_script_setup_true_lang-CeWP9msS.js} +52 -52
- package/dist/{TransferTemplateView-D3smZIqo.js → TransferTemplateView-QDniAq8o.js} +114 -114
- package/dist/{UnitView-PZthqb2i.js → UnitView-SjwJ3lZ0.js} +14 -14
- package/dist/{WarehouseView-Qqqwk353.js → WarehouseView-55LiPQXG.js} +70 -70
- package/dist/api/adjustment-template.d.ts +2 -0
- package/dist/api/bill.d.ts +240 -84
- package/dist/api/inventory.d.ts +15 -6
- package/dist/{app-Dzll4soM.js → app-UTiudUUR.js} +6779 -6514
- package/dist/app.d.ts +8 -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-CSwcVJ9W.js → decimal-tyBgHJ47.js} +1 -1
- package/dist/feature-z7inw9y6.js +946 -0
- package/dist/{format-unit-display-D2-2_8Wo.js → format-unit-display-DN0KtCh2.js} +61 -61
- package/dist/index-Dj2Ccgp1.js +29202 -0
- package/dist/{StockView-CyJlLOjk.js → index-DlhdTaa8.js} +2218 -3854
- package/dist/{stock-VALQOiWM.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-CYRocBpq.js → supplier-BhyiTwSJ.js} +1 -1
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/dist/{use-inventory-binding-dialog-SiBEsYI-.js → use-inventory-binding-dialog-DwSvUvRl.js} +1 -1
- package/dist/views/adjustment-template/wastage-template/WastageTemplateReason.vue.d.ts +18 -0
- package/dist/views/adjustment-template/wastage-template/actions.d.ts +37 -3
- package/dist/views/adjustment-template/wastage-template/props.d.ts +7 -0
- package/dist/views/adjustment-template/wastage-template/table.d.ts +32 -2
- 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-DZS3wyBm.js +0 -1657
- package/dist/feature-CFAsUae4.js +0 -92
- package/dist/index-CLdXLjws.js +0 -12087
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { a as
|
|
1
|
+
import { defineComponent as G, computed as _, openBlock as v, createElementBlock as w, createElementVNode as l, Fragment as q, renderList as H, toDisplayString as V, createCommentVNode as Y, ref as M, resolveComponent as I, createBlock as T, withCtx as R, createVNode as y, unref as a, isRef as Z, normalizeClass as ae, normalizeStyle as re, Teleport as ie, normalizeProps as ue, guardReactiveProps as de } from "vue";
|
|
2
|
+
import { a as K, d as U, S as me, f as ce, D as ee, h as N, e as oe, l as j, A as pe, i as J, L as fe, N as ve, o as te, u as ye, y as be, z as ge, B as xe, E as _e, G as he } from "./app-UTiudUUR.js";
|
|
3
3
|
import { useDialog as Ve, useSnackbar as le, useProxiedModel as ne, useBreakpoints as Ue } from "@feedmepos/ui-library";
|
|
4
4
|
import { i as we, _ as Ce } from "./is-linked-ingredient-error-fJ2TJb3z.js";
|
|
5
5
|
import { defineStore as ke, storeToRefs as Se } from "pinia";
|
|
6
6
|
import { useI18n as O } from "@feedmepos/mf-common";
|
|
7
|
-
import { F as Fe } from "./decimal-
|
|
8
|
-
import { _ as $e } from "./NumberPrecisionInput.vue_vue_type_script_setup_true_lang-
|
|
7
|
+
import { F as Fe } from "./decimal-tyBgHJ47.js";
|
|
8
|
+
import { _ as $e } from "./NumberPrecisionInput.vue_vue_type_script_setup_true_lang-BlEgALMj.js";
|
|
9
9
|
const Ee = { class: "flex flex-col gap-8" }, Ie = {
|
|
10
10
|
key: 0,
|
|
11
11
|
class: "flex flex-col"
|
|
@@ -24,13 +24,13 @@ const Ee = { class: "flex flex-col gap-8" }, Ie = {
|
|
|
24
24
|
}, Be = { class: "flex-1 py-8 px-16" }, ze = {
|
|
25
25
|
class: "flex-0 py-8 px-16",
|
|
26
26
|
style: { "flex-basis": "240px" }
|
|
27
|
-
}, Le = /* @__PURE__ */
|
|
27
|
+
}, Le = /* @__PURE__ */ G({
|
|
28
28
|
__name: "UnitUsedBy",
|
|
29
29
|
props: {
|
|
30
30
|
unit: {}
|
|
31
31
|
},
|
|
32
32
|
setup(k) {
|
|
33
|
-
const f = k, b =
|
|
33
|
+
const f = k, b = K(), i = _(() => b.validateUnitUsage(f.unit)), r = _(() => i.value.filter((c) => c.from === "INGREDIENT")), o = _(() => i.value.filter((c) => c.from === "RECIPE")), m = _(() => i.value.filter((c) => c.from === "MENU"));
|
|
34
34
|
return (c, p) => (v(), w("div", Ee, [
|
|
35
35
|
p[3] || (p[3] = l("div", { class: "fm-typo-en-body-md-400" }, "Sorry, this unit is used in the following modules:", -1)),
|
|
36
36
|
r.value.length ? (v(), w("div", Ie, [
|
|
@@ -93,7 +93,7 @@ const Ee = { class: "flex flex-col gap-8" }, Ie = {
|
|
|
93
93
|
]));
|
|
94
94
|
}
|
|
95
95
|
}), Q = ke("unitForm", function() {
|
|
96
|
-
const f = Ve(), b = le(), i =
|
|
96
|
+
const f = Ve(), b = le(), i = K(), r = M(!1), o = M();
|
|
97
97
|
function m() {
|
|
98
98
|
const n = {
|
|
99
99
|
unit: {},
|
|
@@ -232,7 +232,7 @@ function Ne() {
|
|
|
232
232
|
}
|
|
233
233
|
] };
|
|
234
234
|
}
|
|
235
|
-
const je = { class: "flex flex-col gap-24" }, qe = { class: "flex gap-24" }, He = { class: "flex-1" },
|
|
235
|
+
const je = { class: "flex flex-col gap-24" }, qe = { class: "flex gap-24" }, He = { class: "flex-1" }, Ge = { class: "flex-1" }, Ke = { class: "flex" }, Oe = { class: "flex items-center" }, Ye = { class: "fm-typo-en-body-lg-600 flex-grow" }, Je = { class: "flex flex-col gap-24" }, Qe = { class: "flex gap-24" }, We = { class: "flex-1" }, Xe = { class: "flex-1" }, Ze = /* @__PURE__ */ G({
|
|
236
236
|
__name: "UnitForm",
|
|
237
237
|
props: {
|
|
238
238
|
mode: {},
|
|
@@ -338,7 +338,7 @@ const je = { class: "flex flex-col gap-24" }, qe = { class: "flex gap-24" }, He
|
|
|
338
338
|
"label-mark": "required"
|
|
339
339
|
}, null, 8, ["disabled", "label", "modelValue", "rules"])
|
|
340
340
|
]),
|
|
341
|
-
l("div",
|
|
341
|
+
l("div", Ge, [
|
|
342
342
|
y(d, {
|
|
343
343
|
disabled: e.disabled,
|
|
344
344
|
label: a(o)("inventory.unit.symbol"),
|
|
@@ -360,7 +360,7 @@ const je = { class: "flex flex-col gap-24" }, qe = { class: "flex gap-24" }, He
|
|
|
360
360
|
}, null, 8, ["disabled", "label", "modelValue", "rules"])
|
|
361
361
|
])
|
|
362
362
|
]),
|
|
363
|
-
l("div",
|
|
363
|
+
l("div", Ke, [
|
|
364
364
|
y(S, {
|
|
365
365
|
disabled: e.disabled,
|
|
366
366
|
type: "button",
|
|
@@ -441,7 +441,7 @@ const je = { class: "flex flex-col gap-24" }, qe = { class: "flex gap-24" }, He
|
|
|
441
441
|
}, 512);
|
|
442
442
|
};
|
|
443
443
|
}
|
|
444
|
-
}), et = { class: "flex gap-4" }, tt = /* @__PURE__ */
|
|
444
|
+
}), et = { class: "flex gap-4" }, tt = /* @__PURE__ */ G({
|
|
445
445
|
__name: "UnitDialog",
|
|
446
446
|
props: {
|
|
447
447
|
show: { type: Boolean },
|
|
@@ -450,7 +450,7 @@ const je = { class: "flex flex-col gap-24" }, qe = { class: "flex gap-24" }, He
|
|
|
450
450
|
},
|
|
451
451
|
emits: ["update:show"],
|
|
452
452
|
setup(k) {
|
|
453
|
-
const f = k, b =
|
|
453
|
+
const f = k, b = K(), i = le(), { t: r } = O(), o = ne(f, "show"), m = ne(f, "unit"), c = _(() => {
|
|
454
454
|
switch (f.mode) {
|
|
455
455
|
case U.READ:
|
|
456
456
|
return "";
|
|
@@ -563,10 +563,10 @@ const je = { class: "flex flex-col gap-24" }, qe = { class: "flex gap-24" }, He
|
|
|
563
563
|
}, 8, ["model-value", "header"]);
|
|
564
564
|
};
|
|
565
565
|
}
|
|
566
|
-
}), nt = { class: "flex flex-col py-8" }, ot = { class: "fm-typo-en-body-lg-600 text-fm-color-typo-primary" }, lt = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, pt = /* @__PURE__ */
|
|
566
|
+
}), nt = { class: "flex flex-col py-8" }, ot = { class: "fm-typo-en-body-lg-600 text-fm-color-typo-primary" }, lt = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, pt = /* @__PURE__ */ G({
|
|
567
567
|
__name: "UnitView",
|
|
568
568
|
setup(k) {
|
|
569
|
-
const f =
|
|
569
|
+
const f = K(), b = ye(), i = _(() => f.units), { createUnit: r, updateUnit: o } = Q(), { unitDialogProps: m, unitViewLoading: c } = Se(Q()), { columnDefs: p } = Ne();
|
|
570
570
|
function s(D) {
|
|
571
571
|
D === "add" && r();
|
|
572
572
|
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { ref as W, defineComponent as I, watch as ee, onMounted as te, onUnmounted as
|
|
2
|
-
import {
|
|
3
|
-
import { useCoreStore as
|
|
4
|
-
import { useDialogChild as
|
|
1
|
+
import { ref as W, defineComponent as I, watch as ee, onMounted as te, onUnmounted as xe, openBlock as S, createElementBlock as q, toRaw as be, reactive as Fe, createElementVNode as g, toDisplayString as U, unref as c, createVNode as V, resolveComponent as L, createSlots as $e, withCtx as N, createTextVNode as We, renderSlot as De, createBlock as z, createCommentVNode as Ae, computed as x, isRef as we, normalizeClass as Se, normalizeStyle as Pe } from "vue";
|
|
2
|
+
import { X as Re, ak as Te, al as Ue, f as Ee, D as Ve, h as Z, e as G, am as Le, _ as Ne, l as E, d as T, u as Be, y as qe, z as ze, B as Ie, E as je, G as J } from "./app-UTiudUUR.js";
|
|
3
|
+
import { useCoreStore as Ge, useI18n as j } from "@feedmepos/mf-common";
|
|
4
|
+
import { useDialogChild as Oe, useDialog as Me, useSnackbar as ae, useProxiedModel as oe, useBreakpoints as Ke } from "@feedmepos/ui-library";
|
|
5
5
|
import { c as le, u as se } from "./googlemap-Dm8ERVai.js";
|
|
6
|
-
const
|
|
7
|
-
const y =
|
|
6
|
+
const Q = Re((m, h) => {
|
|
7
|
+
const y = Ge();
|
|
8
8
|
return {
|
|
9
9
|
async readWarehouses() {
|
|
10
10
|
var l;
|
|
@@ -34,7 +34,7 @@ function He() {
|
|
|
34
34
|
};
|
|
35
35
|
}
|
|
36
36
|
const _e = W(He());
|
|
37
|
-
function
|
|
37
|
+
function Ce() {
|
|
38
38
|
return {
|
|
39
39
|
// state
|
|
40
40
|
get warehouses() {
|
|
@@ -45,17 +45,17 @@ function xe() {
|
|
|
45
45
|
},
|
|
46
46
|
// actions
|
|
47
47
|
async readWarehouses() {
|
|
48
|
-
const m =
|
|
48
|
+
const m = Q();
|
|
49
49
|
this.warehouses = await m.readWarehouses();
|
|
50
50
|
},
|
|
51
51
|
async createWarehouse(m) {
|
|
52
|
-
await
|
|
52
|
+
await Q().createWarehouse(m);
|
|
53
53
|
},
|
|
54
54
|
async updateWarehouse(m) {
|
|
55
|
-
await
|
|
55
|
+
await Q().updateWarehouse(m._id, m.profile);
|
|
56
56
|
},
|
|
57
57
|
async deleteWarehouse(m) {
|
|
58
|
-
await
|
|
58
|
+
await Q().deleteWarehouse(m._id);
|
|
59
59
|
},
|
|
60
60
|
async init() {
|
|
61
61
|
const m = Te();
|
|
@@ -67,14 +67,14 @@ function xe() {
|
|
|
67
67
|
}
|
|
68
68
|
};
|
|
69
69
|
}
|
|
70
|
-
function
|
|
70
|
+
function Xe(m, h) {
|
|
71
71
|
function y(p, s) {
|
|
72
|
-
if (p ===
|
|
73
|
-
m(
|
|
72
|
+
if (p === Z.Edit) {
|
|
73
|
+
m(G(s));
|
|
74
74
|
return;
|
|
75
75
|
}
|
|
76
|
-
if (p ===
|
|
77
|
-
h(
|
|
76
|
+
if (p === Z.Delete) {
|
|
77
|
+
h(G(s));
|
|
78
78
|
return;
|
|
79
79
|
}
|
|
80
80
|
}
|
|
@@ -104,7 +104,7 @@ function Ze(m, h) {
|
|
|
104
104
|
header: "",
|
|
105
105
|
cell(p) {
|
|
106
106
|
return Ee(
|
|
107
|
-
[Ve[
|
|
107
|
+
[Ve[Z.Edit], Ve[Z.Delete]],
|
|
108
108
|
(s) => {
|
|
109
109
|
y(s, p.row.original.original);
|
|
110
110
|
}
|
|
@@ -139,7 +139,7 @@ function Ze(m, h) {
|
|
|
139
139
|
}
|
|
140
140
|
return { columnDefs: n, formatRowData: l };
|
|
141
141
|
}
|
|
142
|
-
const
|
|
142
|
+
const Ze = /* @__PURE__ */ I({
|
|
143
143
|
__name: "GoogleMap",
|
|
144
144
|
props: {
|
|
145
145
|
markers: {
|
|
@@ -187,7 +187,7 @@ const Je = /* @__PURE__ */ I({
|
|
|
187
187
|
function $(r, f, b) {
|
|
188
188
|
v(r, f, b);
|
|
189
189
|
}
|
|
190
|
-
function
|
|
190
|
+
function C(r) {
|
|
191
191
|
P(null), M.value = r.map((f, b) => {
|
|
192
192
|
const F = new l.maps.Marker({
|
|
193
193
|
position: f,
|
|
@@ -219,7 +219,7 @@ const Je = /* @__PURE__ */ I({
|
|
|
219
219
|
n("polygon-change", { index: r, path: f });
|
|
220
220
|
}
|
|
221
221
|
function t(r, f) {
|
|
222
|
-
const F = o(r).filter((D,
|
|
222
|
+
const F = o(r).filter((D, O) => O !== f);
|
|
223
223
|
n("polygon-change", { index: r, path: F });
|
|
224
224
|
}
|
|
225
225
|
function B(r, f) {
|
|
@@ -255,9 +255,9 @@ const Je = /* @__PURE__ */ I({
|
|
|
255
255
|
scrollwheel: !0
|
|
256
256
|
}), Y(s.value, "click", (r) => n("map-click", _(r)));
|
|
257
257
|
}
|
|
258
|
-
return ee(() => a.markers,
|
|
259
|
-
!p.value || !l || (R(),
|
|
260
|
-
}),
|
|
258
|
+
return ee(() => a.markers, C, { deep: !0 }), ee(() => a.polygons, w, { deep: !0 }), te(() => {
|
|
259
|
+
!p.value || !l || (R(), C(a.markers), w(a.polygons));
|
|
260
|
+
}), xe(() => {
|
|
261
261
|
u.forEach((r) => r.remove());
|
|
262
262
|
}), (r, f) => (S(), q("div", {
|
|
263
263
|
ref_key: "mapRef",
|
|
@@ -265,7 +265,7 @@ const Je = /* @__PURE__ */ I({
|
|
|
265
265
|
class: "map app-map"
|
|
266
266
|
}, null, 512));
|
|
267
267
|
}
|
|
268
|
-
}),
|
|
268
|
+
}), Je = { class: "flex flex-col gap-24" }, Qe = { class: "flex flex-col gap-8" }, Ye = { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, eo = { class: "fm-typo-en-body-lg-600" }, oo = { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, to = { class: "fm-typo-en-body-lg-600" }, ao = { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, lo = { class: "fm-typo-en-body-lg-600" }, so = /* @__PURE__ */ I({
|
|
269
269
|
__name: "CoordinateDialog",
|
|
270
270
|
props: {
|
|
271
271
|
address: {
|
|
@@ -278,8 +278,8 @@ const Je = /* @__PURE__ */ I({
|
|
|
278
278
|
}
|
|
279
279
|
},
|
|
280
280
|
setup(m) {
|
|
281
|
-
const h = m, y =
|
|
282
|
-
|
|
281
|
+
const h = m, y = Oe(), a = se(), { t: n } = j(), l = Fe(
|
|
282
|
+
G(h.coordinate ? h.coordinate : le.jb)
|
|
283
283
|
), p = W(""), s = Le(async function() {
|
|
284
284
|
p.value = await a.getFirstMatchingAddress(
|
|
285
285
|
l.lat,
|
|
@@ -287,14 +287,14 @@ const Je = /* @__PURE__ */ I({
|
|
|
287
287
|
);
|
|
288
288
|
}, 1e3);
|
|
289
289
|
te(() => {
|
|
290
|
-
y.emitData(
|
|
290
|
+
y.emitData(G(l)), s();
|
|
291
291
|
});
|
|
292
292
|
function u({ position: v }) {
|
|
293
|
-
l.lat = v.lat, l.lng = v.lng, y.emitData(
|
|
293
|
+
l.lat = v.lat, l.lng = v.lng, y.emitData(G(l)), s();
|
|
294
294
|
}
|
|
295
295
|
const _ = W();
|
|
296
|
-
return (v, M) => (S(), q("div",
|
|
297
|
-
g("div",
|
|
296
|
+
return (v, M) => (S(), q("div", Je, [
|
|
297
|
+
g("div", Qe, [
|
|
298
298
|
g("div", null, [
|
|
299
299
|
g("span", Ye, U(c(n)("inventory.formField.coordinate.address")) + ": ", 1),
|
|
300
300
|
g("span", eo, U(p.value), 1)
|
|
@@ -308,7 +308,7 @@ const Je = /* @__PURE__ */ I({
|
|
|
308
308
|
g("span", lo, U(l.lat), 1)
|
|
309
309
|
])
|
|
310
310
|
]),
|
|
311
|
-
V(
|
|
311
|
+
V(Ze, {
|
|
312
312
|
ref_key: "gmapRef",
|
|
313
313
|
ref: _,
|
|
314
314
|
class: "h-[272px] sm:h-[240px] xs:h-[240px]",
|
|
@@ -374,7 +374,7 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
374
374
|
}).onPrimary(i);
|
|
375
375
|
}
|
|
376
376
|
const $ = (i) => a("update:modelValue", i ? no(i) : null);
|
|
377
|
-
async function
|
|
377
|
+
async function C() {
|
|
378
378
|
if (!y.disabled) {
|
|
379
379
|
if (!n.isGoogleMapReady) {
|
|
380
380
|
p.open({
|
|
@@ -405,7 +405,7 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
405
405
|
focused: u.value,
|
|
406
406
|
"helper-text": i.helperText,
|
|
407
407
|
"helper-state": i.helperState,
|
|
408
|
-
onClick: k[0] || (k[0] = (t) =>
|
|
408
|
+
onClick: k[0] || (k[0] = (t) => C())
|
|
409
409
|
}, $e({
|
|
410
410
|
default: N(({ invalid: t }) => [
|
|
411
411
|
i.modelValue && i.modelValue[0] && i.modelValue[1] ? (S(), q("div", io, [
|
|
@@ -453,7 +453,7 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
453
453
|
},
|
|
454
454
|
emits: ["update:modelValue", "validation-success"],
|
|
455
455
|
setup(m, { expose: h, emit: y }) {
|
|
456
|
-
const a = m, n = y, { t: l } = j(), p =
|
|
456
|
+
const a = m, n = y, { t: l } = j(), p = x({
|
|
457
457
|
get() {
|
|
458
458
|
var o, e;
|
|
459
459
|
return ((e = (o = a.modelValue) == null ? void 0 : o.profile) == null ? void 0 : e.name) ?? "";
|
|
@@ -462,7 +462,7 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
462
462
|
const e = a.modelValue ?? {};
|
|
463
463
|
e.profile ?? (e.profile = {}), e.profile.name = o, n("update:modelValue", e);
|
|
464
464
|
}
|
|
465
|
-
}), s =
|
|
465
|
+
}), s = x({
|
|
466
466
|
get() {
|
|
467
467
|
var o, e;
|
|
468
468
|
return ((e = (o = a.modelValue) == null ? void 0 : o.profile) == null ? void 0 : e.regNo) ?? "";
|
|
@@ -471,7 +471,7 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
471
471
|
const e = a.modelValue ?? {};
|
|
472
472
|
e.profile ?? (e.profile = {}), e.profile.regNo = o, n("update:modelValue", e);
|
|
473
473
|
}
|
|
474
|
-
}), u =
|
|
474
|
+
}), u = x({
|
|
475
475
|
get() {
|
|
476
476
|
var o, e, t;
|
|
477
477
|
return ((t = (e = (o = a.modelValue) == null ? void 0 : o.profile) == null ? void 0 : e.address) == null ? void 0 : t.line1) ?? "";
|
|
@@ -481,7 +481,7 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
481
481
|
const e = a.modelValue ?? {};
|
|
482
482
|
e.profile ?? (e.profile = {}), (t = e.profile).address ?? (t.address = {}), e.profile.address.line1 = o, n("update:modelValue", e);
|
|
483
483
|
}
|
|
484
|
-
}), _ =
|
|
484
|
+
}), _ = x({
|
|
485
485
|
get() {
|
|
486
486
|
var o, e, t;
|
|
487
487
|
return ((t = (e = (o = a.modelValue) == null ? void 0 : o.profile) == null ? void 0 : e.address) == null ? void 0 : t.line2) ?? "";
|
|
@@ -491,7 +491,7 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
491
491
|
const e = a.modelValue ?? {};
|
|
492
492
|
e.profile ?? (e.profile = {}), (t = e.profile).address ?? (t.address = {}), e.profile.address.line2 = o, n("update:modelValue", e);
|
|
493
493
|
}
|
|
494
|
-
}), v =
|
|
494
|
+
}), v = x({
|
|
495
495
|
get() {
|
|
496
496
|
var o, e, t;
|
|
497
497
|
return ((t = (e = (o = a.modelValue) == null ? void 0 : o.profile) == null ? void 0 : e.address) == null ? void 0 : t.city) ?? "";
|
|
@@ -501,7 +501,7 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
501
501
|
const e = a.modelValue ?? {};
|
|
502
502
|
e.profile ?? (e.profile = {}), (t = e.profile).address ?? (t.address = {}), e.profile.address.city = o, n("update:modelValue", e);
|
|
503
503
|
}
|
|
504
|
-
}), M =
|
|
504
|
+
}), M = x({
|
|
505
505
|
get() {
|
|
506
506
|
var o, e, t;
|
|
507
507
|
return ((t = (e = (o = a.modelValue) == null ? void 0 : o.profile) == null ? void 0 : e.address) == null ? void 0 : t.postcode) ?? "";
|
|
@@ -511,7 +511,7 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
511
511
|
const e = a.modelValue ?? {};
|
|
512
512
|
e.profile ?? (e.profile = {}), (t = e.profile).address ?? (t.address = {}), e.profile.address.postcode = o, n("update:modelValue", e);
|
|
513
513
|
}
|
|
514
|
-
}), $ =
|
|
514
|
+
}), $ = x({
|
|
515
515
|
get() {
|
|
516
516
|
var o, e, t;
|
|
517
517
|
return ((t = (e = (o = a.modelValue) == null ? void 0 : o.profile) == null ? void 0 : e.address) == null ? void 0 : t.state) ?? "";
|
|
@@ -521,7 +521,7 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
521
521
|
const e = a.modelValue ?? {};
|
|
522
522
|
e.profile ?? (e.profile = {}), (t = e.profile).address ?? (t.address = {}), e.profile.address.state = o, n("update:modelValue", e);
|
|
523
523
|
}
|
|
524
|
-
}),
|
|
524
|
+
}), C = x({
|
|
525
525
|
get() {
|
|
526
526
|
var o, e, t;
|
|
527
527
|
return ((t = (e = (o = a.modelValue) == null ? void 0 : o.profile) == null ? void 0 : e.address) == null ? void 0 : t.country) ?? "";
|
|
@@ -531,7 +531,7 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
531
531
|
const e = a.modelValue ?? {};
|
|
532
532
|
e.profile ?? (e.profile = {}), (t = e.profile).address ?? (t.address = {}), e.profile.address.country = o, n("update:modelValue", e);
|
|
533
533
|
}
|
|
534
|
-
}), P =
|
|
534
|
+
}), P = x({
|
|
535
535
|
get() {
|
|
536
536
|
var o, e, t;
|
|
537
537
|
return ((t = (e = (o = a.modelValue) == null ? void 0 : o.profile) == null ? void 0 : e.address) == null ? void 0 : t.coordinates) ?? null;
|
|
@@ -541,7 +541,7 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
541
541
|
const e = a.modelValue ?? {};
|
|
542
542
|
e.profile ?? (e.profile = {}), (t = e.profile).address ?? (t.address = {}), e.profile.address.coordinates = o, n("update:modelValue", e);
|
|
543
543
|
}
|
|
544
|
-
}), i =
|
|
544
|
+
}), i = x({
|
|
545
545
|
get() {
|
|
546
546
|
var o, e;
|
|
547
547
|
return ((e = (o = a.modelValue) == null ? void 0 : o.profile) == null ? void 0 : e.phoneNo) ?? "";
|
|
@@ -550,7 +550,7 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
550
550
|
const e = a.modelValue ?? {};
|
|
551
551
|
e.profile ?? (e.profile = {}), e.profile.phoneNo = o, n("update:modelValue", e);
|
|
552
552
|
}
|
|
553
|
-
}), k =
|
|
553
|
+
}), k = x({
|
|
554
554
|
get() {
|
|
555
555
|
var o, e;
|
|
556
556
|
return ((e = (o = a.modelValue) == null ? void 0 : o.profile) == null ? void 0 : e.email) ?? "";
|
|
@@ -647,8 +647,8 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
647
647
|
rules: [c(E)()],
|
|
648
648
|
"label-mark": "required",
|
|
649
649
|
label: c(l)("inventory.warehouse.address.country"),
|
|
650
|
-
modelValue:
|
|
651
|
-
"onUpdate:modelValue": e[7] || (e[7] = (d) =>
|
|
650
|
+
modelValue: C.value,
|
|
651
|
+
"onUpdate:modelValue": e[7] || (e[7] = (d) => C.value = d)
|
|
652
652
|
}, null, 8, ["disabled", "rules", "label", "modelValue"])
|
|
653
653
|
])
|
|
654
654
|
]),
|
|
@@ -697,7 +697,7 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
697
697
|
},
|
|
698
698
|
emits: ["update:show", "submitted"],
|
|
699
699
|
setup(m, { expose: h, emit: y }) {
|
|
700
|
-
const a = m, n = y, l = W(!1), p = ae(), { t: s } = j(), u =
|
|
700
|
+
const a = m, n = y, l = W(!1), p = ae(), { t: s } = j(), u = Ce(), _ = x(() => {
|
|
701
701
|
switch (a.mode) {
|
|
702
702
|
case T.READ:
|
|
703
703
|
return "";
|
|
@@ -707,7 +707,7 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
707
707
|
return s("inventory.warehouse.create.title");
|
|
708
708
|
}
|
|
709
709
|
return "";
|
|
710
|
-
}), v =
|
|
710
|
+
}), v = x(() => {
|
|
711
711
|
switch (a.mode) {
|
|
712
712
|
case T.READ:
|
|
713
713
|
return "";
|
|
@@ -732,7 +732,7 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
732
732
|
(e = (o = M.value) == null ? void 0 : o.resetInputs) == null || e.call(o);
|
|
733
733
|
}
|
|
734
734
|
});
|
|
735
|
-
const $ = oe(a, "show"),
|
|
735
|
+
const $ = oe(a, "show"), C = oe(a, "warehouse");
|
|
736
736
|
function P() {
|
|
737
737
|
var o, e;
|
|
738
738
|
(e = (o = M.value) == null ? void 0 : o.validateInputs) == null || e.call(o);
|
|
@@ -752,11 +752,11 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
752
752
|
l.value = !0;
|
|
753
753
|
try {
|
|
754
754
|
await Promise.all([
|
|
755
|
-
u.createWarehouse(
|
|
755
|
+
u.createWarehouse(C.value),
|
|
756
756
|
new Promise((t) => setTimeout(t, 1e3))
|
|
757
757
|
]), p.open({
|
|
758
758
|
title: s("inventory.common.success"),
|
|
759
|
-
message: s("inventory.warehouse.create.success", { name: (e = (o =
|
|
759
|
+
message: s("inventory.warehouse.create.success", { name: (e = (o = C.value) == null ? void 0 : o.profile) == null ? void 0 : e.name }),
|
|
760
760
|
type: "success"
|
|
761
761
|
}), n("update:show", !1), n("submitted");
|
|
762
762
|
} catch (t) {
|
|
@@ -771,7 +771,7 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
771
771
|
}
|
|
772
772
|
async function A() {
|
|
773
773
|
var o, e;
|
|
774
|
-
if (
|
|
774
|
+
if (C.value === null) {
|
|
775
775
|
p.open({
|
|
776
776
|
title: s("inventory.warehouse.update.error.title"),
|
|
777
777
|
message: s("inventory.warehouse.update.error.emptyWarehouse"),
|
|
@@ -782,11 +782,11 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
782
782
|
l.value = !0;
|
|
783
783
|
try {
|
|
784
784
|
await Promise.all([
|
|
785
|
-
u.updateWarehouse(
|
|
785
|
+
u.updateWarehouse(C.value),
|
|
786
786
|
new Promise((t) => setTimeout(t, 1e3))
|
|
787
787
|
]), p.open({
|
|
788
788
|
title: s("inventory.common.success"),
|
|
789
|
-
message: s("inventory.warehouse.update.success", { name: (e = (o =
|
|
789
|
+
message: s("inventory.warehouse.update.success", { name: (e = (o = C.value) == null ? void 0 : o.profile) == null ? void 0 : e.name }),
|
|
790
790
|
type: "success"
|
|
791
791
|
}), n("update:show", !1), n("submitted");
|
|
792
792
|
} catch (t) {
|
|
@@ -816,8 +816,8 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
816
816
|
class: "w-full",
|
|
817
817
|
ref_key: "formRef",
|
|
818
818
|
ref: M,
|
|
819
|
-
modelValue: c(
|
|
820
|
-
"onUpdate:modelValue": e[0] || (e[0] = (d) => we(
|
|
819
|
+
modelValue: c(C),
|
|
820
|
+
"onUpdate:modelValue": e[0] || (e[0] = (d) => we(C) ? C.value = d : null),
|
|
821
821
|
onValidationSuccess: i,
|
|
822
822
|
key: ((w = o.warehouse) == null ? void 0 : w._id) ?? "",
|
|
823
823
|
disabled: l.value
|
|
@@ -837,13 +837,13 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
837
837
|
}, 8, ["header", "modelValue", "dismiss-away"]);
|
|
838
838
|
};
|
|
839
839
|
}
|
|
840
|
-
}),
|
|
840
|
+
}), Co = { class: "flex flex-col py-8" }, xo = { class: "fm-typo-en-body-lg-600 text-fm-color-typo-primary" }, Fo = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, $o = {
|
|
841
841
|
key: 0,
|
|
842
842
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
|
|
843
843
|
}, Wo = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary line-clamp-3" }, Uo = /* @__PURE__ */ I({
|
|
844
844
|
__name: "WarehouseView",
|
|
845
845
|
setup(m) {
|
|
846
|
-
const h =
|
|
846
|
+
const h = Ce(), y = Be(), a = x(() => h.warehouses), n = Me(), l = ae(), p = W(!1), { t: s } = j();
|
|
847
847
|
te(() => {
|
|
848
848
|
y._currentLocation && A();
|
|
849
849
|
}), ee([() => y._currentLocation], () => {
|
|
@@ -892,7 +892,7 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
892
892
|
n.close();
|
|
893
893
|
}
|
|
894
894
|
}
|
|
895
|
-
const { columnDefs:
|
|
895
|
+
const { columnDefs: C, formatRowData: P } = Xe(
|
|
896
896
|
v,
|
|
897
897
|
M
|
|
898
898
|
);
|
|
@@ -913,7 +913,7 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
913
913
|
p.value = !1;
|
|
914
914
|
}
|
|
915
915
|
}
|
|
916
|
-
const { breakpoints: o } = Ke(), e =
|
|
916
|
+
const { breakpoints: o } = Ke(), e = x(() => o.value.xs || o.value.sm), t = x(() => e.value ? 10 : 20), B = qe();
|
|
917
917
|
return (w, d) => {
|
|
918
918
|
const Y = L("FmTable");
|
|
919
919
|
return S(), z(ze, {
|
|
@@ -946,7 +946,7 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
946
946
|
}, null, 8, ["search"]),
|
|
947
947
|
(S(), z(Y, {
|
|
948
948
|
style: Pe(c(B).tableHeight),
|
|
949
|
-
"column-defs": c(
|
|
949
|
+
"column-defs": c(C),
|
|
950
950
|
"row-data": c(P)(a.value),
|
|
951
951
|
"search-value": k.value,
|
|
952
952
|
loading: !c(y)._currentLocation || p.value,
|
|
@@ -960,31 +960,31 @@ const uo = { class: "flex gap-8 items-center" }, io = { key: 0 }, co = { key: 1
|
|
|
960
960
|
onRowClick: (r) => v(r.original)
|
|
961
961
|
}, {
|
|
962
962
|
default: N((r) => {
|
|
963
|
-
var f, b, F, D,
|
|
963
|
+
var f, b, F, D, O, re, ne, ue, K, ie, de, ce, pe, me, H, fe, he, ye, ve, X, ge;
|
|
964
964
|
return [
|
|
965
|
-
g("div",
|
|
966
|
-
g("div",
|
|
967
|
-
V(c(
|
|
965
|
+
g("div", Co, [
|
|
966
|
+
g("div", xo, [
|
|
967
|
+
V(c(J), {
|
|
968
968
|
render: (F = (b = (f = r.warehouse) == null ? void 0 : f.column) == null ? void 0 : b.columnDef) == null ? void 0 : F.cell,
|
|
969
|
-
props: (
|
|
969
|
+
props: (O = (D = r.warehouse) == null ? void 0 : D.getContext) == null ? void 0 : O.call(D)
|
|
970
970
|
}, null, 8, ["render", "props"])
|
|
971
971
|
]),
|
|
972
972
|
g("div", Fo, [
|
|
973
|
-
V(c(
|
|
973
|
+
V(c(J), {
|
|
974
974
|
render: (ue = (ne = (re = r.contact) == null ? void 0 : re.column) == null ? void 0 : ne.columnDef) == null ? void 0 : ue.cell,
|
|
975
975
|
props: (ie = (K = r.contact) == null ? void 0 : K.getContext) == null ? void 0 : ie.call(K)
|
|
976
976
|
}, null, 8, ["render", "props"])
|
|
977
977
|
]),
|
|
978
978
|
(de = R.original) != null && de.email ? (S(), q("div", $o, [
|
|
979
|
-
V(c(
|
|
979
|
+
V(c(J), {
|
|
980
980
|
render: (me = (pe = (ce = r.email) == null ? void 0 : ce.column) == null ? void 0 : pe.columnDef) == null ? void 0 : me.cell,
|
|
981
981
|
props: (fe = (H = r.email) == null ? void 0 : H.getContext) == null ? void 0 : fe.call(H)
|
|
982
982
|
}, null, 8, ["render", "props"])
|
|
983
983
|
])) : Ae("", !0),
|
|
984
984
|
g("div", Wo, [
|
|
985
|
-
V(c(
|
|
985
|
+
V(c(J), {
|
|
986
986
|
render: (ve = (ye = (he = r.address) == null ? void 0 : he.column) == null ? void 0 : ye.columnDef) == null ? void 0 : ve.cell,
|
|
987
|
-
props: (ge = (
|
|
987
|
+
props: (ge = (X = r.address) == null ? void 0 : X.getContext) == null ? void 0 : ge.call(X)
|
|
988
988
|
}, null, 8, ["render", "props"])
|
|
989
989
|
])
|
|
990
990
|
])
|
|
@@ -20,4 +20,6 @@ export declare const useAdjustmentTemplateApi: () => {
|
|
|
20
20
|
updateTemplate(template: FdoAdjustmentTemplate & RevisionIdMeta): Promise<FdoAdjustmentTemplate>;
|
|
21
21
|
deleteTemplate(template: FdoAdjustmentTemplate & RevisionIdMeta): Promise<any>;
|
|
22
22
|
importTemplates(templates: Array<(FdoAdjustmentTemplate & RevisionIdMeta) | Omit<FdoAdjustmentTemplate, '_id'>>): Promise<any>;
|
|
23
|
+
getReasons(): Promise<FdoAdjustmentTemplateReason>;
|
|
24
|
+
update(reason: FdoAdjustmentTemplateReason): Promise<any>;
|
|
23
25
|
};
|