@feedmepos/mf-payment 1.5.27-dev → 1.5.29-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-Cy1BbWNh.js → Actions.vue_vue_type_script_setup_true_lang-DGrZmVUQ.js} +2 -2
- package/dist/{Chargeback-Dl4rSQ5U.js → Chargeback-CocH4bON.js} +5 -5
- package/dist/{DocumentViewer.vue_vue_type_script_setup_true_lang-B0ThjP1l.js → DocumentViewer.vue_vue_type_script_setup_true_lang-tGPnCbHL.js} +1 -1
- package/dist/{OnboardForm-D3q5YAEo.js → OnboardForm-BLk46c4b.js} +5 -5
- package/dist/{OnboardForm-BwuKMUCZ.js → OnboardForm-CqohYc7w.js} +5 -5
- package/dist/{OnboardSubmission-BBdqr387.js → OnboardSubmission-CIZuFLWF.js} +2 -2
- package/dist/{OnboardSubmission-D958LAp4.js → OnboardSubmission-CNJ-CYki.js} +5 -5
- package/dist/{PayoutAccount-DPkIAGxl.js → PayoutAccount-2vZvDUNZ.js} +5 -5
- package/dist/{PayoutAccount-DOrQRIwu.js → PayoutAccount-Qzl0EU8D.js} +4 -4
- package/dist/{PayoutAccountSetting-BeN4xXv3.js → PayoutAccountSetting-DfrRhtcP.js} +4 -4
- package/dist/{Restaurant-DlQV3dot.js → Restaurant-Ckh7iZ9v.js} +4 -4
- package/dist/{RestaurantSetting-Yb9S8Wfg.js → RestaurantSetting-CeHORT_l.js} +3 -3
- package/dist/Settlement-DWj3kJpX.js +490 -0
- package/dist/{Settlement-jznt2FLc.js → Settlement-Dkf0_6WU.js} +3 -3
- package/dist/{SettlementTransactions-DLVFBcdV.js → SettlementTransactions-B_-EF9FQ.js} +4 -4
- package/dist/{SettlementTransactions-Bm7D3JZu.js → SettlementTransactions-BfDzz9CE.js} +4 -4
- package/dist/{Status.vue_vue_type_script_setup_true_lang-DnWFKNCZ.js → Status.vue_vue_type_script_setup_true_lang-BRylU6yC.js} +1 -1
- package/dist/{Terminal-B6wzbr0C.js → Terminal-CO1Qqx4X.js} +5 -5
- package/dist/{TerminalSetting-BV1Uh1OM.js → TerminalSetting-14CDkcsr.js} +3 -3
- package/dist/Transaction-CkZKTFNI.js +473 -0
- package/dist/{Transaction-DL0_I7Ez.js → Transaction-LS_h6ecG.js} +6 -6
- package/dist/{TransactionOld-CDKLMs5_.js → TransactionOld-Bivy85L4.js} +6 -6
- package/dist/{app-U26B2g_2.js → app-DUlTcsCJ.js} +184 -152
- package/dist/app.js +1 -1
- package/dist/{assets-DvPzXLhl.js → assets-zMyaBFbU.js} +29 -28
- package/dist/components/SourceSelector.vue.d.ts +4 -1
- package/dist/{grafana-DwrmpEec.js → grafana-D_fIUdUm.js} +1 -1
- package/dist/{index-2-UOiJfz.js → index-BganQIV3.js} +1 -1
- package/dist/{index-zMl6AuFw.js → index-C87vsLzf.js} +1 -1
- package/dist/{index-DRKoa7dT.js → index-CcCcgcKj.js} +106 -101
- package/dist/{index-OA39241x.js → index-CsxAKwXK.js} +1 -1
- package/dist/{index-BxuQxtra.js → index-D7IY2VY_.js} +1 -1
- package/dist/{index-DcB4capd.js → index-DEC3wCyK.js} +1 -1
- package/dist/{index-zvJkckUa.js → index-DGCnviAy.js} +1 -1
- package/dist/{index-PpSEr3rk.js → index-WuRUC8sI.js} +2 -2
- package/dist/{index-BPKJne1Q.js → index-cOl7pH9_.js} +1 -1
- package/dist/{index.vue_vue_type_script_setup_true_lang-BYTNfOkc.js → index.vue_vue_type_script_setup_true_lang-H0-KLC0F.js} +1 -1
- package/dist/package.json +2 -2
- package/dist/{payout-account-9xeRIv-9.js → payout-account-DyUwLBkF.js} +3 -3
- package/dist/stores/payoutAccount.d.ts +34 -34
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/dist/views/admin/payout-account/tabs/Information.vue.d.ts +34 -34
- package/dist/views/admin/payout-account/tabs/PaymentChannel.vue.d.ts +56 -56
- package/dist/views/admin/payout-account/tabs/PaymentGateway.vue.d.ts +56 -56
- package/dist/views/admin/payout-account/tabs/PaymentStatus.vue.d.ts +34 -34
- package/dist/views/admin/payout-account/tabs/Settlement.vue.d.ts +34 -34
- package/dist/views/admin/payout-account/tabs/TokenGateway.vue.d.ts +56 -56
- package/dist/views/admin/payout-account/tabs/token/ApplePayToken.vue.d.ts +2 -2
- package/dist/views/admin/payout-account/tabs/token/GooglePayToken.vue.d.ts +2 -2
- package/dist/views/admin/restaurant/tabs/gateway/AdyenGateway.vue.d.ts +4 -4
- package/dist/views/admin/restaurant/tabs/gateway/DigioGateway.vue.d.ts +4 -4
- package/dist/views/admin/restaurant/tabs/gateway/FiuuGateway.vue.d.ts +6 -6
- package/dist/views/admin/restaurant/tabs/gateway/GhlGateway.vue.d.ts +6 -6
- package/dist/views/admin/restaurant/tabs/gateway/GrabGateway.vue.d.ts +4 -4
- package/dist/views/admin/restaurant/tabs/gateway/KsherGateway.vue.d.ts +4 -4
- package/dist/views/admin/restaurant/tabs/gateway/MacauPassGateway.vue.d.ts +6 -6
- package/dist/views/admin/restaurant/tabs/gateway/MaybankGateway.vue.d.ts +6 -6
- package/dist/views/admin/restaurant/tabs/gateway/RevenueMonsterGateway.vue.d.ts +4 -4
- package/dist/views/admin/restaurant/tabs/gateway/SoftSpaceGateway.vue.d.ts +4 -4
- package/dist/views/admin/settlement/SettlementTable.vue.d.ts +4 -0
- package/dist/views/admin/terminal/TerminalDialog.vue.d.ts +14 -14
- package/dist/views/admin/terminal/tabs/EcrGateway.vue.d.ts +14 -14
- package/dist/views/admin/terminal/tabs/Information.vue.d.ts +14 -14
- package/dist/views/admin/terminal/tabs/QrGateway.vue.d.ts +14 -14
- package/dist/views/admin/terminal/tabs/SettingRequest.vue.d.ts +14 -14
- package/dist/views/admin/terminal/tabs/SoftposGateway.vue.d.ts +14 -14
- package/dist/views/admin/terminal/tabs/ecr/Ghl2Gateway.vue.d.ts +14 -14
- package/dist/views/admin/terminal/tabs/ecr/Ghl3Gateway.vue.d.ts +14 -14
- package/dist/views/admin/terminal/tabs/ecr/GhlGateway.vue.d.ts +14 -14
- package/dist/views/admin/terminal/tabs/ecr/GlobalPaymentsGateway.vue.d.ts +14 -14
- package/dist/views/admin/terminal/tabs/ecr/HlbbGateway.vue.d.ts +14 -14
- package/dist/views/admin/terminal/tabs/ecr/KBankGateway.vue.d.ts +14 -14
- package/dist/views/admin/terminal/tabs/ecr/Maybank2Gateway.vue.d.ts +14 -14
- package/dist/views/admin/terminal/tabs/ecr/Maybank3Gateway.vue.d.ts +14 -14
- package/dist/views/admin/terminal/tabs/ecr/MaybankGateway.vue.d.ts +14 -14
- package/dist/views/admin/terminal/tabs/ecr/NetsGateway.vue.d.ts +14 -14
- package/dist/views/admin/terminal/tabs/ecr/TerminalGateway.vue.d.ts +14 -14
- package/dist/views/admin/terminal/tabs/qr/PromptPayGateway.vue.d.ts +14 -14
- package/dist/views/admin/terminal/tabs/settings/KioskMode.vue.d.ts +14 -14
- package/dist/views/payout-account/PayoutAccountTable.vue.d.ts +68 -68
- package/dist/views/settlement/FiuuSettlementTable.vue.d.ts +44 -44
- package/dist/views/settlement/FiuuSettlementTransactions.vue.d.ts +22 -22
- package/dist/views/settlement/SettlementTable.vue.d.ts +5 -1
- package/dist/views/settlement/cell/InvoiceStatus.vue.d.ts +5 -0
- package/package.json +2 -2
- package/dist/Settlement-CpmdJ84I.js +0 -444
- package/dist/Transaction-BAKFOtrH.js +0 -456
|
@@ -0,0 +1,473 @@
|
|
|
1
|
+
import { defineComponent as Y, ref as x, watch as U, onMounted as G, resolveComponent as T, unref as n, openBlock as F, createBlock as q, createElementBlock as w, createVNode as p, withCtx as $, createElementVNode as A, Fragment as j, renderList as J, createTextVNode as Q, toDisplayString as H, isRef as N, h as D } from "vue";
|
|
2
|
+
import { t as I } from "./index-BganQIV3.js";
|
|
3
|
+
import { h as B } from "./moment-h96o7c8I.js";
|
|
4
|
+
import { useI18n as L, useCoreStore as z } from "@feedmepos/mf-common";
|
|
5
|
+
import { _ as W } from "./Layout.vue_vue_type_script_setup_true_lang-BKIvkgA_.js";
|
|
6
|
+
import { t as X, b as Z } from "./assets-zMyaBFbU.js";
|
|
7
|
+
import { u as ee } from "./index-C87vsLzf.js";
|
|
8
|
+
import { _ as ae } from "./AsyncButton.vue_vue_type_script_setup_true_lang-DcjzvYwT.js";
|
|
9
|
+
import { _ as te } from "./SelectAll.vue_vue_type_script_setup_true_lang-BNZTqdoF.js";
|
|
10
|
+
import { _ as ne } from "./DateRangePicker.vue_vue_type_script_setup_true_lang-kymnzYpd.js";
|
|
11
|
+
import { p as se } from "./index-CsxAKwXK.js";
|
|
12
|
+
import { t as re } from "./index-DEC3wCyK.js";
|
|
13
|
+
import { u as oe, p as R } from "./index-CcCcgcKj.js";
|
|
14
|
+
import { useSnackbar as le, useDialog as ie } from "@feedmepos/ui-library";
|
|
15
|
+
import { _ as ce, a as ue, b as me, c as de } from "./Actions.vue_vue_type_script_setup_true_lang-DGrZmVUQ.js";
|
|
16
|
+
import { g as pe } from "./grafana-D_fIUdUm.js";
|
|
17
|
+
import { w as O } from "./Modal-DB8M9o1T.js";
|
|
18
|
+
import { u as P } from "./error-K1CakhA9.js";
|
|
19
|
+
import { _ as ye } from "./index.vue_vue_type_script_setup_true_lang-H0-KLC0F.js";
|
|
20
|
+
const fe = {
|
|
21
|
+
key: 1,
|
|
22
|
+
class: "inline-flex"
|
|
23
|
+
}, _e = { class: "relative" }, ve = { class: "sticky top-0 py-8 bg-white translate-y-[-12px]" }, be = /* @__PURE__ */ Y({
|
|
24
|
+
__name: "SourceSelector",
|
|
25
|
+
props: {
|
|
26
|
+
id: {},
|
|
27
|
+
by: {},
|
|
28
|
+
excludePayoutAccount: { type: Boolean },
|
|
29
|
+
excludeRestaurant: { type: Boolean },
|
|
30
|
+
excludeDevice: { type: Boolean }
|
|
31
|
+
},
|
|
32
|
+
emits: ["update:id", "update:by"],
|
|
33
|
+
setup(V, { emit: y }) {
|
|
34
|
+
const h = V, m = y, { t: s } = L(), { currentBusiness: b, readRestaurants: f } = z(), { isLoading: _, startAsyncCall: d } = oe(!0), v = x([]), u = x(), g = x(""), S = x([]);
|
|
35
|
+
let E;
|
|
36
|
+
U(g, async () => {
|
|
37
|
+
E && clearTimeout(E), E = setTimeout(() => {
|
|
38
|
+
var l = new RegExp(g.value, "i");
|
|
39
|
+
S.value = v.value.filter((i) => {
|
|
40
|
+
const o = JSON.stringify(i);
|
|
41
|
+
return l.test(o);
|
|
42
|
+
});
|
|
43
|
+
}, 700);
|
|
44
|
+
}), U(u, () => {
|
|
45
|
+
var l, i;
|
|
46
|
+
m("update:id", (l = u.value) == null ? void 0 : l.value), m("update:by", (i = u.value) == null ? void 0 : i.by);
|
|
47
|
+
});
|
|
48
|
+
async function K() {
|
|
49
|
+
return d(async () => {
|
|
50
|
+
let l = await se.readBusinessPayoutAccounts();
|
|
51
|
+
if (l.length !== 0)
|
|
52
|
+
return l;
|
|
53
|
+
});
|
|
54
|
+
}
|
|
55
|
+
async function M() {
|
|
56
|
+
return d(async () => {
|
|
57
|
+
let l = await re.getBusinessTerminals();
|
|
58
|
+
if (l.length !== 0)
|
|
59
|
+
return l;
|
|
60
|
+
});
|
|
61
|
+
}
|
|
62
|
+
async function k() {
|
|
63
|
+
_.value = !0;
|
|
64
|
+
const l = [];
|
|
65
|
+
if (!h.excludePayoutAccount) {
|
|
66
|
+
const i = await K();
|
|
67
|
+
l.push(
|
|
68
|
+
...(i || []).map((o) => {
|
|
69
|
+
var a, e;
|
|
70
|
+
return {
|
|
71
|
+
by: "PAYOUT_ACCOUNT",
|
|
72
|
+
value: o._id,
|
|
73
|
+
prefix: s("payment.components.payout_account"),
|
|
74
|
+
type: "Payout Account - " + o.store.event,
|
|
75
|
+
label: ((e = (a = o.ref) == null ? void 0 : a.profile) == null ? void 0 : e.name) ?? o.ref.name
|
|
76
|
+
};
|
|
77
|
+
})
|
|
78
|
+
);
|
|
79
|
+
}
|
|
80
|
+
if (!h.excludeRestaurant) {
|
|
81
|
+
const i = await f();
|
|
82
|
+
l.push(
|
|
83
|
+
...(i || []).map((o) => ({
|
|
84
|
+
by: "RESTAURANT",
|
|
85
|
+
value: o._id,
|
|
86
|
+
prefix: s("payment.components.restaurant"),
|
|
87
|
+
type: "Restaurant",
|
|
88
|
+
label: o.profile.name + " (" + (o.profile.code ?? "--") + ")"
|
|
89
|
+
}))
|
|
90
|
+
);
|
|
91
|
+
}
|
|
92
|
+
if (!h.excludeDevice) {
|
|
93
|
+
const i = await M();
|
|
94
|
+
l.push(
|
|
95
|
+
...(i || []).map((o) => ({
|
|
96
|
+
by: "DEVICE",
|
|
97
|
+
value: o._id,
|
|
98
|
+
prefix: s("payment.components.device"),
|
|
99
|
+
type: "Device - " + o.deviceType,
|
|
100
|
+
label: o.deviceType === "TERMINAL" ? o.name : o.restaurant.profile.name
|
|
101
|
+
}))
|
|
102
|
+
);
|
|
103
|
+
}
|
|
104
|
+
v.value = l, S.value = v.value, _.value = !1;
|
|
105
|
+
}
|
|
106
|
+
return G(k), U(b, k), (l, i) => {
|
|
107
|
+
const o = T("FmCircularProgress"), a = T("FmChip"), e = T("FmSearch"), r = T("FmMenuItem"), c = T("FmMenu");
|
|
108
|
+
return n(_) ? (F(), q(o, {
|
|
109
|
+
key: 0,
|
|
110
|
+
size: "md"
|
|
111
|
+
})) : (F(), w("div", fe, [
|
|
112
|
+
p(c, { "close-on-click": !0 }, {
|
|
113
|
+
"menu-button": $(() => {
|
|
114
|
+
var t;
|
|
115
|
+
return [
|
|
116
|
+
p(a, {
|
|
117
|
+
icon: "account_box",
|
|
118
|
+
label: ((t = u.value) == null ? void 0 : t.label) ?? n(s)("payment.components.select"),
|
|
119
|
+
removable: !!u.value,
|
|
120
|
+
onChipClosed: i[0] || (i[0] = (C) => u.value = void 0)
|
|
121
|
+
}, null, 8, ["label", "removable"])
|
|
122
|
+
];
|
|
123
|
+
}),
|
|
124
|
+
default: $(() => [
|
|
125
|
+
A("div", _e, [
|
|
126
|
+
A("div", ve, [
|
|
127
|
+
p(e, {
|
|
128
|
+
"model-value": g.value,
|
|
129
|
+
"onUpdate:modelValue": i[1] || (i[1] = (t) => g.value = t),
|
|
130
|
+
placeholder: n(s)("payment.components.select")
|
|
131
|
+
}, null, 8, ["model-value", "placeholder"])
|
|
132
|
+
]),
|
|
133
|
+
A("div", null, [
|
|
134
|
+
(F(!0), w(j, null, J(S.value, (t) => (F(), q(r, {
|
|
135
|
+
key: t.value,
|
|
136
|
+
label: t.label,
|
|
137
|
+
sublabel: t.type,
|
|
138
|
+
onClick: () => u.value = t
|
|
139
|
+
}, null, 8, ["label", "sublabel", "onClick"]))), 128))
|
|
140
|
+
])
|
|
141
|
+
])
|
|
142
|
+
]),
|
|
143
|
+
_: 1
|
|
144
|
+
})
|
|
145
|
+
]));
|
|
146
|
+
};
|
|
147
|
+
}
|
|
148
|
+
}), ge = { class: "flex items-center gap-1" }, Te = /* @__PURE__ */ Y({
|
|
149
|
+
__name: "BillSeqNumber",
|
|
150
|
+
props: {
|
|
151
|
+
row: {},
|
|
152
|
+
data: {}
|
|
153
|
+
},
|
|
154
|
+
setup(V) {
|
|
155
|
+
return (y, h) => {
|
|
156
|
+
const m = T("FmIcon");
|
|
157
|
+
return F(), w("span", ge, [
|
|
158
|
+
Q(H(V.row.original.seqNumber) + " ", 1),
|
|
159
|
+
p(m, {
|
|
160
|
+
size: "md",
|
|
161
|
+
name: "check",
|
|
162
|
+
color: "#16a34a"
|
|
163
|
+
})
|
|
164
|
+
]);
|
|
165
|
+
};
|
|
166
|
+
}
|
|
167
|
+
}), he = { class: "flex justify-between mb-6 items-center" }, Ae = { class: "flex space-x-8 items-start" }, Se = { class: "flex space-x-4 self-center" }, Ne = { class: "flex space-x-12 mb-6" }, Le = /* @__PURE__ */ Y({
|
|
168
|
+
__name: "Transaction",
|
|
169
|
+
setup(V) {
|
|
170
|
+
var i, o;
|
|
171
|
+
const y = le(), h = ie(), { sessionUser: m } = z(), { t: s } = L(), b = x(), { dateRange: f, searchKey: _, status: d, id: v, by: u } = ee({
|
|
172
|
+
by: "",
|
|
173
|
+
id: "",
|
|
174
|
+
searchKey: "",
|
|
175
|
+
status: [R.F_PAYMENT_TRANSACTION_STATUS.Enum.SUCCESS],
|
|
176
|
+
dateRange: {
|
|
177
|
+
startDate: B().startOf("day").format("YYYY-MM-DD"),
|
|
178
|
+
endDate: B().endOf("day").format("YYYY-MM-DD")
|
|
179
|
+
}
|
|
180
|
+
});
|
|
181
|
+
let g;
|
|
182
|
+
U(_, async () => {
|
|
183
|
+
g && clearTimeout(g), g = setTimeout(
|
|
184
|
+
() => {
|
|
185
|
+
var a;
|
|
186
|
+
return (a = b.value) == null ? void 0 : a.reset();
|
|
187
|
+
},
|
|
188
|
+
700
|
|
189
|
+
);
|
|
190
|
+
}), U([f, d, v, u], () => {
|
|
191
|
+
var a;
|
|
192
|
+
(a = b.value) == null || a.reset();
|
|
193
|
+
});
|
|
194
|
+
const S = [
|
|
195
|
+
{
|
|
196
|
+
label: "Success",
|
|
197
|
+
value: R.F_PAYMENT_TRANSACTION_STATUS.Enum.SUCCESS
|
|
198
|
+
},
|
|
199
|
+
{
|
|
200
|
+
label: "Refunded",
|
|
201
|
+
value: R.F_PAYMENT_TRANSACTION_STATUS.Enum.REFUNDED
|
|
202
|
+
},
|
|
203
|
+
{
|
|
204
|
+
label: "Process",
|
|
205
|
+
value: R.F_PAYMENT_TRANSACTION_STATUS.Enum.PENDING
|
|
206
|
+
},
|
|
207
|
+
{
|
|
208
|
+
label: "Failed",
|
|
209
|
+
value: R.F_PAYMENT_TRANSACTION_STATUS.Enum.FAILED
|
|
210
|
+
}
|
|
211
|
+
];
|
|
212
|
+
async function E(a, e) {
|
|
213
|
+
var r;
|
|
214
|
+
try {
|
|
215
|
+
const c = await I.refetchTransaction({ transactionId: a.id });
|
|
216
|
+
(r = b.value) == null || r.replaceData(e, c), y.open({
|
|
217
|
+
type: "success",
|
|
218
|
+
title: "Transaction queried and updated successfully."
|
|
219
|
+
});
|
|
220
|
+
} catch (c) {
|
|
221
|
+
y.open({
|
|
222
|
+
type: "error",
|
|
223
|
+
title: "Fail to query transaction.",
|
|
224
|
+
message: P(c)
|
|
225
|
+
});
|
|
226
|
+
}
|
|
227
|
+
}
|
|
228
|
+
async function K(a, e) {
|
|
229
|
+
O(
|
|
230
|
+
h,
|
|
231
|
+
"Refund Transaction",
|
|
232
|
+
"Are you sure to refund transaction? This action cannot be revert!",
|
|
233
|
+
async () => {
|
|
234
|
+
var r;
|
|
235
|
+
try {
|
|
236
|
+
const c = await I.refundTransaction({
|
|
237
|
+
transactionId: a.id,
|
|
238
|
+
reason: "portal transaction refund",
|
|
239
|
+
amount: a.fdoAmount
|
|
240
|
+
});
|
|
241
|
+
(r = b.value) == null || r.replaceData(e, c), y.open({
|
|
242
|
+
type: "success",
|
|
243
|
+
title: "Transaction refund request initiated."
|
|
244
|
+
});
|
|
245
|
+
} catch (c) {
|
|
246
|
+
y.open({
|
|
247
|
+
type: "error",
|
|
248
|
+
title: "Fail to request refund transaction.",
|
|
249
|
+
message: P(c)
|
|
250
|
+
});
|
|
251
|
+
}
|
|
252
|
+
}
|
|
253
|
+
);
|
|
254
|
+
}
|
|
255
|
+
async function M(a, e) {
|
|
256
|
+
O(
|
|
257
|
+
h,
|
|
258
|
+
"Notify Transaction",
|
|
259
|
+
"Are you sure to perform notify transaction?",
|
|
260
|
+
async () => {
|
|
261
|
+
try {
|
|
262
|
+
await I.renotifyTransaction(a.id), y.open({
|
|
263
|
+
type: "success",
|
|
264
|
+
title: "Transaction notify successfully."
|
|
265
|
+
});
|
|
266
|
+
} catch (r) {
|
|
267
|
+
y.open({
|
|
268
|
+
type: "error",
|
|
269
|
+
title: "Fail to notify transaction.",
|
|
270
|
+
message: P(r)
|
|
271
|
+
});
|
|
272
|
+
}
|
|
273
|
+
}
|
|
274
|
+
);
|
|
275
|
+
}
|
|
276
|
+
async function k(a, e) {
|
|
277
|
+
const r = pe([
|
|
278
|
+
{
|
|
279
|
+
type: "span",
|
|
280
|
+
queryKey: "transaction.id",
|
|
281
|
+
queryValue: a.id
|
|
282
|
+
}
|
|
283
|
+
], a.transactionAt);
|
|
284
|
+
window.open(r, "_blank");
|
|
285
|
+
}
|
|
286
|
+
x("");
|
|
287
|
+
const l = [
|
|
288
|
+
{
|
|
289
|
+
header: () => s("payment.transactions.table.id"),
|
|
290
|
+
accessorKey: "id",
|
|
291
|
+
cell: ({ cell: a, row: e }) => {
|
|
292
|
+
var r, c;
|
|
293
|
+
return ((r = m.value) != null && r.role.isStaff || (c = m.value) != null && c.role.isAdmin) && e.original.transactionId ? e.original.id + `
|
|
294
|
+
ID: ` + e.original.transactionId : e.original.id;
|
|
295
|
+
}
|
|
296
|
+
},
|
|
297
|
+
{
|
|
298
|
+
header: () => s("payment.transactions.table.pay_id"),
|
|
299
|
+
accessorKey: "payId"
|
|
300
|
+
},
|
|
301
|
+
{
|
|
302
|
+
header: () => s("payment.transactions.table.gateway_id"),
|
|
303
|
+
accessorKey: "gatewayTransactionId"
|
|
304
|
+
},
|
|
305
|
+
{
|
|
306
|
+
header: () => s("payment.transactions.table.bill_seq"),
|
|
307
|
+
accessorKey: "seqNumber",
|
|
308
|
+
cell: ({ cell: a, row: e }) => e.original.seqNumberBinded ? D(Te, { row: e, data: a.getValue() }) : e.original.seqNumber
|
|
309
|
+
},
|
|
310
|
+
{
|
|
311
|
+
header: () => s("payment.transactions.table.gateway"),
|
|
312
|
+
accessorKey: "gateway",
|
|
313
|
+
meta: {
|
|
314
|
+
textAlign: "center"
|
|
315
|
+
},
|
|
316
|
+
cell: ({ cell: a, row: e }) => e.original.gateway ? D(ce, { row: e, data: a.getValue() }) : ""
|
|
317
|
+
},
|
|
318
|
+
{
|
|
319
|
+
header: () => s("payment.transactions.table.method"),
|
|
320
|
+
accessorKey: "method",
|
|
321
|
+
meta: {
|
|
322
|
+
textAlign: "center"
|
|
323
|
+
},
|
|
324
|
+
cell: ({ cell: a, row: e }) => e.original.method ? D(ue, { row: e, data: a.getValue() }) : ""
|
|
325
|
+
},
|
|
326
|
+
{
|
|
327
|
+
header: () => s("payment.transactions.table.type"),
|
|
328
|
+
accessorKey: "payFor",
|
|
329
|
+
meta: {
|
|
330
|
+
textAlign: "center"
|
|
331
|
+
}
|
|
332
|
+
},
|
|
333
|
+
{
|
|
334
|
+
header: () => s("payment.transactions.table.status"),
|
|
335
|
+
accessorKey: "status",
|
|
336
|
+
cell: ({ cell: a, row: e }) => D(me, { row: e, data: a.getValue() })
|
|
337
|
+
},
|
|
338
|
+
{
|
|
339
|
+
header: () => s("payment.transactions.table.restaurant"),
|
|
340
|
+
accessorKey: "restaurantId"
|
|
341
|
+
},
|
|
342
|
+
{
|
|
343
|
+
header: () => s("payment.transactions.table.source"),
|
|
344
|
+
accessorKey: "source",
|
|
345
|
+
cell: ({ cell: a, row: e }) => `(${e.original.sourceType}) ${e.original.source}`
|
|
346
|
+
},
|
|
347
|
+
{
|
|
348
|
+
header: () => s("payment.transactions.table.transaction_at"),
|
|
349
|
+
accessorKey: "transactionAt",
|
|
350
|
+
meta: {
|
|
351
|
+
width: "180px"
|
|
352
|
+
},
|
|
353
|
+
cell: ({ cell: a, row: e }) => e.original.status === "REFUNDED" ? e.original.refundedAt : e.original.transactionAt
|
|
354
|
+
},
|
|
355
|
+
{
|
|
356
|
+
header: () => s("payment.transactions.table.sales_amount"),
|
|
357
|
+
accessorKey: "amount",
|
|
358
|
+
cell: ({ cell: a, row: e }) => {
|
|
359
|
+
var r, c;
|
|
360
|
+
return ((r = m.value) != null && r.role.isStaff || (c = m.value) != null && c.role.isAdmin) && e.original.flags.isDelivery ? e.original.amount + "( " + e.original.gatewayAmount + ")" : e.original.amount;
|
|
361
|
+
}
|
|
362
|
+
}
|
|
363
|
+
];
|
|
364
|
+
return ((i = m.value) != null && i.role.isStaff || (o = m.value) != null && o.role.isAdmin) && l.push({
|
|
365
|
+
header: () => s("payment.transactions.table.actions"),
|
|
366
|
+
accessorKey: "actions",
|
|
367
|
+
cell: ({ row: a }) => D(de, {
|
|
368
|
+
transaction: a.original,
|
|
369
|
+
onAction: (e) => {
|
|
370
|
+
var r;
|
|
371
|
+
switch (e) {
|
|
372
|
+
case "notify":
|
|
373
|
+
return M(a.original, a.index);
|
|
374
|
+
case "query":
|
|
375
|
+
return E(a.original, a.index);
|
|
376
|
+
case "refund":
|
|
377
|
+
return (r = m.value) != null && r.role.isStaff ? y.open({
|
|
378
|
+
type: "error",
|
|
379
|
+
title: "You are not allowed to refund transaction."
|
|
380
|
+
}) : K(a.original, a.index);
|
|
381
|
+
case "history":
|
|
382
|
+
return k(a.original, a.index);
|
|
383
|
+
}
|
|
384
|
+
}
|
|
385
|
+
})
|
|
386
|
+
}), (a, e) => {
|
|
387
|
+
const r = T("FmSearch"), c = T("FmSelect");
|
|
388
|
+
return F(), q(W, {
|
|
389
|
+
title: n(s)("payment.transactions.title"),
|
|
390
|
+
description: n(s)("payment.transactions.description"),
|
|
391
|
+
loading: !1
|
|
392
|
+
}, {
|
|
393
|
+
default: $(() => [
|
|
394
|
+
A("div", he, [
|
|
395
|
+
A("div", Ae, [
|
|
396
|
+
p(r, {
|
|
397
|
+
"model-value": n(_),
|
|
398
|
+
"onUpdate:modelValue": e[0] || (e[0] = (t) => N(_) ? _.value = t : null),
|
|
399
|
+
class: "mr-8",
|
|
400
|
+
label: n(s)("payment.transactions.search.title"),
|
|
401
|
+
placeholder: n(s)("payment.transactions.search.placeholder")
|
|
402
|
+
}, null, 8, ["model-value", "label", "placeholder"]),
|
|
403
|
+
p(c, {
|
|
404
|
+
modelValue: n(d),
|
|
405
|
+
"onUpdate:modelValue": e[2] || (e[2] = (t) => N(d) ? d.value = t : null),
|
|
406
|
+
class: "mr-6 w-[300px]",
|
|
407
|
+
label: n(s)("payment.transactions.status"),
|
|
408
|
+
"label-mark": "required",
|
|
409
|
+
multiselect: "",
|
|
410
|
+
items: S
|
|
411
|
+
}, {
|
|
412
|
+
"prepend-menu": $(() => [
|
|
413
|
+
p(te, {
|
|
414
|
+
modelValue: n(d),
|
|
415
|
+
"onUpdate:modelValue": e[1] || (e[1] = (t) => N(d) ? d.value = t : null),
|
|
416
|
+
items: S
|
|
417
|
+
}, null, 8, ["modelValue"])
|
|
418
|
+
]),
|
|
419
|
+
_: 1
|
|
420
|
+
}, 8, ["modelValue", "label"])
|
|
421
|
+
]),
|
|
422
|
+
A("div", Se, [
|
|
423
|
+
p(ae, {
|
|
424
|
+
button: {
|
|
425
|
+
appendIcon: "file_download",
|
|
426
|
+
variant: "primary",
|
|
427
|
+
label: n(s)("payment.transactions.button.export")
|
|
428
|
+
},
|
|
429
|
+
handler: async () => {
|
|
430
|
+
var C;
|
|
431
|
+
const t = await ((C = b.value) == null ? void 0 : C.allData());
|
|
432
|
+
t != null && await n(I).downloadPortalTransactionReport(n(f), n(X)(t));
|
|
433
|
+
}
|
|
434
|
+
}, null, 8, ["button", "handler"])
|
|
435
|
+
])
|
|
436
|
+
]),
|
|
437
|
+
A("div", Ne, [
|
|
438
|
+
p(be, {
|
|
439
|
+
id: n(v),
|
|
440
|
+
"onUpdate:id": e[3] || (e[3] = (t) => N(v) ? v.value = t : null),
|
|
441
|
+
by: n(u),
|
|
442
|
+
"onUpdate:by": e[4] || (e[4] = (t) => N(u) ? u.value = t : null)
|
|
443
|
+
}, null, 8, ["id", "by"]),
|
|
444
|
+
p(ne, {
|
|
445
|
+
modelValue: n(f),
|
|
446
|
+
"onUpdate:modelValue": e[5] || (e[5] = (t) => N(f) ? f.value = t : null)
|
|
447
|
+
}, null, 8, ["modelValue"])
|
|
448
|
+
]),
|
|
449
|
+
p(ye, {
|
|
450
|
+
ref_key: "controller",
|
|
451
|
+
ref: b,
|
|
452
|
+
"column-defs": l,
|
|
453
|
+
"rows-defs": n(Z),
|
|
454
|
+
paginate: (t, C) => n(I).readTransactionsV2({
|
|
455
|
+
limit: t,
|
|
456
|
+
cursor: C,
|
|
457
|
+
status: n(d),
|
|
458
|
+
by: n(u),
|
|
459
|
+
id: n(v),
|
|
460
|
+
search: n(_),
|
|
461
|
+
start: n(f).startDate,
|
|
462
|
+
end: n(f).endDate
|
|
463
|
+
})
|
|
464
|
+
}, null, 8, ["rows-defs", "paginate"])
|
|
465
|
+
]),
|
|
466
|
+
_: 1
|
|
467
|
+
}, 8, ["title", "description"]);
|
|
468
|
+
};
|
|
469
|
+
}
|
|
470
|
+
});
|
|
471
|
+
export {
|
|
472
|
+
Le as default
|
|
473
|
+
};
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import { defineComponent as I, resolveComponent as m, openBlock as g, createBlock as F, normalizeClass as U, withCtx as w, createElementVNode as h, toDisplayString as M, unref as f, createElementBlock as E, createVNode as y, Fragment as L, renderList as z, ref as R, createTextVNode as j, watch as $, isRef as C, h as D } from "vue";
|
|
2
|
-
import { t as b } from "./index-
|
|
2
|
+
import { t as b } from "./index-BganQIV3.js";
|
|
3
3
|
import { h as S } from "./moment-h96o7c8I.js";
|
|
4
|
-
import { g as Q, a as W, t as H, b as x } from "./assets-
|
|
5
|
-
import { u as J } from "./index-
|
|
4
|
+
import { g as Q, a as W, t as H, b as x } from "./assets-zMyaBFbU.js";
|
|
5
|
+
import { u as J } from "./index-C87vsLzf.js";
|
|
6
6
|
import { _ as X } from "./AdminLayout.vue_vue_type_script_setup_true_lang-0Mf1MhAL.js";
|
|
7
7
|
import { _ as Z } from "./AsyncButton.vue_vue_type_script_setup_true_lang-DcjzvYwT.js";
|
|
8
8
|
import { useDialogChild as ee, useSnackbar as te, useDialog as ae } from "@feedmepos/ui-library";
|
|
9
9
|
import { w as G } from "./Modal-DB8M9o1T.js";
|
|
10
10
|
import { u as v } from "./error-K1CakhA9.js";
|
|
11
11
|
import { _ as ne } from "./DateRangePicker.vue_vue_type_script_setup_true_lang-kymnzYpd.js";
|
|
12
|
-
import { g as re } from "./grafana-
|
|
13
|
-
import { _ as oe } from "./index.vue_vue_type_script_setup_true_lang-
|
|
14
|
-
import { e as V } from "./index-
|
|
12
|
+
import { g as re } from "./grafana-D_fIUdUm.js";
|
|
13
|
+
import { _ as oe } from "./index.vue_vue_type_script_setup_true_lang-H0-KLC0F.js";
|
|
14
|
+
import { e as V } from "./index-CcCcgcKj.js";
|
|
15
15
|
import { _ as se } from "./AutoCopyCell.vue_vue_type_script_setup_true_lang-DrBLdVka.js";
|
|
16
16
|
import { s as A, z as ie } from "./validator-DzjyJnvv.js";
|
|
17
17
|
import { useCoreStore as ce } from "@feedmepos/mf-common";
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import { defineComponent as S, ref as K, watch as x, resolveComponent as F, openBlock as Y, createBlock as C, h as A, onMounted as M, unref as i, withCtx as O, createElementVNode as w, createVNode as _, isRef as R } from "vue";
|
|
2
|
-
import { t as v } from "./index-
|
|
3
|
-
import { u as U } from "./index-
|
|
2
|
+
import { t as v } from "./index-BganQIV3.js";
|
|
3
|
+
import { u as U } from "./index-CcCcgcKj.js";
|
|
4
4
|
import { useSnackbar as L, useDialog as P } from "@feedmepos/ui-library";
|
|
5
|
-
import { b as $, t as B } from "./assets-
|
|
6
|
-
import { _ as J, a as j, b as G, c as Q } from "./Actions.vue_vue_type_script_setup_true_lang-
|
|
7
|
-
import { g as z } from "./grafana-
|
|
5
|
+
import { b as $, t as B } from "./assets-zMyaBFbU.js";
|
|
6
|
+
import { _ as J, a as j, b as G, c as Q } from "./Actions.vue_vue_type_script_setup_true_lang-DGrZmVUQ.js";
|
|
7
|
+
import { g as z } from "./grafana-D_fIUdUm.js";
|
|
8
8
|
import { w as k } from "./Modal-DB8M9o1T.js";
|
|
9
9
|
import { u as V } from "./error-K1CakhA9.js";
|
|
10
10
|
import { useCoreStore as N, useI18n as E } from "@feedmepos/mf-common";
|
|
11
11
|
import { h as I } from "./moment-h96o7c8I.js";
|
|
12
12
|
import { _ as H } from "./Layout.vue_vue_type_script_setup_true_lang-BKIvkgA_.js";
|
|
13
|
-
import { u as W } from "./index-
|
|
13
|
+
import { u as W } from "./index-C87vsLzf.js";
|
|
14
14
|
import { _ as X } from "./AsyncButton.vue_vue_type_script_setup_true_lang-DcjzvYwT.js";
|
|
15
15
|
import { _ as Z } from "./RestaurantSelector.vue_vue_type_script_setup_true_lang-DG3iyjkK.js";
|
|
16
16
|
import { _ as aa } from "./DateRangePicker.vue_vue_type_script_setup_true_lang-kymnzYpd.js";
|