@feedmepos/mf-payment 1.0.17-beta.1 → 1.0.18-beta.1
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/{PayoutAccount-DVTKC9HU.js → PayoutAccount-DCq9zJ7I.js} +3 -3
- package/dist/{PayoutAccount-DaSWi1Me.js → PayoutAccount-Dlrre2MV.js} +83 -115
- package/dist/PayoutAccountSetting-D6Scsqvm.js +426 -0
- package/dist/{Restaurant-C-pno48_.js → Restaurant-AoDzEhKi.js} +4 -4
- package/dist/{RestaurantSetting-D5BXiTn2.js → RestaurantSetting-CAQfJwaq.js} +137 -115
- package/dist/{Settlement-Cgxts5eu.js → Settlement-anAN-1YR.js} +3 -3
- package/dist/Settlement-kfM1jLO-.js +444 -0
- package/dist/{SettlementTransactions-BXPsJSOI.js → SettlementTransactions-IhEM3Qtp.js} +4 -4
- package/dist/{SettlementTransactions-BWe-hWjq.js → SettlementTransactions-dVE594dr.js} +4 -4
- package/dist/Terminal-C0Irg7I_.js +435 -0
- package/dist/{TerminalSetting-BciOf47B.js → TerminalSetting-mMj1OSGc.js} +3 -3
- package/dist/{TerminalTransaction-BYlEOFjg.js → TerminalTransaction-2Oe5b_rm.js} +176 -188
- package/dist/TerminalTransaction-Coth2MwA.js +269 -0
- package/dist/Transaction-BbbVDMIm.js +247 -0
- package/dist/{Transaction-B362xcHT.js → Transaction-ChE2VgSa.js} +6 -6
- package/dist/{TransactionOld--8HuiCzC.js → TransactionOld-T8CKBB6U.js} +4 -4
- package/dist/{TransactionTable.vue_vue_type_script_setup_true_lang-yAM0nD2z.js → TransactionTable.vue_vue_type_script_setup_true_lang-CoPiWynn.js} +2 -2
- package/dist/api/index.d.ts +1 -1
- package/dist/api/settlement/index.d.ts +5 -1
- package/dist/api/terminal/index.d.ts +1 -0
- package/dist/api/terminal-transaction/index.d.ts +2 -2
- package/dist/{app-Dm8kGtux.js → app-B36bwKcX.js} +165 -165
- package/dist/app.js +1 -1
- package/dist/{assets-BDTkzAxB.js → assets-fxpnHIZr.js} +1 -1
- package/dist/grafana-BFQCDk-V.js +54 -0
- package/dist/index-9a-RyWYf.js +52 -0
- package/dist/{index-BroiGVyD.js → index-C2q2ptf8.js} +1 -1
- package/dist/{index-D7Uh09kd.js → index-CC8HNMje.js} +1 -1
- package/dist/{index-DmltKkqh.js → index-CEJAjyRa.js} +1 -1
- package/dist/{index-4uEqQ1dj.js → index-Cj90pU-C.js} +27 -20
- package/dist/{index-CtVHR2Os.js → index-DueuWuxx.js} +1 -1
- package/dist/{index-CZAwC5k6.js → index-ZMBnoQxd.js} +31 -23
- package/dist/{index.vue_vue_type_script_setup_true_lang-3Bmqvkzy.js → index.vue_vue_type_script_setup_true_lang-PfAufXp3.js} +1 -1
- package/dist/package.json +2 -2
- package/dist/{payout-account-BZ-WV3GM.js → payout-account-D-LZ6-Lb.js} +2 -2
- package/dist/style.css +1 -1
- package/dist/{transaction-XK-M9o1a.js → transaction-5dZS6JFA.js} +21 -12
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/dist/views/admin/terminal/cell/Actions.vue.d.ts +2 -0
- package/dist/views/settlement/FiuuSettlementTable.vue.d.ts +293 -0
- package/dist/views/settlement/FiuuSettlementTransactions.vue.d.ts +147 -0
- package/package.json +2 -2
- package/dist/PayoutAccountSelector.vue_vue_type_script_setup_true_lang-CYE3OEXe.js +0 -110
- package/dist/PayoutAccountSetting-CqWDYDDi.js +0 -758
- package/dist/Settlement-I67N2bqy.js +0 -145
- package/dist/Terminal-o9zfC9WW.js +0 -404
- package/dist/TerminalTransaction-C_2wLJJV.js +0 -820
- package/dist/Transaction-gDdSiqs9.js +0 -145
- package/dist/grafana-Dtn-kbRH.js +0 -49
- package/dist/index-BC85ddk1.js +0 -47
- package/dist/index-CZ9tbaEh.js +0 -28
- package/dist/views/admin/payout-account/cell/IsActive.vue.d.ts +0 -7
- package/dist/views/admin/payout-account/tabs/PaymentGateway.vue.d.ts +0 -81
- package/dist/views/admin/terminal-transaction/cell/Timestamp.vue.d.ts +0 -7
@@ -0,0 +1,269 @@
|
|
1
|
+
import { defineComponent as y, openBlock as p, createElementBlock as w, Fragment as O, unref as c, createCommentVNode as F, createElementVNode as d, resolveComponent as N, createBlock as b, normalizeClass as D, withCtx as h, toDisplayString as V, ref as M, watch as T, createVNode as m, isRef as _, h as I } from "vue";
|
2
|
+
import { c as n } from "./index-CC8HNMje.js";
|
3
|
+
import { h as g } from "./moment-h96o7c8I.js";
|
4
|
+
import { u as k } from "./index-DueuWuxx.js";
|
5
|
+
import { _ as K } from "./index.vue_vue_type_script_setup_true_lang-PfAufXp3.js";
|
6
|
+
import "@feedmepos/ui-library";
|
7
|
+
import { g as Y } from "./assets-fxpnHIZr.js";
|
8
|
+
import { E as $, t as C } from "./index-ZMBnoQxd.js";
|
9
|
+
import { d as L } from "./dinero-CIVmXLL-.js";
|
10
|
+
import { _ as B } from "./AsyncButton.vue_vue_type_script_setup_true_lang-DcjzvYwT.js";
|
11
|
+
import { _ as G } from "./AutoCopyCell.vue_vue_type_script_setup_true_lang-CdmfrBoW.js";
|
12
|
+
import { _ as P } from "./Layout.vue_vue_type_script_setup_true_lang-DJm5br5a.js";
|
13
|
+
import { _ as q } from "./SelectAll.vue_vue_type_script_setup_true_lang-DA4rs3tk.js";
|
14
|
+
import { _ as U } from "./DateRangePicker.vue_vue_type_script_setup_true_lang-dP_5WjEJ.js";
|
15
|
+
import { _ as j } from "./RestaurantSelector.vue_vue_type_script_setup_true_lang-p4qddIbp.js";
|
16
|
+
import { useCoreStore as H } from "@feedmepos/mf-common";
|
17
|
+
const W = ["src"], z = ["src"], Q = /* @__PURE__ */ y({
|
18
|
+
__name: "Gateway",
|
19
|
+
props: {
|
20
|
+
row: {},
|
21
|
+
data: {}
|
22
|
+
},
|
23
|
+
setup(f) {
|
24
|
+
return (t, u) => (p(), w(O, null, [
|
25
|
+
t.row.original.ecrGateway ? (p(), w("img", {
|
26
|
+
key: 0,
|
27
|
+
class: "bg-fm-color-overlay-background rounded-md m-auto border-transparent w-[32px] h-[32px]",
|
28
|
+
src: c($)
|
29
|
+
}, null, 8, W)) : F("", !0),
|
30
|
+
d("img", {
|
31
|
+
class: "rounded-md m-auto border-transparent object-contain w-[32px] h-[32px]",
|
32
|
+
src: c(Y)(t.row.original.gateway)
|
33
|
+
}, null, 8, z)
|
34
|
+
], 64));
|
35
|
+
}
|
36
|
+
}), J = /* @__PURE__ */ y({
|
37
|
+
__name: "Status",
|
38
|
+
props: {
|
39
|
+
row: {},
|
40
|
+
data: {}
|
41
|
+
},
|
42
|
+
setup(f) {
|
43
|
+
const t = f;
|
44
|
+
function u() {
|
45
|
+
return t.data === n.F_TERMINAL_TRANSACTION_ACTION.Enum.process ? "!w-[16px] !h-[16px] bg-yellow-400" : t.data === n.F_TERMINAL_TRANSACTION_ACTION.Enum.failed ? "!w-[16px] !h-[16px] bg-red-400" : t.data === n.F_TERMINAL_TRANSACTION_ACTION.Enum.refunded ? "!w-[16px] !h-[16px] bg-blue-400" : "!w-[16px] !h-[16px] bg-green-400";
|
46
|
+
}
|
47
|
+
return (o, s) => {
|
48
|
+
const l = N("FmBadge");
|
49
|
+
return p(), b(l, {
|
50
|
+
inline: "",
|
51
|
+
class: D(u())
|
52
|
+
}, {
|
53
|
+
default: h(() => [
|
54
|
+
d("div", null, V(o.data.toUpperCase()), 1)
|
55
|
+
]),
|
56
|
+
_: 1
|
57
|
+
}, 8, ["class"]);
|
58
|
+
};
|
59
|
+
}
|
60
|
+
}), X = { class: "flex justify-between mb-6 items-start" }, Z = { class: "flex space-x-8 items-start" }, ee = { class: "flex space-x-4 self-center" }, ae = { class: "flex space-x-12 mb-6" }, Ie = /* @__PURE__ */ y({
|
61
|
+
__name: "TerminalTransaction",
|
62
|
+
setup(f) {
|
63
|
+
const t = M(), { currentRestaurant: u } = H(), { dateRange: o, status: s, searchKey: l } = k({
|
64
|
+
searchKey: "",
|
65
|
+
status: [n.F_TERMINAL_TRANSACTION_ACTION.Enum.success],
|
66
|
+
dateRange: {
|
67
|
+
startDate: g().startOf("day").format("YYYY-MM-DD"),
|
68
|
+
endDate: g().endOf("day").format("YYYY-MM-DD")
|
69
|
+
}
|
70
|
+
});
|
71
|
+
T([o, s], () => {
|
72
|
+
var e;
|
73
|
+
return (e = t.value) == null ? void 0 : e.reset();
|
74
|
+
}), T(u, () => {
|
75
|
+
var e;
|
76
|
+
return (e = t.value) == null ? void 0 : e.reset();
|
77
|
+
});
|
78
|
+
let A;
|
79
|
+
T(l, async () => {
|
80
|
+
A && clearTimeout(A), A = setTimeout(
|
81
|
+
() => {
|
82
|
+
var e;
|
83
|
+
return (e = t.value) == null ? void 0 : e.reset();
|
84
|
+
},
|
85
|
+
700
|
86
|
+
);
|
87
|
+
});
|
88
|
+
const x = [
|
89
|
+
{
|
90
|
+
label: "Success",
|
91
|
+
value: n.F_TERMINAL_TRANSACTION_ACTION.Enum.success
|
92
|
+
},
|
93
|
+
{
|
94
|
+
label: "Refunded",
|
95
|
+
value: n.F_TERMINAL_TRANSACTION_ACTION.Enum.refunded
|
96
|
+
},
|
97
|
+
{
|
98
|
+
label: "Process",
|
99
|
+
value: n.F_TERMINAL_TRANSACTION_ACTION.Enum.process
|
100
|
+
},
|
101
|
+
{
|
102
|
+
label: "Failed",
|
103
|
+
value: n.F_TERMINAL_TRANSACTION_ACTION.Enum.failed
|
104
|
+
}
|
105
|
+
], R = function(e) {
|
106
|
+
const a = e;
|
107
|
+
let i = "-";
|
108
|
+
return a.details && a.details.amount && (i = L(a.details.amount).toFormat("$0.00")), {
|
109
|
+
id: e._id,
|
110
|
+
transactionId: e.transactionId,
|
111
|
+
orderId: e.orderId,
|
112
|
+
refId: e.refId,
|
113
|
+
terminalId: e.terminalId,
|
114
|
+
transactionAt: g(e.transactionAt).format("YYYY-MM-DD HH:mm:ss"),
|
115
|
+
action: e.action,
|
116
|
+
gateway: e.gateway,
|
117
|
+
ecrGateway: e.ecrGateway,
|
118
|
+
amount: i,
|
119
|
+
seqNumber: e.seqNumber,
|
120
|
+
error: e.error
|
121
|
+
};
|
122
|
+
}, S = [
|
123
|
+
{
|
124
|
+
accessorKey: "transactionId",
|
125
|
+
header: () => "Transaction ID",
|
126
|
+
meta: {
|
127
|
+
textAlign: "left"
|
128
|
+
},
|
129
|
+
cell: ({ cell: e }) => I(G, { data: e.getValue() })
|
130
|
+
},
|
131
|
+
{
|
132
|
+
accessorKey: "orderId",
|
133
|
+
header: () => "Pay ID",
|
134
|
+
meta: {
|
135
|
+
textAlign: "left"
|
136
|
+
}
|
137
|
+
},
|
138
|
+
{
|
139
|
+
header: () => "Bill Seq No",
|
140
|
+
accessorKey: "seqNumber"
|
141
|
+
},
|
142
|
+
{
|
143
|
+
accessorKey: "refId",
|
144
|
+
header: () => "Reference ID",
|
145
|
+
meta: {
|
146
|
+
textAlign: "left"
|
147
|
+
}
|
148
|
+
},
|
149
|
+
{
|
150
|
+
accessorKey: "gateway",
|
151
|
+
header: () => "Gateway",
|
152
|
+
meta: {
|
153
|
+
textAlign: "center",
|
154
|
+
maxWidth: "128px"
|
155
|
+
},
|
156
|
+
cell: ({ cell: e, row: a }) => I(Q, { row: a, data: e.getValue() })
|
157
|
+
},
|
158
|
+
{
|
159
|
+
accessorKey: "action",
|
160
|
+
header: () => "Status",
|
161
|
+
meta: {
|
162
|
+
textAlign: "right",
|
163
|
+
maxWidth: "132px"
|
164
|
+
},
|
165
|
+
cell: ({ cell: e, row: a }) => I(J, { row: a, data: e.getValue() })
|
166
|
+
},
|
167
|
+
{
|
168
|
+
accessorKey: "amount",
|
169
|
+
header: () => "Sales Amount",
|
170
|
+
meta: {
|
171
|
+
textAlign: "center"
|
172
|
+
}
|
173
|
+
},
|
174
|
+
{
|
175
|
+
accessorKey: "terminalId",
|
176
|
+
header: () => "Terminal ID",
|
177
|
+
meta: {
|
178
|
+
textAlign: "left"
|
179
|
+
}
|
180
|
+
},
|
181
|
+
{
|
182
|
+
accessorKey: "transactionAt",
|
183
|
+
header: () => "Transaction At",
|
184
|
+
meta: {
|
185
|
+
textAlign: "left"
|
186
|
+
}
|
187
|
+
}
|
188
|
+
], E = (e, a) => u.value ? C.readRestaurantTransactions({
|
189
|
+
restaurantId: u.value._id,
|
190
|
+
status: s.value,
|
191
|
+
searchKey: l.value,
|
192
|
+
limit: e,
|
193
|
+
cursor: a,
|
194
|
+
start: o.value.startDate,
|
195
|
+
end: o.value.endDate
|
196
|
+
}) : Promise.resolve({ data: [], meta: { cursor: "" } });
|
197
|
+
return (e, a) => {
|
198
|
+
const i = N("FmSearch"), v = N("FmSelect");
|
199
|
+
return p(), b(P, {
|
200
|
+
title: "Terminal Transactions",
|
201
|
+
description: "Transactions are purchases or payments made in retail using electronic devices such as POS systems, kiosks, terminals, or ECRs.",
|
202
|
+
loading: !1
|
203
|
+
}, {
|
204
|
+
default: h(() => [
|
205
|
+
d("div", X, [
|
206
|
+
d("div", Z, [
|
207
|
+
m(j),
|
208
|
+
m(i, {
|
209
|
+
"model-value": c(l),
|
210
|
+
"onUpdate:modelValue": a[0] || (a[0] = (r) => _(l) ? l.value = r : null),
|
211
|
+
class: "mr-8",
|
212
|
+
label: "Search",
|
213
|
+
placeholder: "Search Transactions ..."
|
214
|
+
}, null, 8, ["model-value"]),
|
215
|
+
m(v, {
|
216
|
+
modelValue: c(s),
|
217
|
+
"onUpdate:modelValue": a[2] || (a[2] = (r) => _(s) ? s.value = r : null),
|
218
|
+
class: "mr-6 w-[300px]",
|
219
|
+
label: "Status",
|
220
|
+
"label-mark": "required",
|
221
|
+
multiselect: "",
|
222
|
+
items: x
|
223
|
+
}, {
|
224
|
+
"prepend-menu": h(() => [
|
225
|
+
m(q, {
|
226
|
+
modelValue: c(s),
|
227
|
+
"onUpdate:modelValue": a[1] || (a[1] = (r) => _(s) ? s.value = r : null),
|
228
|
+
items: x
|
229
|
+
}, null, 8, ["modelValue"])
|
230
|
+
]),
|
231
|
+
_: 1
|
232
|
+
}, 8, ["modelValue"])
|
233
|
+
]),
|
234
|
+
d("div", ee, [
|
235
|
+
m(B, {
|
236
|
+
button: {
|
237
|
+
appendIcon: "file_download",
|
238
|
+
variant: "primary",
|
239
|
+
label: "Export"
|
240
|
+
},
|
241
|
+
handler: () => {
|
242
|
+
var r;
|
243
|
+
return c(C).downloadTransactions(((r = t.value) == null ? void 0 : r.data()) ?? []);
|
244
|
+
}
|
245
|
+
}, null, 8, ["handler"])
|
246
|
+
])
|
247
|
+
]),
|
248
|
+
d("div", ae, [
|
249
|
+
m(U, {
|
250
|
+
modelValue: c(o),
|
251
|
+
"onUpdate:modelValue": a[3] || (a[3] = (r) => _(o) ? o.value = r : null)
|
252
|
+
}, null, 8, ["modelValue"])
|
253
|
+
]),
|
254
|
+
m(K, {
|
255
|
+
ref_key: "controller",
|
256
|
+
ref: t,
|
257
|
+
"column-defs": S,
|
258
|
+
"rows-defs": R,
|
259
|
+
paginate: E
|
260
|
+
}, null, 512)
|
261
|
+
]),
|
262
|
+
_: 1
|
263
|
+
});
|
264
|
+
};
|
265
|
+
}
|
266
|
+
});
|
267
|
+
export {
|
268
|
+
Ie as default
|
269
|
+
};
|
@@ -0,0 +1,247 @@
|
|
1
|
+
import { defineComponent as D, mergeModels as B, ref as w, computed as R, useModel as q, watch as h, onMounted as O, resolveComponent as S, openBlock as s, createElementBlock as N, Fragment as g, unref as v, createBlock as T, createCommentVNode as P, withCtx as b, createVNode as p, renderList as I, createElementVNode as M, isRef as E } from "vue";
|
2
|
+
import { t as U, a as z } from "./transaction-5dZS6JFA.js";
|
3
|
+
import { u as $, _ as F } from "./index-CC8HNMje.js";
|
4
|
+
import { _ as J } from "./TransactionTable.vue_vue_type_script_setup_true_lang-CoPiWynn.js";
|
5
|
+
import { h as Y } from "./moment-h96o7c8I.js";
|
6
|
+
import { useCoreStore as L } from "@feedmepos/mf-common";
|
7
|
+
import { _ as K } from "./Layout.vue_vue_type_script_setup_true_lang-DJm5br5a.js";
|
8
|
+
import { u as j } from "./index-DueuWuxx.js";
|
9
|
+
import { _ as G } from "./AsyncButton.vue_vue_type_script_setup_true_lang-DcjzvYwT.js";
|
10
|
+
import { _ as Q } from "./SelectAll.vue_vue_type_script_setup_true_lang-DA4rs3tk.js";
|
11
|
+
import { _ as H } from "./DateRangePicker.vue_vue_type_script_setup_true_lang-dP_5WjEJ.js";
|
12
|
+
import { p as W } from "./index-CEJAjyRa.js";
|
13
|
+
const X = /* @__PURE__ */ D({
|
14
|
+
__name: "PayoutAccountSelector",
|
15
|
+
props: /* @__PURE__ */ B({
|
16
|
+
event: {
|
17
|
+
type: Array
|
18
|
+
}
|
19
|
+
}, {
|
20
|
+
modelValue: { required: !0 },
|
21
|
+
modelModifiers: {}
|
22
|
+
}),
|
23
|
+
emits: ["update:modelValue"],
|
24
|
+
setup(x) {
|
25
|
+
const f = x, { currentBusiness: c } = L(), { isLoading: i, startAsyncCall: r } = $(!0), y = w([]), A = R(() => y.value.map((e) => {
|
26
|
+
var n, u;
|
27
|
+
return {
|
28
|
+
event: e.store.event,
|
29
|
+
label: ((u = (n = e.ref) == null ? void 0 : n.profile) == null ? void 0 : u.name) ?? e.ref.name,
|
30
|
+
value: e._id
|
31
|
+
};
|
32
|
+
})), V = R(() => new Set(y.value.map((e) => e.store.event))), _ = q(x, "modelValue"), l = w();
|
33
|
+
h(l, () => {
|
34
|
+
var e;
|
35
|
+
_.value = (e = l.value) == null ? void 0 : e.value;
|
36
|
+
});
|
37
|
+
async function k() {
|
38
|
+
await r(async () => {
|
39
|
+
var u, a;
|
40
|
+
let e = await W.readBusinessPayoutAccounts();
|
41
|
+
if (e.length === 0)
|
42
|
+
return;
|
43
|
+
f.event && (e = e.filter((o) => {
|
44
|
+
var m;
|
45
|
+
return (m = f.event) == null ? void 0 : m.includes(o.store.event);
|
46
|
+
}));
|
47
|
+
let n = e.find((o) => o._id === _.value);
|
48
|
+
n || (n = e[0]), l.value = {
|
49
|
+
event: n.store.event,
|
50
|
+
label: ((a = (u = n.ref) == null ? void 0 : u.profile) == null ? void 0 : a.name) ?? n.ref.name,
|
51
|
+
value: n._id
|
52
|
+
}, y.value = e;
|
53
|
+
});
|
54
|
+
}
|
55
|
+
function C() {
|
56
|
+
k();
|
57
|
+
}
|
58
|
+
return O(C), h(c, C), (e, n) => {
|
59
|
+
const u = S("FmCircularProgress"), a = S("FmChip"), o = S("FmMenuItem"), m = S("FmMenu");
|
60
|
+
return s(), N(g, null, [
|
61
|
+
v(i) ? (s(), T(u, {
|
62
|
+
key: 0,
|
63
|
+
size: "md"
|
64
|
+
})) : P("", !0),
|
65
|
+
v(i) ? P("", !0) : (s(), T(m, { key: 1 }, {
|
66
|
+
"menu-button": b(() => {
|
67
|
+
var t;
|
68
|
+
return [
|
69
|
+
p(a, {
|
70
|
+
icon: "account_box",
|
71
|
+
label: l.value ? l.value.event + " | " + ((t = l.value) == null ? void 0 : t.label) : "Select Payout Account",
|
72
|
+
removable: l.value,
|
73
|
+
onChipClosed: n[0] || (n[0] = (d) => l.value = null)
|
74
|
+
}, null, 8, ["label", "removable"])
|
75
|
+
];
|
76
|
+
}),
|
77
|
+
default: b(() => [
|
78
|
+
V.value.size > 1 ? (s(!0), N(g, { key: 0 }, I(V.value, (t) => (s(), T(m, {
|
79
|
+
placement: "right-start",
|
80
|
+
width: 200
|
81
|
+
}, {
|
82
|
+
"menu-button": b(() => [
|
83
|
+
p(o, {
|
84
|
+
label: t,
|
85
|
+
expandable: ""
|
86
|
+
}, null, 8, ["label"])
|
87
|
+
]),
|
88
|
+
default: b(() => [
|
89
|
+
(s(!0), N(g, null, I(A.value.filter((d) => d.event === t), (d) => (s(), T(o, {
|
90
|
+
onClick: (le) => l.value = d,
|
91
|
+
key: d.value,
|
92
|
+
label: d.label,
|
93
|
+
selectable: ""
|
94
|
+
}, null, 8, ["onClick", "label"]))), 128))
|
95
|
+
]),
|
96
|
+
_: 2
|
97
|
+
}, 1024))), 256)) : (s(), N(g, { key: 1 }, [
|
98
|
+
A.value.length === 0 ? (s(), T(o, {
|
99
|
+
key: "empty",
|
100
|
+
label: "No payout accounts"
|
101
|
+
})) : P("", !0),
|
102
|
+
(s(!0), N(g, null, I(A.value, (t) => (s(), T(o, {
|
103
|
+
onClick: (d) => l.value = t,
|
104
|
+
key: t.value,
|
105
|
+
label: t.label,
|
106
|
+
selectable: ""
|
107
|
+
}, null, 8, ["onClick", "label"]))), 128))
|
108
|
+
], 64))
|
109
|
+
]),
|
110
|
+
_: 1
|
111
|
+
}))
|
112
|
+
], 64);
|
113
|
+
};
|
114
|
+
}
|
115
|
+
}), Z = { class: "flex justify-between mb-6 items-center" }, ee = { class: "flex space-x-8 items-start" }, te = { class: "flex space-x-4 self-center" }, ae = { class: "flex space-x-12 mb-6" }, _e = /* @__PURE__ */ D({
|
116
|
+
__name: "Transaction",
|
117
|
+
setup(x) {
|
118
|
+
const { dateRange: f, searchKey: c, accountId: i, status: r } = j({
|
119
|
+
accountId: "",
|
120
|
+
searchKey: "",
|
121
|
+
status: [F.F_PAYMENT_TRANSACTION_STATUS.Enum.SUCCESS],
|
122
|
+
dateRange: {
|
123
|
+
startDate: Y().startOf("day").format("YYYY-MM-DD"),
|
124
|
+
endDate: Y().endOf("day").format("YYYY-MM-DD")
|
125
|
+
}
|
126
|
+
}), { isLoading: y, startAsyncCall: A } = $(!0), { currentBusiness: V } = L(), _ = w([]), l = w([]);
|
127
|
+
async function k() {
|
128
|
+
i.value && await A(async () => {
|
129
|
+
const { startDate: u, endDate: a } = f.value, o = await U.readAccountTransactions({
|
130
|
+
status: r.value,
|
131
|
+
accountId: i.value,
|
132
|
+
start: u,
|
133
|
+
end: a
|
134
|
+
});
|
135
|
+
if (_.value = z(o), l.value = _.value, c.value > "") {
|
136
|
+
var m = new RegExp(c.value, "i");
|
137
|
+
l.value = _.value.filter((t) => {
|
138
|
+
const d = JSON.stringify(t);
|
139
|
+
return m.test(d);
|
140
|
+
});
|
141
|
+
}
|
142
|
+
});
|
143
|
+
}
|
144
|
+
function C() {
|
145
|
+
k();
|
146
|
+
}
|
147
|
+
O(C), h(V, C), h([i, f, r], k);
|
148
|
+
let e;
|
149
|
+
h(c, async () => {
|
150
|
+
e && clearTimeout(e), e = setTimeout(() => {
|
151
|
+
var u = new RegExp(c.value, "i");
|
152
|
+
l.value = _.value.filter((a) => {
|
153
|
+
const o = JSON.stringify(a);
|
154
|
+
return u.test(o);
|
155
|
+
});
|
156
|
+
}, 700);
|
157
|
+
});
|
158
|
+
const n = [
|
159
|
+
{
|
160
|
+
label: "Success",
|
161
|
+
value: F.F_PAYMENT_TRANSACTION_STATUS.Enum.SUCCESS
|
162
|
+
},
|
163
|
+
{
|
164
|
+
label: "Refunded",
|
165
|
+
value: F.F_PAYMENT_TRANSACTION_STATUS.Enum.REFUNDED
|
166
|
+
},
|
167
|
+
{
|
168
|
+
label: "Process",
|
169
|
+
value: F.F_PAYMENT_TRANSACTION_STATUS.Enum.PENDING
|
170
|
+
},
|
171
|
+
{
|
172
|
+
label: "Failed",
|
173
|
+
value: F.F_PAYMENT_TRANSACTION_STATUS.Enum.FAILED
|
174
|
+
}
|
175
|
+
];
|
176
|
+
return (u, a) => {
|
177
|
+
const o = S("FmSearch"), m = S("FmSelect");
|
178
|
+
return s(), T(K, {
|
179
|
+
title: "Online Transactions",
|
180
|
+
description: "Transactions are purchases or payments made over the internet using electronic methods like cards or digital wallets.",
|
181
|
+
loading: !1
|
182
|
+
}, {
|
183
|
+
default: b(() => [
|
184
|
+
M("div", Z, [
|
185
|
+
M("div", ee, [
|
186
|
+
p(o, {
|
187
|
+
"model-value": v(c),
|
188
|
+
"onUpdate:modelValue": a[0] || (a[0] = (t) => E(c) ? c.value = t : null),
|
189
|
+
class: "mr-8",
|
190
|
+
label: "Search",
|
191
|
+
placeholder: "Search Transactions ..."
|
192
|
+
}, null, 8, ["model-value"]),
|
193
|
+
p(m, {
|
194
|
+
modelValue: v(r),
|
195
|
+
"onUpdate:modelValue": a[2] || (a[2] = (t) => E(r) ? r.value = t : null),
|
196
|
+
class: "mr-6 w-[300px]",
|
197
|
+
label: "Status",
|
198
|
+
"label-mark": "required",
|
199
|
+
multiselect: "",
|
200
|
+
items: n
|
201
|
+
}, {
|
202
|
+
"prepend-menu": b(() => [
|
203
|
+
p(Q, {
|
204
|
+
modelValue: v(r),
|
205
|
+
"onUpdate:modelValue": a[1] || (a[1] = (t) => E(r) ? r.value = t : null),
|
206
|
+
items: n
|
207
|
+
}, null, 8, ["modelValue"])
|
208
|
+
]),
|
209
|
+
_: 1
|
210
|
+
}, 8, ["modelValue"])
|
211
|
+
]),
|
212
|
+
M("div", te, [
|
213
|
+
p(G, {
|
214
|
+
button: {
|
215
|
+
appendIcon: "file_download",
|
216
|
+
variant: "primary",
|
217
|
+
label: "Export"
|
218
|
+
},
|
219
|
+
handler: async () => {
|
220
|
+
await v(U).downloadPortalTransactionReport(_.value);
|
221
|
+
}
|
222
|
+
}, null, 8, ["handler"])
|
223
|
+
])
|
224
|
+
]),
|
225
|
+
M("div", ae, [
|
226
|
+
p(X, {
|
227
|
+
modelValue: v(i),
|
228
|
+
"onUpdate:modelValue": a[3] || (a[3] = (t) => E(i) ? i.value = t : null)
|
229
|
+
}, null, 8, ["modelValue"]),
|
230
|
+
p(H, {
|
231
|
+
modelValue: v(f),
|
232
|
+
"onUpdate:modelValue": a[4] || (a[4] = (t) => E(f) ? f.value = t : null)
|
233
|
+
}, null, 8, ["modelValue"])
|
234
|
+
]),
|
235
|
+
p(J, {
|
236
|
+
loading: v(y),
|
237
|
+
data: l.value
|
238
|
+
}, null, 8, ["loading", "data"])
|
239
|
+
]),
|
240
|
+
_: 1
|
241
|
+
});
|
242
|
+
};
|
243
|
+
}
|
244
|
+
});
|
245
|
+
export {
|
246
|
+
_e as default
|
247
|
+
};
|
@@ -1,17 +1,17 @@
|
|
1
1
|
import { defineComponent as b, resolveComponent as g, openBlock as p, createBlock as E, normalizeClass as R, withCtx as T, createElementVNode as h, toDisplayString as V, createElementBlock as A, unref as u, createVNode as d, Fragment as Y, renderList as $, ref as C, watch as x, isRef as N, h as y } from "vue";
|
2
|
-
import { t as _, a as P, b as I } from "./transaction-
|
2
|
+
import { t as _, a as P, b as I } from "./transaction-5dZS6JFA.js";
|
3
3
|
import { h as w } from "./moment-h96o7c8I.js";
|
4
|
-
import { u as L } from "./index-
|
4
|
+
import { u as L } from "./index-DueuWuxx.js";
|
5
5
|
import { _ as B } from "./AdminLayout.vue_vue_type_script_setup_true_lang-BTmMOzwx.js";
|
6
6
|
import { _ as U } from "./AsyncButton.vue_vue_type_script_setup_true_lang-DcjzvYwT.js";
|
7
7
|
import { useSnackbar as G, useDialog as j } from "@feedmepos/ui-library";
|
8
8
|
import { w as D } from "./Modal-DB8M9o1T.js";
|
9
9
|
import { u as S } from "./error-K1CakhA9.js";
|
10
10
|
import { _ as Q } from "./DateRangePicker.vue_vue_type_script_setup_true_lang-dP_5WjEJ.js";
|
11
|
-
import { g as z } from "./grafana-
|
12
|
-
import { _ as H } from "./index.vue_vue_type_script_setup_true_lang-
|
13
|
-
import { e as v } from "./index-
|
14
|
-
import { g as J, a as W } from "./assets-
|
11
|
+
import { g as z } from "./grafana-BFQCDk-V.js";
|
12
|
+
import { _ as H } from "./index.vue_vue_type_script_setup_true_lang-PfAufXp3.js";
|
13
|
+
import { e as v } from "./index-CC8HNMje.js";
|
14
|
+
import { g as J, a as W } from "./assets-fxpnHIZr.js";
|
15
15
|
import { _ as X } from "./AutoCopyCell.vue_vue_type_script_setup_true_lang-CdmfrBoW.js";
|
16
16
|
const Z = /* @__PURE__ */ b({
|
17
17
|
__name: "Status",
|
@@ -1,11 +1,11 @@
|
|
1
1
|
import { defineComponent as R, ref as v, onMounted as Y, watch as m, resolveComponent as S, openBlock as b, createBlock as V, unref as r, withCtx as C, createElementVNode as d, createVNode as l, isRef as h } from "vue";
|
2
|
-
import { t as y, a as M } from "./transaction-
|
3
|
-
import { u as O } from "./index-
|
4
|
-
import { _ as $ } from "./TransactionTable.vue_vue_type_script_setup_true_lang-
|
2
|
+
import { t as y, a as M } from "./transaction-5dZS6JFA.js";
|
3
|
+
import { u as O } from "./index-CC8HNMje.js";
|
4
|
+
import { _ as $ } from "./TransactionTable.vue_vue_type_script_setup_true_lang-CoPiWynn.js";
|
5
5
|
import { h as g } from "./moment-h96o7c8I.js";
|
6
6
|
import { useCoreStore as k } from "@feedmepos/mf-common";
|
7
7
|
import { _ as E } from "./Layout.vue_vue_type_script_setup_true_lang-DJm5br5a.js";
|
8
|
-
import { u as N } from "./index-
|
8
|
+
import { u as N } from "./index-DueuWuxx.js";
|
9
9
|
import { _ as L } from "./AsyncButton.vue_vue_type_script_setup_true_lang-DcjzvYwT.js";
|
10
10
|
import { _ as P } from "./RestaurantSelector.vue_vue_type_script_setup_true_lang-p4qddIbp.js";
|
11
11
|
import { _ as A } from "./DateRangePicker.vue_vue_type_script_setup_true_lang-dP_5WjEJ.js";
|
@@ -1,9 +1,9 @@
|
|
1
1
|
import { defineComponent as o, resolveComponent as p, openBlock as s, createBlock as _, normalizeClass as f, withCtx as A, createElementVNode as N, toDisplayString as T, createElementBlock as g, unref as h, ref as w, h as u } from "vue";
|
2
2
|
import "@feedmepos/ui-library";
|
3
|
-
import { e as m } from "./index-
|
3
|
+
import { e as m } from "./index-CC8HNMje.js";
|
4
4
|
import "./dinero-CIVmXLL-.js";
|
5
5
|
import "./moment-h96o7c8I.js";
|
6
|
-
import { g as x, a as E } from "./assets-
|
6
|
+
import { g as x, a as E } from "./assets-fxpnHIZr.js";
|
7
7
|
const F = /* @__PURE__ */ o({
|
8
8
|
__name: "Status",
|
9
9
|
props: {
|
package/dist/api/index.d.ts
CHANGED
@@ -32,7 +32,7 @@ export declare const businessClientInstance: () => AxiosInstance;
|
|
32
32
|
export declare const restaurantClientInstance: (prefix?: string) => AxiosInstance;
|
33
33
|
type TransformFunction<T> = (value: T) => any;
|
34
34
|
type TransformFunctions<T> = {
|
35
|
-
[K in keyof T]?: TransformFunction<T[K]>;
|
35
|
+
[K in keyof T | string]?: TransformFunction<T[K | any]>;
|
36
36
|
};
|
37
37
|
export declare function flattenObject(obj: Record<string, any>, parentKey?: string): Record<string, any>;
|
38
38
|
export declare function localWorkbookAndDownload<T extends Object>(data: T[], options?: {
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { type SettlementDtoOutput } from "@feedmepos/payment-entity";
|
1
|
+
import { RMSSettlementDto, type SettlementDtoOutput } from "@feedmepos/payment-entity";
|
2
2
|
export declare const settlementApi: {
|
3
3
|
updateRemark(payload: {
|
4
4
|
id: string;
|
@@ -27,4 +27,8 @@ export declare const settlementApi: {
|
|
27
27
|
start: string;
|
28
28
|
end: string;
|
29
29
|
}): Promise<SettlementDtoOutput[]>;
|
30
|
+
readRestaurantRMSSettlements(dateRange: {
|
31
|
+
start: string;
|
32
|
+
end: string;
|
33
|
+
}): Promise<RMSSettlementDto[]>;
|
30
34
|
};
|
@@ -15,6 +15,7 @@ export declare const temrinalApi: {
|
|
15
15
|
updateById(id: string, payload: UpdateTerminalByIdDto): Promise<FdoTerminal>;
|
16
16
|
getBindCode(id: string): Promise<string>;
|
17
17
|
unbind(id: string): Promise<any>;
|
18
|
+
delete(id: string): Promise<any>;
|
18
19
|
/**
|
19
20
|
* Relying on the payout account so need pass in the restaurant id from the payout account
|
20
21
|
*/
|
@@ -10,8 +10,8 @@ export declare const terminalTransactionApi: {
|
|
10
10
|
limit: number;
|
11
11
|
cursor: string;
|
12
12
|
}): Promise<PaginatedResult<FdoTerminalTransaction>>;
|
13
|
-
|
14
|
-
|
13
|
+
readRestaurantTransactions(payload: {
|
14
|
+
restaurantId: string;
|
15
15
|
status: F_TERMINAL_TRANSACTION_ACTION[];
|
16
16
|
searchKey: string;
|
17
17
|
start: string;
|