@feedmepos/mf-report 5.5.11-beta.1 → 5.5.11-beta.2
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.
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { defineComponent as q, mergeModels as ye, useModel as X, computed as Y, resolveComponent as S, createElementBlock as
|
|
1
|
+
import { defineComponent as q, mergeModels as ye, useModel as X, computed as Y, resolveComponent as S, createElementBlock as D, openBlock as c, createElementVNode as t, createCommentVNode as N, normalizeClass as Ae, Fragment as L, renderList as H, createBlock as M, createVNode as r, withCtx as ge, toDisplayString as T, unref as u, ref as B, onUnmounted as be, watch as ve, isRef as we, h as I, resolveDynamicComponent as xe, mergeProps as Ee, onMounted as ze } from "vue";
|
|
2
2
|
import { useRouter as de, useRoute as Ye } from "vue-router";
|
|
3
3
|
import { u as J, I as ce, d as Le, e as _e, f as he, b as pe, q as qe, m as He, p as Ve, r as ke, s as $e, t as Se, v as Pe, w as Xe, x as Qe, y as Ge, A as fe, z as Ne, B as Je, E as We } from "./global-loader-BqFQzk46.js";
|
|
4
4
|
import { u as Ce } from "./message-dialog-UoMWOnil.js";
|
|
5
5
|
import { useSnackbar as ue } from "@feedmepos/ui-library";
|
|
6
6
|
import { s as Ze } from "./index-DqqTHE7n.js";
|
|
7
|
-
import { storeToRefs as
|
|
8
|
-
import { _ as
|
|
7
|
+
import { storeToRefs as De } from "pinia";
|
|
8
|
+
import { _ as Fe } from "./DateRangeSelect.vue_vue_type_script_setup_true_lang-CN3UKRaQ.js";
|
|
9
9
|
const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-between" }, tt = { class: "text-nowrap w-[100%] overflow-hidden text-ellipsis" }, ot = {
|
|
10
10
|
key: 0,
|
|
11
11
|
class: "w-[24px] flex items-center"
|
|
@@ -33,8 +33,8 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
33
33
|
modelModifiers: {}
|
|
34
34
|
}),
|
|
35
35
|
emits: /* @__PURE__ */ ye(["remove"], ["update:modelValue"]),
|
|
36
|
-
setup(
|
|
37
|
-
const e = X(
|
|
36
|
+
setup(v, { emit: o }) {
|
|
37
|
+
const e = X(v, "modelValue"), s = v, V = Y(
|
|
38
38
|
() => Object.keys(s.options).map((_) => {
|
|
39
39
|
const C = s.options[_];
|
|
40
40
|
return {
|
|
@@ -46,27 +46,27 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
46
46
|
), h = o;
|
|
47
47
|
return (_, C) => {
|
|
48
48
|
const b = S("FmTextField"), x = S("FmTooltip"), m = S("FmIcon");
|
|
49
|
-
return c(),
|
|
49
|
+
return c(), D("div", et, [
|
|
50
50
|
t("div", {
|
|
51
|
-
class: Ae(`${
|
|
51
|
+
class: Ae(`${v.removable ? "w-[calc(100%-24px)]" : "w-[100%]"} flex flex-row items-center gap-[4px]`)
|
|
52
52
|
}, [
|
|
53
|
-
(c(!0),
|
|
53
|
+
(c(!0), D(L, null, H(V.value, (w) => {
|
|
54
54
|
var k;
|
|
55
|
-
return c(),
|
|
55
|
+
return c(), D(L, {
|
|
56
56
|
key: w.key
|
|
57
57
|
}, [
|
|
58
|
-
w.editable ? (c(),
|
|
58
|
+
w.editable ? (c(), D("div", {
|
|
59
59
|
key: 0,
|
|
60
|
-
class: Ae(`${
|
|
60
|
+
class: Ae(`${v.removable ? "w-[50%]" : "w-[100%]"}`)
|
|
61
61
|
}, [
|
|
62
62
|
r(b, {
|
|
63
63
|
"model-value": e.value[w.key],
|
|
64
64
|
placeholder: w.placeholder,
|
|
65
|
-
type:
|
|
66
|
-
rules:
|
|
65
|
+
type: v.type,
|
|
66
|
+
rules: v.rules,
|
|
67
67
|
"onUpdate:modelValue": (d) => {
|
|
68
68
|
let y = d;
|
|
69
|
-
|
|
69
|
+
v.type === "number" && (y = Number(d)), e.value = {
|
|
70
70
|
...e.value,
|
|
71
71
|
[w.key]: y
|
|
72
72
|
};
|
|
@@ -85,7 +85,7 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
85
85
|
], 64);
|
|
86
86
|
}), 128))
|
|
87
87
|
], 2),
|
|
88
|
-
|
|
88
|
+
v.removable ? (c(), D("div", ot, [
|
|
89
89
|
r(m, {
|
|
90
90
|
color: "system-error-300",
|
|
91
91
|
class: "cursor-pointer",
|
|
@@ -119,8 +119,8 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
119
119
|
modelModifiers: {}
|
|
120
120
|
}),
|
|
121
121
|
emits: ["update:modelValue"],
|
|
122
|
-
setup(
|
|
123
|
-
const { t: o } = J(), e = X(
|
|
122
|
+
setup(v) {
|
|
123
|
+
const { t: o } = J(), e = X(v, "modelValue"), s = Y(() => {
|
|
124
124
|
switch (e.value.name) {
|
|
125
125
|
case ce.AutoCount:
|
|
126
126
|
case ce.SQL:
|
|
@@ -133,30 +133,30 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
133
133
|
return (V, h) => {
|
|
134
134
|
var x, m;
|
|
135
135
|
const _ = S("FmSwitch"), C = S("FmTextField"), b = S("FmTimePicker");
|
|
136
|
-
return c(),
|
|
136
|
+
return c(), D(L, null, [
|
|
137
137
|
t("div", at, [
|
|
138
|
-
t("div", lt, T(
|
|
139
|
-
|
|
138
|
+
t("div", lt, T(u(o)("report.integration.auto", { label: v.label })), 1),
|
|
139
|
+
v.label == "upload" ? (c(), D("div", nt, T(u(o)("report.integration.lastUploadDate")) + ": " + T(v.lastUploadDate ? u(Le)(v.lastUploadDate).format("MMMM D, YYYY h:mm A") : u(o)("report.integration.noData.title")), 1)) : N("", !0)
|
|
140
140
|
]),
|
|
141
141
|
t("div", st, [
|
|
142
|
-
t("div", it, T(
|
|
142
|
+
t("div", it, T(u(o)("report.common.enable")), 1),
|
|
143
143
|
r(_, {
|
|
144
144
|
modelValue: e.value.enable,
|
|
145
145
|
"onUpdate:modelValue": h[0] || (h[0] = (w) => e.value.enable = w),
|
|
146
146
|
style: { gap: "0px" }
|
|
147
147
|
}, null, 8, ["modelValue"])
|
|
148
148
|
]),
|
|
149
|
-
s.value ? (c(),
|
|
150
|
-
t("div", mt, T(
|
|
149
|
+
s.value ? (c(), D("div", rt, [
|
|
150
|
+
t("div", mt, T(u(o)("report.common.email")), 1),
|
|
151
151
|
t("div", ct, [
|
|
152
152
|
r(C, {
|
|
153
153
|
"model-value": (e.value.emails || []).join(","),
|
|
154
154
|
placeholder: "Email",
|
|
155
155
|
"onUpdate:modelValue": h[1] || (h[1] = (w) => {
|
|
156
156
|
switch (e.value.name) {
|
|
157
|
-
case
|
|
158
|
-
case
|
|
159
|
-
case
|
|
157
|
+
case u(ce).AutoCount:
|
|
158
|
+
case u(ce).SQL:
|
|
159
|
+
case u(ce).iFlexi_HRMS:
|
|
160
160
|
e.value.emails = w.split(",");
|
|
161
161
|
break;
|
|
162
162
|
}
|
|
@@ -166,11 +166,11 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
166
166
|
])) : N("", !0),
|
|
167
167
|
t("div", dt, [
|
|
168
168
|
t("div", pt, [
|
|
169
|
-
t("div", ut, T(
|
|
169
|
+
t("div", ut, T(u(Ze)(v.label)) + " time ", 1),
|
|
170
170
|
t("div", ft, [
|
|
171
171
|
r(b, {
|
|
172
172
|
class: "gap-[0px]",
|
|
173
|
-
"model-value":
|
|
173
|
+
"model-value": u(Le)().hour(((x = e.value.triggerTime) == null ? void 0 : x.hour) ?? 0).minute(((m = e.value.triggerTime) == null ? void 0 : m.minute) ?? 0).format("HH:mm"),
|
|
174
174
|
"onUpdate:modelValue": h[2] || (h[2] = (w) => {
|
|
175
175
|
w && (e.value.triggerTime.hour = Number(w.split(":")[0]), e.value.triggerTime.minute = Number(w.split(":")[1]));
|
|
176
176
|
})
|
|
@@ -179,13 +179,13 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
179
179
|
]),
|
|
180
180
|
r(K, {
|
|
181
181
|
"model-value": {
|
|
182
|
-
label:
|
|
182
|
+
label: u(o)("report.integration.delayDay"),
|
|
183
183
|
delayDay: e.value.delayDay
|
|
184
184
|
},
|
|
185
185
|
type: "number",
|
|
186
186
|
options: {
|
|
187
|
-
label: { placeholder:
|
|
188
|
-
delayDay: { placeholder:
|
|
187
|
+
label: { placeholder: u(o)("report.integration.delayDay"), editable: !1 },
|
|
188
|
+
delayDay: { placeholder: u(o)("report.integration.delayDay"), editable: !0 }
|
|
189
189
|
},
|
|
190
190
|
rules: [(w) => w > 0 || "Delay days must be greater than 0"],
|
|
191
191
|
"onUpdate:modelValue": h[3] || (h[3] = (w) => {
|
|
@@ -230,8 +230,8 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
230
230
|
modelModifiers: {}
|
|
231
231
|
}),
|
|
232
232
|
emits: /* @__PURE__ */ ye(["remove"], ["update:modelValue"]),
|
|
233
|
-
setup(
|
|
234
|
-
const e = X(
|
|
233
|
+
setup(v, { emit: o }) {
|
|
234
|
+
const e = X(v, "modelValue"), s = v, V = Y(
|
|
235
235
|
() => Object.keys(s.options).map((x) => {
|
|
236
236
|
const m = s.options[x];
|
|
237
237
|
return {
|
|
@@ -252,28 +252,28 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
252
252
|
}, C = (x) => s.singleValueMode ? e.value : e.value[x.key], b = o;
|
|
253
253
|
return (x, m) => {
|
|
254
254
|
const w = S("FmSelect"), k = S("FmTextField"), d = S("FmTooltip"), y = S("FmIcon");
|
|
255
|
-
return c(),
|
|
255
|
+
return c(), D("div", vt, [
|
|
256
256
|
t("div", {
|
|
257
|
-
class: Ae(`${
|
|
257
|
+
class: Ae(`${v.removable ? "w-[calc(100%-24px)]" : "w-[100%]"} flex flex-row items-center gap-[4px]`)
|
|
258
258
|
}, [
|
|
259
|
-
(c(!0),
|
|
259
|
+
(c(!0), D(L, null, H(V.value, (n) => (c(), D(L, {
|
|
260
260
|
key: n.key
|
|
261
261
|
}, [
|
|
262
|
-
n.editable ? (c(),
|
|
262
|
+
n.editable ? (c(), D("div", gt, [
|
|
263
263
|
n.dropdownOptions ? (c(), M(w, {
|
|
264
264
|
key: 0,
|
|
265
265
|
"model-value": C(n),
|
|
266
266
|
placeholder: n.placeholder,
|
|
267
267
|
items: n.dropdownOptions,
|
|
268
268
|
"shift-menu": !0,
|
|
269
|
-
"onUpdate:modelValue": (
|
|
269
|
+
"onUpdate:modelValue": (g) => h(g, n.key)
|
|
270
270
|
}, null, 8, ["model-value", "placeholder", "items", "onUpdate:modelValue"])) : (c(), M(k, {
|
|
271
271
|
key: 1,
|
|
272
272
|
"model-value": C(n),
|
|
273
273
|
placeholder: n.placeholder,
|
|
274
|
-
type:
|
|
275
|
-
rules:
|
|
276
|
-
"onUpdate:modelValue": (
|
|
274
|
+
type: v.type,
|
|
275
|
+
rules: v.rules,
|
|
276
|
+
"onUpdate:modelValue": (g) => h(g, n.key)
|
|
277
277
|
}, null, 8, ["model-value", "placeholder", "type", "rules", "onUpdate:modelValue"]))
|
|
278
278
|
])) : (c(), M(d, {
|
|
279
279
|
key: 1,
|
|
@@ -287,7 +287,7 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
287
287
|
}, 1032, ["content"]))
|
|
288
288
|
], 64))), 128))
|
|
289
289
|
], 2),
|
|
290
|
-
|
|
290
|
+
v.removable ? (c(), D("div", xt, [
|
|
291
291
|
r(y, {
|
|
292
292
|
color: "system-error-300",
|
|
293
293
|
class: "cursor-pointer",
|
|
@@ -302,7 +302,7 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
302
302
|
}), _t = {
|
|
303
303
|
key: 0,
|
|
304
304
|
class: "flex flex-col h-full"
|
|
305
|
-
}, bt = { class: "flex flex-col gap-[16px] pb-[24px]" }, wt = { class: "flex flex-row justify-between items-center gap-2" }, ht = { class: "flex flex-row gap-2 items-center" }, Vt = { class: "relative group cursor-pointer" }, kt = { class: "flex flex-col gap-16 pt-[24px] overflow-scroll" }, $t = { class: "flex flex-row items-center justify-between gap-2" }, St = { class: "w-[25%]" }, Ct = { class: "flex flex-col gap-[16px]" },
|
|
305
|
+
}, bt = { class: "flex flex-col gap-[16px] pb-[24px]" }, wt = { class: "flex flex-row justify-between items-center gap-2" }, ht = { class: "flex flex-row gap-2 items-center" }, Vt = { class: "relative group cursor-pointer" }, kt = { class: "flex flex-col gap-16 pt-[24px] overflow-scroll" }, $t = { class: "flex flex-row items-center justify-between gap-2" }, St = { class: "w-[25%]" }, Ct = { class: "flex flex-col gap-[16px]" }, Dt = { class: "flex flex-row items-center max-w-[100%] justify-between" }, Ft = { class: "flex-grow" }, Ut = { class: "flex flex-row items-center max-w-[100%] justify-between" }, Tt = { class: "flex flex-col gap-[16px]" }, It = { class: "flex flex-row items-center max-w-[100%] justify-between" }, Mt = { class: "flex-grow" }, Kt = { class: "flex flex-row items-center max-w-[100%] justify-between" }, At = { class: "flex-grow" }, Pt = { class: "flex flex-row items-center max-w-[100%] justify-between" }, Nt = { class: "flex-grow" }, Rt = { class: "flex flex-row items-center gap-x-16" }, Ot = {
|
|
306
306
|
key: 0,
|
|
307
307
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
|
|
308
308
|
}, Bt = {
|
|
@@ -340,18 +340,18 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
340
340
|
modelModifiers: {}
|
|
341
341
|
}),
|
|
342
342
|
emits: ["update:modelValue"],
|
|
343
|
-
setup(
|
|
344
|
-
const { t: o } = J(), e = X(
|
|
345
|
-
() => b.map((
|
|
343
|
+
setup(v) {
|
|
344
|
+
const { t: o } = J(), e = X(v, "modelValue"), s = ue(), V = _e(), h = de(), { promptLoader: _ } = he(), { promptMessage: C } = Ce(), { restaurants: b } = pe(), x = B(!1), m = Y(
|
|
345
|
+
() => b.map((f) => ({ label: f.name, value: f.id }))
|
|
346
346
|
), w = Y(() => {
|
|
347
|
-
var
|
|
348
|
-
return x.value ? "Connecting" : (i = (
|
|
347
|
+
var f, i;
|
|
348
|
+
return x.value ? "Connecting" : (i = (f = e.value) == null ? void 0 : f.platform) != null && i.accessToken ? "Disconnect" : "Connect";
|
|
349
349
|
}), k = B(0);
|
|
350
350
|
async function d() {
|
|
351
|
-
var
|
|
351
|
+
var f;
|
|
352
352
|
if (x.value)
|
|
353
353
|
s.open({ type: "error", message: "Connecting in progress" });
|
|
354
|
-
else if ((
|
|
354
|
+
else if ((f = e.value.platform) != null && f.accessToken)
|
|
355
355
|
await C({
|
|
356
356
|
message: o("report.integration.xero.confirmDisconnect", { name: e.value.name }),
|
|
357
357
|
title: o("report.integration.xero.disconnectTitle")
|
|
@@ -360,13 +360,13 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
360
360
|
try {
|
|
361
361
|
const i = await He(e.value._id);
|
|
362
362
|
x.value = !0;
|
|
363
|
-
const
|
|
364
|
-
var
|
|
363
|
+
const P = setInterval(async () => {
|
|
364
|
+
var A;
|
|
365
365
|
k.value += 1;
|
|
366
366
|
try {
|
|
367
367
|
await V.getSettings();
|
|
368
368
|
} finally {
|
|
369
|
-
(k.value === 12 || (
|
|
369
|
+
(k.value === 12 || (A = e.value.platform) != null && A.accessToken) && (x.value = !1, P && clearInterval(P), k.value = 0);
|
|
370
370
|
}
|
|
371
371
|
}, 5e3);
|
|
372
372
|
window.open(i.redirect, "_blank");
|
|
@@ -392,33 +392,33 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
392
392
|
await _(async () => {
|
|
393
393
|
try {
|
|
394
394
|
await ke(e.value._id, e.value), await V.getSettings();
|
|
395
|
-
} catch (
|
|
396
|
-
s.open({ type: "error", message:
|
|
395
|
+
} catch (f) {
|
|
396
|
+
s.open({ type: "error", message: f.message });
|
|
397
397
|
}
|
|
398
398
|
});
|
|
399
399
|
}
|
|
400
|
-
function
|
|
401
|
-
const i =
|
|
400
|
+
function g(f) {
|
|
401
|
+
const i = v.tenantOptions.data.find((P) => P.value === f);
|
|
402
402
|
i && e.value.platform && (e.value.platform.tenant = {
|
|
403
403
|
id: i.value,
|
|
404
404
|
name: i.label
|
|
405
405
|
});
|
|
406
406
|
}
|
|
407
|
-
function $(
|
|
408
|
-
var
|
|
409
|
-
(
|
|
407
|
+
function $(f, i) {
|
|
408
|
+
var P, A;
|
|
409
|
+
(A = (P = e.value.platform) == null ? void 0 : P.mappings) != null && A[f] && (e.value.platform.mappings[f] = e.value.platform.mappings[f].filter(
|
|
410
410
|
(Q, E) => E !== i
|
|
411
411
|
));
|
|
412
412
|
}
|
|
413
|
-
function
|
|
414
|
-
var i,
|
|
415
|
-
(
|
|
416
|
-
...e.value.platform.mappings[
|
|
417
|
-
|
|
413
|
+
function a(f) {
|
|
414
|
+
var i, P;
|
|
415
|
+
(P = (i = e.value.platform) == null ? void 0 : i.mappings) != null && P[f] && (e.value.platform.mappings[f] = [
|
|
416
|
+
...e.value.platform.mappings[f],
|
|
417
|
+
f === "items" ? {
|
|
418
418
|
feedmeKey: "",
|
|
419
419
|
xeroAccount: "",
|
|
420
420
|
name: ""
|
|
421
|
-
} :
|
|
421
|
+
} : f === "taxes" ? {
|
|
422
422
|
feedmeKey: "",
|
|
423
423
|
xeroAccount: ""
|
|
424
424
|
} : {
|
|
@@ -427,39 +427,39 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
427
427
|
}
|
|
428
428
|
]);
|
|
429
429
|
}
|
|
430
|
-
async function
|
|
430
|
+
async function l() {
|
|
431
431
|
await _(async () => {
|
|
432
432
|
try {
|
|
433
433
|
await $e(e.value._id), await V.getSettings();
|
|
434
|
-
} catch (
|
|
435
|
-
s.open({ type: "error", message:
|
|
434
|
+
} catch (f) {
|
|
435
|
+
s.open({ type: "error", message: f.message });
|
|
436
436
|
}
|
|
437
437
|
});
|
|
438
438
|
}
|
|
439
439
|
return be(async () => {
|
|
440
440
|
await V.getSettings();
|
|
441
|
-
}), (
|
|
442
|
-
var z, W, Z, ee, te, oe, ae, le, ne, se,
|
|
443
|
-
const
|
|
444
|
-
return (W = (z = e.value) == null ? void 0 : z.platform) != null && W.mappings ? (c(),
|
|
441
|
+
}), (f, i) => {
|
|
442
|
+
var z, W, Z, ee, te, oe, ae, le, ne, se, F, p, U, O, me, Te, Ie, Re, Oe, Be, je;
|
|
443
|
+
const P = S("FmIcon"), A = S("FmButton"), Q = S("FmMenuDivider"), E = S("FmCircularProgress"), G = S("FmSelect"), R = S("FmTextField"), j = S("FmSwitch");
|
|
444
|
+
return (W = (z = e.value) == null ? void 0 : z.platform) != null && W.mappings ? (c(), D("div", _t, [
|
|
445
445
|
t("div", bt, [
|
|
446
446
|
t("div", wt, [
|
|
447
447
|
i[10] || (i[10] = t("div", { class: "fm-typo-en-title-sm-800" }, "Connect", -1)),
|
|
448
448
|
t("div", ht, [
|
|
449
449
|
t("div", Vt, [
|
|
450
|
-
r(
|
|
450
|
+
r(P, {
|
|
451
451
|
name: "refresh",
|
|
452
452
|
class: "p-2 bg-gray-100 rounded-full",
|
|
453
|
-
onClick:
|
|
453
|
+
onClick: l
|
|
454
454
|
}),
|
|
455
455
|
i[9] || (i[9] = t("span", { class: "absolute left-1/2 -translate-x-2/3 top-full mt-2 w-max bg-gray-900 text-white text-sm px-2 py-1 rounded opacity-0 group-hover:opacity-100 transition-opacity" }, " Repopulate the fields based on the dates selected in Preview. ", -1))
|
|
456
456
|
]),
|
|
457
|
-
r(
|
|
457
|
+
r(A, {
|
|
458
458
|
variant: "tertiary",
|
|
459
459
|
label: "Delete",
|
|
460
460
|
onClick: y
|
|
461
461
|
}),
|
|
462
|
-
r(
|
|
462
|
+
r(A, {
|
|
463
463
|
variant: "primary",
|
|
464
464
|
label: "Update",
|
|
465
465
|
onClick: n
|
|
@@ -472,30 +472,30 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
472
472
|
i[21] || (i[21] = t("div", { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, " Authenticate with your official Xero account to enable FeedMe to securely upload data to Xero. ", -1)),
|
|
473
473
|
t("div", $t, [
|
|
474
474
|
t("div", St, [
|
|
475
|
-
r(
|
|
475
|
+
r(A, {
|
|
476
476
|
disabled: x.value,
|
|
477
477
|
variant: "primary",
|
|
478
478
|
label: w.value,
|
|
479
479
|
onClick: d
|
|
480
480
|
}, null, 8, ["disabled", "label"])
|
|
481
481
|
]),
|
|
482
|
-
!
|
|
482
|
+
!v.tenantOptions.isLoaded && ((Z = e.value.platform) != null && Z.accessToken) ? (c(), M(E, {
|
|
483
483
|
key: 0,
|
|
484
484
|
size: "xl"
|
|
485
485
|
})) : N("", !0),
|
|
486
486
|
r(G, {
|
|
487
487
|
class: "flex-grow",
|
|
488
|
-
items:
|
|
488
|
+
items: v.tenantOptions.data || [],
|
|
489
489
|
"model-value": (ee = e.value.platform.tenant) == null ? void 0 : ee.id,
|
|
490
|
-
placeholder:
|
|
491
|
-
"onUpdate:modelValue":
|
|
490
|
+
placeholder: v.tenantOptions.data ? "Select tenant " : (te = e.value.platform.tenant) == null ? void 0 : te.name,
|
|
491
|
+
"onUpdate:modelValue": g
|
|
492
492
|
}, null, 8, ["items", "model-value", "placeholder"])
|
|
493
493
|
]),
|
|
494
494
|
t("div", Ct, [
|
|
495
495
|
i[13] || (i[13] = t("div", { class: "flex flex-row items-center fm-typo-en-title-sm-800 h-[36px]" }, "General", -1)),
|
|
496
|
-
t("div",
|
|
496
|
+
t("div", Dt, [
|
|
497
497
|
i[11] || (i[11] = t("div", { class: "w-[25%]" }, "Name", -1)),
|
|
498
|
-
t("div",
|
|
498
|
+
t("div", Ft, [
|
|
499
499
|
r(R, {
|
|
500
500
|
modelValue: e.value.name,
|
|
501
501
|
"onUpdate:modelValue": i[0] || (i[0] = (ie) => e.value.name = ie)
|
|
@@ -558,19 +558,19 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
558
558
|
]),
|
|
559
559
|
t("div", Rt, [
|
|
560
560
|
i[17] || (i[17] = t("div", { class: "fm-typo-en-title-sm-800" }, "Taxes", -1)),
|
|
561
|
-
r(
|
|
561
|
+
r(A, {
|
|
562
562
|
variant: "primary",
|
|
563
563
|
icon: "add",
|
|
564
|
-
onClick: i[6] || (i[6] = () =>
|
|
564
|
+
onClick: i[6] || (i[6] = () => a("taxes"))
|
|
565
565
|
})
|
|
566
566
|
]),
|
|
567
|
-
|
|
568
|
-
!
|
|
567
|
+
v.taxOptions.isError || e.value.platform.accessToken == null ? (c(), D("div", Ot, " Error connecting xero. Please connect to your Xero account to view the setting options. ")) : N("", !0),
|
|
568
|
+
!v.taxOptions.isLoaded && ((ae = e.value.platform) != null && ae.accessToken) ? (c(), M(E, {
|
|
569
569
|
key: 1,
|
|
570
570
|
size: "xl"
|
|
571
571
|
})) : N("", !0),
|
|
572
|
-
((le =
|
|
573
|
-
(c(!0),
|
|
572
|
+
((le = v.taxOptions.data) == null ? void 0 : le.length) > 0 ? (c(), D("div", Bt, [
|
|
573
|
+
(c(!0), D(L, null, H((F = (se = (ne = e.value) == null ? void 0 : ne.platform) == null ? void 0 : se.mappings) == null ? void 0 : F.taxes, (ie, re) => (c(), M(Ke, {
|
|
574
574
|
key: `tax-${re}`,
|
|
575
575
|
modelValue: e.value.platform.mappings.taxes[re],
|
|
576
576
|
"onUpdate:modelValue": (Me) => e.value.platform.mappings.taxes[re] = Me,
|
|
@@ -579,7 +579,7 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
579
579
|
xeroAccount: {
|
|
580
580
|
placeholder: "Select Tax",
|
|
581
581
|
editable: !0,
|
|
582
|
-
dropdownOptions:
|
|
582
|
+
dropdownOptions: v.taxOptions.data ?? []
|
|
583
583
|
}
|
|
584
584
|
},
|
|
585
585
|
removable: !0,
|
|
@@ -588,19 +588,19 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
588
588
|
])) : N("", !0),
|
|
589
589
|
t("div", jt, [
|
|
590
590
|
i[18] || (i[18] = t("div", { class: "fm-typo-en-title-sm-800" }, "Items", -1)),
|
|
591
|
-
r(
|
|
591
|
+
r(A, {
|
|
592
592
|
variant: "primary",
|
|
593
593
|
icon: "add",
|
|
594
|
-
onClick: i[7] || (i[7] = () =>
|
|
594
|
+
onClick: i[7] || (i[7] = () => a("items"))
|
|
595
595
|
})
|
|
596
596
|
]),
|
|
597
|
-
|
|
598
|
-
!
|
|
597
|
+
v.accountCodeOptions.isError || e.value.platform.accessToken == null ? (c(), D("div", Lt, " Error connecting xero. Please connect to your Xero account to view the setting options. ")) : N("", !0),
|
|
598
|
+
!v.accountCodeOptions.isLoaded && ((p = e.value.platform) != null && p.accessToken) ? (c(), M(E, {
|
|
599
599
|
key: 4,
|
|
600
600
|
size: "xl"
|
|
601
601
|
})) : N("", !0),
|
|
602
|
-
((U =
|
|
603
|
-
(c(!0),
|
|
602
|
+
((U = v.accountCodeOptions.data) == null ? void 0 : U.length) > 0 ? (c(), D("div", Et, [
|
|
603
|
+
(c(!0), D(L, null, H((Te = (me = (O = e.value) == null ? void 0 : O.platform) == null ? void 0 : me.mappings) == null ? void 0 : Te.items, (ie, re) => (c(), M(Ke, {
|
|
604
604
|
key: `item-${re}`,
|
|
605
605
|
modelValue: e.value.platform.mappings.items[re],
|
|
606
606
|
"onUpdate:modelValue": (Me) => e.value.platform.mappings.items[re] = Me,
|
|
@@ -609,7 +609,7 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
609
609
|
xeroAccount: {
|
|
610
610
|
placeholder: "Select Item Code",
|
|
611
611
|
editable: !0,
|
|
612
|
-
dropdownOptions:
|
|
612
|
+
dropdownOptions: v.accountCodeOptions.data ?? []
|
|
613
613
|
}
|
|
614
614
|
},
|
|
615
615
|
removable: !0,
|
|
@@ -618,19 +618,19 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
618
618
|
])) : N("", !0),
|
|
619
619
|
t("div", zt, [
|
|
620
620
|
i[19] || (i[19] = t("div", { class: "fm-typo-en-title-sm-800" }, "Payments", -1)),
|
|
621
|
-
r(
|
|
621
|
+
r(A, {
|
|
622
622
|
variant: "primary",
|
|
623
623
|
icon: "add",
|
|
624
|
-
onClick: i[8] || (i[8] = () =>
|
|
624
|
+
onClick: i[8] || (i[8] = () => a("payments"))
|
|
625
625
|
})
|
|
626
626
|
]),
|
|
627
|
-
|
|
628
|
-
!
|
|
627
|
+
v.accountCodeOptions.isError || e.value.platform.accessToken == null ? (c(), D("div", Yt, " Error connecting xero. Please connect to your Xero account to view the setting options. ")) : N("", !0),
|
|
628
|
+
!v.accountCodeOptions.isLoaded && ((Ie = e.value.platform) != null && Ie.accessToken) ? (c(), M(E, {
|
|
629
629
|
key: 7,
|
|
630
630
|
size: "xl"
|
|
631
631
|
})) : N("", !0),
|
|
632
|
-
((Re =
|
|
633
|
-
(c(!0),
|
|
632
|
+
((Re = v.accountCodeOptions.data) == null ? void 0 : Re.length) > 0 ? (c(), D("div", qt, [
|
|
633
|
+
(c(!0), D(L, null, H((je = (Be = (Oe = e.value) == null ? void 0 : Oe.platform) == null ? void 0 : Be.mappings) == null ? void 0 : je.payments, (ie, re) => (c(), M(Ke, {
|
|
634
634
|
key: `payment-${re}`,
|
|
635
635
|
modelValue: e.value.platform.mappings.payments[re],
|
|
636
636
|
"onUpdate:modelValue": (Me) => e.value.platform.mappings.payments[re] = Me,
|
|
@@ -639,7 +639,7 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
639
639
|
xeroAccount: {
|
|
640
640
|
placeholder: "Select Payment Code",
|
|
641
641
|
editable: !0,
|
|
642
|
-
dropdownOptions:
|
|
642
|
+
dropdownOptions: v.accountCodeOptions.data ?? []
|
|
643
643
|
}
|
|
644
644
|
},
|
|
645
645
|
removable: !0,
|
|
@@ -661,7 +661,7 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
661
661
|
modelModifiers: {}
|
|
662
662
|
},
|
|
663
663
|
emits: ["update:modelValue"],
|
|
664
|
-
setup(
|
|
664
|
+
setup(v) {
|
|
665
665
|
const o = B([]), { t: e } = J(), s = Y(
|
|
666
666
|
() => o.value.reduce((m, w) => {
|
|
667
667
|
const k = m.length, { invoice: d, payments: y } = w;
|
|
@@ -672,9 +672,9 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
672
672
|
ref: d.Reference
|
|
673
673
|
};
|
|
674
674
|
for (let n = 0; n < Math.max(d.LineItems.length, y.length); n++) {
|
|
675
|
-
const
|
|
676
|
-
m[
|
|
677
|
-
...m[
|
|
675
|
+
const g = k + n;
|
|
676
|
+
m[g] || (m[g] = {}), d.LineItems[n] && (m[g] = {
|
|
677
|
+
...m[g],
|
|
678
678
|
itemDescription: d.LineItems[n].Description,
|
|
679
679
|
itemQuantity: d.LineItems[n].Quantity,
|
|
680
680
|
itemUnitAmount: d.LineItems[n].UnitAmount,
|
|
@@ -684,8 +684,8 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
684
684
|
itemTaxType: d.LineItems[n].TaxType,
|
|
685
685
|
itemAmount: d.LineItems[n].LineAmount,
|
|
686
686
|
itemDiscount: d.LineItems[n].DiscountAmount
|
|
687
|
-
}), y[n] && (m[
|
|
688
|
-
...m[
|
|
687
|
+
}), y[n] && (m[g] = {
|
|
688
|
+
...m[g],
|
|
689
689
|
paymentAccount: y[n].Account.Code,
|
|
690
690
|
paymentReference: y[n].Reference,
|
|
691
691
|
paymentAmount: y[n].Amount
|
|
@@ -769,7 +769,7 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
769
769
|
header: "Payment Amount",
|
|
770
770
|
enableSorting: !1
|
|
771
771
|
}
|
|
772
|
-
], h = X(
|
|
772
|
+
], h = X(v, "modelValue"), _ = B(!1), C = ue(), { dateRange: b } = De(pe());
|
|
773
773
|
ve(
|
|
774
774
|
() => b.value,
|
|
775
775
|
async () => {
|
|
@@ -797,10 +797,10 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
797
797
|
}
|
|
798
798
|
return (m, w) => {
|
|
799
799
|
const k = S("FmButton"), d = S("FmCircularProgress"), y = S("FmTable");
|
|
800
|
-
return c(),
|
|
800
|
+
return c(), D("div", Xt, [
|
|
801
801
|
t("div", Qt, [
|
|
802
|
-
r(
|
|
803
|
-
"date-range":
|
|
802
|
+
r(Fe, {
|
|
803
|
+
"date-range": u(b),
|
|
804
804
|
"onUpdate:dateRange": w[0] || (w[0] = (n) => we(b) ? b.value = n : null),
|
|
805
805
|
compare: !1
|
|
806
806
|
}, null, 8, ["date-range"]),
|
|
@@ -811,9 +811,9 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
811
811
|
onClick: x
|
|
812
812
|
}, null, 8, ["loading"])
|
|
813
813
|
]),
|
|
814
|
-
_.value ? (c(),
|
|
814
|
+
_.value ? (c(), D("div", Gt, [
|
|
815
815
|
r(d, { size: "xl" }),
|
|
816
|
-
t("span", Jt, T(
|
|
816
|
+
t("span", Jt, T(u(e)("report.common.isLoading")), 1)
|
|
817
817
|
])) : s.value.length > 0 ? (c(), M(y, {
|
|
818
818
|
key: 1,
|
|
819
819
|
class: "flex overflow-scroll",
|
|
@@ -830,8 +830,8 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
830
830
|
modelModifiers: {}
|
|
831
831
|
},
|
|
832
832
|
emits: ["update:modelValue"],
|
|
833
|
-
setup(
|
|
834
|
-
const { t: o } = J(), e = X(
|
|
833
|
+
setup(v) {
|
|
834
|
+
const { t: o } = J(), e = X(v, "modelValue"), s = B("setting"), V = B({}), h = B({}), _ = B({}), C = [
|
|
835
835
|
{
|
|
836
836
|
label: o("report.integration.setting"),
|
|
837
837
|
value: "setting",
|
|
@@ -911,30 +911,30 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
911
911
|
},
|
|
912
912
|
{ immediate: !0 }
|
|
913
913
|
), (d, y) => {
|
|
914
|
-
var $,
|
|
915
|
-
const n = S("FmPageHead"),
|
|
916
|
-
return c(),
|
|
914
|
+
var $, a, l;
|
|
915
|
+
const n = S("FmPageHead"), g = S("FmTabs");
|
|
916
|
+
return c(), D("div", Zt, [
|
|
917
917
|
r(n, {
|
|
918
918
|
title: (($ = e.value) == null ? void 0 : $.name) || "Xero",
|
|
919
919
|
"back-button": !0,
|
|
920
920
|
style: { paddingLeft: "0px", paddingRight: "0px" },
|
|
921
|
-
"onClick:back":
|
|
921
|
+
"onClick:back": u(b).back
|
|
922
922
|
}, {
|
|
923
923
|
description: ge(() => y[2] || (y[2] = [
|
|
924
924
|
t("div", null, null, -1)
|
|
925
925
|
])),
|
|
926
926
|
_: 1
|
|
927
927
|
}, 8, ["title", "onClick:back"]),
|
|
928
|
-
r(
|
|
928
|
+
r(g, {
|
|
929
929
|
"model-value": s.value,
|
|
930
|
-
"onUpdate:modelValue": y[0] || (y[0] = (
|
|
930
|
+
"onUpdate:modelValue": y[0] || (y[0] = (f) => s.value = f),
|
|
931
931
|
items: C
|
|
932
932
|
}, null, 8, ["model-value"]),
|
|
933
933
|
t("div", eo, [
|
|
934
|
-
(c(), M(xe((
|
|
934
|
+
(c(), M(xe((a = x.value) == null ? void 0 : a.component), Ee({
|
|
935
935
|
modelValue: e.value,
|
|
936
|
-
"onUpdate:modelValue": y[1] || (y[1] = (
|
|
937
|
-
}, (
|
|
936
|
+
"onUpdate:modelValue": y[1] || (y[1] = (f) => e.value = f)
|
|
937
|
+
}, (l = x.value) == null ? void 0 : l.props), null, 16, ["modelValue"]))
|
|
938
938
|
])
|
|
939
939
|
]);
|
|
940
940
|
};
|
|
@@ -942,16 +942,16 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
942
942
|
}), oo = {
|
|
943
943
|
key: 0,
|
|
944
944
|
class: "flex flex-col h-full"
|
|
945
|
-
}, ao = { class: "flex flex-col gap-16 pb-[24px]" }, lo = { class: "flex flex-row justify-between items-center gap-2" }, no = { class: "fm-typo-en-title-sm-800" }, so = { class: "flex flex-row gap-2 items-center" }, io = { class: "relative group cursor-pointer" }, ro = { class: "absolute left-1/2 -translate-x-2/3 top-full mt-2 w-max bg-gray-900 text-white text-sm px-2 py-1 rounded opacity-0 group-hover:opacity-100 transition-opacity" }, mo = { class: "flex flex-col gap-24 pt-[24px] overflow-scroll" }, co = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, po = { class: "flex flex-row items-center justify-between" }, uo = { class: "w-[25%]" }, fo = { class: "flex-grow" }, vo = { class: "flex flex-row items-center justify-between" }, go = { class: "w-[25%]" }, yo = { class: "flex-grow" }, xo = { class: "flex flex-col gap-16" }, _o = { class: "fm-typo-en-title-sm-800" }, bo = { class: "flex flex-row items-center max-w-[100%]" }, wo = { class: "w-[25%]" }, ho = { class: "flex-grow" }, Vo = { class: "flex flex-row items-center max-w-[100%]" }, ko = { class: "w-[25%]" }, $o = { class: "flex flex-row items-center max-w-[100%]" }, So = { class: "w-[25%]" }, Co = { class: "flex flex-col gap-16" },
|
|
945
|
+
}, ao = { class: "flex flex-col gap-16 pb-[24px]" }, lo = { class: "flex flex-row justify-between items-center gap-2" }, no = { class: "fm-typo-en-title-sm-800" }, so = { class: "flex flex-row gap-2 items-center" }, io = { class: "relative group cursor-pointer" }, ro = { class: "absolute left-1/2 -translate-x-2/3 top-full mt-2 w-max bg-gray-900 text-white text-sm px-2 py-1 rounded opacity-0 group-hover:opacity-100 transition-opacity" }, mo = { class: "flex flex-col gap-24 pt-[24px] overflow-scroll" }, co = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, po = { class: "flex flex-row items-center justify-between" }, uo = { class: "w-[25%]" }, fo = { class: "flex-grow" }, vo = { class: "flex flex-row items-center justify-between" }, go = { class: "w-[25%]" }, yo = { class: "flex-grow" }, xo = { class: "flex flex-col gap-16" }, _o = { class: "fm-typo-en-title-sm-800" }, bo = { class: "flex flex-row items-center max-w-[100%]" }, wo = { class: "w-[25%]" }, ho = { class: "flex-grow" }, Vo = { class: "flex flex-row items-center max-w-[100%]" }, ko = { class: "w-[25%]" }, $o = { class: "flex flex-row items-center max-w-[100%]" }, So = { class: "w-[25%]" }, Co = { class: "flex flex-col gap-16" }, Do = { class: "xs:grid-cols-1 grid-cols-2 grid gap-16" }, Fo = { class: "flex flex-row items-center gap-x-16" }, Uo = { class: "fm-typo-en-title-sm-800" }, To = { class: "xs:grid-cols-1 grid-cols-2 grid gap-16" }, Io = { class: "flex flex-row items-center gap-x-16" }, Mo = { class: "fm-typo-en-title-sm-800" }, Ko = { class: "xs:grid-cols-1 grid-cols-2 grid gap-16" }, Ao = { class: "flex flex-row items-center gap-x-16" }, Po = { class: "fm-typo-en-title-sm-800" }, No = /* @__PURE__ */ q({
|
|
946
946
|
__name: "Setting",
|
|
947
947
|
props: {
|
|
948
948
|
modelValue: { required: !0 },
|
|
949
949
|
modelModifiers: {}
|
|
950
950
|
},
|
|
951
951
|
emits: ["update:modelValue"],
|
|
952
|
-
setup(
|
|
953
|
-
const o = X(
|
|
954
|
-
() => C.map((
|
|
952
|
+
setup(v) {
|
|
953
|
+
const o = X(v, "modelValue"), e = ue(), s = _e(), V = de(), { promptLoader: h } = he(), { promptMessage: _ } = Ce(), { restaurants: C } = pe(), b = Y(
|
|
954
|
+
() => C.map((a) => ({ label: a.name, value: a.id }))
|
|
955
955
|
), { t: x } = J();
|
|
956
956
|
async function m() {
|
|
957
957
|
await _({
|
|
@@ -960,8 +960,8 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
960
960
|
}) && await h(async () => {
|
|
961
961
|
try {
|
|
962
962
|
await Ve(o.value._id), await s.getSettings(), V.back();
|
|
963
|
-
} catch (
|
|
964
|
-
e.open({ type: "error", message:
|
|
963
|
+
} catch (l) {
|
|
964
|
+
e.open({ type: "error", message: l.message });
|
|
965
965
|
}
|
|
966
966
|
});
|
|
967
967
|
}
|
|
@@ -969,22 +969,22 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
969
969
|
await h(async () => {
|
|
970
970
|
try {
|
|
971
971
|
await ke(o.value._id, o.value), await s.getSettings();
|
|
972
|
-
} catch (
|
|
973
|
-
e.open({ type: "error", message:
|
|
972
|
+
} catch (a) {
|
|
973
|
+
e.open({ type: "error", message: a.message });
|
|
974
974
|
}
|
|
975
975
|
});
|
|
976
976
|
}
|
|
977
|
-
function k(
|
|
978
|
-
var
|
|
979
|
-
(i = (
|
|
980
|
-
(
|
|
977
|
+
function k(a, l) {
|
|
978
|
+
var f, i;
|
|
979
|
+
(i = (f = o.value.platform) == null ? void 0 : f.mappings) != null && i[a] && (o.value.platform.mappings[a] = o.value.platform.mappings[a].filter(
|
|
980
|
+
(P, A) => A !== l
|
|
981
981
|
));
|
|
982
982
|
}
|
|
983
|
-
function d(
|
|
984
|
-
var
|
|
985
|
-
if ((
|
|
983
|
+
function d(a) {
|
|
984
|
+
var l, f;
|
|
985
|
+
if ((f = (l = o.value.platform) == null ? void 0 : l.mappings) != null && f[a]) {
|
|
986
986
|
let i;
|
|
987
|
-
switch (
|
|
987
|
+
switch (a) {
|
|
988
988
|
case "items":
|
|
989
989
|
i = {
|
|
990
990
|
key: "",
|
|
@@ -1007,8 +1007,8 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1007
1007
|
};
|
|
1008
1008
|
break;
|
|
1009
1009
|
}
|
|
1010
|
-
o.value.platform.mappings[
|
|
1011
|
-
...o.value.platform.mappings[
|
|
1010
|
+
o.value.platform.mappings[a] = [
|
|
1011
|
+
...o.value.platform.mappings[a],
|
|
1012
1012
|
i
|
|
1013
1013
|
];
|
|
1014
1014
|
}
|
|
@@ -1032,97 +1032,97 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1032
1032
|
}
|
|
1033
1033
|
];
|
|
1034
1034
|
function n({
|
|
1035
|
-
key:
|
|
1036
|
-
value:
|
|
1035
|
+
key: a,
|
|
1036
|
+
value: l
|
|
1037
1037
|
}) {
|
|
1038
|
-
var
|
|
1039
|
-
(i = (
|
|
1038
|
+
var f, i;
|
|
1039
|
+
(i = (f = o.value) == null ? void 0 : f.platform) != null && i.mappings && (o.value.platform.mappings[a] = l);
|
|
1040
1040
|
}
|
|
1041
|
-
function
|
|
1041
|
+
function g(a) {
|
|
1042
1042
|
return {
|
|
1043
|
-
key: { placeholder:
|
|
1044
|
-
account: { placeholder:
|
|
1043
|
+
key: { placeholder: a, editable: !1 },
|
|
1044
|
+
account: { placeholder: a, editable: !0 }
|
|
1045
1045
|
};
|
|
1046
1046
|
}
|
|
1047
1047
|
async function $() {
|
|
1048
1048
|
await h(async () => {
|
|
1049
1049
|
try {
|
|
1050
1050
|
await $e(o.value._id), await s.getSettings();
|
|
1051
|
-
} catch (
|
|
1052
|
-
e.open({ type: "error", message:
|
|
1051
|
+
} catch (a) {
|
|
1052
|
+
e.open({ type: "error", message: a.message });
|
|
1053
1053
|
}
|
|
1054
1054
|
});
|
|
1055
1055
|
}
|
|
1056
1056
|
return be(async () => {
|
|
1057
1057
|
await s.getSettings();
|
|
1058
|
-
}), (
|
|
1059
|
-
var E, G, R, j, z, W, Z, ee, te, oe, ae, le, ne, se,
|
|
1060
|
-
const
|
|
1061
|
-
return (G = (E = o.value) == null ? void 0 : E.platform) != null && G.mappings ? (c(),
|
|
1058
|
+
}), (a, l) => {
|
|
1059
|
+
var E, G, R, j, z, W, Z, ee, te, oe, ae, le, ne, se, F;
|
|
1060
|
+
const f = S("FmIcon"), i = S("FmButton"), P = S("FmMenuDivider"), A = S("FmTextField"), Q = S("FmSelect");
|
|
1061
|
+
return (G = (E = o.value) == null ? void 0 : E.platform) != null && G.mappings ? (c(), D("div", oo, [
|
|
1062
1062
|
t("div", ao, [
|
|
1063
1063
|
t("div", lo, [
|
|
1064
|
-
t("div", no, T(
|
|
1064
|
+
t("div", no, T(u(x)("report.integration.bukku.connect")), 1),
|
|
1065
1065
|
t("div", so, [
|
|
1066
1066
|
t("div", io, [
|
|
1067
|
-
r(
|
|
1067
|
+
r(f, {
|
|
1068
1068
|
name: "refresh",
|
|
1069
1069
|
class: "p-2 bg-gray-100 rounded-full",
|
|
1070
1070
|
onClick: $
|
|
1071
1071
|
}),
|
|
1072
|
-
t("span", ro, T(
|
|
1072
|
+
t("span", ro, T(u(x)("report.integration.refreshSetting")), 1)
|
|
1073
1073
|
]),
|
|
1074
1074
|
r(i, {
|
|
1075
1075
|
variant: "tertiary",
|
|
1076
|
-
label:
|
|
1076
|
+
label: u(x)("report.common.delete"),
|
|
1077
1077
|
onClick: m
|
|
1078
1078
|
}, null, 8, ["label"]),
|
|
1079
1079
|
r(i, {
|
|
1080
1080
|
variant: "primary",
|
|
1081
|
-
label:
|
|
1081
|
+
label: u(x)("report.common.update"),
|
|
1082
1082
|
onClick: w
|
|
1083
1083
|
}, null, 8, ["label"])
|
|
1084
1084
|
])
|
|
1085
1085
|
])
|
|
1086
1086
|
]),
|
|
1087
|
-
r(
|
|
1087
|
+
r(P, { style: { margin: 0 } }),
|
|
1088
1088
|
t("div", mo, [
|
|
1089
|
-
t("div", co, T(
|
|
1089
|
+
t("div", co, T(u(x)("report.integration.bukku.authentication")), 1),
|
|
1090
1090
|
t("div", po, [
|
|
1091
|
-
t("div", uo, T(
|
|
1091
|
+
t("div", uo, T(u(x)("report.integration.subdomain")), 1),
|
|
1092
1092
|
t("div", fo, [
|
|
1093
|
-
r(
|
|
1093
|
+
r(A, {
|
|
1094
1094
|
modelValue: o.value.platform.subdomain,
|
|
1095
|
-
"onUpdate:modelValue":
|
|
1096
|
-
placeholder:
|
|
1095
|
+
"onUpdate:modelValue": l[0] || (l[0] = (p) => o.value.platform.subdomain = p),
|
|
1096
|
+
placeholder: u(x)("report.integration.subdomain")
|
|
1097
1097
|
}, null, 8, ["modelValue", "placeholder"])
|
|
1098
1098
|
])
|
|
1099
1099
|
]),
|
|
1100
1100
|
t("div", vo, [
|
|
1101
|
-
t("div", go, T(
|
|
1101
|
+
t("div", go, T(u(x)("report.integration.token")), 1),
|
|
1102
1102
|
t("div", yo, [
|
|
1103
|
-
r(
|
|
1103
|
+
r(A, {
|
|
1104
1104
|
modelValue: o.value.platform.token,
|
|
1105
|
-
"onUpdate:modelValue":
|
|
1106
|
-
placeholder:
|
|
1105
|
+
"onUpdate:modelValue": l[1] || (l[1] = (p) => o.value.platform.token = p),
|
|
1106
|
+
placeholder: u(x)("report.integration.token")
|
|
1107
1107
|
}, null, 8, ["modelValue", "placeholder"])
|
|
1108
1108
|
])
|
|
1109
1109
|
]),
|
|
1110
1110
|
t("div", xo, [
|
|
1111
|
-
t("div", _o, T(
|
|
1111
|
+
t("div", _o, T(u(x)("report.integration.general")), 1),
|
|
1112
1112
|
t("div", bo, [
|
|
1113
|
-
t("div", wo, T(
|
|
1113
|
+
t("div", wo, T(u(x)("report.common.name")), 1),
|
|
1114
1114
|
t("div", ho, [
|
|
1115
|
-
r(
|
|
1115
|
+
r(A, {
|
|
1116
1116
|
modelValue: o.value.name,
|
|
1117
|
-
"onUpdate:modelValue":
|
|
1117
|
+
"onUpdate:modelValue": l[2] || (l[2] = (p) => o.value.name = p)
|
|
1118
1118
|
}, null, 8, ["modelValue"])
|
|
1119
1119
|
])
|
|
1120
1120
|
]),
|
|
1121
1121
|
t("div", Vo, [
|
|
1122
|
-
t("div", ko, T(
|
|
1122
|
+
t("div", ko, T(u(x)("report.common.location")), 1),
|
|
1123
1123
|
r(Q, {
|
|
1124
1124
|
modelValue: o.value.platform.locationIds,
|
|
1125
|
-
"onUpdate:modelValue":
|
|
1125
|
+
"onUpdate:modelValue": l[3] || (l[3] = (p) => o.value.platform.locationIds = p),
|
|
1126
1126
|
multiselect: !0,
|
|
1127
1127
|
items: b.value,
|
|
1128
1128
|
placeholder: "Select location",
|
|
@@ -1130,10 +1130,10 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1130
1130
|
}, null, 8, ["modelValue", "items"])
|
|
1131
1131
|
]),
|
|
1132
1132
|
t("div", $o, [
|
|
1133
|
-
t("div", So, T(
|
|
1133
|
+
t("div", So, T(u(x)("report.integration.grouping.title")), 1),
|
|
1134
1134
|
r(Q, {
|
|
1135
1135
|
modelValue: o.value.platform.grouping,
|
|
1136
|
-
"onUpdate:modelValue":
|
|
1136
|
+
"onUpdate:modelValue": l[4] || (l[4] = (p) => o.value.platform.grouping = p),
|
|
1137
1137
|
multiselect: !1,
|
|
1138
1138
|
items: y,
|
|
1139
1139
|
placeholder: "Select grouping",
|
|
@@ -1142,7 +1142,7 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1142
1142
|
])
|
|
1143
1143
|
]),
|
|
1144
1144
|
t("div", Co, [
|
|
1145
|
-
t("div",
|
|
1145
|
+
t("div", Do, [
|
|
1146
1146
|
r(K, {
|
|
1147
1147
|
"model-value": {
|
|
1148
1148
|
key: "Contact",
|
|
@@ -1158,9 +1158,9 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1158
1158
|
editable: !0
|
|
1159
1159
|
}
|
|
1160
1160
|
},
|
|
1161
|
-
"onUpdate:modelValue":
|
|
1161
|
+
"onUpdate:modelValue": l[5] || (l[5] = (p) => {
|
|
1162
1162
|
var U, O, me;
|
|
1163
|
-
(me = (O = (U = o.value) == null ? void 0 : U.platform) == null ? void 0 : O.mappings) != null && me.contact && (o.value.platform.mappings.contact.account =
|
|
1163
|
+
(me = (O = (U = o.value) == null ? void 0 : U.platform) == null ? void 0 : O.mappings) != null && me.contact && (o.value.platform.mappings.contact.account = p.account);
|
|
1164
1164
|
})
|
|
1165
1165
|
}, null, 8, ["model-value"]),
|
|
1166
1166
|
r(K, {
|
|
@@ -1168,45 +1168,45 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1168
1168
|
key: "Invoice no",
|
|
1169
1169
|
account: o.value.platform.mappings.invoiceDocNo
|
|
1170
1170
|
},
|
|
1171
|
-
options:
|
|
1172
|
-
"onUpdate:modelValue":
|
|
1171
|
+
options: g("Invoice no"),
|
|
1172
|
+
"onUpdate:modelValue": l[6] || (l[6] = (p) => n({ key: "invoiceDocNo", value: p.account }))
|
|
1173
1173
|
}, null, 8, ["model-value", "options"]),
|
|
1174
1174
|
r(K, {
|
|
1175
1175
|
"model-value": {
|
|
1176
1176
|
key: "Credit note no",
|
|
1177
1177
|
account: o.value.platform.mappings.creditNoteDocNo
|
|
1178
1178
|
},
|
|
1179
|
-
options:
|
|
1180
|
-
"onUpdate:modelValue":
|
|
1179
|
+
options: g("Credit note no"),
|
|
1180
|
+
"onUpdate:modelValue": l[7] || (l[7] = (p) => n({ key: "creditNoteDocNo", value: p.account }))
|
|
1181
1181
|
}, null, 8, ["model-value", "options"]),
|
|
1182
1182
|
r(K, {
|
|
1183
1183
|
"model-value": {
|
|
1184
1184
|
key: "Payment no",
|
|
1185
1185
|
account: o.value.platform.mappings.paymentDocNo
|
|
1186
1186
|
},
|
|
1187
|
-
options:
|
|
1188
|
-
"onUpdate:modelValue":
|
|
1187
|
+
options: g("Payment no"),
|
|
1188
|
+
"onUpdate:modelValue": l[8] || (l[8] = (p) => n({ key: "paymentDocNo", value: p.account }))
|
|
1189
1189
|
}, null, 8, ["model-value", "options"]),
|
|
1190
1190
|
r(K, {
|
|
1191
1191
|
"model-value": {
|
|
1192
1192
|
key: "Refund no",
|
|
1193
1193
|
account: o.value.platform.mappings.refundDocNo
|
|
1194
1194
|
},
|
|
1195
|
-
options:
|
|
1196
|
-
"onUpdate:modelValue":
|
|
1195
|
+
options: g("Refund no"),
|
|
1196
|
+
"onUpdate:modelValue": l[9] || (l[9] = (p) => n({ key: "refundDocNo", value: p.account }))
|
|
1197
1197
|
}, null, 8, ["model-value", "options"]),
|
|
1198
1198
|
r(K, {
|
|
1199
1199
|
"model-value": {
|
|
1200
1200
|
key: "Rounding",
|
|
1201
1201
|
account: o.value.platform.mappings.rounding.account
|
|
1202
1202
|
},
|
|
1203
|
-
options:
|
|
1204
|
-
"onUpdate:modelValue":
|
|
1203
|
+
options: g("Rounding"),
|
|
1204
|
+
"onUpdate:modelValue": l[10] || (l[10] = (p) => {
|
|
1205
1205
|
var U, O, me;
|
|
1206
|
-
(me = (O = (U = o.value) == null ? void 0 : U.platform) == null ? void 0 : O.mappings) != null && me.rounding && (o.value.platform.mappings.rounding.account =
|
|
1206
|
+
(me = (O = (U = o.value) == null ? void 0 : U.platform) == null ? void 0 : O.mappings) != null && me.rounding && (o.value.platform.mappings.rounding.account = p.account);
|
|
1207
1207
|
})
|
|
1208
1208
|
}, null, 8, ["model-value", "options"]),
|
|
1209
|
-
(c(!0),
|
|
1209
|
+
(c(!0), D(L, null, H((z = (j = (R = o.value) == null ? void 0 : R.platform) == null ? void 0 : j.mappings) == null ? void 0 : z.charges, (p, U) => (c(), M(K, {
|
|
1210
1210
|
key: `charge-${U}`,
|
|
1211
1211
|
modelValue: o.value.platform.mappings.charges[U],
|
|
1212
1212
|
"onUpdate:modelValue": (O) => o.value.platform.mappings.charges[U] = O,
|
|
@@ -1225,20 +1225,20 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1225
1225
|
]),
|
|
1226
1226
|
r(Ue, {
|
|
1227
1227
|
modelValue: o.value.platform,
|
|
1228
|
-
"onUpdate:modelValue":
|
|
1228
|
+
"onUpdate:modelValue": l[11] || (l[11] = (p) => o.value.platform = p),
|
|
1229
1229
|
label: "upload",
|
|
1230
1230
|
"last-upload-date": (W = o.value.platform) == null ? void 0 : W.lastUploadDate
|
|
1231
1231
|
}, null, 8, ["modelValue", "last-upload-date"]),
|
|
1232
|
-
t("div",
|
|
1233
|
-
t("div", Uo, T(
|
|
1232
|
+
t("div", Fo, [
|
|
1233
|
+
t("div", Uo, T(u(x)("report.integration.items")), 1),
|
|
1234
1234
|
r(i, {
|
|
1235
1235
|
variant: "primary",
|
|
1236
1236
|
icon: "add",
|
|
1237
|
-
onClick:
|
|
1237
|
+
onClick: l[12] || (l[12] = () => d("items"))
|
|
1238
1238
|
})
|
|
1239
1239
|
]),
|
|
1240
1240
|
t("div", To, [
|
|
1241
|
-
(c(!0),
|
|
1241
|
+
(c(!0), D(L, null, H((te = (ee = (Z = o.value) == null ? void 0 : Z.platform) == null ? void 0 : ee.mappings) == null ? void 0 : te.items, (p, U) => (c(), M(K, {
|
|
1242
1242
|
key: `item-${U}`,
|
|
1243
1243
|
modelValue: o.value.platform.mappings.items[U],
|
|
1244
1244
|
"onUpdate:modelValue": (O) => o.value.platform.mappings.items[U] = O,
|
|
@@ -1251,15 +1251,15 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1251
1251
|
}, null, 8, ["modelValue", "onUpdate:modelValue", "onRemove"]))), 128))
|
|
1252
1252
|
]),
|
|
1253
1253
|
t("div", Io, [
|
|
1254
|
-
t("div", Mo, T(
|
|
1254
|
+
t("div", Mo, T(u(x)("report.integration.taxes")), 1),
|
|
1255
1255
|
r(i, {
|
|
1256
1256
|
variant: "primary",
|
|
1257
1257
|
icon: "add",
|
|
1258
|
-
onClick:
|
|
1258
|
+
onClick: l[13] || (l[13] = () => d("taxes"))
|
|
1259
1259
|
})
|
|
1260
1260
|
]),
|
|
1261
1261
|
t("div", Ko, [
|
|
1262
|
-
(c(!0),
|
|
1262
|
+
(c(!0), D(L, null, H((le = (ae = (oe = o.value) == null ? void 0 : oe.platform) == null ? void 0 : ae.mappings) == null ? void 0 : le.taxes, (p, U) => (c(), M(K, {
|
|
1263
1263
|
key: `tax-${U}`,
|
|
1264
1264
|
modelValue: o.value.platform.mappings.taxes[U],
|
|
1265
1265
|
"onUpdate:modelValue": (O) => o.value.platform.mappings.taxes[U] = O,
|
|
@@ -1272,14 +1272,14 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1272
1272
|
}, null, 8, ["modelValue", "onUpdate:modelValue", "onRemove"]))), 128))
|
|
1273
1273
|
]),
|
|
1274
1274
|
t("div", Ao, [
|
|
1275
|
-
t("div", Po, T(
|
|
1275
|
+
t("div", Po, T(u(x)("report.integration.payments")), 1),
|
|
1276
1276
|
r(i, {
|
|
1277
1277
|
variant: "primary",
|
|
1278
1278
|
icon: "add",
|
|
1279
|
-
onClick:
|
|
1279
|
+
onClick: l[14] || (l[14] = () => d("payments"))
|
|
1280
1280
|
})
|
|
1281
1281
|
]),
|
|
1282
|
-
(c(!0),
|
|
1282
|
+
(c(!0), D(L, null, H((F = (se = (ne = o.value) == null ? void 0 : ne.platform) == null ? void 0 : se.mappings) == null ? void 0 : F.payments, (p, U) => (c(), D("div", {
|
|
1283
1283
|
key: `payment-${U}`,
|
|
1284
1284
|
class: "grid-cols-1 grid gap-x-16"
|
|
1285
1285
|
}, [
|
|
@@ -1309,7 +1309,7 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1309
1309
|
modelModifiers: {}
|
|
1310
1310
|
},
|
|
1311
1311
|
emits: ["update:modelValue"],
|
|
1312
|
-
setup(
|
|
1312
|
+
setup(v) {
|
|
1313
1313
|
const o = B([]), e = Y(
|
|
1314
1314
|
() => o.value.reduce((m, w) => {
|
|
1315
1315
|
const k = m.length, { invoice: d, payments: y } = w;
|
|
@@ -1321,11 +1321,11 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1321
1321
|
title: d.title
|
|
1322
1322
|
};
|
|
1323
1323
|
for (let n = 0; n < Math.max(d.form_items.length, y.length); n++) {
|
|
1324
|
-
const
|
|
1325
|
-
m[
|
|
1324
|
+
const g = k + n;
|
|
1325
|
+
m[g] || (m[g] = {});
|
|
1326
1326
|
const $ = d.form_items[n];
|
|
1327
|
-
$ && (m[
|
|
1328
|
-
...m[
|
|
1327
|
+
$ && (m[g] = {
|
|
1328
|
+
...m[g],
|
|
1329
1329
|
itemDescription: $.description,
|
|
1330
1330
|
itemQuantity: $.quantity,
|
|
1331
1331
|
itemUnitPrice: $.unit_price,
|
|
@@ -1333,15 +1333,15 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1333
1333
|
itemTaxCode: $._tax_code_name,
|
|
1334
1334
|
itemDiscount: $.discount
|
|
1335
1335
|
});
|
|
1336
|
-
const
|
|
1337
|
-
|
|
1338
|
-
...m[
|
|
1339
|
-
paymentNo:
|
|
1340
|
-
paymentMethod:
|
|
1341
|
-
paymentAccount:
|
|
1342
|
-
paymentDescription:
|
|
1343
|
-
paymentAmount:
|
|
1344
|
-
paymentSkip:
|
|
1336
|
+
const a = y[n];
|
|
1337
|
+
a && (m[g] = {
|
|
1338
|
+
...m[g],
|
|
1339
|
+
paymentNo: a.number,
|
|
1340
|
+
paymentMethod: a.deposit_items[0]._payment_method_name,
|
|
1341
|
+
paymentAccount: a.deposit_items[0]._account_name,
|
|
1342
|
+
paymentDescription: a.description,
|
|
1343
|
+
paymentAmount: a.amount,
|
|
1344
|
+
paymentSkip: a.skip
|
|
1345
1345
|
});
|
|
1346
1346
|
}
|
|
1347
1347
|
return m;
|
|
@@ -1436,7 +1436,7 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1436
1436
|
header: "Skip",
|
|
1437
1437
|
enableSorting: !1
|
|
1438
1438
|
}
|
|
1439
|
-
], h = X(
|
|
1439
|
+
], h = X(v, "modelValue"), _ = B(!1), C = ue(), { dateRange: b } = De(pe());
|
|
1440
1440
|
ve(
|
|
1441
1441
|
() => b.value,
|
|
1442
1442
|
async () => {
|
|
@@ -1464,23 +1464,23 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1464
1464
|
}
|
|
1465
1465
|
return (m, w) => {
|
|
1466
1466
|
const k = S("FmButton"), d = S("FmCircularProgress"), y = S("FmTable");
|
|
1467
|
-
return c(),
|
|
1467
|
+
return c(), D("div", Ro, [
|
|
1468
1468
|
t("div", Oo, [
|
|
1469
|
-
r(
|
|
1470
|
-
"date-range":
|
|
1469
|
+
r(Fe, {
|
|
1470
|
+
"date-range": u(b),
|
|
1471
1471
|
"onUpdate:dateRange": w[0] || (w[0] = (n) => we(b) ? b.value = n : null),
|
|
1472
1472
|
compare: !1
|
|
1473
1473
|
}, null, 8, ["date-range"]),
|
|
1474
1474
|
r(k, {
|
|
1475
1475
|
loading: _.value,
|
|
1476
1476
|
variant: "primary",
|
|
1477
|
-
label:
|
|
1477
|
+
label: u(s)("report.common.upload"),
|
|
1478
1478
|
onClick: x
|
|
1479
1479
|
}, null, 8, ["loading", "label"])
|
|
1480
1480
|
]),
|
|
1481
|
-
_.value ? (c(),
|
|
1481
|
+
_.value ? (c(), D("div", Bo, [
|
|
1482
1482
|
r(d, { size: "xl" }),
|
|
1483
|
-
t("span", jo, T(
|
|
1483
|
+
t("span", jo, T(u(s)("report.integration.table.loading")), 1)
|
|
1484
1484
|
])) : e.value.length > 0 ? (c(), M(y, {
|
|
1485
1485
|
key: 1,
|
|
1486
1486
|
class: "flex overflow-scroll",
|
|
@@ -1497,8 +1497,8 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1497
1497
|
modelModifiers: {}
|
|
1498
1498
|
},
|
|
1499
1499
|
emits: ["update:modelValue"],
|
|
1500
|
-
setup(
|
|
1501
|
-
const { t: o } = J(), e = X(
|
|
1500
|
+
setup(v) {
|
|
1501
|
+
const { t: o } = J(), e = X(v, "modelValue"), s = B("setting"), V = [
|
|
1502
1502
|
{
|
|
1503
1503
|
label: o("report.integration.setting"),
|
|
1504
1504
|
value: "setting",
|
|
@@ -1522,12 +1522,12 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1522
1522
|
return (C, b) => {
|
|
1523
1523
|
var w;
|
|
1524
1524
|
const x = S("FmPageHead"), m = S("FmTabs");
|
|
1525
|
-
return c(),
|
|
1525
|
+
return c(), D("div", Eo, [
|
|
1526
1526
|
r(x, {
|
|
1527
1527
|
title: ((w = e.value) == null ? void 0 : w.name) || "Bukku",
|
|
1528
1528
|
"back-button": !0,
|
|
1529
1529
|
style: { paddingLeft: "0px", paddingRight: "0px" },
|
|
1530
|
-
"onClick:back":
|
|
1530
|
+
"onClick:back": u(h).back
|
|
1531
1531
|
}, {
|
|
1532
1532
|
description: ge(() => b[2] || (b[2] = [
|
|
1533
1533
|
t("div", null, null, -1)
|
|
@@ -1558,9 +1558,9 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1558
1558
|
modelModifiers: {}
|
|
1559
1559
|
},
|
|
1560
1560
|
emits: ["update:modelValue"],
|
|
1561
|
-
setup(
|
|
1562
|
-
const { t: o } = J(), e = X(
|
|
1563
|
-
() => b.map((
|
|
1561
|
+
setup(v) {
|
|
1562
|
+
const { t: o } = J(), e = X(v, "modelValue"), s = ue(), V = _e(), h = de(), { promptLoader: _ } = he(), { promptMessage: C } = Ce(), { restaurants: b } = pe(), x = Y(
|
|
1563
|
+
() => b.map((a) => ({ label: a.name, value: a.id }))
|
|
1564
1564
|
);
|
|
1565
1565
|
async function m() {
|
|
1566
1566
|
await C({
|
|
@@ -1569,8 +1569,8 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1569
1569
|
}) && await _(async () => {
|
|
1570
1570
|
try {
|
|
1571
1571
|
await Ve(e.value._id), await V.getSettings(), h.back();
|
|
1572
|
-
} catch (
|
|
1573
|
-
s.open({ type: "error", message:
|
|
1572
|
+
} catch (l) {
|
|
1573
|
+
s.open({ type: "error", message: l.message });
|
|
1574
1574
|
}
|
|
1575
1575
|
});
|
|
1576
1576
|
}
|
|
@@ -1578,22 +1578,22 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1578
1578
|
await _(async () => {
|
|
1579
1579
|
try {
|
|
1580
1580
|
await ke(e.value._id, e.value), await V.getSettings();
|
|
1581
|
-
} catch (
|
|
1582
|
-
s.open({ type: "error", message:
|
|
1581
|
+
} catch (a) {
|
|
1582
|
+
s.open({ type: "error", message: a.message });
|
|
1583
1583
|
}
|
|
1584
1584
|
});
|
|
1585
1585
|
}
|
|
1586
|
-
function k(
|
|
1587
|
-
var
|
|
1588
|
-
(i = (
|
|
1589
|
-
(
|
|
1586
|
+
function k(a, l) {
|
|
1587
|
+
var f, i;
|
|
1588
|
+
(i = (f = e.value.platform) == null ? void 0 : f.mappings) != null && i[a] && (e.value.platform.mappings[a] = e.value.platform.mappings[a].filter(
|
|
1589
|
+
(P, A) => A !== l
|
|
1590
1590
|
));
|
|
1591
1591
|
}
|
|
1592
|
-
function d(
|
|
1593
|
-
var
|
|
1594
|
-
(
|
|
1595
|
-
...e.value.platform.mappings[
|
|
1596
|
-
|
|
1592
|
+
function d(a) {
|
|
1593
|
+
var l, f;
|
|
1594
|
+
(f = (l = e.value.platform) == null ? void 0 : l.mappings) != null && f[a] && (e.value.platform.mappings[a] = [
|
|
1595
|
+
...e.value.platform.mappings[a],
|
|
1596
|
+
a === "items" ? {
|
|
1597
1597
|
key: "",
|
|
1598
1598
|
account: "",
|
|
1599
1599
|
description: ""
|
|
@@ -1618,88 +1618,88 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1618
1618
|
}
|
|
1619
1619
|
];
|
|
1620
1620
|
function n({
|
|
1621
|
-
key:
|
|
1622
|
-
value:
|
|
1621
|
+
key: a,
|
|
1622
|
+
value: l
|
|
1623
1623
|
}) {
|
|
1624
|
-
var
|
|
1625
|
-
(i = (
|
|
1624
|
+
var f, i;
|
|
1625
|
+
(i = (f = e.value) == null ? void 0 : f.platform) != null && i.mappings && (e.value.platform.mappings[a] = l);
|
|
1626
1626
|
}
|
|
1627
|
-
function
|
|
1627
|
+
function g(a) {
|
|
1628
1628
|
return {
|
|
1629
|
-
key: { placeholder:
|
|
1630
|
-
account: { placeholder:
|
|
1629
|
+
key: { placeholder: a, editable: !1 },
|
|
1630
|
+
account: { placeholder: a, editable: !0 }
|
|
1631
1631
|
};
|
|
1632
1632
|
}
|
|
1633
1633
|
async function $() {
|
|
1634
1634
|
await _(async () => {
|
|
1635
1635
|
try {
|
|
1636
1636
|
await $e(e.value._id), await V.getSettings();
|
|
1637
|
-
} catch (
|
|
1638
|
-
s.open({ type: "error", message:
|
|
1637
|
+
} catch (a) {
|
|
1638
|
+
s.open({ type: "error", message: a.message });
|
|
1639
1639
|
}
|
|
1640
1640
|
});
|
|
1641
1641
|
}
|
|
1642
1642
|
return be(async () => {
|
|
1643
1643
|
await V.getSettings();
|
|
1644
|
-
}), (
|
|
1644
|
+
}), (a, l) => {
|
|
1645
1645
|
var E, G, R, j, z, W, Z, ee, te, oe, ae, le, ne, se;
|
|
1646
|
-
const
|
|
1647
|
-
return (G = (E = e.value) == null ? void 0 : E.platform) != null && G.mappings ? (c(),
|
|
1646
|
+
const f = S("FmIcon"), i = S("FmButton"), P = S("FmMenuDivider"), A = S("FmTextField"), Q = S("FmSelect");
|
|
1647
|
+
return (G = (E = e.value) == null ? void 0 : E.platform) != null && G.mappings ? (c(), D("div", qo, [
|
|
1648
1648
|
t("div", Ho, [
|
|
1649
1649
|
t("div", Xo, [
|
|
1650
|
-
|
|
1650
|
+
l[14] || (l[14] = t("div", { class: "fm-typo-en-title-sm-800" }, null, -1)),
|
|
1651
1651
|
t("div", Qo, [
|
|
1652
1652
|
t("div", Go, [
|
|
1653
|
-
r(
|
|
1653
|
+
r(f, {
|
|
1654
1654
|
name: "refresh",
|
|
1655
1655
|
class: "p-2 bg-gray-100 rounded-full",
|
|
1656
1656
|
onClick: $
|
|
1657
1657
|
}),
|
|
1658
|
-
t("span", Jo, T(
|
|
1658
|
+
t("span", Jo, T(u(o)("report.integration.refreshSetting")), 1)
|
|
1659
1659
|
]),
|
|
1660
1660
|
r(i, {
|
|
1661
1661
|
variant: "tertiary",
|
|
1662
|
-
label:
|
|
1662
|
+
label: u(o)("report.common.remove"),
|
|
1663
1663
|
onClick: m
|
|
1664
1664
|
}, null, 8, ["label"]),
|
|
1665
1665
|
r(i, {
|
|
1666
1666
|
variant: "primary",
|
|
1667
|
-
label:
|
|
1667
|
+
label: u(o)("report.common.update"),
|
|
1668
1668
|
onClick: w
|
|
1669
1669
|
}, null, 8, ["label"])
|
|
1670
1670
|
])
|
|
1671
1671
|
])
|
|
1672
1672
|
]),
|
|
1673
|
-
r(
|
|
1673
|
+
r(P, { style: { margin: 0 } }),
|
|
1674
1674
|
t("div", Wo, [
|
|
1675
1675
|
t("div", Zo, [
|
|
1676
|
-
t("div", ea, T(
|
|
1676
|
+
t("div", ea, T(u(o)("report.integration.general")), 1),
|
|
1677
1677
|
t("div", ta, [
|
|
1678
|
-
t("div", oa, T(
|
|
1678
|
+
t("div", oa, T(u(o)("report.common.name")), 1),
|
|
1679
1679
|
t("div", aa, [
|
|
1680
|
-
r(
|
|
1680
|
+
r(A, {
|
|
1681
1681
|
modelValue: e.value.name,
|
|
1682
|
-
"onUpdate:modelValue":
|
|
1682
|
+
"onUpdate:modelValue": l[0] || (l[0] = (F) => e.value.name = F)
|
|
1683
1683
|
}, null, 8, ["modelValue"])
|
|
1684
1684
|
])
|
|
1685
1685
|
]),
|
|
1686
1686
|
t("div", la, [
|
|
1687
|
-
t("div", na, T(
|
|
1687
|
+
t("div", na, T(u(o)("report.integration.location")), 1),
|
|
1688
1688
|
r(Q, {
|
|
1689
1689
|
modelValue: e.value.platform.locationIds,
|
|
1690
|
-
"onUpdate:modelValue":
|
|
1690
|
+
"onUpdate:modelValue": l[1] || (l[1] = (F) => e.value.platform.locationIds = F),
|
|
1691
1691
|
multiselect: !0,
|
|
1692
1692
|
items: x.value,
|
|
1693
1693
|
placeholder: "Select location",
|
|
1694
1694
|
class: "flex-grow",
|
|
1695
|
-
rules: [(
|
|
1695
|
+
rules: [(F) => F.length !== 0 || "Please select at least 1 location"]
|
|
1696
1696
|
}, null, 8, ["modelValue", "items", "rules"])
|
|
1697
1697
|
]),
|
|
1698
1698
|
t("div", sa, [
|
|
1699
|
-
t("div", ia, T(
|
|
1699
|
+
t("div", ia, T(u(o)("report.integration.grouping.title")), 1),
|
|
1700
1700
|
r(Q, {
|
|
1701
1701
|
modelValue: e.value.platform.grouping,
|
|
1702
|
-
"onUpdate:modelValue":
|
|
1702
|
+
"onUpdate:modelValue": l[2] || (l[2] = (F) => e.value.platform.grouping = F),
|
|
1703
1703
|
multiselect: !1,
|
|
1704
1704
|
items: y,
|
|
1705
1705
|
placeholder: "Select grouping",
|
|
@@ -1711,61 +1711,61 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1711
1711
|
t("div", ma, [
|
|
1712
1712
|
r(K, {
|
|
1713
1713
|
"model-value": { key: "Project", account: e.value.platform.mappings.project },
|
|
1714
|
-
options:
|
|
1715
|
-
"onUpdate:modelValue":
|
|
1714
|
+
options: g("Project"),
|
|
1715
|
+
"onUpdate:modelValue": l[3] || (l[3] = (F) => n({ key: "project", value: F.account }))
|
|
1716
1716
|
}, null, 8, ["model-value", "options"]),
|
|
1717
1717
|
r(K, {
|
|
1718
1718
|
"model-value": { key: "Debtor", account: e.value.platform.mappings.debtor },
|
|
1719
|
-
options:
|
|
1720
|
-
"onUpdate:modelValue":
|
|
1719
|
+
options: g("Debtor"),
|
|
1720
|
+
"onUpdate:modelValue": l[4] || (l[4] = (F) => n({ key: "debtor", value: F.account }))
|
|
1721
1721
|
}, null, 8, ["model-value", "options"]),
|
|
1722
1722
|
r(K, {
|
|
1723
1723
|
"model-value": {
|
|
1724
1724
|
key: "Invoice no",
|
|
1725
1725
|
account: e.value.platform.mappings.invoiceDocNo
|
|
1726
1726
|
},
|
|
1727
|
-
options:
|
|
1728
|
-
"onUpdate:modelValue":
|
|
1727
|
+
options: g("Invoice no"),
|
|
1728
|
+
"onUpdate:modelValue": l[5] || (l[5] = (F) => n({ key: "invoiceDocNo", value: F.account }))
|
|
1729
1729
|
}, null, 8, ["model-value", "options"]),
|
|
1730
1730
|
r(K, {
|
|
1731
1731
|
"model-value": {
|
|
1732
1732
|
key: "Credit note no",
|
|
1733
1733
|
account: e.value.platform.mappings.creditNoteDocNo
|
|
1734
1734
|
},
|
|
1735
|
-
options:
|
|
1736
|
-
"onUpdate:modelValue":
|
|
1735
|
+
options: g("Credit note no"),
|
|
1736
|
+
"onUpdate:modelValue": l[6] || (l[6] = (F) => n({ key: "creditNoteDocNo", value: F.account }))
|
|
1737
1737
|
}, null, 8, ["model-value", "options"]),
|
|
1738
1738
|
r(K, {
|
|
1739
1739
|
"model-value": {
|
|
1740
1740
|
key: "Payment no",
|
|
1741
1741
|
account: e.value.platform.mappings.paymentDocNo
|
|
1742
1742
|
},
|
|
1743
|
-
options:
|
|
1744
|
-
"onUpdate:modelValue":
|
|
1743
|
+
options: g("Payment no"),
|
|
1744
|
+
"onUpdate:modelValue": l[7] || (l[7] = (F) => n({ key: "paymentDocNo", value: F.account }))
|
|
1745
1745
|
}, null, 8, ["model-value", "options"]),
|
|
1746
1746
|
r(K, {
|
|
1747
1747
|
"model-value": {
|
|
1748
1748
|
key: "Refund no",
|
|
1749
1749
|
account: e.value.platform.mappings.refundDocNo
|
|
1750
1750
|
},
|
|
1751
|
-
options:
|
|
1752
|
-
"onUpdate:modelValue":
|
|
1751
|
+
options: g("Refund no"),
|
|
1752
|
+
"onUpdate:modelValue": l[8] || (l[8] = (F) => n({ key: "refundDocNo", value: F.account }))
|
|
1753
1753
|
}, null, 8, ["model-value", "options"]),
|
|
1754
1754
|
r(K, {
|
|
1755
1755
|
"model-value": {
|
|
1756
1756
|
key: "Rounding",
|
|
1757
1757
|
account: e.value.platform.mappings.rounding.account
|
|
1758
1758
|
},
|
|
1759
|
-
options:
|
|
1760
|
-
"onUpdate:modelValue":
|
|
1761
|
-
var
|
|
1762
|
-
(O = (U = (
|
|
1759
|
+
options: g("Rounding"),
|
|
1760
|
+
"onUpdate:modelValue": l[9] || (l[9] = (F) => {
|
|
1761
|
+
var p, U, O;
|
|
1762
|
+
(O = (U = (p = e.value) == null ? void 0 : p.platform) == null ? void 0 : U.mappings) != null && O.rounding && (e.value.platform.mappings.rounding.account = F.account);
|
|
1763
1763
|
})
|
|
1764
1764
|
}, null, 8, ["model-value", "options"]),
|
|
1765
|
-
(c(!0),
|
|
1766
|
-
key: `charge-${
|
|
1767
|
-
modelValue: e.value.platform.mappings.charges[
|
|
1768
|
-
"onUpdate:modelValue": (U) => e.value.platform.mappings.charges[
|
|
1765
|
+
(c(!0), D(L, null, H((z = (j = (R = e.value) == null ? void 0 : R.platform) == null ? void 0 : j.mappings) == null ? void 0 : z.charges, (F, p) => (c(), M(K, {
|
|
1766
|
+
key: `charge-${p}`,
|
|
1767
|
+
modelValue: e.value.platform.mappings.charges[p],
|
|
1768
|
+
"onUpdate:modelValue": (U) => e.value.platform.mappings.charges[p] = U,
|
|
1769
1769
|
options: {
|
|
1770
1770
|
key: { placeholder: "Key", editable: !1 },
|
|
1771
1771
|
account: { placeholder: "Account code", editable: !0 }
|
|
@@ -1775,70 +1775,70 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1775
1775
|
]),
|
|
1776
1776
|
r(Ue, {
|
|
1777
1777
|
modelValue: e.value.platform,
|
|
1778
|
-
"onUpdate:modelValue":
|
|
1779
|
-
label:
|
|
1778
|
+
"onUpdate:modelValue": l[10] || (l[10] = (F) => e.value.platform = F),
|
|
1779
|
+
label: u(o)("report.input.email")
|
|
1780
1780
|
}, null, 8, ["modelValue", "label"]),
|
|
1781
1781
|
t("div", ca, [
|
|
1782
|
-
t("div", da, T(
|
|
1782
|
+
t("div", da, T(u(o)("report.integration.items")), 1),
|
|
1783
1783
|
r(i, {
|
|
1784
1784
|
variant: "primary",
|
|
1785
1785
|
icon: "add",
|
|
1786
|
-
onClick:
|
|
1786
|
+
onClick: l[11] || (l[11] = () => d("items"))
|
|
1787
1787
|
})
|
|
1788
1788
|
]),
|
|
1789
1789
|
t("div", pa, [
|
|
1790
|
-
(c(!0),
|
|
1791
|
-
key: `item-${
|
|
1792
|
-
modelValue: e.value.platform.mappings.items[
|
|
1793
|
-
"onUpdate:modelValue": (U) => e.value.platform.mappings.items[
|
|
1790
|
+
(c(!0), D(L, null, H((ee = (Z = (W = e.value) == null ? void 0 : W.platform) == null ? void 0 : Z.mappings) == null ? void 0 : ee.items, (F, p) => (c(), M(K, {
|
|
1791
|
+
key: `item-${p}`,
|
|
1792
|
+
modelValue: e.value.platform.mappings.items[p],
|
|
1793
|
+
"onUpdate:modelValue": (U) => e.value.platform.mappings.items[p] = U,
|
|
1794
1794
|
options: {
|
|
1795
1795
|
key: { placeholder: "Key", editable: !0 },
|
|
1796
1796
|
account: { placeholder: "Account code", editable: !0 }
|
|
1797
1797
|
},
|
|
1798
1798
|
removable: !0,
|
|
1799
|
-
onRemove: () => k("items",
|
|
1799
|
+
onRemove: () => k("items", p)
|
|
1800
1800
|
}, null, 8, ["modelValue", "onUpdate:modelValue", "onRemove"]))), 128))
|
|
1801
1801
|
]),
|
|
1802
1802
|
t("div", ua, [
|
|
1803
|
-
t("div", fa, T(
|
|
1803
|
+
t("div", fa, T(u(o)("report.integration.taxes")), 1),
|
|
1804
1804
|
r(i, {
|
|
1805
1805
|
variant: "primary",
|
|
1806
1806
|
icon: "add",
|
|
1807
|
-
onClick:
|
|
1807
|
+
onClick: l[12] || (l[12] = () => d("taxes"))
|
|
1808
1808
|
})
|
|
1809
1809
|
]),
|
|
1810
1810
|
t("div", va, [
|
|
1811
|
-
(c(!0),
|
|
1812
|
-
key: `tax-${
|
|
1813
|
-
modelValue: e.value.platform.mappings.taxes[
|
|
1814
|
-
"onUpdate:modelValue": (U) => e.value.platform.mappings.taxes[
|
|
1811
|
+
(c(!0), D(L, null, H((ae = (oe = (te = e.value) == null ? void 0 : te.platform) == null ? void 0 : oe.mappings) == null ? void 0 : ae.taxes, (F, p) => (c(), M(K, {
|
|
1812
|
+
key: `tax-${p}`,
|
|
1813
|
+
modelValue: e.value.platform.mappings.taxes[p],
|
|
1814
|
+
"onUpdate:modelValue": (U) => e.value.platform.mappings.taxes[p] = U,
|
|
1815
1815
|
options: {
|
|
1816
1816
|
key: { placeholder: "Key", editable: !0 },
|
|
1817
1817
|
account: { placeholder: "Account code", editable: !0 }
|
|
1818
1818
|
},
|
|
1819
1819
|
removable: !0,
|
|
1820
|
-
onRemove: () => k("taxes",
|
|
1820
|
+
onRemove: () => k("taxes", p)
|
|
1821
1821
|
}, null, 8, ["modelValue", "onUpdate:modelValue", "onRemove"]))), 128))
|
|
1822
1822
|
]),
|
|
1823
1823
|
t("div", ga, [
|
|
1824
|
-
t("div", ya, T(
|
|
1824
|
+
t("div", ya, T(u(o)("report.integration.payments")), 1),
|
|
1825
1825
|
r(i, {
|
|
1826
1826
|
variant: "primary",
|
|
1827
1827
|
icon: "add",
|
|
1828
|
-
onClick:
|
|
1828
|
+
onClick: l[13] || (l[13] = () => d("payments"))
|
|
1829
1829
|
})
|
|
1830
1830
|
]),
|
|
1831
1831
|
t("div", xa, [
|
|
1832
|
-
(c(!0),
|
|
1833
|
-
key: `payment-${
|
|
1834
|
-
modelValue: e.value.platform.mappings.payments[
|
|
1835
|
-
"onUpdate:modelValue": (U) => e.value.platform.mappings.payments[
|
|
1832
|
+
(c(!0), D(L, null, H((se = (ne = (le = e.value) == null ? void 0 : le.platform) == null ? void 0 : ne.mappings) == null ? void 0 : se.payments, (F, p) => (c(), M(K, {
|
|
1833
|
+
key: `payment-${p}`,
|
|
1834
|
+
modelValue: e.value.platform.mappings.payments[p],
|
|
1835
|
+
"onUpdate:modelValue": (U) => e.value.platform.mappings.payments[p] = U,
|
|
1836
1836
|
options: {
|
|
1837
1837
|
key: { placeholder: "Key", editable: !0 },
|
|
1838
1838
|
account: { placeholder: "Payment name", editable: !0 }
|
|
1839
1839
|
},
|
|
1840
1840
|
removable: !0,
|
|
1841
|
-
onRemove: () => k("payments",
|
|
1841
|
+
onRemove: () => k("payments", p)
|
|
1842
1842
|
}, null, 8, ["modelValue", "onUpdate:modelValue", "onRemove"]))), 128))
|
|
1843
1843
|
])
|
|
1844
1844
|
])
|
|
@@ -1855,7 +1855,7 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1855
1855
|
modelModifiers: {}
|
|
1856
1856
|
},
|
|
1857
1857
|
emits: ["update:modelValue"],
|
|
1858
|
-
setup(
|
|
1858
|
+
setup(v) {
|
|
1859
1859
|
const { t: o } = J(), e = B([]), s = Y(
|
|
1860
1860
|
() => e.value.reduce((m, w) => {
|
|
1861
1861
|
const k = m.length, { invoice: d, payments: y } = w;
|
|
@@ -1867,16 +1867,16 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1867
1867
|
description: d.Description
|
|
1868
1868
|
};
|
|
1869
1869
|
for (let n = 0; n < Math.max(d._items.length, y.length); n++) {
|
|
1870
|
-
const
|
|
1871
|
-
m[
|
|
1872
|
-
...m[
|
|
1870
|
+
const g = k + n;
|
|
1871
|
+
m[g] || (m[g] = {}), d._items[n] && (m[g] = {
|
|
1872
|
+
...m[g],
|
|
1873
1873
|
itemDescription: d._items[n].DetailDescription,
|
|
1874
1874
|
itemUnitPrice: d._items[n].Amount,
|
|
1875
1875
|
itemAccount: d._items[n].AccNo,
|
|
1876
1876
|
itemTaxCode: d._items[n].TaxType,
|
|
1877
1877
|
itemTax: d._items[n].Tax
|
|
1878
|
-
}), y[n] && (m[
|
|
1879
|
-
...m[
|
|
1878
|
+
}), y[n] && (m[g] = {
|
|
1879
|
+
...m[g],
|
|
1880
1880
|
paymentDocNo: y[n].DocNo,
|
|
1881
1881
|
paymentMethod: y[n].paymentMethod,
|
|
1882
1882
|
paymentDescription: y[n].Description,
|
|
@@ -1956,7 +1956,7 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1956
1956
|
header: "Payment Amount",
|
|
1957
1957
|
enableSorting: !1
|
|
1958
1958
|
}
|
|
1959
|
-
], h = X(
|
|
1959
|
+
], h = X(v, "modelValue"), _ = B(!1), C = ue(), { dateRange: b } = De(pe());
|
|
1960
1960
|
ve(
|
|
1961
1961
|
() => b.value,
|
|
1962
1962
|
async () => {
|
|
@@ -1984,23 +1984,23 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
1984
1984
|
}
|
|
1985
1985
|
return (m, w) => {
|
|
1986
1986
|
const k = S("FmButton"), d = S("FmCircularProgress"), y = S("FmTable");
|
|
1987
|
-
return c(),
|
|
1987
|
+
return c(), D("div", ba, [
|
|
1988
1988
|
t("div", wa, [
|
|
1989
|
-
r(
|
|
1990
|
-
"date-range":
|
|
1989
|
+
r(Fe, {
|
|
1990
|
+
"date-range": u(b),
|
|
1991
1991
|
"onUpdate:dateRange": w[0] || (w[0] = (n) => we(b) ? b.value = n : null),
|
|
1992
1992
|
compare: !1
|
|
1993
1993
|
}, null, 8, ["date-range"]),
|
|
1994
1994
|
r(k, {
|
|
1995
1995
|
loading: _.value,
|
|
1996
1996
|
variant: "primary",
|
|
1997
|
-
label:
|
|
1997
|
+
label: u(o)("report.common.download"),
|
|
1998
1998
|
onClick: x
|
|
1999
1999
|
}, null, 8, ["loading", "label"])
|
|
2000
2000
|
]),
|
|
2001
|
-
_.value ? (c(),
|
|
2001
|
+
_.value ? (c(), D("div", ha, [
|
|
2002
2002
|
r(d, { size: "xl" }),
|
|
2003
|
-
t("span", Va, T(
|
|
2003
|
+
t("span", Va, T(u(o)("report.common.isLoading")), 1)
|
|
2004
2004
|
])) : s.value.length > 0 ? (c(), M(y, {
|
|
2005
2005
|
key: 1,
|
|
2006
2006
|
class: "flex overflow-scroll",
|
|
@@ -2017,8 +2017,8 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2017
2017
|
modelModifiers: {}
|
|
2018
2018
|
},
|
|
2019
2019
|
emits: ["update:modelValue"],
|
|
2020
|
-
setup(
|
|
2021
|
-
const { t: o } = J(), e = X(
|
|
2020
|
+
setup(v) {
|
|
2021
|
+
const { t: o } = J(), e = X(v, "modelValue"), s = B("setting"), V = [
|
|
2022
2022
|
{
|
|
2023
2023
|
label: o("report.integration.setting"),
|
|
2024
2024
|
value: "setting",
|
|
@@ -2042,12 +2042,12 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2042
2042
|
return (C, b) => {
|
|
2043
2043
|
var w;
|
|
2044
2044
|
const x = S("FmPageHead"), m = S("FmTabs");
|
|
2045
|
-
return c(),
|
|
2045
|
+
return c(), D("div", $a, [
|
|
2046
2046
|
r(x, {
|
|
2047
2047
|
title: ((w = e.value) == null ? void 0 : w.name) || "AutoCount",
|
|
2048
2048
|
"back-button": !0,
|
|
2049
2049
|
style: { paddingLeft: "0px", paddingRight: "0px" },
|
|
2050
|
-
"onClick:back":
|
|
2050
|
+
"onClick:back": u(h).back
|
|
2051
2051
|
}, {
|
|
2052
2052
|
description: ge(() => b[2] || (b[2] = [
|
|
2053
2053
|
t("div", null, null, -1)
|
|
@@ -2068,19 +2068,19 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2068
2068
|
]);
|
|
2069
2069
|
};
|
|
2070
2070
|
}
|
|
2071
|
-
}),
|
|
2071
|
+
}), Da = {
|
|
2072
2072
|
key: 0,
|
|
2073
2073
|
class: "flex flex-col h-full"
|
|
2074
|
-
},
|
|
2074
|
+
}, Fa = { class: "flex flex-col gap-16 pb-[24px]" }, Ua = { class: "flex flex-row justify-between items-center gap-2" }, Ta = { class: "flex flex-row gap-2 items-center" }, Ia = { class: "relative group cursor-pointer" }, Ma = { class: "absolute left-1/2 -translate-x-2/3 top-full mt-2 w-max bg-gray-900 text-white text-sm px-2 py-1 rounded opacity-0 group-hover:opacity-100 transition-opacity" }, Ka = { class: "flex flex-col gap-24 pt-[24px] overflow-scroll" }, Aa = { class: "flex flex-col gap-16" }, Pa = { class: "fm-typo-en-title-sm-800" }, Na = { class: "flex flex-row items-center max-w-[100%]" }, Ra = { class: "w-[25%]" }, Oa = { class: "flex-grow" }, Ba = { class: "flex flex-row items-center max-w-[100%]" }, ja = { class: "w-[25%]" }, La = { class: "flex flex-row items-center max-w-[100%]" }, Ea = { class: "w-[25%]" }, za = { class: "flex flex-col gap-16" }, Ya = { class: "xs:grid-cols-1 grid-cols-2 grid gap-16" }, qa = { class: "grid-cols-1 grid gap-16" }, Ha = { class: "flex flex-row items-center gap-x-16" }, Xa = { class: "fm-typo-en-title-sm-800" }, Qa = { class: "grid-cols-1 grid gap-16" }, Ga = { class: "flex flex-row items-center gap-x-16" }, Ja = { class: "fm-typo-en-title-sm-800" }, Wa = { class: "xs:grid-cols-1 grid-cols-2 grid gap-16" }, Za = { class: "flex flex-row items-center gap-x-16" }, el = { class: "fm-typo-en-title-sm-800" }, tl = { class: "xs:grid-cols-1 grid-cols-2 grid gap-16" }, ol = /* @__PURE__ */ q({
|
|
2075
2075
|
__name: "Setting",
|
|
2076
2076
|
props: {
|
|
2077
2077
|
modelValue: { required: !0 },
|
|
2078
2078
|
modelModifiers: {}
|
|
2079
2079
|
},
|
|
2080
2080
|
emits: ["update:modelValue"],
|
|
2081
|
-
setup(
|
|
2082
|
-
const { t: o } = J(), e = X(
|
|
2083
|
-
() => b.map((
|
|
2081
|
+
setup(v) {
|
|
2082
|
+
const { t: o } = J(), e = X(v, "modelValue"), s = ue(), V = _e(), h = de(), { promptLoader: _ } = he(), { promptMessage: C } = Ce(), { restaurants: b } = pe(), x = Y(
|
|
2083
|
+
() => b.map((a) => ({ label: a.name, value: a.id }))
|
|
2084
2084
|
);
|
|
2085
2085
|
async function m() {
|
|
2086
2086
|
await C({
|
|
@@ -2089,8 +2089,8 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2089
2089
|
}) && await _(async () => {
|
|
2090
2090
|
try {
|
|
2091
2091
|
await Ve(e.value._id), await V.getSettings(), h.back();
|
|
2092
|
-
} catch (
|
|
2093
|
-
s.open({ type: "error", message:
|
|
2092
|
+
} catch (l) {
|
|
2093
|
+
s.open({ type: "error", message: l.message });
|
|
2094
2094
|
}
|
|
2095
2095
|
});
|
|
2096
2096
|
}
|
|
@@ -2098,22 +2098,22 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2098
2098
|
await _(async () => {
|
|
2099
2099
|
try {
|
|
2100
2100
|
await ke(e.value._id, e.value), await V.getSettings();
|
|
2101
|
-
} catch (
|
|
2102
|
-
s.open({ type: "error", message:
|
|
2101
|
+
} catch (a) {
|
|
2102
|
+
s.open({ type: "error", message: a.message });
|
|
2103
2103
|
}
|
|
2104
2104
|
});
|
|
2105
2105
|
}
|
|
2106
|
-
function k(
|
|
2107
|
-
var
|
|
2108
|
-
(i = (
|
|
2109
|
-
(
|
|
2106
|
+
function k(a, l) {
|
|
2107
|
+
var f, i;
|
|
2108
|
+
(i = (f = e.value.platform) == null ? void 0 : f.mappings) != null && i[a] && (e.value.platform.mappings[a] = e.value.platform.mappings[a].filter(
|
|
2109
|
+
(P, A) => A !== l
|
|
2110
2110
|
));
|
|
2111
2111
|
}
|
|
2112
|
-
function d(
|
|
2113
|
-
var
|
|
2114
|
-
(
|
|
2115
|
-
...e.value.platform.mappings[
|
|
2116
|
-
|
|
2112
|
+
function d(a) {
|
|
2113
|
+
var l, f;
|
|
2114
|
+
(f = (l = e.value.platform) == null ? void 0 : l.mappings) != null && f[a] && (e.value.platform.mappings[a] = [
|
|
2115
|
+
...e.value.platform.mappings[a],
|
|
2116
|
+
a === "items" ? {
|
|
2117
2117
|
key: "",
|
|
2118
2118
|
account: "",
|
|
2119
2119
|
description: ""
|
|
@@ -2139,88 +2139,88 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2139
2139
|
}
|
|
2140
2140
|
];
|
|
2141
2141
|
function n({
|
|
2142
|
-
key:
|
|
2143
|
-
value:
|
|
2142
|
+
key: a,
|
|
2143
|
+
value: l
|
|
2144
2144
|
}) {
|
|
2145
|
-
var
|
|
2146
|
-
(i = (
|
|
2145
|
+
var f, i;
|
|
2146
|
+
(i = (f = e.value) == null ? void 0 : f.platform) != null && i.mappings && (e.value.platform.mappings[a] = l);
|
|
2147
2147
|
}
|
|
2148
|
-
function
|
|
2148
|
+
function g(a) {
|
|
2149
2149
|
return {
|
|
2150
|
-
key: { placeholder:
|
|
2151
|
-
account: { placeholder:
|
|
2150
|
+
key: { placeholder: a, editable: !1 },
|
|
2151
|
+
account: { placeholder: a, editable: !0 }
|
|
2152
2152
|
};
|
|
2153
2153
|
}
|
|
2154
2154
|
async function $() {
|
|
2155
2155
|
await _(async () => {
|
|
2156
2156
|
try {
|
|
2157
2157
|
await $e(e.value._id), await V.getSettings();
|
|
2158
|
-
} catch (
|
|
2159
|
-
s.open({ type: "error", message:
|
|
2158
|
+
} catch (a) {
|
|
2159
|
+
s.open({ type: "error", message: a.message });
|
|
2160
2160
|
}
|
|
2161
2161
|
});
|
|
2162
2162
|
}
|
|
2163
2163
|
return be(async () => {
|
|
2164
2164
|
await V.getSettings();
|
|
2165
|
-
}), (
|
|
2165
|
+
}), (a, l) => {
|
|
2166
2166
|
var E, G, R, j, z, W, Z, ee, te, oe, ae, le, ne, se;
|
|
2167
|
-
const
|
|
2168
|
-
return (G = (E = e.value) == null ? void 0 : E.platform) != null && G.mappings ? (c(),
|
|
2169
|
-
t("div",
|
|
2167
|
+
const f = S("FmIcon"), i = S("FmButton"), P = S("FmMenuDivider"), A = S("FmTextField"), Q = S("FmSelect");
|
|
2168
|
+
return (G = (E = e.value) == null ? void 0 : E.platform) != null && G.mappings ? (c(), D("div", Da, [
|
|
2169
|
+
t("div", Fa, [
|
|
2170
2170
|
t("div", Ua, [
|
|
2171
|
-
|
|
2171
|
+
l[15] || (l[15] = t("div", { class: "fm-typo-en-title-sm-800" }, null, -1)),
|
|
2172
2172
|
t("div", Ta, [
|
|
2173
2173
|
t("div", Ia, [
|
|
2174
|
-
r(
|
|
2174
|
+
r(f, {
|
|
2175
2175
|
name: "refresh",
|
|
2176
2176
|
class: "p-2 bg-gray-100 rounded-full",
|
|
2177
2177
|
onClick: $
|
|
2178
2178
|
}),
|
|
2179
|
-
t("span", Ma, T(
|
|
2179
|
+
t("span", Ma, T(u(o)("report.integration.refreshSetting")), 1)
|
|
2180
2180
|
]),
|
|
2181
2181
|
r(i, {
|
|
2182
2182
|
variant: "tertiary",
|
|
2183
|
-
label:
|
|
2183
|
+
label: u(o)("report.common.delete"),
|
|
2184
2184
|
onClick: m
|
|
2185
2185
|
}, null, 8, ["label"]),
|
|
2186
2186
|
r(i, {
|
|
2187
2187
|
variant: "primary",
|
|
2188
|
-
label:
|
|
2188
|
+
label: u(o)("report.common.update"),
|
|
2189
2189
|
onClick: w
|
|
2190
2190
|
}, null, 8, ["label"])
|
|
2191
2191
|
])
|
|
2192
2192
|
])
|
|
2193
2193
|
]),
|
|
2194
|
-
r(
|
|
2194
|
+
r(P, { style: { margin: 0 } }),
|
|
2195
2195
|
t("div", Ka, [
|
|
2196
2196
|
t("div", Aa, [
|
|
2197
|
-
t("div", Pa, T(
|
|
2197
|
+
t("div", Pa, T(u(o)("report.integration.general")), 1),
|
|
2198
2198
|
t("div", Na, [
|
|
2199
|
-
t("div", Ra, T(
|
|
2199
|
+
t("div", Ra, T(u(o)("report.common.name")), 1),
|
|
2200
2200
|
t("div", Oa, [
|
|
2201
|
-
r(
|
|
2201
|
+
r(A, {
|
|
2202
2202
|
modelValue: e.value.name,
|
|
2203
|
-
"onUpdate:modelValue":
|
|
2203
|
+
"onUpdate:modelValue": l[0] || (l[0] = (F) => e.value.name = F)
|
|
2204
2204
|
}, null, 8, ["modelValue"])
|
|
2205
2205
|
])
|
|
2206
2206
|
]),
|
|
2207
2207
|
t("div", Ba, [
|
|
2208
|
-
t("div", ja, T(
|
|
2208
|
+
t("div", ja, T(u(o)("report.integration.location")), 1),
|
|
2209
2209
|
r(Q, {
|
|
2210
2210
|
modelValue: e.value.platform.locationIds,
|
|
2211
|
-
"onUpdate:modelValue":
|
|
2211
|
+
"onUpdate:modelValue": l[1] || (l[1] = (F) => e.value.platform.locationIds = F),
|
|
2212
2212
|
multiselect: !0,
|
|
2213
2213
|
items: x.value,
|
|
2214
2214
|
placeholder: "Select location",
|
|
2215
2215
|
class: "flex-grow",
|
|
2216
|
-
rules: [(
|
|
2216
|
+
rules: [(F) => F.length !== 0 || "Please select at least 1 location"]
|
|
2217
2217
|
}, null, 8, ["modelValue", "items", "rules"])
|
|
2218
2218
|
]),
|
|
2219
2219
|
t("div", La, [
|
|
2220
|
-
t("div", Ea, T(
|
|
2220
|
+
t("div", Ea, T(u(o)("report.integration.grouping.title")), 1),
|
|
2221
2221
|
r(Q, {
|
|
2222
2222
|
modelValue: e.value.platform.grouping,
|
|
2223
|
-
"onUpdate:modelValue":
|
|
2223
|
+
"onUpdate:modelValue": l[2] || (l[2] = (F) => e.value.platform.grouping = F),
|
|
2224
2224
|
multiselect: !1,
|
|
2225
2225
|
items: y,
|
|
2226
2226
|
placeholder: "Select grouping",
|
|
@@ -2232,56 +2232,56 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2232
2232
|
t("div", Ya, [
|
|
2233
2233
|
r(K, {
|
|
2234
2234
|
"model-value": { key: "Debtor", account: e.value.platform.mappings.debtor },
|
|
2235
|
-
options:
|
|
2236
|
-
"onUpdate:modelValue":
|
|
2235
|
+
options: g("Debtor"),
|
|
2236
|
+
"onUpdate:modelValue": l[3] || (l[3] = (F) => n({ key: "debtor", value: F.account }))
|
|
2237
2237
|
}, null, 8, ["model-value", "options"]),
|
|
2238
2238
|
r(K, {
|
|
2239
2239
|
"model-value": {
|
|
2240
2240
|
key: "Invoice no",
|
|
2241
2241
|
account: e.value.platform.mappings.invoiceDocNo
|
|
2242
2242
|
},
|
|
2243
|
-
options:
|
|
2244
|
-
"onUpdate:modelValue":
|
|
2243
|
+
options: g("Invoice no"),
|
|
2244
|
+
"onUpdate:modelValue": l[4] || (l[4] = (F) => n({ key: "invoiceDocNo", value: F.account }))
|
|
2245
2245
|
}, null, 8, ["model-value", "options"]),
|
|
2246
2246
|
r(K, {
|
|
2247
2247
|
"model-value": {
|
|
2248
2248
|
key: "Credit note no",
|
|
2249
2249
|
account: e.value.platform.mappings.creditNoteDocNo
|
|
2250
2250
|
},
|
|
2251
|
-
options:
|
|
2252
|
-
"onUpdate:modelValue":
|
|
2251
|
+
options: g("Credit note no"),
|
|
2252
|
+
"onUpdate:modelValue": l[5] || (l[5] = (F) => n({ key: "creditNoteDocNo", value: F.account }))
|
|
2253
2253
|
}, null, 8, ["model-value", "options"]),
|
|
2254
2254
|
r(K, {
|
|
2255
2255
|
"model-value": {
|
|
2256
2256
|
key: "Payment no",
|
|
2257
2257
|
account: e.value.platform.mappings.paymentDocNo
|
|
2258
2258
|
},
|
|
2259
|
-
options:
|
|
2260
|
-
"onUpdate:modelValue":
|
|
2259
|
+
options: g("Payment no"),
|
|
2260
|
+
"onUpdate:modelValue": l[6] || (l[6] = (F) => n({ key: "paymentDocNo", value: F.account }))
|
|
2261
2261
|
}, null, 8, ["model-value", "options"]),
|
|
2262
2262
|
r(K, {
|
|
2263
2263
|
"model-value": {
|
|
2264
2264
|
key: "Refund no",
|
|
2265
2265
|
account: e.value.platform.mappings.refundDocNo
|
|
2266
2266
|
},
|
|
2267
|
-
options:
|
|
2268
|
-
"onUpdate:modelValue":
|
|
2267
|
+
options: g("Refund no"),
|
|
2268
|
+
"onUpdate:modelValue": l[7] || (l[7] = (F) => n({ key: "refundDocNo", value: F.account }))
|
|
2269
2269
|
}, null, 8, ["model-value", "options"]),
|
|
2270
2270
|
r(K, {
|
|
2271
2271
|
"model-value": {
|
|
2272
2272
|
key: "Project header",
|
|
2273
2273
|
account: e.value.platform.mappings.projectHeader
|
|
2274
2274
|
},
|
|
2275
|
-
options:
|
|
2276
|
-
"onUpdate:modelValue":
|
|
2275
|
+
options: g("Project header"),
|
|
2276
|
+
"onUpdate:modelValue": l[8] || (l[8] = (F) => n({ key: "projectHeader", value: F.account }))
|
|
2277
2277
|
}, null, 8, ["model-value", "options"]),
|
|
2278
2278
|
r(K, {
|
|
2279
2279
|
"model-value": {
|
|
2280
2280
|
key: "Project detail",
|
|
2281
2281
|
account: e.value.platform.mappings.projectDetail
|
|
2282
2282
|
},
|
|
2283
|
-
options:
|
|
2284
|
-
"onUpdate:modelValue":
|
|
2283
|
+
options: g("Project detail"),
|
|
2284
|
+
"onUpdate:modelValue": l[9] || (l[9] = (F) => n({ key: "projectDetail", value: F.account }))
|
|
2285
2285
|
}, null, 8, ["model-value", "options"])
|
|
2286
2286
|
]),
|
|
2287
2287
|
t("div", qa, [
|
|
@@ -2296,15 +2296,15 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2296
2296
|
account: { placeholder: "Account code", editable: !0 },
|
|
2297
2297
|
code: { placeholder: "Item code", editable: !0 }
|
|
2298
2298
|
},
|
|
2299
|
-
"onUpdate:modelValue":
|
|
2300
|
-
var
|
|
2301
|
-
(O = (U = (
|
|
2299
|
+
"onUpdate:modelValue": l[10] || (l[10] = (F) => {
|
|
2300
|
+
var p, U, O;
|
|
2301
|
+
(O = (U = (p = e.value) == null ? void 0 : p.platform) == null ? void 0 : U.mappings) != null && O.rounding && (e.value.platform.mappings.rounding.account = F.account, e.value.platform.mappings.rounding.code = F.code);
|
|
2302
2302
|
})
|
|
2303
2303
|
}, null, 8, ["model-value"]),
|
|
2304
|
-
(c(!0),
|
|
2305
|
-
key: `charge-${
|
|
2306
|
-
modelValue: e.value.platform.mappings.charges[
|
|
2307
|
-
"onUpdate:modelValue": (U) => e.value.platform.mappings.charges[
|
|
2304
|
+
(c(!0), D(L, null, H((z = (j = (R = e.value) == null ? void 0 : R.platform) == null ? void 0 : j.mappings) == null ? void 0 : z.charges, (F, p) => (c(), M(K, {
|
|
2305
|
+
key: `charge-${p}`,
|
|
2306
|
+
modelValue: e.value.platform.mappings.charges[p],
|
|
2307
|
+
"onUpdate:modelValue": (U) => e.value.platform.mappings.charges[p] = U,
|
|
2308
2308
|
options: {
|
|
2309
2309
|
key: { placeholder: "Key", editable: !1 },
|
|
2310
2310
|
account: { placeholder: "Account code", editable: !0 },
|
|
@@ -2315,71 +2315,71 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2315
2315
|
]),
|
|
2316
2316
|
r(Ue, {
|
|
2317
2317
|
modelValue: e.value.platform,
|
|
2318
|
-
"onUpdate:modelValue":
|
|
2318
|
+
"onUpdate:modelValue": l[11] || (l[11] = (F) => e.value.platform = F),
|
|
2319
2319
|
label: "email"
|
|
2320
2320
|
}, null, 8, ["modelValue"]),
|
|
2321
2321
|
t("div", Ha, [
|
|
2322
|
-
t("div", Xa, T(
|
|
2322
|
+
t("div", Xa, T(u(o)("report.integration.items")), 1),
|
|
2323
2323
|
r(i, {
|
|
2324
2324
|
variant: "primary",
|
|
2325
2325
|
icon: "add",
|
|
2326
|
-
onClick:
|
|
2326
|
+
onClick: l[12] || (l[12] = () => d("items"))
|
|
2327
2327
|
})
|
|
2328
2328
|
]),
|
|
2329
2329
|
t("div", Qa, [
|
|
2330
|
-
(c(!0),
|
|
2331
|
-
key: `item-${
|
|
2332
|
-
modelValue: e.value.platform.mappings.items[
|
|
2333
|
-
"onUpdate:modelValue": (U) => e.value.platform.mappings.items[
|
|
2330
|
+
(c(!0), D(L, null, H((ee = (Z = (W = e.value) == null ? void 0 : W.platform) == null ? void 0 : Z.mappings) == null ? void 0 : ee.items, (F, p) => (c(), M(K, {
|
|
2331
|
+
key: `item-${p}`,
|
|
2332
|
+
modelValue: e.value.platform.mappings.items[p],
|
|
2333
|
+
"onUpdate:modelValue": (U) => e.value.platform.mappings.items[p] = U,
|
|
2334
2334
|
options: {
|
|
2335
2335
|
key: { placeholder: "Key", editable: !0 },
|
|
2336
2336
|
account: { placeholder: "Account code", editable: !0 },
|
|
2337
2337
|
code: { placeholder: "Item code", editable: !0 }
|
|
2338
2338
|
},
|
|
2339
2339
|
removable: !0,
|
|
2340
|
-
onRemove: () => k("items",
|
|
2340
|
+
onRemove: () => k("items", p)
|
|
2341
2341
|
}, null, 8, ["modelValue", "onUpdate:modelValue", "onRemove"]))), 128))
|
|
2342
2342
|
]),
|
|
2343
2343
|
t("div", Ga, [
|
|
2344
|
-
t("div", Ja, T(
|
|
2344
|
+
t("div", Ja, T(u(o)("report.integration.taxes")), 1),
|
|
2345
2345
|
r(i, {
|
|
2346
2346
|
variant: "primary",
|
|
2347
2347
|
icon: "add",
|
|
2348
|
-
onClick:
|
|
2348
|
+
onClick: l[13] || (l[13] = () => d("taxes"))
|
|
2349
2349
|
})
|
|
2350
2350
|
]),
|
|
2351
2351
|
t("div", Wa, [
|
|
2352
|
-
(c(!0),
|
|
2353
|
-
key: `tax-${
|
|
2354
|
-
modelValue: e.value.platform.mappings.taxes[
|
|
2355
|
-
"onUpdate:modelValue": (U) => e.value.platform.mappings.taxes[
|
|
2352
|
+
(c(!0), D(L, null, H((ae = (oe = (te = e.value) == null ? void 0 : te.platform) == null ? void 0 : oe.mappings) == null ? void 0 : ae.taxes, (F, p) => (c(), M(K, {
|
|
2353
|
+
key: `tax-${p}`,
|
|
2354
|
+
modelValue: e.value.platform.mappings.taxes[p],
|
|
2355
|
+
"onUpdate:modelValue": (U) => e.value.platform.mappings.taxes[p] = U,
|
|
2356
2356
|
options: {
|
|
2357
2357
|
key: { placeholder: "Key", editable: !0 },
|
|
2358
2358
|
account: { placeholder: "Account code", editable: !0 }
|
|
2359
2359
|
},
|
|
2360
2360
|
removable: !0,
|
|
2361
|
-
onRemove: () => k("taxes",
|
|
2361
|
+
onRemove: () => k("taxes", p)
|
|
2362
2362
|
}, null, 8, ["modelValue", "onUpdate:modelValue", "onRemove"]))), 128))
|
|
2363
2363
|
]),
|
|
2364
2364
|
t("div", Za, [
|
|
2365
|
-
t("div", el, T(
|
|
2365
|
+
t("div", el, T(u(o)("report.integration.payments")), 1),
|
|
2366
2366
|
r(i, {
|
|
2367
2367
|
variant: "primary",
|
|
2368
2368
|
icon: "add",
|
|
2369
|
-
onClick:
|
|
2369
|
+
onClick: l[14] || (l[14] = () => d("payments"))
|
|
2370
2370
|
})
|
|
2371
2371
|
]),
|
|
2372
2372
|
t("div", tl, [
|
|
2373
|
-
(c(!0),
|
|
2374
|
-
key: `payment-${
|
|
2375
|
-
modelValue: e.value.platform.mappings.payments[
|
|
2376
|
-
"onUpdate:modelValue": (U) => e.value.platform.mappings.payments[
|
|
2373
|
+
(c(!0), D(L, null, H((se = (ne = (le = e.value) == null ? void 0 : le.platform) == null ? void 0 : ne.mappings) == null ? void 0 : se.payments, (F, p) => (c(), M(K, {
|
|
2374
|
+
key: `payment-${p}`,
|
|
2375
|
+
modelValue: e.value.platform.mappings.payments[p],
|
|
2376
|
+
"onUpdate:modelValue": (U) => e.value.platform.mappings.payments[p] = U,
|
|
2377
2377
|
options: {
|
|
2378
2378
|
key: { placeholder: "Key", editable: !0 },
|
|
2379
2379
|
account: { placeholder: "Method", editable: !0 }
|
|
2380
2380
|
},
|
|
2381
2381
|
removable: !0,
|
|
2382
|
-
onRemove: () => k("payments",
|
|
2382
|
+
onRemove: () => k("payments", p)
|
|
2383
2383
|
}, null, 8, ["modelValue", "onUpdate:modelValue", "onRemove"]))), 128))
|
|
2384
2384
|
])
|
|
2385
2385
|
])
|
|
@@ -2396,7 +2396,7 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2396
2396
|
modelModifiers: {}
|
|
2397
2397
|
},
|
|
2398
2398
|
emits: ["update:modelValue"],
|
|
2399
|
-
setup(
|
|
2399
|
+
setup(v) {
|
|
2400
2400
|
const { t: o } = J(), e = B([]), s = Y(
|
|
2401
2401
|
() => e.value.reduce((m, w) => {
|
|
2402
2402
|
const k = m.length, { invoice: d, payments: y } = w;
|
|
@@ -2407,16 +2407,16 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2407
2407
|
description: d.Description_HDR
|
|
2408
2408
|
};
|
|
2409
2409
|
for (let n = 0; n < Math.max(d._items.length, y.length); n++) {
|
|
2410
|
-
const
|
|
2411
|
-
m[
|
|
2412
|
-
...m[
|
|
2410
|
+
const g = k + n;
|
|
2411
|
+
m[g] || (m[g] = {}), d._items[n] && (m[g] = {
|
|
2412
|
+
...m[g],
|
|
2413
2413
|
itemDescription: d._items[n].Description_DTL,
|
|
2414
2414
|
itemUnitPrice: d._items[n].UnitPrice,
|
|
2415
2415
|
itemAccount: d._items[n].ACCOUNT,
|
|
2416
2416
|
itemTaxCode: d._items[n].Tax,
|
|
2417
2417
|
itemTax: d._items[n].TaxAmt
|
|
2418
|
-
}), y[n] && (m[
|
|
2419
|
-
...m[
|
|
2418
|
+
}), y[n] && (m[g] = {
|
|
2419
|
+
...m[g],
|
|
2420
2420
|
paymentDocNo: y[n].DOCNO_Header,
|
|
2421
2421
|
paymentMethod: y[n].PAYMENTMETHOD,
|
|
2422
2422
|
paymentAccount: y[n].CODE,
|
|
@@ -2492,7 +2492,7 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2492
2492
|
header: "Payment Amount",
|
|
2493
2493
|
enableSorting: !1
|
|
2494
2494
|
}
|
|
2495
|
-
], h = X(
|
|
2495
|
+
], h = X(v, "modelValue"), _ = B(!1), C = ue(), { dateRange: b } = De(pe());
|
|
2496
2496
|
ve(
|
|
2497
2497
|
() => b.value,
|
|
2498
2498
|
async () => {
|
|
@@ -2520,23 +2520,23 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2520
2520
|
}
|
|
2521
2521
|
return (m, w) => {
|
|
2522
2522
|
const k = S("FmButton"), d = S("FmCircularProgress"), y = S("FmTable");
|
|
2523
|
-
return c(),
|
|
2523
|
+
return c(), D("div", al, [
|
|
2524
2524
|
t("div", ll, [
|
|
2525
|
-
r(
|
|
2526
|
-
"date-range":
|
|
2525
|
+
r(Fe, {
|
|
2526
|
+
"date-range": u(b),
|
|
2527
2527
|
"onUpdate:dateRange": w[0] || (w[0] = (n) => we(b) ? b.value = n : null),
|
|
2528
2528
|
compare: !1
|
|
2529
2529
|
}, null, 8, ["date-range"]),
|
|
2530
2530
|
r(k, {
|
|
2531
2531
|
loading: _.value,
|
|
2532
2532
|
variant: "primary",
|
|
2533
|
-
label:
|
|
2533
|
+
label: u(o)("report.common.download"),
|
|
2534
2534
|
onClick: x
|
|
2535
2535
|
}, null, 8, ["loading", "label"])
|
|
2536
2536
|
]),
|
|
2537
|
-
_.value ? (c(),
|
|
2537
|
+
_.value ? (c(), D("div", nl, [
|
|
2538
2538
|
r(d, { size: "xl" }),
|
|
2539
|
-
t("span", sl, T(
|
|
2539
|
+
t("span", sl, T(u(o)("report.common.isLoading")), 1)
|
|
2540
2540
|
])) : s.value.length > 0 ? (c(), M(y, {
|
|
2541
2541
|
key: 1,
|
|
2542
2542
|
class: "flex overflow-scroll",
|
|
@@ -2553,8 +2553,8 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2553
2553
|
modelModifiers: {}
|
|
2554
2554
|
},
|
|
2555
2555
|
emits: ["update:modelValue"],
|
|
2556
|
-
setup(
|
|
2557
|
-
const { t: o } = J(), e = X(
|
|
2556
|
+
setup(v) {
|
|
2557
|
+
const { t: o } = J(), e = X(v, "modelValue"), s = B("setting"), V = [
|
|
2558
2558
|
{
|
|
2559
2559
|
label: o("report.integration.setting"),
|
|
2560
2560
|
value: "setting",
|
|
@@ -2578,12 +2578,12 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2578
2578
|
return (C, b) => {
|
|
2579
2579
|
var w;
|
|
2580
2580
|
const x = S("FmPageHead"), m = S("FmTabs");
|
|
2581
|
-
return c(),
|
|
2581
|
+
return c(), D("div", rl, [
|
|
2582
2582
|
r(x, {
|
|
2583
2583
|
title: ((w = e.value) == null ? void 0 : w.name) || "SQL",
|
|
2584
2584
|
"back-button": !0,
|
|
2585
2585
|
style: { paddingLeft: "0px", paddingRight: "0px" },
|
|
2586
|
-
"onClick:back":
|
|
2586
|
+
"onClick:back": u(h).back
|
|
2587
2587
|
}, {
|
|
2588
2588
|
description: ge(() => b[2] || (b[2] = [
|
|
2589
2589
|
t("div", null, null, -1)
|
|
@@ -2607,22 +2607,22 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2607
2607
|
}), dl = {
|
|
2608
2608
|
key: 0,
|
|
2609
2609
|
class: "flex flex-col h-full"
|
|
2610
|
-
}, pl = { class: "flex flex-col gap-16 pb-[24px]" }, ul = { class: "flex flex-row justify-between items-center gap-2" }, fl = { class: "fm-typo-en-title-sm-800" }, vl = { class: "flex flex-row gap-2 items-center" }, gl = { class: "flex flex-row gap-2 items-center" }, yl = { class: "relative group cursor-pointer" }, xl = { class: "absolute left-1/2 -translate-x-2/3 top-full mt-2 w-max bg-gray-900 text-white text-sm px-2 py-1 rounded opacity-0 group-hover:opacity-100 transition-opacity" }, _l = { class: "flex flex-col gap-24 pt-[24px] overflow-y-auto overflow-x-hidden" }, bl = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, wl = { class: "flex flex-row items-center max-w-[100%]" }, hl = { class: "w-[25%]" }, Vl = { class: "flex-grow" }, kl = { class: "flex flex-col gap-24 pt-[24px] overflow-y-auto overflow-x-hidden" }, $l = { class: "flex flex-row items-center justify-between" }, Sl = { class: "w-[25%]" }, Cl = { class: "flex-grow" },
|
|
2610
|
+
}, pl = { class: "flex flex-col gap-16 pb-[24px]" }, ul = { class: "flex flex-row justify-between items-center gap-2" }, fl = { class: "fm-typo-en-title-sm-800" }, vl = { class: "flex flex-row gap-2 items-center" }, gl = { class: "flex flex-row gap-2 items-center" }, yl = { class: "relative group cursor-pointer" }, xl = { class: "absolute left-1/2 -translate-x-2/3 top-full mt-2 w-max bg-gray-900 text-white text-sm px-2 py-1 rounded opacity-0 group-hover:opacity-100 transition-opacity" }, _l = { class: "flex flex-col gap-24 pt-[24px] overflow-y-auto overflow-x-hidden" }, bl = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, wl = { class: "flex flex-row items-center max-w-[100%]" }, hl = { class: "w-[25%]" }, Vl = { class: "flex-grow" }, kl = { class: "flex flex-col gap-24 pt-[24px] overflow-y-auto overflow-x-hidden" }, $l = { class: "flex flex-row items-center justify-between" }, Sl = { class: "w-[25%]" }, Cl = { class: "flex-grow" }, Dl = { class: "flex flex-row items-center justify-between" }, Fl = { class: "w-[25%]" }, Ul = { class: "flex-grow" }, Tl = { class: "flex flex-col gap-16" }, Il = { class: "fm-typo-en-title-sm-800" }, Ml = { class: "flex flex-row items-center max-w-[100%]" }, Kl = { class: "w-[25%]" }, Al = { class: "flex-grow" }, Pl = { class: "flex flex-row items-center max-w-[100%]" }, Nl = { class: "w-[25%]" }, Rl = { class: "flex flex-row items-center max-w-[100%]" }, Ol = { class: "w-[25%]" }, Bl = { class: "flex flex-row items-center max-w-[100%]" }, jl = { class: "flex-grow" }, Ll = { class: "flex flex-row items-center max-w-[100%]" }, El = { class: "flex-grow" }, zl = {
|
|
2611
2611
|
key: 0,
|
|
2612
2612
|
class: "flex flex-row items-center max-w-[100%]"
|
|
2613
|
-
},
|
|
2613
|
+
}, Yl = { class: "flex flex-col gap-16" }, ql = { class: "xs:grid-cols-1 grid-cols-2 grid gap-16" }, Hl = { key: 1 }, Xl = { class: "flex flex-row items-center gap-x-16" }, Ql = { class: "fm-typo-en-title-sm-800" }, Gl = { class: "xs:grid-cols-1 grid-cols-2 grid gap-16" }, Jl = { class: "flex flex-row items-center gap-x-16" }, Wl = { class: "fm-typo-en-title-sm-800" }, Zl = { class: "xs:grid-cols-1 grid-cols-2 grid gap-16" }, en = { class: "flex flex-row items-center gap-x-16" }, tn = { class: "fm-typo-en-title-sm-800" }, on = { class: "flex flex-row items-center justify-between" }, an = { class: "flex-grow" }, ln = {
|
|
2614
2614
|
key: 0,
|
|
2615
2615
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
|
|
2616
|
-
},
|
|
2616
|
+
}, nn = {
|
|
2617
2617
|
key: 1,
|
|
2618
2618
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
|
|
2619
|
-
},
|
|
2619
|
+
}, sn = {
|
|
2620
2620
|
key: 3,
|
|
2621
2621
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
|
|
2622
|
-
},
|
|
2622
|
+
}, rn = {
|
|
2623
2623
|
key: 0,
|
|
2624
2624
|
class: "flex flex-row items-center"
|
|
2625
|
-
},
|
|
2625
|
+
}, mn = /* @__PURE__ */ q({
|
|
2626
2626
|
__name: "Setting",
|
|
2627
2627
|
props: /* @__PURE__ */ ye({
|
|
2628
2628
|
retrievedMethods: {
|
|
@@ -2638,15 +2638,15 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2638
2638
|
modelModifiers: {}
|
|
2639
2639
|
}),
|
|
2640
2640
|
emits: ["update:modelValue"],
|
|
2641
|
-
setup(
|
|
2642
|
-
const { t: o } = J(), e = X(
|
|
2641
|
+
setup(v) {
|
|
2642
|
+
const { t: o } = J(), e = X(v, "modelValue"), s = ue(), V = _e(), h = de(), { promptLoader: _ } = he(), { promptMessage: C } = Ce(), { restaurants: b } = pe(), x = Y(
|
|
2643
2643
|
() => b.map(($) => ({ label: $.name, value: $.id }))
|
|
2644
2644
|
);
|
|
2645
2645
|
function m($) {
|
|
2646
|
-
var
|
|
2647
|
-
!((
|
|
2648
|
-
const
|
|
2649
|
-
|
|
2646
|
+
var a;
|
|
2647
|
+
!((a = v.retrievedMethods) != null && a.data) || !Array.isArray(v.retrievedMethods.data) || $.forEach((l) => {
|
|
2648
|
+
const f = v.retrievedMethods.data.find((i) => i.value == l.id);
|
|
2649
|
+
f && (l.cnId = f.cnId);
|
|
2650
2650
|
});
|
|
2651
2651
|
}
|
|
2652
2652
|
async function w() {
|
|
@@ -2656,30 +2656,30 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2656
2656
|
}) && await _(async () => {
|
|
2657
2657
|
try {
|
|
2658
2658
|
await Ve(e.value._id), await V.getSettings(), h.back();
|
|
2659
|
-
} catch (
|
|
2660
|
-
s.open({ type: "error", message:
|
|
2659
|
+
} catch (a) {
|
|
2660
|
+
s.open({ type: "error", message: a.message });
|
|
2661
2661
|
}
|
|
2662
2662
|
});
|
|
2663
2663
|
}
|
|
2664
2664
|
async function k() {
|
|
2665
2665
|
await _(async () => {
|
|
2666
|
-
var $,
|
|
2666
|
+
var $, a, l;
|
|
2667
2667
|
try {
|
|
2668
|
-
(
|
|
2669
|
-
} catch (
|
|
2670
|
-
s.open({ type: "error", message:
|
|
2668
|
+
(l = (a = ($ = e.value) == null ? void 0 : $.platform) == null ? void 0 : a.mappings) != null && l.paymentMethods && m(e.value.platform.mappings.paymentMethods), await ke(e.value._id, e.value), await V.getSettings();
|
|
2669
|
+
} catch (f) {
|
|
2670
|
+
s.open({ type: "error", message: f.message });
|
|
2671
2671
|
}
|
|
2672
2672
|
});
|
|
2673
2673
|
}
|
|
2674
|
-
function d($,
|
|
2675
|
-
var
|
|
2676
|
-
(
|
|
2677
|
-
(i,
|
|
2674
|
+
function d($, a) {
|
|
2675
|
+
var l, f;
|
|
2676
|
+
(f = (l = e.value.platform) == null ? void 0 : l.mappings) != null && f[$] && (e.value.platform.mappings[$] = e.value.platform.mappings[$].filter(
|
|
2677
|
+
(i, P) => P !== a
|
|
2678
2678
|
));
|
|
2679
2679
|
}
|
|
2680
2680
|
function y($) {
|
|
2681
|
-
var
|
|
2682
|
-
(
|
|
2681
|
+
var a, l;
|
|
2682
|
+
(l = (a = e.value.platform) == null ? void 0 : a.mappings) != null && l[$] && (e.value.platform.mappings[$] = [
|
|
2683
2683
|
...e.value.platform.mappings[$],
|
|
2684
2684
|
$ === "items" ? {
|
|
2685
2685
|
key: "",
|
|
@@ -2702,16 +2702,16 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2702
2702
|
];
|
|
2703
2703
|
ve(
|
|
2704
2704
|
() => {
|
|
2705
|
-
var $,
|
|
2706
|
-
return (
|
|
2705
|
+
var $, a, l;
|
|
2706
|
+
return (l = (a = ($ = e.value) == null ? void 0 : $.platform) == null ? void 0 : a.mappings) == null ? void 0 : l.taxes;
|
|
2707
2707
|
},
|
|
2708
2708
|
($) => {
|
|
2709
|
-
$ && $.forEach((
|
|
2710
|
-
var
|
|
2711
|
-
const
|
|
2712
|
-
let i =
|
|
2713
|
-
if (!i &&
|
|
2714
|
-
switch (
|
|
2709
|
+
$ && $.forEach((a, l) => {
|
|
2710
|
+
var P;
|
|
2711
|
+
const f = a.key || "";
|
|
2712
|
+
let i = a.account;
|
|
2713
|
+
if (!i && f) {
|
|
2714
|
+
switch (f) {
|
|
2715
2715
|
case "SST_SV":
|
|
2716
2716
|
i = "SST-6";
|
|
2717
2717
|
break;
|
|
@@ -2722,8 +2722,8 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2722
2722
|
i = "SST-0";
|
|
2723
2723
|
break;
|
|
2724
2724
|
}
|
|
2725
|
-
(
|
|
2726
|
-
...
|
|
2725
|
+
(P = e.value.platform) != null && P.mappings && (e.value.platform.mappings.taxes[l] = {
|
|
2726
|
+
...a,
|
|
2727
2727
|
account: i
|
|
2728
2728
|
});
|
|
2729
2729
|
}
|
|
@@ -2732,19 +2732,19 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2732
2732
|
{ immediate: !0, deep: !0 }
|
|
2733
2733
|
), ve(
|
|
2734
2734
|
() => {
|
|
2735
|
-
var $,
|
|
2736
|
-
return (
|
|
2735
|
+
var $, a, l;
|
|
2736
|
+
return (l = (a = ($ = e.value) == null ? void 0 : $.platform) == null ? void 0 : a.mappings) == null ? void 0 : l.version;
|
|
2737
2737
|
},
|
|
2738
2738
|
($) => {
|
|
2739
|
-
var
|
|
2740
|
-
$ === "v1" && !((
|
|
2739
|
+
var a, l, f, i, P;
|
|
2740
|
+
$ === "v1" && !((f = (l = (a = e.value) == null ? void 0 : a.platform) == null ? void 0 : l.mappings) != null && f.payee) && (P = (i = e.value) == null ? void 0 : i.platform) != null && P.mappings && (e.value.platform.mappings.payee = {
|
|
2741
2741
|
id: 1,
|
|
2742
2742
|
name: ""
|
|
2743
2743
|
});
|
|
2744
2744
|
},
|
|
2745
2745
|
{ immediate: !0 }
|
|
2746
2746
|
);
|
|
2747
|
-
async function
|
|
2747
|
+
async function g() {
|
|
2748
2748
|
await _(async () => {
|
|
2749
2749
|
try {
|
|
2750
2750
|
await $e(e.value._id), await V.getSettings();
|
|
@@ -2755,31 +2755,31 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2755
2755
|
}
|
|
2756
2756
|
return be(async () => {
|
|
2757
2757
|
await V.getSettings();
|
|
2758
|
-
}), ($,
|
|
2759
|
-
var G, R, j, z, W, Z, ee, te, oe, ae, le, ne, se,
|
|
2760
|
-
const
|
|
2761
|
-
return (R = (G = e.value) == null ? void 0 : G.platform) != null && R.mappings ? (c(),
|
|
2758
|
+
}), ($, a) => {
|
|
2759
|
+
var G, R, j, z, W, Z, ee, te, oe, ae, le, ne, se, F;
|
|
2760
|
+
const l = S("FmIcon"), f = S("FmButton"), i = S("FmSelect"), P = S("FmMenuDivider"), A = S("FmTextField"), Q = S("FmCircularProgress"), E = S("FmCheckbox");
|
|
2761
|
+
return (R = (G = e.value) == null ? void 0 : G.platform) != null && R.mappings ? (c(), D("div", dl, [
|
|
2762
2762
|
t("div", pl, [
|
|
2763
2763
|
t("div", ul, [
|
|
2764
|
-
t("div", fl, T(
|
|
2764
|
+
t("div", fl, T(u(o)("report.integration.connect")), 1),
|
|
2765
2765
|
t("div", vl, [
|
|
2766
2766
|
t("div", gl, [
|
|
2767
2767
|
t("div", yl, [
|
|
2768
|
-
r(
|
|
2768
|
+
r(l, {
|
|
2769
2769
|
name: "refresh",
|
|
2770
2770
|
class: "p-2 bg-gray-100 rounded-full",
|
|
2771
|
-
onClick:
|
|
2771
|
+
onClick: g
|
|
2772
2772
|
}),
|
|
2773
|
-
t("span", xl, T(
|
|
2773
|
+
t("span", xl, T(u(o)("report.integration.refreshSetting")), 1)
|
|
2774
2774
|
]),
|
|
2775
|
-
r(
|
|
2775
|
+
r(f, {
|
|
2776
2776
|
variant: "tertiary",
|
|
2777
|
-
label:
|
|
2777
|
+
label: u(o)("report.common.delete"),
|
|
2778
2778
|
onClick: w
|
|
2779
2779
|
}, null, 8, ["label"]),
|
|
2780
|
-
r(
|
|
2780
|
+
r(f, {
|
|
2781
2781
|
variant: "primary",
|
|
2782
|
-
label:
|
|
2782
|
+
label: u(o)("report.common.update"),
|
|
2783
2783
|
onClick: k
|
|
2784
2784
|
}, null, 8, ["label"])
|
|
2785
2785
|
])
|
|
@@ -2787,13 +2787,13 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2787
2787
|
])
|
|
2788
2788
|
]),
|
|
2789
2789
|
t("div", _l, [
|
|
2790
|
-
t("div", bl, T(
|
|
2790
|
+
t("div", bl, T(u(o)("report.integration.biztory.authenticate")), 1),
|
|
2791
2791
|
t("div", wl, [
|
|
2792
|
-
t("div", hl, "Biztory " + T(
|
|
2792
|
+
t("div", hl, "Biztory " + T(u(o)("report.integration.biztory.version")), 1),
|
|
2793
2793
|
t("div", Vl, [
|
|
2794
2794
|
r(i, {
|
|
2795
2795
|
modelValue: e.value.platform.mappings.version,
|
|
2796
|
-
"onUpdate:modelValue":
|
|
2796
|
+
"onUpdate:modelValue": a[0] || (a[0] = (p) => e.value.platform.mappings.version = p),
|
|
2797
2797
|
items: [
|
|
2798
2798
|
{ label: "v1", value: "v1" },
|
|
2799
2799
|
{ label: "v2", value: "v2" }
|
|
@@ -2802,68 +2802,86 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2802
2802
|
}, null, 8, ["modelValue"])
|
|
2803
2803
|
])
|
|
2804
2804
|
]),
|
|
2805
|
-
r(
|
|
2805
|
+
r(P, { style: { margin: 0 } }),
|
|
2806
2806
|
t("div", kl, [
|
|
2807
2807
|
t("div", $l, [
|
|
2808
|
-
t("div", Sl, T(
|
|
2808
|
+
t("div", Sl, T(u(o)("report.integration.biztory.subdomain")), 1),
|
|
2809
2809
|
t("div", Cl, [
|
|
2810
|
-
r(
|
|
2810
|
+
r(A, {
|
|
2811
2811
|
modelValue: e.value.platform.subdomain,
|
|
2812
|
-
"onUpdate:modelValue":
|
|
2812
|
+
"onUpdate:modelValue": a[1] || (a[1] = (p) => e.value.platform.subdomain = p),
|
|
2813
2813
|
placeholder: "Subdomain"
|
|
2814
2814
|
}, null, 8, ["modelValue"])
|
|
2815
2815
|
])
|
|
2816
2816
|
]),
|
|
2817
|
-
t("div",
|
|
2818
|
-
t("div",
|
|
2817
|
+
t("div", Dl, [
|
|
2818
|
+
t("div", Fl, T(u(o)("report.integration.biztory.apiKey")), 1),
|
|
2819
2819
|
t("div", Ul, [
|
|
2820
|
-
r(
|
|
2820
|
+
r(A, {
|
|
2821
2821
|
modelValue: e.value.platform.api_key,
|
|
2822
|
-
"onUpdate:modelValue":
|
|
2822
|
+
"onUpdate:modelValue": a[2] || (a[2] = (p) => e.value.platform.api_key = p),
|
|
2823
2823
|
placeholder: "API Key"
|
|
2824
2824
|
}, null, 8, ["modelValue"])
|
|
2825
2825
|
])
|
|
2826
2826
|
]),
|
|
2827
2827
|
t("div", Tl, [
|
|
2828
|
-
t("div", Il, T(
|
|
2828
|
+
t("div", Il, T(u(o)("report.integration.general")), 1),
|
|
2829
2829
|
t("div", Ml, [
|
|
2830
|
-
t("div", Kl, T(
|
|
2830
|
+
t("div", Kl, T(u(o)("report.common.name")), 1),
|
|
2831
2831
|
t("div", Al, [
|
|
2832
|
-
r(
|
|
2832
|
+
r(A, {
|
|
2833
2833
|
modelValue: e.value.name,
|
|
2834
|
-
"onUpdate:modelValue":
|
|
2834
|
+
"onUpdate:modelValue": a[3] || (a[3] = (p) => e.value.name = p)
|
|
2835
2835
|
}, null, 8, ["modelValue"])
|
|
2836
2836
|
])
|
|
2837
2837
|
]),
|
|
2838
2838
|
t("div", Pl, [
|
|
2839
|
-
t("div", Nl, T(
|
|
2839
|
+
t("div", Nl, T(u(o)("report.common.location")), 1),
|
|
2840
2840
|
r(i, {
|
|
2841
2841
|
modelValue: e.value.platform.locationIds,
|
|
2842
|
-
"onUpdate:modelValue":
|
|
2842
|
+
"onUpdate:modelValue": a[4] || (a[4] = (p) => e.value.platform.locationIds = p),
|
|
2843
2843
|
multiselect: !0,
|
|
2844
2844
|
items: x.value,
|
|
2845
|
-
placeholder:
|
|
2845
|
+
placeholder: u(o)("report.common.location"),
|
|
2846
2846
|
class: "flex-grow"
|
|
2847
2847
|
}, null, 8, ["modelValue", "items", "placeholder"])
|
|
2848
2848
|
]),
|
|
2849
2849
|
t("div", Rl, [
|
|
2850
|
-
t("div", Ol, T(
|
|
2850
|
+
t("div", Ol, T(u(o)("report.integration.grouping.title")), 1),
|
|
2851
2851
|
r(i, {
|
|
2852
2852
|
modelValue: e.value.platform.grouping,
|
|
2853
|
-
"onUpdate:modelValue":
|
|
2853
|
+
"onUpdate:modelValue": a[5] || (a[5] = (p) => e.value.platform.grouping = p),
|
|
2854
2854
|
multiselect: !1,
|
|
2855
2855
|
items: n,
|
|
2856
|
-
placeholder:
|
|
2856
|
+
placeholder: u(o)("report.integration.grouping.title"),
|
|
2857
2857
|
class: "flex-grow",
|
|
2858
2858
|
disabled: ""
|
|
2859
2859
|
}, null, 8, ["modelValue", "placeholder"])
|
|
2860
2860
|
]),
|
|
2861
|
-
|
|
2862
|
-
|
|
2861
|
+
t("div", Bl, [
|
|
2862
|
+
a[15] || (a[15] = t("div", { class: "w-[25%]" }, T("Invoice no"), -1)),
|
|
2863
|
+
t("div", jl, [
|
|
2864
|
+
r(A, {
|
|
2865
|
+
modelValue: e.value.platform.mappings.invoiceDocNo,
|
|
2866
|
+
"onUpdate:modelValue": a[6] || (a[6] = (p) => e.value.platform.mappings.invoiceDocNo = p)
|
|
2867
|
+
}, null, 8, ["modelValue"])
|
|
2868
|
+
])
|
|
2869
|
+
]),
|
|
2870
|
+
t("div", Ll, [
|
|
2871
|
+
a[16] || (a[16] = t("div", { class: "w-[25%]" }, T("Credit no"), -1)),
|
|
2872
|
+
t("div", El, [
|
|
2873
|
+
r(A, {
|
|
2874
|
+
modelValue: e.value.platform.mappings.creditNoteDocNo,
|
|
2875
|
+
"onUpdate:modelValue": a[7] || (a[7] = (p) => e.value.platform.mappings.creditNoteDocNo = p)
|
|
2876
|
+
}, null, 8, ["modelValue"])
|
|
2877
|
+
])
|
|
2878
|
+
]),
|
|
2879
|
+
e.value.platform.mappings.version == "v1" ? (c(), D("div", zl, [
|
|
2880
|
+
a[17] || (a[17] = t("div", { class: "w-[33%]" }, "Payee ID", -1)),
|
|
2863
2881
|
e.value.platform.mappings.version == "v1" ? (c(), M(K, {
|
|
2864
2882
|
key: 0,
|
|
2865
2883
|
modelValue: e.value.platform.mappings.payee,
|
|
2866
|
-
"onUpdate:modelValue":
|
|
2884
|
+
"onUpdate:modelValue": a[8] || (a[8] = (p) => e.value.platform.mappings.payee = p),
|
|
2867
2885
|
options: {
|
|
2868
2886
|
id: { placeholder: "ID", editable: !0 }
|
|
2869
2887
|
},
|
|
@@ -2871,23 +2889,23 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2871
2889
|
}, null, 8, ["modelValue"])) : N("", !0)
|
|
2872
2890
|
])) : N("", !0)
|
|
2873
2891
|
]),
|
|
2874
|
-
t("div",
|
|
2875
|
-
t("div",
|
|
2876
|
-
!
|
|
2892
|
+
t("div", Yl, [
|
|
2893
|
+
t("div", ql, [
|
|
2894
|
+
!v.retrievedCustomers.isLoaded && e.value.platform.mappings.version == "v2" ? (c(), M(Q, {
|
|
2877
2895
|
key: 0,
|
|
2878
2896
|
size: "xl"
|
|
2879
2897
|
})) : N("", !0),
|
|
2880
|
-
|
|
2898
|
+
v.retrievedCustomers.isLoaded && v.retrievedCustomers.data && ((j = v.retrievedCustomers.data) == null ? void 0 : j.length) != 0 ? (c(), D("div", Hl, [
|
|
2881
2899
|
e.value.platform.mappings.version == "v2" ? (c(), M(Ke, {
|
|
2882
2900
|
key: 0,
|
|
2883
2901
|
modelValue: e.value.platform.mappings.payeeId,
|
|
2884
|
-
"onUpdate:modelValue":
|
|
2902
|
+
"onUpdate:modelValue": a[9] || (a[9] = (p) => e.value.platform.mappings.payeeId = p),
|
|
2885
2903
|
options: {
|
|
2886
2904
|
key: { placeholder: "Payee", editable: !1 },
|
|
2887
2905
|
customer: {
|
|
2888
2906
|
placeholder: "Select payee",
|
|
2889
2907
|
editable: !0,
|
|
2890
|
-
dropdownOptions: ((z =
|
|
2908
|
+
dropdownOptions: ((z = v.retrievedCustomers) == null ? void 0 : z.data) ?? []
|
|
2891
2909
|
}
|
|
2892
2910
|
},
|
|
2893
2911
|
removable: !1,
|
|
@@ -2898,20 +2916,20 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2898
2916
|
]),
|
|
2899
2917
|
r(Ue, {
|
|
2900
2918
|
modelValue: e.value.platform,
|
|
2901
|
-
"onUpdate:modelValue":
|
|
2919
|
+
"onUpdate:modelValue": a[10] || (a[10] = (p) => e.value.platform = p),
|
|
2902
2920
|
label: "upload",
|
|
2903
2921
|
"last-upload-date": (W = e.value.platform) == null ? void 0 : W.lastUploadDate
|
|
2904
2922
|
}, null, 8, ["modelValue", "last-upload-date"]),
|
|
2905
|
-
t("div",
|
|
2906
|
-
t("div",
|
|
2907
|
-
r(
|
|
2923
|
+
t("div", Xl, [
|
|
2924
|
+
t("div", Ql, T(u(o)("report.integration.biztory.items")), 1),
|
|
2925
|
+
r(f, {
|
|
2908
2926
|
variant: "primary",
|
|
2909
2927
|
icon: "add",
|
|
2910
|
-
onClick:
|
|
2928
|
+
onClick: a[11] || (a[11] = () => y("items"))
|
|
2911
2929
|
})
|
|
2912
2930
|
]),
|
|
2913
|
-
t("div",
|
|
2914
|
-
(c(!0),
|
|
2931
|
+
t("div", Gl, [
|
|
2932
|
+
(c(!0), D(L, null, H((te = (ee = (Z = e.value) == null ? void 0 : Z.platform) == null ? void 0 : ee.mappings) == null ? void 0 : te.items, (p, U) => (c(), M(K, {
|
|
2915
2933
|
key: `item-${U}`,
|
|
2916
2934
|
modelValue: e.value.platform.mappings.items[U],
|
|
2917
2935
|
"onUpdate:modelValue": (O) => e.value.platform.mappings.items[U] = O,
|
|
@@ -2923,16 +2941,16 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2923
2941
|
onRemove: () => d("items", U)
|
|
2924
2942
|
}, null, 8, ["modelValue", "onUpdate:modelValue", "onRemove"]))), 128))
|
|
2925
2943
|
]),
|
|
2926
|
-
t("div",
|
|
2927
|
-
t("div",
|
|
2928
|
-
r(
|
|
2944
|
+
t("div", Jl, [
|
|
2945
|
+
t("div", Wl, T(u(o)("report.integration.biztory.taxes")), 1),
|
|
2946
|
+
r(f, {
|
|
2929
2947
|
variant: "primary",
|
|
2930
2948
|
icon: "add",
|
|
2931
|
-
onClick:
|
|
2949
|
+
onClick: a[12] || (a[12] = () => y("taxes"))
|
|
2932
2950
|
})
|
|
2933
2951
|
]),
|
|
2934
|
-
t("div",
|
|
2935
|
-
(c(!0),
|
|
2952
|
+
t("div", Zl, [
|
|
2953
|
+
(c(!0), D(L, null, H((le = (ae = (oe = e.value) == null ? void 0 : oe.platform) == null ? void 0 : ae.mappings) == null ? void 0 : le.taxes, (p, U) => (c(), M(K, {
|
|
2936
2954
|
key: `tax-${U}`,
|
|
2937
2955
|
modelValue: e.value.platform.mappings.taxes[U],
|
|
2938
2956
|
"onUpdate:modelValue": (O) => e.value.platform.mappings.taxes[U] = O,
|
|
@@ -2944,20 +2962,20 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2944
2962
|
onRemove: () => d("taxes", U)
|
|
2945
2963
|
}, null, 8, ["modelValue", "onUpdate:modelValue", "onRemove"]))), 128))
|
|
2946
2964
|
]),
|
|
2947
|
-
t("div",
|
|
2948
|
-
t("div",
|
|
2949
|
-
r(
|
|
2965
|
+
t("div", en, [
|
|
2966
|
+
t("div", tn, T(u(o)("report.integration.biztory.payments")), 1),
|
|
2967
|
+
r(f, {
|
|
2950
2968
|
variant: "primary",
|
|
2951
2969
|
icon: "add",
|
|
2952
|
-
onClick:
|
|
2970
|
+
onClick: a[13] || (a[13] = () => y("paymentMethods"))
|
|
2953
2971
|
})
|
|
2954
2972
|
]),
|
|
2955
|
-
t("div",
|
|
2956
|
-
|
|
2957
|
-
t("div",
|
|
2973
|
+
t("div", on, [
|
|
2974
|
+
a[18] || (a[18] = t("div", { class: "w-[25%]" }, "Payment Term", -1)),
|
|
2975
|
+
t("div", an, [
|
|
2958
2976
|
r(K, {
|
|
2959
2977
|
modelValue: e.value.platform.mappings.paymentTerm,
|
|
2960
|
-
"onUpdate:modelValue":
|
|
2978
|
+
"onUpdate:modelValue": a[14] || (a[14] = (p) => e.value.platform.mappings.paymentTerm = p),
|
|
2961
2979
|
options: {
|
|
2962
2980
|
id: { placeholder: "ID", editable: !0 },
|
|
2963
2981
|
name: { placeholder: "Name", editable: !0 }
|
|
@@ -2966,20 +2984,20 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2966
2984
|
}, null, 8, ["modelValue"])
|
|
2967
2985
|
])
|
|
2968
2986
|
]),
|
|
2969
|
-
|
|
2970
|
-
|
|
2971
|
-
|
|
2987
|
+
v.retrievedMethods.isError ? N("", !0) : (c(), D("div", ln, T(u(o)("report.integration.biztory.paymentTerm")), 1)),
|
|
2988
|
+
v.retrievedMethods.isLoaded && v.retrievedMethods.data && v.retrievedMethods.data.length == 0 && !v.retrievedMethods.isError ? (c(), D("span", nn, T(u(o)("report.integration.biztory.noPaymentMethods")), 1)) : N("", !0),
|
|
2989
|
+
v.retrievedMethods.isLoaded ? N("", !0) : (c(), M(Q, {
|
|
2972
2990
|
key: 2,
|
|
2973
2991
|
size: "xl"
|
|
2974
2992
|
})),
|
|
2975
|
-
|
|
2976
|
-
(c(!0),
|
|
2993
|
+
v.retrievedMethods.isError ? (c(), D("span", sn, T(u(o)("report.integration.biztory.error")), 1)) : N("", !0),
|
|
2994
|
+
(c(!0), D(L, null, H((F = (se = (ne = e.value) == null ? void 0 : ne.platform) == null ? void 0 : se.mappings) == null ? void 0 : F.paymentMethods, (p, U) => {
|
|
2977
2995
|
var O;
|
|
2978
|
-
return c(),
|
|
2996
|
+
return c(), D("div", {
|
|
2979
2997
|
key: `payment-${U}`,
|
|
2980
2998
|
class: "grid-cols-1 grid gap-x-16"
|
|
2981
2999
|
}, [
|
|
2982
|
-
|
|
3000
|
+
v.retrievedMethods.isLoaded && v.retrievedMethods.data && ((O = v.retrievedMethods.data) == null ? void 0 : O.length) != 0 ? (c(), D("div", rn, [
|
|
2983
3001
|
r(E, {
|
|
2984
3002
|
"model-value": !e.value.platform.mappings.paymentMethods[U].skip,
|
|
2985
3003
|
value: "",
|
|
@@ -2999,7 +3017,7 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
2999
3017
|
id: {
|
|
3000
3018
|
placeholder: "Select mapping",
|
|
3001
3019
|
editable: !0,
|
|
3002
|
-
dropdownOptions:
|
|
3020
|
+
dropdownOptions: v.retrievedMethods.data
|
|
3003
3021
|
}
|
|
3004
3022
|
},
|
|
3005
3023
|
removable: !0,
|
|
@@ -3014,9 +3032,9 @@ const et = { class: "flex flex-row items-center w-[100%] gap-[4px] justify-betwe
|
|
|
3014
3032
|
};
|
|
3015
3033
|
}
|
|
3016
3034
|
});
|
|
3017
|
-
function
|
|
3018
|
-
return
|
|
3019
|
-
var h, _, C, b, x, m, w, k, d, y, n,
|
|
3035
|
+
function cn(v) {
|
|
3036
|
+
return v.reduce((o, e) => {
|
|
3037
|
+
var h, _, C, b, x, m, w, k, d, y, n, g, $, a, l, f, i, P, A, Q, E, G;
|
|
3020
3038
|
const { invoice: s } = e, V = o.length;
|
|
3021
3039
|
o[V] = {
|
|
3022
3040
|
invoice_date: s.invoice_date,
|
|
@@ -3034,7 +3052,7 @@ function nn(f) {
|
|
|
3034
3052
|
payment_method: ((d = (k = s.transactions) == null ? void 0 : k[0]) == null ? void 0 : d.payment_method) || "-",
|
|
3035
3053
|
payment_term: ((y = s == null ? void 0 : s.payment_term) == null ? void 0 : y.name) || ""
|
|
3036
3054
|
};
|
|
3037
|
-
for (let R = 1; R < Math.max(((n = s.items) == null ? void 0 : n.length) || 0, ((
|
|
3055
|
+
for (let R = 1; R < Math.max(((n = s.items) == null ? void 0 : n.length) || 0, ((g = s.transactions) == null ? void 0 : g.length) || 0); R++) {
|
|
3038
3056
|
const j = V + R;
|
|
3039
3057
|
o[j] || (o[j] = {});
|
|
3040
3058
|
const z = s.items[R];
|
|
@@ -3045,11 +3063,11 @@ function nn(f) {
|
|
|
3045
3063
|
item_price: z.price,
|
|
3046
3064
|
item_tax: z.total_tax,
|
|
3047
3065
|
item_tax_label: z.tax_label || "-",
|
|
3048
|
-
payment_amount: ((
|
|
3049
|
-
payment_method: ((
|
|
3066
|
+
payment_amount: ((a = ($ = s.transactions) == null ? void 0 : $[R]) == null ? void 0 : a.amount) || void 0,
|
|
3067
|
+
payment_method: ((f = (l = s.transactions) == null ? void 0 : l[R]) == null ? void 0 : f.payment_method) || "-",
|
|
3050
3068
|
payment_term: ((i = s == null ? void 0 : s.payment_term) == null ? void 0 : i.name) || ""
|
|
3051
3069
|
} : o[j] = {
|
|
3052
|
-
payment_amount: ((
|
|
3070
|
+
payment_amount: ((A = (P = s.transactions) == null ? void 0 : P[R]) == null ? void 0 : A.amount) || void 0,
|
|
3053
3071
|
payment_method: ((E = (Q = s.transactions) == null ? void 0 : Q[R]) == null ? void 0 : E.payment_method) || "-",
|
|
3054
3072
|
payment_term: ((G = s == null ? void 0 : s.payment_term) == null ? void 0 : G.name) || ""
|
|
3055
3073
|
};
|
|
@@ -3057,7 +3075,7 @@ function nn(f) {
|
|
|
3057
3075
|
return o;
|
|
3058
3076
|
}, []);
|
|
3059
3077
|
}
|
|
3060
|
-
const
|
|
3078
|
+
const dn = [
|
|
3061
3079
|
{
|
|
3062
3080
|
accessorKey: "invoice_date",
|
|
3063
3081
|
header: () => I("p", { class: "min-w-[90px] text-nowrap text-ellipsis" }, "Date"),
|
|
@@ -3129,9 +3147,9 @@ const sn = [
|
|
|
3129
3147
|
enableSorting: !1
|
|
3130
3148
|
}
|
|
3131
3149
|
];
|
|
3132
|
-
function
|
|
3133
|
-
return
|
|
3134
|
-
var C, b, x, m, w, k, d, y, n,
|
|
3150
|
+
function pn(v) {
|
|
3151
|
+
return v.reduce((o, e) => {
|
|
3152
|
+
var C, b, x, m, w, k, d, y, n, g;
|
|
3135
3153
|
const { invoice: s, payments: V } = e, h = o.length;
|
|
3136
3154
|
o[h] = {
|
|
3137
3155
|
invoice_date: s.invoice_date,
|
|
@@ -3150,33 +3168,33 @@ function rn(f) {
|
|
|
3150
3168
|
};
|
|
3151
3169
|
const _ = Math.max(
|
|
3152
3170
|
((n = s.items) == null ? void 0 : n.length) || 0,
|
|
3153
|
-
((
|
|
3171
|
+
((g = s.terms) == null ? void 0 : g.length) || 0,
|
|
3154
3172
|
(V == null ? void 0 : V.length) || 0
|
|
3155
3173
|
);
|
|
3156
3174
|
for (let $ = 1; $ < _; $++) {
|
|
3157
|
-
const
|
|
3158
|
-
o[
|
|
3159
|
-
const
|
|
3160
|
-
|
|
3161
|
-
...o[
|
|
3162
|
-
item_code:
|
|
3163
|
-
item_description:
|
|
3164
|
-
item_price:
|
|
3165
|
-
item_tax_label:
|
|
3166
|
-
item_tax_amount:
|
|
3175
|
+
const a = h + $;
|
|
3176
|
+
o[a] || (o[a] = {});
|
|
3177
|
+
const l = s.items[$], f = s.terms[$], i = V[$];
|
|
3178
|
+
l ? o[a] = {
|
|
3179
|
+
...o[a],
|
|
3180
|
+
item_code: l.code,
|
|
3181
|
+
item_description: l.description,
|
|
3182
|
+
item_price: l.total,
|
|
3183
|
+
item_tax_label: l.tax_label == "?" ? "" : l.tax_label ?? "",
|
|
3184
|
+
item_tax_amount: l.total_tax ?? "",
|
|
3167
3185
|
payment_term_id: s.payment_term.name ?? "",
|
|
3168
|
-
payment_term_amount: (
|
|
3186
|
+
payment_term_amount: (f == null ? void 0 : f.amount) ?? "",
|
|
3169
3187
|
payment_method: (i == null ? void 0 : i.payment_method_name) || ""
|
|
3170
|
-
} : o[
|
|
3188
|
+
} : o[a] = {
|
|
3171
3189
|
payment_term_id: s.payment_term.name ?? "",
|
|
3172
|
-
payment_term_amount: (
|
|
3190
|
+
payment_term_amount: (f == null ? void 0 : f.amount) ?? "",
|
|
3173
3191
|
payment_method: (i == null ? void 0 : i.payment_method_name) || ""
|
|
3174
3192
|
};
|
|
3175
3193
|
}
|
|
3176
3194
|
return o;
|
|
3177
3195
|
}, []);
|
|
3178
3196
|
}
|
|
3179
|
-
const
|
|
3197
|
+
const un = [
|
|
3180
3198
|
{
|
|
3181
3199
|
accessorKey: "invoice_date",
|
|
3182
3200
|
header: () => I("p", { class: "min-w-[90px] text-nowrap text-ellipsis" }, "Date"),
|
|
@@ -3242,18 +3260,18 @@ const mn = [
|
|
|
3242
3260
|
header: () => I("p", { class: "min-w-[90px] text-nowrap text-ellipsis" }, "Payment Method (ID)"),
|
|
3243
3261
|
enableSorting: !1
|
|
3244
3262
|
}
|
|
3245
|
-
],
|
|
3263
|
+
], fn = { class: "h-full flex flex-col gap-16" }, vn = { class: "flex flex-row gap-2 justify-between items-center" }, gn = {
|
|
3246
3264
|
key: 0,
|
|
3247
3265
|
class: "flex gap-24 w-full h-full justify-center items-center overflow-scroll"
|
|
3248
|
-
},
|
|
3266
|
+
}, yn = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, xn = /* @__PURE__ */ q({
|
|
3249
3267
|
__name: "Preview",
|
|
3250
3268
|
props: {
|
|
3251
3269
|
modelValue: { required: !0 },
|
|
3252
3270
|
modelModifiers: {}
|
|
3253
3271
|
},
|
|
3254
3272
|
emits: ["update:modelValue"],
|
|
3255
|
-
setup(
|
|
3256
|
-
const { t: o } = J(), e = X(
|
|
3273
|
+
setup(v) {
|
|
3274
|
+
const { t: o } = J(), e = X(v, "modelValue"), s = B(!1), V = ue(), { dateRange: h } = De(pe()), _ = B([]);
|
|
3257
3275
|
ve(
|
|
3258
3276
|
() => h.value,
|
|
3259
3277
|
async () => {
|
|
@@ -3273,17 +3291,17 @@ const mn = [
|
|
|
3273
3291
|
const C = Y(() => {
|
|
3274
3292
|
switch (e.value.platform.mappings.version) {
|
|
3275
3293
|
case "v1":
|
|
3276
|
-
return
|
|
3294
|
+
return cn(_.value);
|
|
3277
3295
|
case "v2":
|
|
3278
|
-
return
|
|
3296
|
+
return pn(_.value);
|
|
3279
3297
|
}
|
|
3280
3298
|
return [];
|
|
3281
3299
|
}), b = Y(() => {
|
|
3282
3300
|
switch (e.value.platform.mappings.version) {
|
|
3283
3301
|
case "v1":
|
|
3284
|
-
return
|
|
3302
|
+
return dn;
|
|
3285
3303
|
case "v2":
|
|
3286
|
-
return
|
|
3304
|
+
return un;
|
|
3287
3305
|
}
|
|
3288
3306
|
return [];
|
|
3289
3307
|
});
|
|
@@ -3298,10 +3316,10 @@ const mn = [
|
|
|
3298
3316
|
}
|
|
3299
3317
|
return (m, w) => {
|
|
3300
3318
|
const k = S("FmButton"), d = S("FmCircularProgress"), y = S("FmTable");
|
|
3301
|
-
return c(),
|
|
3302
|
-
t("div",
|
|
3303
|
-
r(
|
|
3304
|
-
"date-range":
|
|
3319
|
+
return c(), D("div", fn, [
|
|
3320
|
+
t("div", vn, [
|
|
3321
|
+
r(Fe, {
|
|
3322
|
+
"date-range": u(h),
|
|
3305
3323
|
"onUpdate:dateRange": w[0] || (w[0] = (n) => we(h) ? h.value = n : null),
|
|
3306
3324
|
compare: !1
|
|
3307
3325
|
}, null, 8, ["date-range"]),
|
|
@@ -3312,9 +3330,9 @@ const mn = [
|
|
|
3312
3330
|
onClick: x
|
|
3313
3331
|
}, null, 8, ["loading"])
|
|
3314
3332
|
]),
|
|
3315
|
-
s.value ? (c(),
|
|
3333
|
+
s.value ? (c(), D("div", gn, [
|
|
3316
3334
|
r(d, { size: "xl" }),
|
|
3317
|
-
t("span",
|
|
3335
|
+
t("span", yn, T(u(o)("report.common.isLoading")), 1)
|
|
3318
3336
|
])) : (c(), M(y, {
|
|
3319
3337
|
key: 1,
|
|
3320
3338
|
class: "flex overflow-scroll",
|
|
@@ -3324,15 +3342,15 @@ const mn = [
|
|
|
3324
3342
|
]);
|
|
3325
3343
|
};
|
|
3326
3344
|
}
|
|
3327
|
-
}),
|
|
3345
|
+
}), _n = { class: "h-full relative flex flex-col" }, bn = { class: "py-16 px-16 overflow-hidden flex-grow relative" }, wn = /* @__PURE__ */ q({
|
|
3328
3346
|
__name: "Biztory",
|
|
3329
3347
|
props: {
|
|
3330
3348
|
modelValue: { required: !0 },
|
|
3331
3349
|
modelModifiers: {}
|
|
3332
3350
|
},
|
|
3333
3351
|
emits: ["update:modelValue"],
|
|
3334
|
-
setup(
|
|
3335
|
-
const { t: o } = J(), e = X(
|
|
3352
|
+
setup(v) {
|
|
3353
|
+
const { t: o } = J(), e = X(v, "modelValue"), s = B("setting"), V = [
|
|
3336
3354
|
{
|
|
3337
3355
|
label: o("report.integration.setting"),
|
|
3338
3356
|
value: "setting",
|
|
@@ -3347,11 +3365,11 @@ const mn = [
|
|
|
3347
3365
|
switch (s.value) {
|
|
3348
3366
|
case "preview":
|
|
3349
3367
|
return {
|
|
3350
|
-
component:
|
|
3368
|
+
component: xn
|
|
3351
3369
|
};
|
|
3352
3370
|
case "setting":
|
|
3353
3371
|
return {
|
|
3354
|
-
component:
|
|
3372
|
+
component: mn,
|
|
3355
3373
|
props: {
|
|
3356
3374
|
retrievedMethods: C.value,
|
|
3357
3375
|
retrievedCustomers: b.value
|
|
@@ -3360,18 +3378,18 @@ const mn = [
|
|
|
3360
3378
|
default:
|
|
3361
3379
|
return null;
|
|
3362
3380
|
}
|
|
3363
|
-
}), C = B({}), b = B({}), x = (y, n) => y.map((
|
|
3364
|
-
label: n.length > 2 ? `ID:${
|
|
3365
|
-
value:
|
|
3366
|
-
cnId:
|
|
3367
|
-
})), m = (y) => x(y, ["wallet", "name"]), w = (y) => x(y, ["id", "name"]), k = async (y, n,
|
|
3381
|
+
}), C = B({}), b = B({}), x = (y, n) => y.map((g) => ({
|
|
3382
|
+
label: n.length > 2 ? `ID:${g[n[2]]} [${g[n[0]]}] ${g[n[1]]}` : `[${g[n[0]]}] ${g[n[1]]}`,
|
|
3383
|
+
value: g.id,
|
|
3384
|
+
cnId: g.cnId ? g.cnId : null
|
|
3385
|
+
})), m = (y) => x(y, ["wallet", "name"]), w = (y) => x(y, ["id", "name"]), k = async (y, n, g, $) => {
|
|
3368
3386
|
try {
|
|
3369
|
-
const
|
|
3370
|
-
|
|
3371
|
-
} catch (
|
|
3372
|
-
console.error($,
|
|
3387
|
+
const a = await y(e.value._id);
|
|
3388
|
+
g.value.data = n(a);
|
|
3389
|
+
} catch (a) {
|
|
3390
|
+
console.error($, a), g.value.isError = !0;
|
|
3373
3391
|
} finally {
|
|
3374
|
-
|
|
3392
|
+
g.value.isLoaded = !0;
|
|
3375
3393
|
}
|
|
3376
3394
|
}, d = async () => {
|
|
3377
3395
|
var y, n;
|
|
@@ -3391,14 +3409,14 @@ const mn = [
|
|
|
3391
3409
|
var y;
|
|
3392
3410
|
return (y = e.value.platform.mappings) == null ? void 0 : y.version;
|
|
3393
3411
|
}, d), (y, n) => {
|
|
3394
|
-
var
|
|
3395
|
-
const
|
|
3396
|
-
return c(),
|
|
3397
|
-
r(
|
|
3398
|
-
title: ((
|
|
3412
|
+
var a, l, f;
|
|
3413
|
+
const g = S("FmPageHead"), $ = S("FmTabs");
|
|
3414
|
+
return c(), D("div", _n, [
|
|
3415
|
+
r(g, {
|
|
3416
|
+
title: ((a = e.value) == null ? void 0 : a.name) || "Biztory",
|
|
3399
3417
|
"back-button": !0,
|
|
3400
3418
|
style: { paddingLeft: "0px", paddingRight: "0px" },
|
|
3401
|
-
"onClick:back":
|
|
3419
|
+
"onClick:back": u(h).back
|
|
3402
3420
|
}, {
|
|
3403
3421
|
description: ge(() => n[2] || (n[2] = [
|
|
3404
3422
|
t("div", null, null, -1)
|
|
@@ -3410,27 +3428,27 @@ const mn = [
|
|
|
3410
3428
|
"onUpdate:modelValue": n[0] || (n[0] = (i) => s.value = i),
|
|
3411
3429
|
items: V
|
|
3412
3430
|
}, null, 8, ["model-value"]),
|
|
3413
|
-
t("div",
|
|
3414
|
-
(c(), M(xe((
|
|
3431
|
+
t("div", bn, [
|
|
3432
|
+
(c(), M(xe((l = _.value) == null ? void 0 : l.component), Ee({
|
|
3415
3433
|
modelValue: e.value,
|
|
3416
3434
|
"onUpdate:modelValue": n[1] || (n[1] = (i) => e.value = i)
|
|
3417
|
-
}, (
|
|
3435
|
+
}, (f = _.value) == null ? void 0 : f.props), null, 16, ["modelValue"]))
|
|
3418
3436
|
])
|
|
3419
3437
|
]);
|
|
3420
3438
|
};
|
|
3421
3439
|
}
|
|
3422
|
-
}),
|
|
3440
|
+
}), hn = {
|
|
3423
3441
|
key: 0,
|
|
3424
3442
|
class: "flex flex-col h-full"
|
|
3425
|
-
},
|
|
3443
|
+
}, Vn = { class: "flex flex-col gap-16 pb-[24px]" }, kn = { class: "flex flex-row justify-between items-center gap-2" }, $n = { class: "flex flex-row gap-2 items-center" }, Sn = { class: "relative group cursor-pointer" }, Cn = { class: "absolute left-1/2 -translate-x-2/3 top-full mt-2 w-max bg-gray-900 text-white text-sm px-2 py-1 rounded opacity-0 group-hover:opacity-100 transition-opacity" }, Dn = { class: "flex flex-col gap-24 pt-[24px] overflow-scroll" }, Fn = { class: "flex flex-col gap-16" }, Un = { class: "fm-typo-en-title-sm-800" }, Tn = { class: "flex flex-row items-center max-w-[100%]" }, In = { class: "w-[25%]" }, Mn = { class: "flex-grow" }, Kn = { class: "flex flex-row items-center max-w-[100%]" }, An = { class: "w-[25%]" }, Pn = { class: "flex flex-row items-center gap-x-16" }, Nn = { class: "fm-typo-en-title-sm-800" }, Rn = { class: "grid-cols-1 grid gap-16" }, On = /* @__PURE__ */ q({
|
|
3426
3444
|
__name: "Setting",
|
|
3427
3445
|
props: {
|
|
3428
3446
|
modelValue: { required: !0 },
|
|
3429
3447
|
modelModifiers: {}
|
|
3430
3448
|
},
|
|
3431
3449
|
emits: ["update:modelValue"],
|
|
3432
|
-
setup(
|
|
3433
|
-
const { t: o } = J(), e = X(
|
|
3450
|
+
setup(v) {
|
|
3451
|
+
const { t: o } = J(), e = X(v, "modelValue"), s = ue(), V = _e(), h = de(), { promptLoader: _ } = he(), { promptMessage: C } = Ce(), { restaurants: b } = pe(), x = Y(
|
|
3434
3452
|
() => b.map((n) => ({ label: n.name, value: n.id }))
|
|
3435
3453
|
);
|
|
3436
3454
|
async function m() {
|
|
@@ -3440,8 +3458,8 @@ const mn = [
|
|
|
3440
3458
|
}) && await _(async () => {
|
|
3441
3459
|
try {
|
|
3442
3460
|
await Ve(e.value._id), await V.getSettings(), h.back();
|
|
3443
|
-
} catch (
|
|
3444
|
-
s.open({ type: "error", message:
|
|
3461
|
+
} catch (g) {
|
|
3462
|
+
s.open({ type: "error", message: g.message });
|
|
3445
3463
|
}
|
|
3446
3464
|
});
|
|
3447
3465
|
}
|
|
@@ -3454,15 +3472,15 @@ const mn = [
|
|
|
3454
3472
|
}
|
|
3455
3473
|
});
|
|
3456
3474
|
}
|
|
3457
|
-
function k(n,
|
|
3458
|
-
var $,
|
|
3459
|
-
(
|
|
3460
|
-
(
|
|
3475
|
+
function k(n, g) {
|
|
3476
|
+
var $, a;
|
|
3477
|
+
(a = ($ = e.value.platform) == null ? void 0 : $.mappings) != null && a[n] && (e.value.platform.mappings[n] = e.value.platform.mappings[n].filter(
|
|
3478
|
+
(l, f) => f !== g
|
|
3461
3479
|
));
|
|
3462
3480
|
}
|
|
3463
3481
|
function d(n) {
|
|
3464
|
-
var
|
|
3465
|
-
($ = (
|
|
3482
|
+
var g, $;
|
|
3483
|
+
($ = (g = e.value.platform) == null ? void 0 : g.mappings) != null && $[n] && (e.value.platform.mappings[n] = [
|
|
3466
3484
|
...e.value.platform.mappings[n],
|
|
3467
3485
|
{
|
|
3468
3486
|
key: "",
|
|
@@ -3483,75 +3501,75 @@ const mn = [
|
|
|
3483
3501
|
}
|
|
3484
3502
|
return be(async () => {
|
|
3485
3503
|
await V.getSettings();
|
|
3486
|
-
}), (n,
|
|
3487
|
-
var
|
|
3488
|
-
const $ = S("FmIcon"),
|
|
3489
|
-
return (
|
|
3490
|
-
t("div",
|
|
3491
|
-
t("div",
|
|
3492
|
-
|
|
3493
|
-
t("div",
|
|
3494
|
-
t("div",
|
|
3504
|
+
}), (n, g) => {
|
|
3505
|
+
var P, A, Q, E, G;
|
|
3506
|
+
const $ = S("FmIcon"), a = S("FmButton"), l = S("FmMenuDivider"), f = S("FmTextField"), i = S("FmSelect");
|
|
3507
|
+
return (A = (P = e.value) == null ? void 0 : P.platform) != null && A.mappings ? (c(), D("div", hn, [
|
|
3508
|
+
t("div", Vn, [
|
|
3509
|
+
t("div", kn, [
|
|
3510
|
+
g[4] || (g[4] = t("div", { class: "fm-typo-en-title-sm-800" }, null, -1)),
|
|
3511
|
+
t("div", $n, [
|
|
3512
|
+
t("div", Sn, [
|
|
3495
3513
|
r($, {
|
|
3496
3514
|
name: "refresh",
|
|
3497
3515
|
class: "p-2 bg-gray-100 rounded-full",
|
|
3498
3516
|
onClick: y
|
|
3499
3517
|
}),
|
|
3500
|
-
t("span",
|
|
3518
|
+
t("span", Cn, T(u(o)("report.integration.refreshSetting")), 1)
|
|
3501
3519
|
]),
|
|
3502
|
-
r(
|
|
3520
|
+
r(a, {
|
|
3503
3521
|
variant: "tertiary",
|
|
3504
|
-
label:
|
|
3522
|
+
label: u(o)("report.common.delete"),
|
|
3505
3523
|
onClick: m
|
|
3506
3524
|
}, null, 8, ["label"]),
|
|
3507
|
-
r(
|
|
3525
|
+
r(a, {
|
|
3508
3526
|
variant: "primary",
|
|
3509
|
-
label:
|
|
3527
|
+
label: u(o)("report.common.update"),
|
|
3510
3528
|
onClick: w
|
|
3511
3529
|
}, null, 8, ["label"])
|
|
3512
3530
|
])
|
|
3513
3531
|
])
|
|
3514
3532
|
]),
|
|
3515
|
-
r(
|
|
3516
|
-
t("div",
|
|
3517
|
-
t("div",
|
|
3518
|
-
t("div",
|
|
3519
|
-
t("div",
|
|
3520
|
-
t("div",
|
|
3521
|
-
t("div",
|
|
3522
|
-
r(
|
|
3533
|
+
r(l, { style: { margin: 0 } }),
|
|
3534
|
+
t("div", Dn, [
|
|
3535
|
+
t("div", Fn, [
|
|
3536
|
+
t("div", Un, T(u(o)("report.integration.general")), 1),
|
|
3537
|
+
t("div", Tn, [
|
|
3538
|
+
t("div", In, T(u(o)("report.common.name")), 1),
|
|
3539
|
+
t("div", Mn, [
|
|
3540
|
+
r(f, {
|
|
3523
3541
|
modelValue: e.value.name,
|
|
3524
|
-
"onUpdate:modelValue":
|
|
3542
|
+
"onUpdate:modelValue": g[0] || (g[0] = (R) => e.value.name = R)
|
|
3525
3543
|
}, null, 8, ["modelValue"])
|
|
3526
3544
|
])
|
|
3527
3545
|
]),
|
|
3528
|
-
t("div",
|
|
3529
|
-
t("div",
|
|
3546
|
+
t("div", Kn, [
|
|
3547
|
+
t("div", An, T(u(o)("report.integration.location")), 1),
|
|
3530
3548
|
r(i, {
|
|
3531
3549
|
"model-value": e.value.platform.locationIds[0],
|
|
3532
3550
|
multiselect: !1,
|
|
3533
3551
|
items: x.value,
|
|
3534
3552
|
placeholder: "Select location",
|
|
3535
3553
|
class: "flex-grow",
|
|
3536
|
-
"onUpdate:modelValue":
|
|
3554
|
+
"onUpdate:modelValue": g[1] || (g[1] = (R) => e.value.platform.locationIds[0] = R)
|
|
3537
3555
|
}, null, 8, ["model-value", "items"])
|
|
3538
3556
|
])
|
|
3539
3557
|
]),
|
|
3540
3558
|
r(Ue, {
|
|
3541
3559
|
modelValue: e.value.platform,
|
|
3542
|
-
"onUpdate:modelValue":
|
|
3543
|
-
label:
|
|
3560
|
+
"onUpdate:modelValue": g[2] || (g[2] = (R) => e.value.platform = R),
|
|
3561
|
+
label: u(o)("report.input.email")
|
|
3544
3562
|
}, null, 8, ["modelValue", "label"]),
|
|
3545
|
-
t("div",
|
|
3546
|
-
t("div",
|
|
3547
|
-
r(
|
|
3563
|
+
t("div", Pn, [
|
|
3564
|
+
t("div", Nn, T(u(o)("report.integration.iflexiHrms.employee")), 1),
|
|
3565
|
+
r(a, {
|
|
3548
3566
|
variant: "primary",
|
|
3549
3567
|
icon: "add",
|
|
3550
|
-
onClick:
|
|
3568
|
+
onClick: g[3] || (g[3] = () => d("employees"))
|
|
3551
3569
|
})
|
|
3552
3570
|
]),
|
|
3553
|
-
t("div",
|
|
3554
|
-
(c(!0),
|
|
3571
|
+
t("div", Rn, [
|
|
3572
|
+
(c(!0), D(L, null, H((G = (E = (Q = e.value) == null ? void 0 : Q.platform) == null ? void 0 : E.mappings) == null ? void 0 : G.employees, (R, j) => (c(), M(K, {
|
|
3555
3573
|
key: `employee-${j}`,
|
|
3556
3574
|
modelValue: e.value.platform.mappings.employees[j],
|
|
3557
3575
|
"onUpdate:modelValue": (z) => e.value.platform.mappings.employees[j] = z,
|
|
@@ -3568,17 +3586,17 @@ const mn = [
|
|
|
3568
3586
|
])) : N("", !0);
|
|
3569
3587
|
};
|
|
3570
3588
|
}
|
|
3571
|
-
}),
|
|
3589
|
+
}), Bn = { class: "h-full flex flex-col gap-16" }, jn = { class: "flex flex-row gap-2 justify-between items-center" }, Ln = {
|
|
3572
3590
|
key: 0,
|
|
3573
3591
|
class: "flex gap-24 w-full h-full justify-center items-center overflow-scroll"
|
|
3574
|
-
},
|
|
3592
|
+
}, En = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, zn = /* @__PURE__ */ q({
|
|
3575
3593
|
__name: "Preview",
|
|
3576
3594
|
props: {
|
|
3577
3595
|
modelValue: { required: !0 },
|
|
3578
3596
|
modelModifiers: {}
|
|
3579
3597
|
},
|
|
3580
3598
|
emits: ["update:modelValue"],
|
|
3581
|
-
setup(
|
|
3599
|
+
setup(v) {
|
|
3582
3600
|
const { t: o } = J(), e = B([]), s = [
|
|
3583
3601
|
{
|
|
3584
3602
|
accessorKey: "name",
|
|
@@ -3605,7 +3623,7 @@ const mn = [
|
|
|
3605
3623
|
header: () => I("p", { class: "min-w-[90px] text-nowrap text-ellipsis" }, "Time"),
|
|
3606
3624
|
enableSorting: !1
|
|
3607
3625
|
}
|
|
3608
|
-
], V = X(
|
|
3626
|
+
], V = X(v, "modelValue"), h = B(!1), _ = ue(), { dateRange: C } = De(pe());
|
|
3609
3627
|
ve(
|
|
3610
3628
|
() => C.value,
|
|
3611
3629
|
async () => {
|
|
@@ -3633,23 +3651,23 @@ const mn = [
|
|
|
3633
3651
|
}
|
|
3634
3652
|
return (x, m) => {
|
|
3635
3653
|
const w = S("FmButton"), k = S("FmCircularProgress"), d = S("FmTable");
|
|
3636
|
-
return c(),
|
|
3637
|
-
t("div",
|
|
3638
|
-
r(
|
|
3639
|
-
"date-range":
|
|
3654
|
+
return c(), D("div", Bn, [
|
|
3655
|
+
t("div", jn, [
|
|
3656
|
+
r(Fe, {
|
|
3657
|
+
"date-range": u(C),
|
|
3640
3658
|
"onUpdate:dateRange": m[0] || (m[0] = (y) => we(C) ? C.value = y : null),
|
|
3641
3659
|
compare: !1
|
|
3642
3660
|
}, null, 8, ["date-range"]),
|
|
3643
3661
|
r(w, {
|
|
3644
3662
|
loading: h.value,
|
|
3645
3663
|
variant: "primary",
|
|
3646
|
-
label:
|
|
3664
|
+
label: u(o)("report.common.download"),
|
|
3647
3665
|
onClick: b
|
|
3648
3666
|
}, null, 8, ["loading", "label"])
|
|
3649
3667
|
]),
|
|
3650
|
-
h.value ? (c(),
|
|
3668
|
+
h.value ? (c(), D("div", Ln, [
|
|
3651
3669
|
r(k, { size: "xl" }),
|
|
3652
|
-
t("span",
|
|
3670
|
+
t("span", En, T(u(o)("report.common.isLoading")), 1)
|
|
3653
3671
|
])) : e.value.length > 0 ? (c(), M(d, {
|
|
3654
3672
|
key: 1,
|
|
3655
3673
|
class: "flex overflow-scroll",
|
|
@@ -3659,15 +3677,15 @@ const mn = [
|
|
|
3659
3677
|
]);
|
|
3660
3678
|
};
|
|
3661
3679
|
}
|
|
3662
|
-
}),
|
|
3680
|
+
}), Yn = { class: "h-full relative flex flex-col" }, qn = { class: "py-16 px-16 overflow-hidden flex-grow relative" }, Hn = /* @__PURE__ */ q({
|
|
3663
3681
|
__name: "IFlexiHRMS",
|
|
3664
3682
|
props: {
|
|
3665
3683
|
modelValue: {},
|
|
3666
3684
|
modelModifiers: {}
|
|
3667
3685
|
},
|
|
3668
3686
|
emits: ["update:modelValue"],
|
|
3669
|
-
setup(
|
|
3670
|
-
const { t: o } = J(), e = X(
|
|
3687
|
+
setup(v) {
|
|
3688
|
+
const { t: o } = J(), e = X(v, "modelValue"), s = B("setting"), V = [
|
|
3671
3689
|
{
|
|
3672
3690
|
label: o("report.integration.setting"),
|
|
3673
3691
|
value: "setting",
|
|
@@ -3681,9 +3699,9 @@ const mn = [
|
|
|
3681
3699
|
], h = de(), _ = Y(() => {
|
|
3682
3700
|
switch (s.value) {
|
|
3683
3701
|
case "preview":
|
|
3684
|
-
return
|
|
3702
|
+
return zn;
|
|
3685
3703
|
case "setting":
|
|
3686
|
-
return
|
|
3704
|
+
return On;
|
|
3687
3705
|
default:
|
|
3688
3706
|
return null;
|
|
3689
3707
|
}
|
|
@@ -3691,12 +3709,12 @@ const mn = [
|
|
|
3691
3709
|
return (C, b) => {
|
|
3692
3710
|
var w;
|
|
3693
3711
|
const x = S("FmPageHead"), m = S("FmTabs");
|
|
3694
|
-
return c(),
|
|
3712
|
+
return c(), D("div", Yn, [
|
|
3695
3713
|
r(x, {
|
|
3696
3714
|
title: ((w = e.value) == null ? void 0 : w.name) || "AutoCount",
|
|
3697
3715
|
"back-button": !0,
|
|
3698
3716
|
style: { paddingLeft: "0px", paddingRight: "0px" },
|
|
3699
|
-
"onClick:back":
|
|
3717
|
+
"onClick:back": u(h).back
|
|
3700
3718
|
}, {
|
|
3701
3719
|
description: ge(() => b[2] || (b[2] = [
|
|
3702
3720
|
t("div", null, null, -1)
|
|
@@ -3708,7 +3726,7 @@ const mn = [
|
|
|
3708
3726
|
"onUpdate:modelValue": b[0] || (b[0] = (k) => s.value = k),
|
|
3709
3727
|
items: V
|
|
3710
3728
|
}, null, 8, ["model-value"]),
|
|
3711
|
-
t("div",
|
|
3729
|
+
t("div", qn, [
|
|
3712
3730
|
(c(), M(xe(_.value), {
|
|
3713
3731
|
modelValue: e.value,
|
|
3714
3732
|
"onUpdate:modelValue": b[1] || (b[1] = (k) => e.value = k)
|
|
@@ -3717,9 +3735,9 @@ const mn = [
|
|
|
3717
3735
|
]);
|
|
3718
3736
|
};
|
|
3719
3737
|
}
|
|
3720
|
-
}),
|
|
3738
|
+
}), Xn = { class: "px-24 h-full relative" }, as = /* @__PURE__ */ q({
|
|
3721
3739
|
__name: "Integration",
|
|
3722
|
-
setup(
|
|
3740
|
+
setup(v) {
|
|
3723
3741
|
const o = B(void 0), { params: e } = Ye(), s = _e(), V = B();
|
|
3724
3742
|
ze(async () => {
|
|
3725
3743
|
s.settings.length === 0 && await s.getSettings();
|
|
@@ -3743,14 +3761,14 @@ const mn = [
|
|
|
3743
3761
|
case ce.SQL:
|
|
3744
3762
|
return cl;
|
|
3745
3763
|
case ce.iFlexi_HRMS:
|
|
3746
|
-
return
|
|
3764
|
+
return Hn;
|
|
3747
3765
|
case ce.Biztory:
|
|
3748
|
-
return
|
|
3766
|
+
return wn;
|
|
3749
3767
|
default:
|
|
3750
3768
|
return null;
|
|
3751
3769
|
}
|
|
3752
3770
|
});
|
|
3753
|
-
return (_, C) => (c(),
|
|
3771
|
+
return (_, C) => (c(), D("div", Xn, [
|
|
3754
3772
|
(c(), M(xe(h.value), {
|
|
3755
3773
|
modelValue: V.value,
|
|
3756
3774
|
"onUpdate:modelValue": C[0] || (C[0] = (b) => V.value = b)
|
|
@@ -3759,5 +3777,5 @@ const mn = [
|
|
|
3759
3777
|
}
|
|
3760
3778
|
});
|
|
3761
3779
|
export {
|
|
3762
|
-
|
|
3780
|
+
as as default
|
|
3763
3781
|
};
|