@feedmepos/mf-payment 1.5.32-dev → 1.5.33-dev
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{Actions.vue_vue_type_script_setup_true_lang-BMLg-uol.js → Actions.vue_vue_type_script_setup_true_lang-CWl5TjGX.js} +1 -1
- package/dist/{Chargeback-BkVFinyh.js → Chargeback-BGXLNd-w.js} +5 -5
- package/dist/{DocumentViewer.vue_vue_type_script_setup_true_lang-3pmwclcO.js → DocumentViewer.vue_vue_type_script_setup_true_lang-DVL3Tlwu.js} +1 -1
- package/dist/{OnboardForm-Bi1kSVys.js → OnboardForm-2C1LeXFJ.js} +5 -5
- package/dist/{OnboardForm-CPhzV7E6.js → OnboardForm-BYfjLNbu.js} +5 -5
- package/dist/{OnboardSubmission-B24Jb79p.js → OnboardSubmission-ChwyUxSB.js} +2 -2
- package/dist/{OnboardSubmission-O5wr2kLB.js → OnboardSubmission-CuK2dw8O.js} +5 -5
- package/dist/{PayoutAccount-CSx4qgd8.js → PayoutAccount-BFLTTf65.js} +4 -4
- package/dist/{PayoutAccount-Ejyj7kdu.js → PayoutAccount-C4DGIORU.js} +5 -5
- package/dist/{PayoutAccountSetting-BJljfdwp.js → PayoutAccountSetting-B2xwRNVI.js} +4 -4
- package/dist/{Restaurant-DN2_DdKR.js → Restaurant-uaKyfVHa.js} +4 -4
- package/dist/{RestaurantSetting-f0T5REdJ.js → RestaurantSetting-u3gPnAi3.js} +3 -3
- package/dist/{Settlement-DJ6ETp2U.js → Settlement-8aKO0XlN.js} +3 -3
- package/dist/Settlement-DYMTw2xR.js +610 -0
- package/dist/{SettlementTransactions-DF2ybUos.js → SettlementTransactions-CgLmSBeK.js} +4 -4
- package/dist/{SettlementTransactions-cYUYH2RJ.js → SettlementTransactions-Dy_c3e55.js} +23 -19
- package/dist/{Status.vue_vue_type_script_setup_true_lang-B41rO8q8.js → Status.vue_vue_type_script_setup_true_lang-91BuHsLC.js} +1 -1
- package/dist/{Terminal-DuGHgfMp.js → Terminal-C9XlK0gi.js} +5 -5
- package/dist/{TerminalSetting-iXqUzSSo.js → TerminalSetting-CPMJTKR8.js} +3 -3
- package/dist/Transaction-J4EbMhb-.js +482 -0
- package/dist/{Transaction-CWFcreph.js → Transaction-YZryhRiu.js} +5 -5
- package/dist/{TransactionOld-DttRuS3v.js → TransactionOld-DRA-jAKQ.js} +6 -6
- package/dist/api/settlement/index.d.ts +10 -4
- package/dist/api/transaction/index.d.ts +1 -1
- package/dist/{app-CcfX4_sO.js → app-wX6XYVw4.js} +23 -23
- package/dist/app.js +1 -1
- package/dist/{assets-gWQvONT9.js → assets-im1V-t7Q.js} +1 -1
- package/dist/components/SettlementSelector.vue.d.ts +12 -0
- package/dist/components/SourceSelector.vue.d.ts +2 -0
- package/dist/{grafana-VY3mqepx.js → grafana-DxtD1PVA.js} +1 -1
- package/dist/{index-BcmesiC4.js → index-1hOLckXe.js} +21 -19
- package/dist/{index-Q0ELb0wB.js → index-BAR0oK1p.js} +1 -1
- package/dist/{index-DhYZ6Ghe.js → index-C7qDYSTa.js} +2 -2
- package/dist/{index-DGqWjywh.js → index-CCD_GxfC.js} +1 -1
- package/dist/{index-T2CVm7-_.js → index-CV3NoDGL.js} +5445 -5437
- package/dist/{index-CscYwjzM.js → index-Dqz_cMKc.js} +1 -1
- package/dist/{index-BRhAeH7J.js → index-DyHgJMgm.js} +13 -7
- package/dist/{index-BGIv1us6.js → index-cnWXAOZL.js} +1 -1
- package/dist/{index-Dq4IAN2N.js → index-sVmXR_uy.js} +1 -1
- package/dist/{index.vue_vue_type_script_setup_true_lang-CkzD8rQP.js → index.vue_vue_type_script_setup_true_lang-BLlCp9H7.js} +1 -1
- package/dist/package.json +2 -2
- package/dist/{payout-account-n3WZh5PV.js → payout-account-B5umMzLY.js} +3 -3
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/dist/Settlement-SoOQIN8y.js +0 -490
- package/dist/Transaction-i64HFmDS.js +0 -477
package/package.json
CHANGED
|
@@ -1,490 +0,0 @@
|
|
|
1
|
-
import { defineComponent as C, resolveComponent as w, openBlock as V, createBlock as $, ref as x, computed as T, createElementBlock as I, Fragment as B, unref as e, withDirectives as q, vShow as z, createCommentVNode as M, createVNode as i, h as N, watch as P, createElementVNode as m, withCtx as k, toDisplayString as c, createTextVNode as h, onMounted as E, isRef as R } from "vue";
|
|
2
|
-
import { u as H } from "./index-T2CVm7-_.js";
|
|
3
|
-
import { h as S } from "./moment-h96o7c8I.js";
|
|
4
|
-
import { useCoreStore as O, useI18n as K } from "@feedmepos/mf-common";
|
|
5
|
-
import { _ as L } from "./Layout.vue_vue_type_script_setup_true_lang-BKIvkgA_.js";
|
|
6
|
-
import { s as A } from "./index-BcmesiC4.js";
|
|
7
|
-
import { useDialog as J } from "@feedmepos/ui-library";
|
|
8
|
-
import { d as f } from "./dinero-CIVmXLL-.js";
|
|
9
|
-
import { _ as j } from "./AutoCopyCell.vue_vue_type_script_setup_true_lang-DrBLdVka.js";
|
|
10
|
-
import { useRouter as Q } from "vue-router";
|
|
11
|
-
import { u as W } from "./index-Q0ELb0wB.js";
|
|
12
|
-
import { _ as G } from "./AsyncButton.vue_vue_type_script_setup_true_lang-DcjzvYwT.js";
|
|
13
|
-
import { _ as X } from "./RestaurantSelector.vue_vue_type_script_setup_true_lang-DG3iyjkK.js";
|
|
14
|
-
import { _ as Z } from "./DateRangePicker.vue_vue_type_script_setup_true_lang-kymnzYpd.js";
|
|
15
|
-
const ee = /* @__PURE__ */ C({
|
|
16
|
-
__name: "InvoiceStatus",
|
|
17
|
-
props: {
|
|
18
|
-
data: {}
|
|
19
|
-
},
|
|
20
|
-
setup(p) {
|
|
21
|
-
const t = p;
|
|
22
|
-
function u() {
|
|
23
|
-
return t.data && t.data !== "" ? "#66BB6A" : "#EF5350";
|
|
24
|
-
}
|
|
25
|
-
function l() {
|
|
26
|
-
return t.data && t.data !== "" ? "check" : "close";
|
|
27
|
-
}
|
|
28
|
-
return (s, g) => {
|
|
29
|
-
const _ = w("FmIcon");
|
|
30
|
-
return V(), $(_, {
|
|
31
|
-
name: l(),
|
|
32
|
-
color: u(),
|
|
33
|
-
size: "lg"
|
|
34
|
-
}, null, 8, ["name", "color"]);
|
|
35
|
-
};
|
|
36
|
-
}
|
|
37
|
-
}), te = /* @__PURE__ */ C({
|
|
38
|
-
__name: "SettlementTable",
|
|
39
|
-
props: {
|
|
40
|
-
data: {
|
|
41
|
-
type: Array,
|
|
42
|
-
required: !0
|
|
43
|
-
},
|
|
44
|
-
loading: {
|
|
45
|
-
type: Boolean,
|
|
46
|
-
required: !0
|
|
47
|
-
}
|
|
48
|
-
},
|
|
49
|
-
emits: ["row-click"],
|
|
50
|
-
setup(p, { emit: t }) {
|
|
51
|
-
const { currentCountry: u, namespace: l } = O(), { t: s } = K(), g = x(!0), _ = p, F = t, r = x(""), a = [
|
|
52
|
-
{
|
|
53
|
-
header: () => s("payment.settlements.table.id"),
|
|
54
|
-
accessorKey: "id",
|
|
55
|
-
cell: ({ cell: o }) => N(j, { data: o.getValue() })
|
|
56
|
-
},
|
|
57
|
-
{
|
|
58
|
-
header: () => s("payment.settlements.table.bank"),
|
|
59
|
-
accessorKey: "bank"
|
|
60
|
-
},
|
|
61
|
-
{
|
|
62
|
-
header: () => s("payment.settlements.table.account"),
|
|
63
|
-
accessorKey: "accountNo"
|
|
64
|
-
},
|
|
65
|
-
{
|
|
66
|
-
header: () => s("payment.settlements.table.created_at"),
|
|
67
|
-
accessorKey: "transactionAt",
|
|
68
|
-
meta: {
|
|
69
|
-
width: "180px"
|
|
70
|
-
}
|
|
71
|
-
},
|
|
72
|
-
{
|
|
73
|
-
header: () => s("payment.settlements.table.sales_amount"),
|
|
74
|
-
accessorKey: "amount"
|
|
75
|
-
},
|
|
76
|
-
{
|
|
77
|
-
header: () => s("payment.settlements.table.fee"),
|
|
78
|
-
accessorKey: "fee"
|
|
79
|
-
},
|
|
80
|
-
{
|
|
81
|
-
header: () => s("payment.settlements.table.settlement_amount"),
|
|
82
|
-
accessorKey: "payout"
|
|
83
|
-
},
|
|
84
|
-
{
|
|
85
|
-
header: () => s("payment.settlements.table.invoice_status"),
|
|
86
|
-
accessorKey: "invoiceId",
|
|
87
|
-
cell: ({ cell: o }) => N(ee, { data: o.getValue() })
|
|
88
|
-
}
|
|
89
|
-
], n = T(() => _.data.map((o) => ({
|
|
90
|
-
id: o._id,
|
|
91
|
-
bank: o.beneficiaryBank.name,
|
|
92
|
-
accountNo: o.beneficiaryBank.accountNumber,
|
|
93
|
-
transactionAt: S(o.createdAt).format("YYYY-MM-DD"),
|
|
94
|
-
amount: f(o.totalAmount).toFormat("$0.00"),
|
|
95
|
-
fee: f(o.totalFee).toFormat("$0.00"),
|
|
96
|
-
payout: f(o.totalPayout).toFormat("$0.00"),
|
|
97
|
-
invoiceId: o.invoiceId
|
|
98
|
-
}))), y = () => {
|
|
99
|
-
let o = "https://license.feedme.cc/invoices";
|
|
100
|
-
l.value === "dev" && (o = "https://license.feedmedev.cc/invoices"), open(o, "_blank");
|
|
101
|
-
};
|
|
102
|
-
return (o, b) => {
|
|
103
|
-
const D = w("FmSnackbar"), v = w("FmTable");
|
|
104
|
-
return V(), I(B, null, [
|
|
105
|
-
e(u) === "MY" ? q((V(), $(D, {
|
|
106
|
-
key: 0,
|
|
107
|
-
class: "mb-10",
|
|
108
|
-
title: e(s)("payment.settlements.invoice.title"),
|
|
109
|
-
description: e(s)("payment.settlements.invoice.description"),
|
|
110
|
-
action: e(s)("payment.settlements.invoice.action"),
|
|
111
|
-
variant: "info",
|
|
112
|
-
dismissable: "",
|
|
113
|
-
onOnDismiss: b[0] || (b[0] = (d) => g.value = !1),
|
|
114
|
-
onOnAction: y
|
|
115
|
-
}, null, 8, ["title", "description", "action"])), [
|
|
116
|
-
[z, g.value]
|
|
117
|
-
]) : M("", !0),
|
|
118
|
-
i(v, {
|
|
119
|
-
modelValue: r.value,
|
|
120
|
-
"onUpdate:modelValue": b[1] || (b[1] = (d) => r.value = d),
|
|
121
|
-
"row-data": n.value,
|
|
122
|
-
"shrink-at": !1,
|
|
123
|
-
"column-defs": a,
|
|
124
|
-
loading: _.loading,
|
|
125
|
-
onRowClick: b[2] || (b[2] = (d) => F("row-click", _.data.at(d.index)))
|
|
126
|
-
}, null, 8, ["modelValue", "row-data", "loading"])
|
|
127
|
-
], 64);
|
|
128
|
-
};
|
|
129
|
-
}
|
|
130
|
-
}), ae = /* @__PURE__ */ C({
|
|
131
|
-
__name: "FiuuSettlementTable",
|
|
132
|
-
props: {
|
|
133
|
-
data: {
|
|
134
|
-
type: Array,
|
|
135
|
-
required: !0
|
|
136
|
-
},
|
|
137
|
-
loading: {
|
|
138
|
-
type: Boolean,
|
|
139
|
-
required: !0
|
|
140
|
-
}
|
|
141
|
-
},
|
|
142
|
-
emits: ["row-click"],
|
|
143
|
-
setup(p, { emit: t }) {
|
|
144
|
-
const { t: u } = K(), l = p, s = t, g = x(""), _ = [
|
|
145
|
-
{
|
|
146
|
-
header: () => u("payment.settlements.table.id"),
|
|
147
|
-
accessorKey: "id",
|
|
148
|
-
cell: ({ cell: r }) => N(j, { data: r.getValue() })
|
|
149
|
-
},
|
|
150
|
-
{
|
|
151
|
-
header: () => u("payment.settlements.table.bank"),
|
|
152
|
-
accessorKey: "bank"
|
|
153
|
-
},
|
|
154
|
-
{
|
|
155
|
-
header: () => u("payment.settlements.table.account"),
|
|
156
|
-
accessorKey: "accountNo"
|
|
157
|
-
},
|
|
158
|
-
{
|
|
159
|
-
header: () => u("payment.settlements.table.created_at"),
|
|
160
|
-
accessorKey: "transactionAt",
|
|
161
|
-
meta: {
|
|
162
|
-
width: "180px"
|
|
163
|
-
}
|
|
164
|
-
},
|
|
165
|
-
{
|
|
166
|
-
header: () => u("payment.settlements.table.sales_amount"),
|
|
167
|
-
accessorKey: "amount"
|
|
168
|
-
},
|
|
169
|
-
{
|
|
170
|
-
header: () => u("payment.settlements.table.fee"),
|
|
171
|
-
accessorKey: "fee"
|
|
172
|
-
},
|
|
173
|
-
{
|
|
174
|
-
header: () => u("payment.settlements.table.settlement_amount"),
|
|
175
|
-
accessorKey: "payout"
|
|
176
|
-
}
|
|
177
|
-
], F = T(() => l.data.map((r) => ({
|
|
178
|
-
id: r.summary.referenceNo,
|
|
179
|
-
bank: r.summary.bank.name,
|
|
180
|
-
accountNo: r.summary.bank.accountNo,
|
|
181
|
-
transactionAt: S(r.summary.completedAt).format("YYYY-MM-DD"),
|
|
182
|
-
amount: f(r.summary.amount).toFormat("$0.00"),
|
|
183
|
-
fee: f(r.summary.commission).toFormat("$0.00"),
|
|
184
|
-
payout: f(r.summary.payout).toFormat("$0.00")
|
|
185
|
-
})));
|
|
186
|
-
return (r, a) => {
|
|
187
|
-
const n = w("FmTable");
|
|
188
|
-
return V(), $(n, {
|
|
189
|
-
modelValue: g.value,
|
|
190
|
-
"onUpdate:modelValue": a[0] || (a[0] = (y) => g.value = y),
|
|
191
|
-
"row-data": F.value,
|
|
192
|
-
"shrink-at": !1,
|
|
193
|
-
"column-defs": _,
|
|
194
|
-
loading: l.loading,
|
|
195
|
-
onRowClick: a[1] || (a[1] = (y) => s("row-click", l.data.at(y.index)))
|
|
196
|
-
}, null, 8, ["modelValue", "row-data", "loading"]);
|
|
197
|
-
};
|
|
198
|
-
}
|
|
199
|
-
}), ne = {
|
|
200
|
-
id: "fiuu-settlement-dialog",
|
|
201
|
-
class: "flex mb-6"
|
|
202
|
-
}, oe = { class: "my-6 w-[240px]" }, le = /* @__PURE__ */ C({
|
|
203
|
-
__name: "FiuuSettlementTransactions",
|
|
204
|
-
props: {
|
|
205
|
-
settlement: {
|
|
206
|
-
type: Object,
|
|
207
|
-
required: !0
|
|
208
|
-
}
|
|
209
|
-
},
|
|
210
|
-
setup(p) {
|
|
211
|
-
const { t } = K(), l = x(
|
|
212
|
-
p.settlement.record.map((a) => (Object.assign(a, {
|
|
213
|
-
__localAmount: f(a.amount).toFormat("0.00"),
|
|
214
|
-
__localComission: f(a.commission).toFormat("0.00"),
|
|
215
|
-
__localNetAMount: f(a.netAmount).toFormat("0.00")
|
|
216
|
-
}), a))
|
|
217
|
-
), s = x(l.value), g = x(""), _ = [
|
|
218
|
-
{
|
|
219
|
-
header: () => t("payment.settlements.dialog.fiuu.id"),
|
|
220
|
-
accessorKey: "referenceNo"
|
|
221
|
-
},
|
|
222
|
-
{
|
|
223
|
-
header: () => t("payment.settlements.dialog.fiuu.type"),
|
|
224
|
-
accessorKey: "group"
|
|
225
|
-
},
|
|
226
|
-
{
|
|
227
|
-
header: () => t("payment.settlements.dialog.fiuu.transaction_at"),
|
|
228
|
-
accessorKey: "completedAt",
|
|
229
|
-
meta: {
|
|
230
|
-
width: "180px"
|
|
231
|
-
},
|
|
232
|
-
cell: ({ cell: a }) => S(a.getValue()).format("YYYY-MM-DD HH:mm:ss")
|
|
233
|
-
},
|
|
234
|
-
{
|
|
235
|
-
header: () => t("payment.settlements.dialog.fiuu.sales_amount"),
|
|
236
|
-
accessorKey: "amount",
|
|
237
|
-
cell: ({ cell: a }) => f(a.getValue()).toFormat("$0.00")
|
|
238
|
-
},
|
|
239
|
-
{
|
|
240
|
-
header: () => t("payment.settlements.dialog.fiuu.fee"),
|
|
241
|
-
accessorKey: "commission",
|
|
242
|
-
cell: ({ cell: a }) => f(a.getValue()).toFormat("$0.00")
|
|
243
|
-
},
|
|
244
|
-
{
|
|
245
|
-
header: () => t("payment.settlements.dialog.fiuu.settlement_amount"),
|
|
246
|
-
accessorKey: "netAmount",
|
|
247
|
-
cell: ({ cell: a }) => f(a.getValue()).toFormat("$0.00")
|
|
248
|
-
}
|
|
249
|
-
], F = x("");
|
|
250
|
-
let r;
|
|
251
|
-
return P(F, async () => {
|
|
252
|
-
r && clearTimeout(r), r = setTimeout(() => {
|
|
253
|
-
var a = new RegExp(F.value, "i");
|
|
254
|
-
s.value = l.value.filter((n) => {
|
|
255
|
-
const y = JSON.stringify(n);
|
|
256
|
-
return a.test(y);
|
|
257
|
-
});
|
|
258
|
-
}, 700);
|
|
259
|
-
}), (a, n) => {
|
|
260
|
-
const y = w("FmCardHeader"), o = w("FmCardSection"), b = w("FmCard"), D = w("FmSearch"), v = w("FmTable");
|
|
261
|
-
return V(), I(B, null, [
|
|
262
|
-
m("div", ne, [
|
|
263
|
-
i(b, {
|
|
264
|
-
horizontal: "",
|
|
265
|
-
class: "flex-1 p-6",
|
|
266
|
-
variant: "elevated"
|
|
267
|
-
}, {
|
|
268
|
-
default: k(() => [
|
|
269
|
-
i(o, { class: "flex flex-col gap-16 justify-between" }, {
|
|
270
|
-
default: k(() => [
|
|
271
|
-
i(y, {
|
|
272
|
-
class: "p-0",
|
|
273
|
-
title: e(t)("payment.settlements.dialog.info.transaction.title"),
|
|
274
|
-
subtitle: ""
|
|
275
|
-
}, null, 8, ["title"]),
|
|
276
|
-
i(o, { class: "p-0" }, {
|
|
277
|
-
default: k(() => [
|
|
278
|
-
m("b", null, c(e(t)("payment.settlements.dialog.info.transaction.for")), 1),
|
|
279
|
-
h(": " + c(p.settlement.summary.group) + " ", 1),
|
|
280
|
-
n[2] || (n[2] = m("br", null, null, -1)),
|
|
281
|
-
m("b", null, c(e(t)("payment.settlements.dialog.info.transaction.reference")), 1),
|
|
282
|
-
h(": " + c(p.settlement.summary.referenceNo), 1),
|
|
283
|
-
n[3] || (n[3] = m("br", null, null, -1)),
|
|
284
|
-
m("b", null, c(e(t)("payment.settlements.dialog.info.transaction.count")), 1),
|
|
285
|
-
h(": " + c(l.value.length), 1)
|
|
286
|
-
]),
|
|
287
|
-
_: 1
|
|
288
|
-
})
|
|
289
|
-
]),
|
|
290
|
-
_: 1
|
|
291
|
-
})
|
|
292
|
-
]),
|
|
293
|
-
_: 1
|
|
294
|
-
}),
|
|
295
|
-
i(b, {
|
|
296
|
-
horizontal: "",
|
|
297
|
-
class: "flex-1 p-6 mx-6",
|
|
298
|
-
variant: "elevated"
|
|
299
|
-
}, {
|
|
300
|
-
default: k(() => [
|
|
301
|
-
i(o, { class: "flex flex-col gap-16 justify-between" }, {
|
|
302
|
-
default: k(() => [
|
|
303
|
-
i(y, {
|
|
304
|
-
class: "p-0",
|
|
305
|
-
title: e(t)("payment.settlements.dialog.info.bank.title"),
|
|
306
|
-
subtitle: ""
|
|
307
|
-
}, null, 8, ["title"]),
|
|
308
|
-
i(o, { class: "p-0" }, {
|
|
309
|
-
default: k(() => [
|
|
310
|
-
m("b", null, c(e(t)("payment.settlements.dialog.info.bank.for")), 1),
|
|
311
|
-
h(": " + c(p.settlement.summary.bank.name), 1),
|
|
312
|
-
n[4] || (n[4] = m("br", null, null, -1)),
|
|
313
|
-
m("b", null, c(e(t)("payment.settlements.dialog.info.bank.name")), 1),
|
|
314
|
-
h(": " + c(p.settlement.summary.bank.holderName), 1),
|
|
315
|
-
n[5] || (n[5] = m("br", null, null, -1)),
|
|
316
|
-
m("b", null, c(e(t)("payment.settlements.dialog.info.bank.number")), 1),
|
|
317
|
-
h(": " + c(p.settlement.summary.bank.accountNo), 1)
|
|
318
|
-
]),
|
|
319
|
-
_: 1
|
|
320
|
-
})
|
|
321
|
-
]),
|
|
322
|
-
_: 1
|
|
323
|
-
})
|
|
324
|
-
]),
|
|
325
|
-
_: 1
|
|
326
|
-
}),
|
|
327
|
-
i(b, {
|
|
328
|
-
horizontal: "",
|
|
329
|
-
class: "flex-1 p-6",
|
|
330
|
-
variant: "elevated"
|
|
331
|
-
}, {
|
|
332
|
-
default: k(() => [
|
|
333
|
-
i(o, { class: "flex flex-col gap-16 justify-between" }, {
|
|
334
|
-
default: k(() => [
|
|
335
|
-
i(y, {
|
|
336
|
-
class: "p-0",
|
|
337
|
-
title: e(t)("payment.settlements.dialog.info.payout.title"),
|
|
338
|
-
subtitle: ""
|
|
339
|
-
}, null, 8, ["title"]),
|
|
340
|
-
i(o, { class: "p-0" }, {
|
|
341
|
-
default: k(() => [
|
|
342
|
-
m("b", null, c(e(t)("payment.settlements.dialog.info.payout.amount")), 1),
|
|
343
|
-
h(": " + c(e(f)(p.settlement.summary.amount).toFormat("$0.00")), 1),
|
|
344
|
-
n[6] || (n[6] = m("br", null, null, -1)),
|
|
345
|
-
m("b", null, c(e(t)("payment.settlements.dialog.info.payout.fee")), 1),
|
|
346
|
-
h(": " + c(e(f)(p.settlement.summary.commission).toFormat("$0.00")), 1),
|
|
347
|
-
n[7] || (n[7] = m("br", null, null, -1)),
|
|
348
|
-
m("b", null, c(e(t)("payment.settlements.dialog.info.payout.payout")), 1),
|
|
349
|
-
h(": " + c(e(f)(p.settlement.summary.payout).toFormat("$0.00")), 1)
|
|
350
|
-
]),
|
|
351
|
-
_: 1
|
|
352
|
-
})
|
|
353
|
-
]),
|
|
354
|
-
_: 1
|
|
355
|
-
})
|
|
356
|
-
]),
|
|
357
|
-
_: 1
|
|
358
|
-
})
|
|
359
|
-
]),
|
|
360
|
-
m("div", oe, [
|
|
361
|
-
i(D, {
|
|
362
|
-
modelValue: F.value,
|
|
363
|
-
"onUpdate:modelValue": n[0] || (n[0] = (d) => F.value = d),
|
|
364
|
-
placeholder: e(t)("payment.settlements.dialog.search")
|
|
365
|
-
}, null, 8, ["modelValue", "placeholder"])
|
|
366
|
-
]),
|
|
367
|
-
i(v, {
|
|
368
|
-
modelValue: g.value,
|
|
369
|
-
"onUpdate:modelValue": n[1] || (n[1] = (d) => g.value = d),
|
|
370
|
-
"shrink-at": !1,
|
|
371
|
-
"row-data": s.value,
|
|
372
|
-
"column-defs": _
|
|
373
|
-
}, null, 8, ["modelValue", "row-data"])
|
|
374
|
-
], 64);
|
|
375
|
-
};
|
|
376
|
-
}
|
|
377
|
-
}), se = { class: "flex justify-between items-center mb-6" }, me = { class: "flex space-x-8 items-center" }, re = { class: "flex space-x-4 self-center" }, ie = { class: "mb-6" }, xe = /* @__PURE__ */ C({
|
|
378
|
-
__name: "Settlement",
|
|
379
|
-
setup(p) {
|
|
380
|
-
const t = Q(), { tab: u, dateRange: l } = W({
|
|
381
|
-
tab: "feedme",
|
|
382
|
-
dateRange: {
|
|
383
|
-
startDate: S().startOf("day").format("YYYY-MM-DD"),
|
|
384
|
-
endDate: S().endOf("day").format("YYYY-MM-DD")
|
|
385
|
-
}
|
|
386
|
-
}), { t: s } = K(), { isLoading: g, startAsyncCall: _ } = H(!0), { currentRestaurant: F } = O(), r = J(), a = x([]), n = x([]);
|
|
387
|
-
async function y() {
|
|
388
|
-
const v = await A.readRestaurantSettlements({
|
|
389
|
-
start: l.value.startDate,
|
|
390
|
-
end: l.value.endDate
|
|
391
|
-
});
|
|
392
|
-
a.value = v;
|
|
393
|
-
}
|
|
394
|
-
async function o() {
|
|
395
|
-
const v = await A.readRestaurantRMSSettlements({
|
|
396
|
-
start: l.value.startDate,
|
|
397
|
-
end: l.value.endDate
|
|
398
|
-
});
|
|
399
|
-
n.value = v;
|
|
400
|
-
}
|
|
401
|
-
async function b() {
|
|
402
|
-
await _(async () => Promise.all([y(), o()]));
|
|
403
|
-
}
|
|
404
|
-
async function D(v) {
|
|
405
|
-
const d = S(v.summary.completedAt).format("YYYY/MM/DD");
|
|
406
|
-
r.open({
|
|
407
|
-
title: `${s("payment.settlements.dialog.title")} (${v.summary.referenceNo})`,
|
|
408
|
-
subTitle: `${s("payment.settlements.dialog.date")}: ${d}`,
|
|
409
|
-
minWidth: "90%",
|
|
410
|
-
primaryActions: { text: "Close", close: !0 },
|
|
411
|
-
contentComponent: le,
|
|
412
|
-
contentComponentProps: { settlement: v }
|
|
413
|
-
});
|
|
414
|
-
}
|
|
415
|
-
return E(b), P([F, l], b), (v, d) => {
|
|
416
|
-
const U = w("FmTabs");
|
|
417
|
-
return V(), $(L, {
|
|
418
|
-
title: e(s)("payment.settlements.title"),
|
|
419
|
-
description: e(s)("payment.settlements.description"),
|
|
420
|
-
loading: !1
|
|
421
|
-
}, {
|
|
422
|
-
default: k(() => [
|
|
423
|
-
m("div", se, [
|
|
424
|
-
m("div", me, [
|
|
425
|
-
i(X),
|
|
426
|
-
i(Z, {
|
|
427
|
-
modelValue: e(l),
|
|
428
|
-
"onUpdate:modelValue": d[0] || (d[0] = (Y) => R(l) ? l.value = Y : null)
|
|
429
|
-
}, null, 8, ["modelValue"])
|
|
430
|
-
]),
|
|
431
|
-
m("div", re, [
|
|
432
|
-
i(G, {
|
|
433
|
-
button: {
|
|
434
|
-
appendIcon: "file_download",
|
|
435
|
-
variant: "primary",
|
|
436
|
-
label: "Export"
|
|
437
|
-
},
|
|
438
|
-
handler: async () => {
|
|
439
|
-
await e(A).downloadRestaurantSettlementReport({
|
|
440
|
-
start: e(l).startDate,
|
|
441
|
-
end: e(l).endDate
|
|
442
|
-
});
|
|
443
|
-
}
|
|
444
|
-
}, null, 8, ["handler"])
|
|
445
|
-
])
|
|
446
|
-
]),
|
|
447
|
-
m("div", ie, [
|
|
448
|
-
i(U, {
|
|
449
|
-
modelValue: e(u),
|
|
450
|
-
"onUpdate:modelValue": d[1] || (d[1] = (Y) => R(u) ? u.value = Y : null),
|
|
451
|
-
items: [
|
|
452
|
-
{
|
|
453
|
-
label: "FeedMe",
|
|
454
|
-
value: "feedme",
|
|
455
|
-
icon: "summarize"
|
|
456
|
-
},
|
|
457
|
-
{
|
|
458
|
-
label: "Fiuu (RMS)",
|
|
459
|
-
value: "fiuu",
|
|
460
|
-
icon: "overview"
|
|
461
|
-
}
|
|
462
|
-
]
|
|
463
|
-
}, null, 8, ["modelValue"])
|
|
464
|
-
]),
|
|
465
|
-
e(u) === "fiuu" ? (V(), $(ae, {
|
|
466
|
-
key: 0,
|
|
467
|
-
loading: e(g),
|
|
468
|
-
data: n.value,
|
|
469
|
-
onRowClick: D
|
|
470
|
-
}, null, 8, ["loading", "data"])) : M("", !0),
|
|
471
|
-
e(u) === "feedme" ? (V(), $(te, {
|
|
472
|
-
key: 1,
|
|
473
|
-
loading: e(g),
|
|
474
|
-
data: a.value,
|
|
475
|
-
onRowClick: d[2] || (d[2] = (Y) => e(t).push({
|
|
476
|
-
name: "mf-payment-settlement-transaction",
|
|
477
|
-
params: {
|
|
478
|
-
settlementId: Y._id
|
|
479
|
-
}
|
|
480
|
-
}))
|
|
481
|
-
}, null, 8, ["loading", "data"])) : M("", !0)
|
|
482
|
-
]),
|
|
483
|
-
_: 1
|
|
484
|
-
}, 8, ["title", "description"]);
|
|
485
|
-
};
|
|
486
|
-
}
|
|
487
|
-
});
|
|
488
|
-
export {
|
|
489
|
-
xe as default
|
|
490
|
-
};
|