@feedmepos/mf-payment 1.5.55-dev → 1.5.56-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/{OnboardForm-6AxZrEAf.js → OnboardForm-0BR3jqGJ.js} +1 -1
- package/dist/{OnboardForm-CziPCl4D.js → OnboardForm-BGkRWJ1W.js} +1 -1
- package/dist/{PayoutAccount-BT_92dvG.js → PayoutAccount-BkpugJsP.js} +87 -81
- package/dist/{PayoutAccount-BKxMz4dT.js → PayoutAccount-C0halZXa.js} +218 -211
- package/dist/{PayoutAccountSetting-CUK1KEM0.js → PayoutAccountSetting-C2mquWAV.js} +516 -511
- package/dist/TextInputDialog.vue_vue_type_script_setup_true_lang-D8W8_SO2.js +55 -0
- package/dist/{Transaction-44TKMEDC.js → Transaction-DbeYRQ8Z.js} +157 -204
- package/dist/{app-CxJUOgZy.js → app-D577rfXx.js} +6 -6
- package/dist/app.js +1 -1
- package/dist/package.json +1 -1
- package/dist/{payout-account-CP6qQFlB.js → payout-account-Bo0AnO4t.js} +1 -1
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/package.json +1 -1
|
@@ -1,16 +1,18 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { p as
|
|
3
|
-
import { u as
|
|
1
|
+
import { defineComponent as T, resolveComponent as p, openBlock as g, createElementBlock as h, Fragment as G, createElementVNode as r, createVNode as a, withCtx as F, createTextVNode as k, toDisplayString as I, unref as u, ref as U, watch as Z, createBlock as w, computed as B, isRef as j, createCommentVNode as S, h as K, onMounted as ne, resolveDynamicComponent as J, normalizeProps as Q, mergeProps as W } from "vue";
|
|
2
|
+
import { p as $ } from "./index-C80a7-Ks.js";
|
|
3
|
+
import { u as Y, e as _ } from "./index-D0j1LZAB.js";
|
|
4
4
|
import { _ as oe } from "./Layout.vue_vue_type_script_setup_true_lang-BKIvkgA_.js";
|
|
5
5
|
import { useRouter as ue } from "vue-router";
|
|
6
|
-
import { u as
|
|
6
|
+
import { u as z } from "./index-BkQ7t3F6.js";
|
|
7
7
|
import { _ as L } from "./DocumentViewer.vue_vue_type_script_setup_true_lang-KebV8Zws.js";
|
|
8
|
+
import { h as se } from "./moment-h96o7c8I.js";
|
|
8
9
|
import { P as te } from "./PDFViewer-CIPPbzWD.js";
|
|
9
|
-
import { useSnackbar as
|
|
10
|
-
import { u as
|
|
11
|
-
import {
|
|
10
|
+
import { useSnackbar as H, useDialog as re, components as ie } from "@feedmepos/ui-library";
|
|
11
|
+
import { u as q } from "./error-K1CakhA9.js";
|
|
12
|
+
import { _ as ce } from "./TextInputDialog.vue_vue_type_script_setup_true_lang-D8W8_SO2.js";
|
|
13
|
+
import { z as V, a as A } from "./validator-DzjyJnvv.js";
|
|
12
14
|
import { useCoreStore as ae } from "@feedmepos/mf-common";
|
|
13
|
-
const
|
|
15
|
+
const me = { class: "flex gap-16 mb-6" }, de = { class: "flex gap-16 mb-6" }, pe = /* @__PURE__ */ T({
|
|
14
16
|
__name: "Information",
|
|
15
17
|
props: {
|
|
16
18
|
payoutAccount: {
|
|
@@ -19,37 +21,37 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
19
21
|
}
|
|
20
22
|
},
|
|
21
23
|
setup(n) {
|
|
22
|
-
return (
|
|
24
|
+
return (v, e) => {
|
|
23
25
|
var s, f;
|
|
24
|
-
const
|
|
25
|
-
return
|
|
26
|
-
|
|
27
|
-
|
|
26
|
+
const y = p("FmCardHeader"), o = p("FmCardSection"), t = p("FmCard");
|
|
27
|
+
return g(), h(G, null, [
|
|
28
|
+
r("div", me, [
|
|
29
|
+
a(t, {
|
|
28
30
|
horizontal: "",
|
|
29
31
|
class: "flex-1 p-6",
|
|
30
32
|
variant: "elevated"
|
|
31
33
|
}, {
|
|
32
34
|
default: F(() => [
|
|
33
|
-
|
|
35
|
+
a(o, { class: "flex flex-col gap-16 justify-between" }, {
|
|
34
36
|
default: F(() => [
|
|
35
|
-
|
|
37
|
+
a(y, {
|
|
36
38
|
class: "p-0",
|
|
37
39
|
title: "Account Info",
|
|
38
40
|
subtitle: ""
|
|
39
41
|
}),
|
|
40
|
-
|
|
42
|
+
a(o, { class: "p-0" }, {
|
|
41
43
|
default: F(() => {
|
|
42
|
-
var
|
|
44
|
+
var i, l, d, c, m;
|
|
43
45
|
return [
|
|
44
|
-
e[0] || (e[0] =
|
|
45
|
-
|
|
46
|
-
e[1] || (e[1] =
|
|
47
|
-
e[2] || (e[2] =
|
|
48
|
-
|
|
49
|
-
e[3] || (e[3] =
|
|
50
|
-
e[4] || (e[4] =
|
|
51
|
-
|
|
52
|
-
e[5] || (e[5] =
|
|
46
|
+
e[0] || (e[0] = r("b", null, "For", -1)),
|
|
47
|
+
k(": " + I((l = (i = n.payoutAccount) == null ? void 0 : i.store) == null ? void 0 : l.event) + " ", 1),
|
|
48
|
+
e[1] || (e[1] = r("br", null, null, -1)),
|
|
49
|
+
e[2] || (e[2] = r("b", null, "Reference", -1)),
|
|
50
|
+
k(": " + I((c = (d = n.payoutAccount) == null ? void 0 : d.store) == null ? void 0 : c.id), 1),
|
|
51
|
+
e[3] || (e[3] = r("br", null, null, -1)),
|
|
52
|
+
e[4] || (e[4] = r("b", null, "Business", -1)),
|
|
53
|
+
k(": " + I((m = n.payoutAccount) == null ? void 0 : m.businessId), 1),
|
|
54
|
+
e[5] || (e[5] = r("br", null, null, -1))
|
|
53
55
|
];
|
|
54
56
|
}),
|
|
55
57
|
_: 1
|
|
@@ -60,32 +62,32 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
60
62
|
]),
|
|
61
63
|
_: 1
|
|
62
64
|
}),
|
|
63
|
-
|
|
65
|
+
a(t, {
|
|
64
66
|
horizontal: "",
|
|
65
67
|
class: "flex-1 p-6",
|
|
66
68
|
variant: "elevated"
|
|
67
69
|
}, {
|
|
68
70
|
default: F(() => [
|
|
69
|
-
|
|
71
|
+
a(o, { class: "flex flex-col gap-16 justify-between" }, {
|
|
70
72
|
default: F(() => [
|
|
71
|
-
|
|
73
|
+
a(y, {
|
|
72
74
|
class: "p-0",
|
|
73
75
|
title: "Key Person",
|
|
74
76
|
subtitle: ""
|
|
75
77
|
}),
|
|
76
|
-
|
|
78
|
+
a(o, { class: "p-0" }, {
|
|
77
79
|
default: F(() => {
|
|
78
|
-
var
|
|
80
|
+
var i, l, d, c, m, b, x, C;
|
|
79
81
|
return [
|
|
80
|
-
e[6] || (e[6] =
|
|
81
|
-
|
|
82
|
-
e[7] || (e[7] =
|
|
83
|
-
e[8] || (e[8] =
|
|
84
|
-
|
|
85
|
-
e[9] || (e[9] =
|
|
86
|
-
e[10] || (e[10] =
|
|
87
|
-
|
|
88
|
-
e[11] || (e[11] =
|
|
82
|
+
e[6] || (e[6] = r("b", null, "Email", -1)),
|
|
83
|
+
k(": " + I((d = (l = (i = n.payoutAccount) == null ? void 0 : i.store) == null ? void 0 : l.keyPerson) == null ? void 0 : d.email) + " ", 1),
|
|
84
|
+
e[7] || (e[7] = r("br", null, null, -1)),
|
|
85
|
+
e[8] || (e[8] = r("b", null, "Name", -1)),
|
|
86
|
+
k(": " + I((b = (m = (c = n.payoutAccount) == null ? void 0 : c.store) == null ? void 0 : m.keyPerson) == null ? void 0 : b.name), 1),
|
|
87
|
+
e[9] || (e[9] = r("br", null, null, -1)),
|
|
88
|
+
e[10] || (e[10] = r("b", null, "Phone", -1)),
|
|
89
|
+
k(": " + I((C = (x = n.payoutAccount) == null ? void 0 : x.store.keyPerson) == null ? void 0 : C.phone), 1),
|
|
90
|
+
e[11] || (e[11] = r("br", null, null, -1))
|
|
89
91
|
];
|
|
90
92
|
}),
|
|
91
93
|
_: 1
|
|
@@ -97,33 +99,35 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
97
99
|
_: 1
|
|
98
100
|
})
|
|
99
101
|
]),
|
|
100
|
-
|
|
101
|
-
|
|
102
|
+
r("div", de, [
|
|
103
|
+
a(t, {
|
|
102
104
|
horizontal: "",
|
|
103
105
|
class: "flex-1 p-6",
|
|
104
106
|
variant: "elevated"
|
|
105
107
|
}, {
|
|
106
108
|
default: F(() => [
|
|
107
|
-
|
|
109
|
+
a(o, { class: "flex flex-col gap-16 justify-between" }, {
|
|
108
110
|
default: F(() => [
|
|
109
|
-
|
|
111
|
+
a(y, {
|
|
110
112
|
class: "p-0",
|
|
111
113
|
title: "Status Info",
|
|
112
114
|
subtitle: ""
|
|
113
115
|
}),
|
|
114
|
-
|
|
116
|
+
a(o, { class: "p-0" }, {
|
|
115
117
|
default: F(() => {
|
|
116
|
-
var
|
|
118
|
+
var i, l, d;
|
|
117
119
|
return [
|
|
118
|
-
e[12] || (e[12] =
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
e[
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
e[
|
|
120
|
+
e[12] || (e[12] = r("b", null, "Submission Date", -1)),
|
|
121
|
+
k(": " + I((i = n.payoutAccount) != null && i.submissionDate ? u(se)(n.payoutAccount.submissionDate).format(
|
|
122
|
+
"YYYY-MM-DD HH:mm:ss"
|
|
123
|
+
) : "—"), 1),
|
|
124
|
+
e[13] || (e[13] = r("br", null, null, -1)),
|
|
125
|
+
e[14] || (e[14] = r("b", null, "Status By", -1)),
|
|
126
|
+
k(": " + I(((l = n.payoutAccount) == null ? void 0 : l.statusBy) ?? "—"), 1),
|
|
127
|
+
e[15] || (e[15] = r("br", null, null, -1)),
|
|
128
|
+
e[16] || (e[16] = r("b", null, "Status Reason", -1)),
|
|
129
|
+
k(": " + I(((d = n.payoutAccount) == null ? void 0 : d.statusReason) ?? "—"), 1),
|
|
130
|
+
e[17] || (e[17] = r("br", null, null, -1))
|
|
127
131
|
];
|
|
128
132
|
}),
|
|
129
133
|
_: 1
|
|
@@ -135,8 +139,8 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
135
139
|
_: 1
|
|
136
140
|
})
|
|
137
141
|
]),
|
|
138
|
-
e[18] || (e[18] =
|
|
139
|
-
|
|
142
|
+
e[18] || (e[18] = r("p", { class: "fm-typo-en-body-lg-600 mb-6" }, "Exterior Photo", -1)),
|
|
143
|
+
a(L, {
|
|
140
144
|
document: n.payoutAccount.store.exteriorPhoto,
|
|
141
145
|
"business-id": n.payoutAccount.businessId,
|
|
142
146
|
"restaurant-id": ((f = (s = n.payoutAccount) == null ? void 0 : s.store) == null ? void 0 : f.event) === "ORDERING" ? n.payoutAccount.store.id : void 0
|
|
@@ -144,7 +148,7 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
144
148
|
], 64);
|
|
145
149
|
};
|
|
146
150
|
}
|
|
147
|
-
}),
|
|
151
|
+
}), ye = { class: "flex gap-16 mb-6" }, ve = { class: "flex gap-16" }, fe = { class: "flex-1" }, be = { class: "flex-1" }, ge = /* @__PURE__ */ T({
|
|
148
152
|
__name: "Settlement",
|
|
149
153
|
props: {
|
|
150
154
|
payoutAccount: {
|
|
@@ -153,34 +157,34 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
153
157
|
}
|
|
154
158
|
},
|
|
155
159
|
setup(n) {
|
|
156
|
-
return (
|
|
157
|
-
var s, f,
|
|
158
|
-
const
|
|
159
|
-
return
|
|
160
|
-
|
|
161
|
-
|
|
160
|
+
return (v, e) => {
|
|
161
|
+
var s, f, i, l;
|
|
162
|
+
const y = p("FmCardHeader"), o = p("FmCardSection"), t = p("FmCard");
|
|
163
|
+
return g(), h(G, null, [
|
|
164
|
+
r("div", ye, [
|
|
165
|
+
a(t, {
|
|
162
166
|
horizontal: "",
|
|
163
167
|
class: "flex-1 p-6",
|
|
164
168
|
variant: "elevated"
|
|
165
169
|
}, {
|
|
166
170
|
default: F(() => [
|
|
167
|
-
|
|
171
|
+
a(o, { class: "flex flex-col gap-16 justify-between" }, {
|
|
168
172
|
default: F(() => [
|
|
169
|
-
|
|
173
|
+
a(y, {
|
|
170
174
|
class: "p-0",
|
|
171
175
|
title: "Company Info",
|
|
172
176
|
subtitle: ""
|
|
173
177
|
}),
|
|
174
|
-
|
|
178
|
+
a(o, { class: "p-0" }, {
|
|
175
179
|
default: F(() => {
|
|
176
|
-
var
|
|
180
|
+
var d, c;
|
|
177
181
|
return [
|
|
178
|
-
e[0] || (e[0] =
|
|
179
|
-
|
|
180
|
-
e[1] || (e[1] =
|
|
181
|
-
e[2] || (e[2] =
|
|
182
|
-
|
|
183
|
-
e[3] || (e[3] =
|
|
182
|
+
e[0] || (e[0] = r("b", null, "Name", -1)),
|
|
183
|
+
k(": " + I((d = n.payoutAccount) == null ? void 0 : d.store.companyName), 1),
|
|
184
|
+
e[1] || (e[1] = r("br", null, null, -1)),
|
|
185
|
+
e[2] || (e[2] = r("b", null, "Registration Number", -1)),
|
|
186
|
+
k(": " + I((c = n.payoutAccount) == null ? void 0 : c.store.regNo), 1),
|
|
187
|
+
e[3] || (e[3] = r("br", null, null, -1))
|
|
184
188
|
];
|
|
185
189
|
}),
|
|
186
190
|
_: 1
|
|
@@ -191,31 +195,31 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
191
195
|
]),
|
|
192
196
|
_: 1
|
|
193
197
|
}),
|
|
194
|
-
|
|
198
|
+
a(t, {
|
|
195
199
|
horizontal: "",
|
|
196
200
|
class: "flex-1 p-6",
|
|
197
201
|
variant: "elevated"
|
|
198
202
|
}, {
|
|
199
203
|
default: F(() => [
|
|
200
|
-
|
|
204
|
+
a(o, { class: "flex flex-col gap-16 justify-between" }, {
|
|
201
205
|
default: F(() => [
|
|
202
|
-
|
|
206
|
+
a(y, {
|
|
203
207
|
class: "p-0",
|
|
204
208
|
title: "Bank Info",
|
|
205
209
|
subtitle: ""
|
|
206
210
|
}),
|
|
207
|
-
|
|
211
|
+
a(o, { class: "p-0" }, {
|
|
208
212
|
default: F(() => {
|
|
209
|
-
var
|
|
213
|
+
var d, c, m, b, x, C;
|
|
210
214
|
return [
|
|
211
|
-
e[4] || (e[4] =
|
|
212
|
-
|
|
213
|
-
e[5] || (e[5] =
|
|
214
|
-
e[6] || (e[6] =
|
|
215
|
-
|
|
216
|
-
e[7] || (e[7] =
|
|
217
|
-
e[8] || (e[8] =
|
|
218
|
-
|
|
215
|
+
e[4] || (e[4] = r("b", null, "Bank", -1)),
|
|
216
|
+
k(": " + I((c = (d = n.payoutAccount) == null ? void 0 : d.store.bank) == null ? void 0 : c.name), 1),
|
|
217
|
+
e[5] || (e[5] = r("br", null, null, -1)),
|
|
218
|
+
e[6] || (e[6] = r("b", null, "Name", -1)),
|
|
219
|
+
k(": " + I((b = (m = n.payoutAccount) == null ? void 0 : m.store.bank) == null ? void 0 : b.holderName), 1),
|
|
220
|
+
e[7] || (e[7] = r("br", null, null, -1)),
|
|
221
|
+
e[8] || (e[8] = r("b", null, "Number", -1)),
|
|
222
|
+
k(": " + I((C = (x = n.payoutAccount) == null ? void 0 : x.store.bank) == null ? void 0 : C.accountNumber), 1)
|
|
219
223
|
];
|
|
220
224
|
}),
|
|
221
225
|
_: 1
|
|
@@ -227,17 +231,17 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
227
231
|
_: 1
|
|
228
232
|
})
|
|
229
233
|
]),
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
e[9] || (e[9] =
|
|
233
|
-
|
|
234
|
+
r("div", ve, [
|
|
235
|
+
r("div", fe, [
|
|
236
|
+
e[9] || (e[9] = r("p", { class: "fm-typo-en-body-lg-600 mb-6" }, "SSM", -1)),
|
|
237
|
+
a(L, {
|
|
234
238
|
"business-id": n.payoutAccount.businessId,
|
|
235
239
|
"restaurant-id": ((f = (s = n.payoutAccount) == null ? void 0 : s.store) == null ? void 0 : f.event) === "ORDERING" ? n.payoutAccount.store.id : void 0,
|
|
236
240
|
document: n.payoutAccount.store.ssm
|
|
237
241
|
}, {
|
|
238
|
-
default: F(({ src:
|
|
239
|
-
|
|
240
|
-
pdf:
|
|
242
|
+
default: F(({ src: d }) => [
|
|
243
|
+
a(te, {
|
|
244
|
+
pdf: d,
|
|
241
245
|
"disable-text-layer": !0,
|
|
242
246
|
"disable-annotation-layer": !0
|
|
243
247
|
}, null, 8, ["pdf"])
|
|
@@ -245,16 +249,16 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
245
249
|
_: 1
|
|
246
250
|
}, 8, ["business-id", "restaurant-id", "document"])
|
|
247
251
|
]),
|
|
248
|
-
|
|
249
|
-
e[10] || (e[10] =
|
|
250
|
-
|
|
252
|
+
r("div", be, [
|
|
253
|
+
e[10] || (e[10] = r("p", { class: "fm-typo-en-body-lg-600 mb-6" }, "Bank Statement", -1)),
|
|
254
|
+
a(L, {
|
|
251
255
|
"business-id": n.payoutAccount.businessId,
|
|
252
|
-
"restaurant-id": ((
|
|
256
|
+
"restaurant-id": ((l = (i = n.payoutAccount) == null ? void 0 : i.store) == null ? void 0 : l.event) === "ORDERING" ? n.payoutAccount.store.id : void 0,
|
|
253
257
|
document: n.payoutAccount.store.bankStatement
|
|
254
258
|
}, {
|
|
255
|
-
default: F(({ src:
|
|
256
|
-
|
|
257
|
-
pdf:
|
|
259
|
+
default: F(({ src: d }) => [
|
|
260
|
+
a(te, {
|
|
261
|
+
pdf: d,
|
|
258
262
|
"disable-text-layer": !0,
|
|
259
263
|
"disable-annotation-layer": !0
|
|
260
264
|
}, null, 8, ["pdf"])
|
|
@@ -266,74 +270,74 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
266
270
|
], 64);
|
|
267
271
|
};
|
|
268
272
|
}
|
|
269
|
-
}),
|
|
273
|
+
}), Fe = /* @__PURE__ */ T({
|
|
270
274
|
__name: "RateInput",
|
|
271
275
|
props: {
|
|
272
276
|
data: {},
|
|
273
277
|
onChange: { type: Function }
|
|
274
278
|
},
|
|
275
279
|
setup(n) {
|
|
276
|
-
const
|
|
277
|
-
return Z(e, (
|
|
278
|
-
|
|
279
|
-
}), (
|
|
280
|
-
const t =
|
|
281
|
-
return
|
|
280
|
+
const v = n, e = U(v.data.toString());
|
|
281
|
+
return Z(e, (y) => {
|
|
282
|
+
v.onChange(parseFloat(y));
|
|
283
|
+
}), (y, o) => {
|
|
284
|
+
const t = p("FmTextField");
|
|
285
|
+
return g(), w(t, {
|
|
282
286
|
inputmode: "decimal",
|
|
283
287
|
modelValue: e.value,
|
|
284
|
-
"onUpdate:modelValue":
|
|
288
|
+
"onUpdate:modelValue": o[0] || (o[0] = (s) => e.value = s)
|
|
285
289
|
}, {
|
|
286
|
-
append: F(() => [...
|
|
287
|
-
|
|
290
|
+
append: F(() => [...o[1] || (o[1] = [
|
|
291
|
+
k("%", -1)
|
|
288
292
|
])]),
|
|
289
293
|
_: 1
|
|
290
294
|
}, 8, ["modelValue"]);
|
|
291
295
|
};
|
|
292
296
|
}
|
|
293
|
-
}),
|
|
297
|
+
}), xe = /* @__PURE__ */ T({
|
|
294
298
|
__name: "TPlusInput",
|
|
295
299
|
props: {
|
|
296
300
|
data: {},
|
|
297
301
|
onChange: { type: Function }
|
|
298
302
|
},
|
|
299
303
|
setup(n) {
|
|
300
|
-
const
|
|
301
|
-
return Z(e, (
|
|
302
|
-
|
|
303
|
-
}), (
|
|
304
|
-
const t =
|
|
305
|
-
return
|
|
304
|
+
const v = n, e = U(v.data.toString());
|
|
305
|
+
return Z(e, (y) => {
|
|
306
|
+
v.onChange(parseInt(y));
|
|
307
|
+
}), (y, o) => {
|
|
308
|
+
const t = p("FmTextField");
|
|
309
|
+
return g(), w(t, {
|
|
306
310
|
inputmode: "numeric",
|
|
307
311
|
modelValue: e.value,
|
|
308
|
-
"onUpdate:modelValue":
|
|
312
|
+
"onUpdate:modelValue": o[0] || (o[0] = (s) => e.value = s)
|
|
309
313
|
}, null, 8, ["modelValue"]);
|
|
310
314
|
};
|
|
311
315
|
}
|
|
312
|
-
}),
|
|
316
|
+
}), we = /* @__PURE__ */ T({
|
|
313
317
|
__name: "MinimumFeeInput",
|
|
314
318
|
props: {
|
|
315
319
|
data: {},
|
|
316
320
|
onChange: { type: Function }
|
|
317
321
|
},
|
|
318
322
|
setup(n) {
|
|
319
|
-
const
|
|
320
|
-
return Z(e, (
|
|
321
|
-
|
|
322
|
-
}), (
|
|
323
|
-
const t =
|
|
324
|
-
return
|
|
323
|
+
const v = n, e = U(v.data.toString());
|
|
324
|
+
return Z(e, (y) => {
|
|
325
|
+
v.onChange(parseFloat(y));
|
|
326
|
+
}), (y, o) => {
|
|
327
|
+
const t = p("FmTextField");
|
|
328
|
+
return g(), w(t, {
|
|
325
329
|
inputmode: "numeric",
|
|
326
330
|
modelValue: e.value,
|
|
327
|
-
"onUpdate:modelValue":
|
|
331
|
+
"onUpdate:modelValue": o[0] || (o[0] = (s) => e.value = s)
|
|
328
332
|
}, {
|
|
329
|
-
prepend: F(() => [...
|
|
330
|
-
|
|
333
|
+
prepend: F(() => [...o[1] || (o[1] = [
|
|
334
|
+
k("$", -1)
|
|
331
335
|
])]),
|
|
332
336
|
_: 1
|
|
333
337
|
}, 8, ["modelValue"]);
|
|
334
338
|
};
|
|
335
339
|
}
|
|
336
|
-
}),
|
|
340
|
+
}), Ve = { class: "flex gap-16 mt-6" }, Ae = { class: "flex-1" }, Ce = { class: "flex-1" }, ke = { class: "my-6 w-full flex justify-end" }, Te = { class: "w-[320px]" }, Ue = /* @__PURE__ */ T({
|
|
337
341
|
__name: "PaymentStatus",
|
|
338
342
|
props: {
|
|
339
343
|
onUpdate: {
|
|
@@ -346,45 +350,58 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
346
350
|
}
|
|
347
351
|
},
|
|
348
352
|
setup(n) {
|
|
349
|
-
const
|
|
353
|
+
const v = n, e = U(!1), y = H(), o = re(), t = async (c) => {
|
|
350
354
|
try {
|
|
351
|
-
e.value = !0, await
|
|
355
|
+
e.value = !0, await v.onUpdate(c), y.open({
|
|
352
356
|
type: "success",
|
|
353
357
|
title: "Payout account update succesfully"
|
|
354
358
|
});
|
|
355
|
-
} catch (
|
|
356
|
-
|
|
359
|
+
} catch (m) {
|
|
360
|
+
y.open({
|
|
357
361
|
type: "error",
|
|
358
362
|
title: "Error occurs when updating payout account",
|
|
359
|
-
message:
|
|
363
|
+
message: q(m)
|
|
360
364
|
});
|
|
361
365
|
} finally {
|
|
362
366
|
e.value = !1;
|
|
363
367
|
}
|
|
364
|
-
},
|
|
368
|
+
}, s = async () => {
|
|
369
|
+
o.close(), o.open({
|
|
370
|
+
title: "Rejection Reason",
|
|
371
|
+
closeButton: !0,
|
|
372
|
+
overlay: !0,
|
|
373
|
+
contentComponent: ce,
|
|
374
|
+
contentComponentProps: {
|
|
375
|
+
label: "Reason",
|
|
376
|
+
placeholder: "Enter reason for rejection..."
|
|
377
|
+
}
|
|
378
|
+
}).onPrimary((c) => {
|
|
379
|
+
v.payoutAccount.enable = !1, v.payoutAccount.status = "REJECTED", v.payoutAccount.statusReason = c, t(v.payoutAccount), o.close();
|
|
380
|
+
});
|
|
381
|
+
}, { search: f } = z({
|
|
365
382
|
search: ""
|
|
366
|
-
}),
|
|
367
|
-
const { ssm:
|
|
368
|
-
return
|
|
369
|
-
}),
|
|
383
|
+
}), i = B(() => {
|
|
384
|
+
const { ssm: c, bank: m, bankStatement: b } = v.payoutAccount.store;
|
|
385
|
+
return c && m && m.name && m.accountNumber && m.holderName && b;
|
|
386
|
+
}), l = U(""), d = [
|
|
370
387
|
{
|
|
371
388
|
header: () => "Payment Method",
|
|
372
389
|
accessorKey: "issuer",
|
|
373
|
-
cell: (
|
|
390
|
+
cell: (c) => `${c.row.original.issuer} (${c.row.original.variant})`
|
|
374
391
|
},
|
|
375
392
|
{
|
|
376
393
|
header: () => "Rate",
|
|
377
394
|
accessorKey: "rate",
|
|
378
|
-
cell: ({ row:
|
|
379
|
-
let
|
|
380
|
-
return
|
|
381
|
-
data:
|
|
382
|
-
onChange: (
|
|
383
|
-
const
|
|
384
|
-
|
|
395
|
+
cell: ({ row: c }) => {
|
|
396
|
+
let m = 0;
|
|
397
|
+
return c.original.rate && (m = c.original.rate.amount / Math.pow(10, c.original.rate.precision)), K(Fe, {
|
|
398
|
+
data: m,
|
|
399
|
+
onChange: (b) => {
|
|
400
|
+
const x = v.payoutAccount.methods.at(c.index);
|
|
401
|
+
x.rate || (x.rate = {
|
|
385
402
|
amount: 0,
|
|
386
403
|
precision: 4
|
|
387
|
-
}),
|
|
404
|
+
}), x.rate.amount = b * Math.pow(10, x.rate.precision);
|
|
388
405
|
}
|
|
389
406
|
});
|
|
390
407
|
}
|
|
@@ -392,16 +409,16 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
392
409
|
{
|
|
393
410
|
header: () => "Minimum Fee",
|
|
394
411
|
accessorKey: "minimumFee",
|
|
395
|
-
cell: ({ row:
|
|
396
|
-
let
|
|
397
|
-
return
|
|
398
|
-
data:
|
|
399
|
-
onChange: (
|
|
400
|
-
const
|
|
401
|
-
|
|
412
|
+
cell: ({ row: c }) => {
|
|
413
|
+
let m = 0;
|
|
414
|
+
return c.original.minimumFee && (m = c.original.minimumFee.amount / Math.pow(10, c.original.minimumFee.precision)), K(we, {
|
|
415
|
+
data: m,
|
|
416
|
+
onChange: (b) => {
|
|
417
|
+
const x = v.payoutAccount.methods.at(c.index);
|
|
418
|
+
x.minimumFee || (x.minimumFee = {
|
|
402
419
|
amount: 0,
|
|
403
420
|
precision: 2
|
|
404
|
-
}),
|
|
421
|
+
}), x.minimumFee.amount = b * Math.pow(10, x.minimumFee.precision);
|
|
405
422
|
}
|
|
406
423
|
});
|
|
407
424
|
}
|
|
@@ -409,113 +426,101 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
409
426
|
{
|
|
410
427
|
header: () => "T plus",
|
|
411
428
|
accessorKey: "tPlus",
|
|
412
|
-
cell: ({ row:
|
|
413
|
-
data:
|
|
414
|
-
onChange: (
|
|
415
|
-
const
|
|
416
|
-
|
|
429
|
+
cell: ({ row: c }) => K(xe, {
|
|
430
|
+
data: c.original.tPlus ?? 0,
|
|
431
|
+
onChange: (m) => {
|
|
432
|
+
const b = v.payoutAccount.methods.at(c.index);
|
|
433
|
+
b.tPlus = m;
|
|
417
434
|
}
|
|
418
435
|
})
|
|
419
436
|
}
|
|
420
437
|
];
|
|
421
|
-
return (
|
|
422
|
-
const
|
|
423
|
-
return
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
"onUpdate:modelValue": o[0] || (o[0] = (A) => n.payoutAccount.status = A),
|
|
438
|
+
return (c, m) => {
|
|
439
|
+
const b = p("FmRadio"), x = p("FmRadioGroup"), C = p("FmSwitch"), D = p("FmSearch"), P = p("FmTable"), R = p("FmButton");
|
|
440
|
+
return g(), h(G, null, [
|
|
441
|
+
r("div", Ve, [
|
|
442
|
+
r("div", Ae, [
|
|
443
|
+
a(x, {
|
|
444
|
+
"model-value": n.payoutAccount.status,
|
|
429
445
|
label: "Account Status"
|
|
430
446
|
}, {
|
|
431
447
|
default: F(() => [
|
|
432
|
-
|
|
433
|
-
value: "NEW",
|
|
434
|
-
label: "New"
|
|
435
|
-
}),
|
|
436
|
-
l(y, {
|
|
448
|
+
a(b, {
|
|
437
449
|
value: "PENDING",
|
|
438
450
|
label: "Pending"
|
|
439
451
|
}),
|
|
440
|
-
|
|
452
|
+
a(b, {
|
|
441
453
|
value: "APPROVED",
|
|
442
454
|
label: "Approved"
|
|
443
455
|
}),
|
|
444
|
-
|
|
456
|
+
a(b, {
|
|
445
457
|
value: "REJECTED",
|
|
446
|
-
label: "Rejected"
|
|
458
|
+
label: "Rejected",
|
|
459
|
+
onClick: s
|
|
447
460
|
})
|
|
448
461
|
]),
|
|
449
462
|
_: 1
|
|
450
|
-
}, 8, ["
|
|
451
|
-
n.payoutAccount.status === "REJECTED" ? (b(), x(g, {
|
|
452
|
-
key: 0,
|
|
453
|
-
modelValue: n.payoutAccount.statusReason,
|
|
454
|
-
"onUpdate:modelValue": o[1] || (o[1] = (A) => n.payoutAccount.statusReason = A),
|
|
455
|
-
class: "mt-4",
|
|
456
|
-
label: "Rejection Reason",
|
|
457
|
-
placeholder: "Enter reason for rejection..."
|
|
458
|
-
}, null, 8, ["modelValue"])) : S("", !0)
|
|
463
|
+
}, 8, ["model-value"])
|
|
459
464
|
]),
|
|
460
|
-
|
|
461
|
-
|
|
465
|
+
r("div", Ce, [
|
|
466
|
+
a(C, {
|
|
462
467
|
modelValue: n.payoutAccount.enable,
|
|
463
|
-
"onUpdate:modelValue":
|
|
464
|
-
disabled: !
|
|
468
|
+
"onUpdate:modelValue": m[0] || (m[0] = (M) => n.payoutAccount.enable = M),
|
|
469
|
+
disabled: !i.value,
|
|
465
470
|
label: "Enabled",
|
|
466
471
|
sublabel: "Merchant can use online features such as e-payment, settlement"
|
|
467
472
|
}, null, 8, ["modelValue", "disabled"])
|
|
468
473
|
])
|
|
469
474
|
]),
|
|
470
|
-
n.payoutAccount.enable ? (
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
modelValue:
|
|
475
|
-
"onUpdate:modelValue":
|
|
475
|
+
n.payoutAccount.enable ? (g(), h(G, { key: 0 }, [
|
|
476
|
+
r("div", ke, [
|
|
477
|
+
r("div", Te, [
|
|
478
|
+
a(D, {
|
|
479
|
+
modelValue: u(f),
|
|
480
|
+
"onUpdate:modelValue": m[1] || (m[1] = (M) => j(f) ? f.value = M : null),
|
|
476
481
|
placeholder: "Search Method ..."
|
|
477
482
|
}, null, 8, ["modelValue"])
|
|
478
483
|
])
|
|
479
484
|
]),
|
|
480
|
-
|
|
485
|
+
a(P, {
|
|
481
486
|
class: "mt-6",
|
|
482
|
-
modelValue:
|
|
483
|
-
"onUpdate:modelValue":
|
|
487
|
+
modelValue: l.value,
|
|
488
|
+
"onUpdate:modelValue": m[2] || (m[2] = (M) => l.value = M),
|
|
484
489
|
"shrink-at": !1,
|
|
485
|
-
"search-value":
|
|
490
|
+
"search-value": u(f),
|
|
486
491
|
"row-data": n.payoutAccount.methods,
|
|
487
|
-
"column-defs":
|
|
492
|
+
"column-defs": d
|
|
488
493
|
}, null, 8, ["modelValue", "search-value", "row-data"])
|
|
489
494
|
], 64)) : S("", !0),
|
|
490
|
-
|
|
495
|
+
a(R, {
|
|
491
496
|
class: "w-full mt-6",
|
|
492
497
|
variant: "primary",
|
|
493
498
|
label: "Save",
|
|
494
499
|
loading: e.value,
|
|
495
|
-
onclick: () =>
|
|
500
|
+
onclick: () => t(n.payoutAccount)
|
|
496
501
|
}, null, 8, ["loading", "onclick"])
|
|
497
502
|
], 64);
|
|
498
503
|
};
|
|
499
504
|
}
|
|
500
|
-
}),
|
|
505
|
+
}), Ie = { class: "flex" }, Se = /* @__PURE__ */ T({
|
|
501
506
|
__name: "Actions",
|
|
502
507
|
emits: ["edit", "delete"],
|
|
503
|
-
setup(n, { emit:
|
|
504
|
-
const e =
|
|
505
|
-
return (
|
|
506
|
-
const t =
|
|
507
|
-
return
|
|
508
|
-
|
|
508
|
+
setup(n, { emit: v }) {
|
|
509
|
+
const e = v;
|
|
510
|
+
return (y, o) => {
|
|
511
|
+
const t = p("FmButton");
|
|
512
|
+
return g(), h("div", Ie, [
|
|
513
|
+
a(t, {
|
|
509
514
|
variant: "plain",
|
|
510
515
|
"prepend-icon": "delete",
|
|
511
|
-
onClick:
|
|
516
|
+
onClick: o[0] || (o[0] = (s) => {
|
|
512
517
|
s.stopPropagation(), e("delete");
|
|
513
518
|
})
|
|
514
519
|
})
|
|
515
520
|
]);
|
|
516
521
|
};
|
|
517
522
|
}
|
|
518
|
-
}),
|
|
523
|
+
}), De = { class: "flex justify-end px-6 pb-6" }, _e = /* @__PURE__ */ T({
|
|
519
524
|
__name: "PaymentChannel",
|
|
520
525
|
props: {
|
|
521
526
|
payoutAccount: {
|
|
@@ -524,46 +529,46 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
524
529
|
}
|
|
525
530
|
},
|
|
526
531
|
setup(n) {
|
|
527
|
-
const
|
|
532
|
+
const v = H(), e = n, { isLoading: y, startAsyncCall: o } = Y(), t = U([]);
|
|
528
533
|
function s() {
|
|
529
|
-
|
|
530
|
-
t.value = await
|
|
534
|
+
o(async () => {
|
|
535
|
+
t.value = await $.getChannels(e.payoutAccount._id);
|
|
531
536
|
});
|
|
532
537
|
}
|
|
533
538
|
ne(s);
|
|
534
539
|
function f() {
|
|
535
|
-
|
|
540
|
+
o(async () => {
|
|
536
541
|
try {
|
|
537
|
-
await
|
|
542
|
+
await $.updateChannels(e.payoutAccount._id, t.value), v.open({
|
|
538
543
|
type: "success",
|
|
539
544
|
title: "Payout account channels update succesfully"
|
|
540
545
|
});
|
|
541
|
-
} catch (
|
|
542
|
-
|
|
546
|
+
} catch (d) {
|
|
547
|
+
v.open({
|
|
543
548
|
type: "error",
|
|
544
549
|
title: "Error occurs when updating payout account channels",
|
|
545
|
-
message:
|
|
550
|
+
message: q(d)
|
|
546
551
|
});
|
|
547
552
|
}
|
|
548
553
|
});
|
|
549
554
|
}
|
|
550
|
-
function
|
|
551
|
-
|
|
555
|
+
function i() {
|
|
556
|
+
o(async () => {
|
|
552
557
|
try {
|
|
553
|
-
await
|
|
558
|
+
await $.resetChannels(e.payoutAccount._id), t.value = await $.getChannels(e.payoutAccount._id), v.open({
|
|
554
559
|
type: "success",
|
|
555
560
|
title: "Payout account channels reset succesfully"
|
|
556
561
|
});
|
|
557
|
-
} catch (
|
|
558
|
-
|
|
562
|
+
} catch (d) {
|
|
563
|
+
v.open({
|
|
559
564
|
type: "error",
|
|
560
565
|
title: "Error occurs when reset payout account channels",
|
|
561
|
-
message:
|
|
566
|
+
message: q(d)
|
|
562
567
|
});
|
|
563
568
|
}
|
|
564
569
|
});
|
|
565
570
|
}
|
|
566
|
-
const
|
|
571
|
+
const l = [
|
|
567
572
|
{
|
|
568
573
|
header: () => "Gateway",
|
|
569
574
|
accessorKey: "gateway"
|
|
@@ -575,37 +580,37 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
575
580
|
{
|
|
576
581
|
header: () => "Display",
|
|
577
582
|
accessorKey: "icon",
|
|
578
|
-
cell: ({ row:
|
|
583
|
+
cell: ({ row: d }) => K("img", { src: d.original.icon, width: 32, height: 32 })
|
|
579
584
|
},
|
|
580
585
|
{
|
|
581
586
|
header: () => "Label",
|
|
582
587
|
accessorKey: "label",
|
|
583
|
-
cell: ({ row:
|
|
584
|
-
modelValue:
|
|
585
|
-
"onUpdate:modelValue": (
|
|
588
|
+
cell: ({ row: d }) => K(ie.FmTextField, {
|
|
589
|
+
modelValue: d.original.label,
|
|
590
|
+
"onUpdate:modelValue": (c) => d.original.label = c
|
|
586
591
|
})
|
|
587
592
|
},
|
|
588
593
|
{
|
|
589
594
|
id: "actions",
|
|
590
595
|
header: () => "Actions",
|
|
591
|
-
cell: ({ row:
|
|
592
|
-
onDelete: () => t.value.splice(
|
|
596
|
+
cell: ({ row: d }) => K(Se, {
|
|
597
|
+
onDelete: () => t.value.splice(d.index, 1)
|
|
593
598
|
})
|
|
594
599
|
}
|
|
595
600
|
];
|
|
596
|
-
return (
|
|
597
|
-
const
|
|
598
|
-
return
|
|
599
|
-
|
|
600
|
-
|
|
601
|
+
return (d, c) => {
|
|
602
|
+
const m = p("FmButton"), b = p("FmTable");
|
|
603
|
+
return g(), h(G, null, [
|
|
604
|
+
r("div", De, [
|
|
605
|
+
a(m, {
|
|
601
606
|
class: "mx-4",
|
|
602
607
|
variant: "destructive",
|
|
603
608
|
size: "md",
|
|
604
609
|
icon: "history",
|
|
605
610
|
label: "Reset",
|
|
606
|
-
onClick:
|
|
611
|
+
onClick: i
|
|
607
612
|
}),
|
|
608
|
-
|
|
613
|
+
a(m, {
|
|
609
614
|
variant: "primary",
|
|
610
615
|
size: "md",
|
|
611
616
|
icon: "save",
|
|
@@ -613,16 +618,16 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
613
618
|
onClick: f
|
|
614
619
|
})
|
|
615
620
|
]),
|
|
616
|
-
|
|
617
|
-
loading:
|
|
621
|
+
a(b, {
|
|
622
|
+
loading: u(y),
|
|
618
623
|
"row-data": t.value,
|
|
619
|
-
"column-defs":
|
|
624
|
+
"column-defs": l,
|
|
620
625
|
"shrink-at": !1
|
|
621
626
|
}, null, 8, ["loading", "row-data"])
|
|
622
627
|
], 64);
|
|
623
628
|
};
|
|
624
629
|
}
|
|
625
|
-
}),
|
|
630
|
+
}), Pe = { class: "flex mt-6 space-x-6" }, Re = /* @__PURE__ */ T({
|
|
626
631
|
__name: "FiuuGateway",
|
|
627
632
|
props: {
|
|
628
633
|
gateway: {
|
|
@@ -639,47 +644,47 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
639
644
|
}
|
|
640
645
|
},
|
|
641
646
|
setup(n) {
|
|
642
|
-
var
|
|
643
|
-
const e =
|
|
647
|
+
var y;
|
|
648
|
+
const e = U(((y = n.gateway) == null ? void 0 : y.config) || {
|
|
644
649
|
merchantId: "",
|
|
645
650
|
verifyKey: "",
|
|
646
651
|
secretKey: ""
|
|
647
652
|
});
|
|
648
|
-
return (
|
|
649
|
-
const s =
|
|
650
|
-
return
|
|
653
|
+
return (o, t) => {
|
|
654
|
+
const s = p("FmTextField"), f = p("FmButton"), i = p("FmForm");
|
|
655
|
+
return g(), w(i, {
|
|
651
656
|
ref: "form",
|
|
652
657
|
class: "flex flex-col gap-16",
|
|
653
658
|
onValidationSuccess: t[3] || (t[3] = () => n.onUpdate(e.value))
|
|
654
659
|
}, {
|
|
655
660
|
default: F(() => [
|
|
656
|
-
|
|
661
|
+
a(s, {
|
|
657
662
|
modelValue: e.value.merchantId,
|
|
658
|
-
"onUpdate:modelValue": t[0] || (t[0] = (
|
|
663
|
+
"onUpdate:modelValue": t[0] || (t[0] = (l) => e.value.merchantId = l),
|
|
659
664
|
label: "Merchant ID",
|
|
660
|
-
rules:
|
|
665
|
+
rules: u(V)(u(A).string())
|
|
661
666
|
}, null, 8, ["modelValue", "rules"]),
|
|
662
|
-
|
|
667
|
+
a(s, {
|
|
663
668
|
modelValue: e.value.verifyKey,
|
|
664
|
-
"onUpdate:modelValue": t[1] || (t[1] = (
|
|
669
|
+
"onUpdate:modelValue": t[1] || (t[1] = (l) => e.value.verifyKey = l),
|
|
665
670
|
label: "Verify Key",
|
|
666
|
-
rules:
|
|
671
|
+
rules: u(V)(u(A).string())
|
|
667
672
|
}, null, 8, ["modelValue", "rules"]),
|
|
668
|
-
|
|
673
|
+
a(s, {
|
|
669
674
|
modelValue: e.value.secretKey,
|
|
670
|
-
"onUpdate:modelValue": t[2] || (t[2] = (
|
|
675
|
+
"onUpdate:modelValue": t[2] || (t[2] = (l) => e.value.secretKey = l),
|
|
671
676
|
label: "Secret Key",
|
|
672
|
-
rules:
|
|
677
|
+
rules: u(V)(u(A).string())
|
|
673
678
|
}, null, 8, ["modelValue", "rules"]),
|
|
674
|
-
|
|
675
|
-
n.gateway ? (
|
|
679
|
+
r("div", Pe, [
|
|
680
|
+
n.gateway ? (g(), w(f, {
|
|
676
681
|
key: 0,
|
|
677
682
|
class: "flex-1",
|
|
678
683
|
variant: "secondary",
|
|
679
684
|
label: "Delete",
|
|
680
685
|
onclick: () => n.onDelete()
|
|
681
686
|
}, null, 8, ["onclick"])) : S("", !0),
|
|
682
|
-
|
|
687
|
+
a(f, {
|
|
683
688
|
type: "submit",
|
|
684
689
|
class: "flex-1",
|
|
685
690
|
variant: "primary",
|
|
@@ -691,7 +696,7 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
691
696
|
}, 512);
|
|
692
697
|
};
|
|
693
698
|
}
|
|
694
|
-
}),
|
|
699
|
+
}), he = { class: "flex mt-6 space-x-6" }, Ne = /* @__PURE__ */ T({
|
|
695
700
|
__name: "MacauPassGateway",
|
|
696
701
|
props: {
|
|
697
702
|
gateway: {
|
|
@@ -708,61 +713,61 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
708
713
|
}
|
|
709
714
|
},
|
|
710
715
|
setup(n) {
|
|
711
|
-
var
|
|
712
|
-
const e =
|
|
716
|
+
var y;
|
|
717
|
+
const e = U(((y = n.gateway) == null ? void 0 : y.config) || {
|
|
713
718
|
merchantId: "",
|
|
714
719
|
merchantName: "",
|
|
715
720
|
merchantCategoryCode: "",
|
|
716
721
|
storeID: "",
|
|
717
722
|
storeName: ""
|
|
718
723
|
});
|
|
719
|
-
return (
|
|
720
|
-
const s =
|
|
721
|
-
return
|
|
724
|
+
return (o, t) => {
|
|
725
|
+
const s = p("FmTextField"), f = p("FmButton"), i = p("FmForm");
|
|
726
|
+
return g(), w(i, {
|
|
722
727
|
ref: "form",
|
|
723
728
|
class: "flex flex-col gap-16",
|
|
724
729
|
onValidationSuccess: t[5] || (t[5] = () => n.onUpdate(e.value))
|
|
725
730
|
}, {
|
|
726
731
|
default: F(() => [
|
|
727
|
-
|
|
732
|
+
a(s, {
|
|
728
733
|
modelValue: e.value.merchantId,
|
|
729
|
-
"onUpdate:modelValue": t[0] || (t[0] = (
|
|
734
|
+
"onUpdate:modelValue": t[0] || (t[0] = (l) => e.value.merchantId = l),
|
|
730
735
|
label: "Merchant ID",
|
|
731
|
-
rules:
|
|
736
|
+
rules: u(V)(u(A).string())
|
|
732
737
|
}, null, 8, ["modelValue", "rules"]),
|
|
733
|
-
|
|
738
|
+
a(s, {
|
|
734
739
|
modelValue: e.value.merchantName,
|
|
735
|
-
"onUpdate:modelValue": t[1] || (t[1] = (
|
|
740
|
+
"onUpdate:modelValue": t[1] || (t[1] = (l) => e.value.merchantName = l),
|
|
736
741
|
label: "Merchant Name",
|
|
737
|
-
rules:
|
|
742
|
+
rules: u(V)(u(A).string())
|
|
738
743
|
}, null, 8, ["modelValue", "rules"]),
|
|
739
|
-
|
|
744
|
+
a(s, {
|
|
740
745
|
modelValue: e.value.merchantCategoryCode,
|
|
741
|
-
"onUpdate:modelValue": t[2] || (t[2] = (
|
|
746
|
+
"onUpdate:modelValue": t[2] || (t[2] = (l) => e.value.merchantCategoryCode = l),
|
|
742
747
|
label: "Merchant MCC",
|
|
743
|
-
rules:
|
|
748
|
+
rules: u(V)(u(A).string())
|
|
744
749
|
}, null, 8, ["modelValue", "rules"]),
|
|
745
|
-
|
|
750
|
+
a(s, {
|
|
746
751
|
modelValue: e.value.storeID,
|
|
747
|
-
"onUpdate:modelValue": t[3] || (t[3] = (
|
|
752
|
+
"onUpdate:modelValue": t[3] || (t[3] = (l) => e.value.storeID = l),
|
|
748
753
|
label: "Store ID",
|
|
749
|
-
rules:
|
|
754
|
+
rules: u(V)(u(A).string())
|
|
750
755
|
}, null, 8, ["modelValue", "rules"]),
|
|
751
|
-
|
|
756
|
+
a(s, {
|
|
752
757
|
modelValue: e.value.storeName,
|
|
753
|
-
"onUpdate:modelValue": t[4] || (t[4] = (
|
|
758
|
+
"onUpdate:modelValue": t[4] || (t[4] = (l) => e.value.storeName = l),
|
|
754
759
|
label: "Store Name",
|
|
755
|
-
rules:
|
|
760
|
+
rules: u(V)(u(A).string())
|
|
756
761
|
}, null, 8, ["modelValue", "rules"]),
|
|
757
|
-
|
|
758
|
-
n.gateway ? (
|
|
762
|
+
r("div", he, [
|
|
763
|
+
n.gateway ? (g(), w(f, {
|
|
759
764
|
key: 0,
|
|
760
765
|
class: "flex-1",
|
|
761
766
|
variant: "secondary",
|
|
762
767
|
label: "Delete",
|
|
763
768
|
onclick: () => n.onDelete()
|
|
764
769
|
}, null, 8, ["onclick"])) : S("", !0),
|
|
765
|
-
|
|
770
|
+
a(f, {
|
|
766
771
|
type: "submit",
|
|
767
772
|
class: "flex-1",
|
|
768
773
|
variant: "primary",
|
|
@@ -774,7 +779,7 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
774
779
|
}, 512);
|
|
775
780
|
};
|
|
776
781
|
}
|
|
777
|
-
}),
|
|
782
|
+
}), Me = { class: "flex mt-6 space-x-6" }, $e = /* @__PURE__ */ T({
|
|
778
783
|
__name: "DigioGateway",
|
|
779
784
|
props: {
|
|
780
785
|
gateway: {
|
|
@@ -791,40 +796,40 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
791
796
|
}
|
|
792
797
|
},
|
|
793
798
|
setup(n) {
|
|
794
|
-
var
|
|
795
|
-
const e =
|
|
799
|
+
var y;
|
|
800
|
+
const e = U(((y = n.gateway) == null ? void 0 : y.config) || {
|
|
796
801
|
merchantId: "",
|
|
797
802
|
cardMerchantId: ""
|
|
798
803
|
});
|
|
799
|
-
return (
|
|
800
|
-
const s =
|
|
801
|
-
return
|
|
804
|
+
return (o, t) => {
|
|
805
|
+
const s = p("FmTextField"), f = p("FmButton"), i = p("FmForm");
|
|
806
|
+
return g(), w(i, {
|
|
802
807
|
ref: "form",
|
|
803
808
|
class: "flex flex-col gap-16",
|
|
804
809
|
onValidationSuccess: t[2] || (t[2] = () => n.onUpdate(e.value))
|
|
805
810
|
}, {
|
|
806
811
|
default: F(() => [
|
|
807
|
-
|
|
812
|
+
a(s, {
|
|
808
813
|
modelValue: e.value.merchantId,
|
|
809
|
-
"onUpdate:modelValue": t[0] || (t[0] = (
|
|
814
|
+
"onUpdate:modelValue": t[0] || (t[0] = (l) => e.value.merchantId = l),
|
|
810
815
|
label: "Merchant ID",
|
|
811
|
-
rules:
|
|
816
|
+
rules: u(V)(u(A).string())
|
|
812
817
|
}, null, 8, ["modelValue", "rules"]),
|
|
813
|
-
|
|
818
|
+
a(s, {
|
|
814
819
|
modelValue: e.value.cardMerchantId,
|
|
815
|
-
"onUpdate:modelValue": t[1] || (t[1] = (
|
|
820
|
+
"onUpdate:modelValue": t[1] || (t[1] = (l) => e.value.cardMerchantId = l),
|
|
816
821
|
label: "Card Merchant ID",
|
|
817
|
-
rules:
|
|
822
|
+
rules: u(V)(u(A).string())
|
|
818
823
|
}, null, 8, ["modelValue", "rules"]),
|
|
819
|
-
|
|
820
|
-
n.gateway ? (
|
|
824
|
+
r("div", Me, [
|
|
825
|
+
n.gateway ? (g(), w(f, {
|
|
821
826
|
key: 0,
|
|
822
827
|
class: "flex-1",
|
|
823
828
|
variant: "secondary",
|
|
824
829
|
label: "Delete",
|
|
825
830
|
onclick: () => n.onDelete()
|
|
826
831
|
}, null, 8, ["onclick"])) : S("", !0),
|
|
827
|
-
|
|
832
|
+
a(f, {
|
|
828
833
|
type: "submit",
|
|
829
834
|
class: "flex-1",
|
|
830
835
|
variant: "primary",
|
|
@@ -836,7 +841,7 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
836
841
|
}, 512);
|
|
837
842
|
};
|
|
838
843
|
}
|
|
839
|
-
}),
|
|
844
|
+
}), Ee = { class: "flex mt-6 space-x-6" }, Ge = /* @__PURE__ */ T({
|
|
840
845
|
__name: "AdyenGateway",
|
|
841
846
|
props: {
|
|
842
847
|
gateway: {
|
|
@@ -853,8 +858,8 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
853
858
|
}
|
|
854
859
|
},
|
|
855
860
|
setup(n) {
|
|
856
|
-
var
|
|
857
|
-
const e =
|
|
861
|
+
var y;
|
|
862
|
+
const e = U(((y = n.gateway) == null ? void 0 : y.config) || {
|
|
858
863
|
merchantAccount: "",
|
|
859
864
|
username: "",
|
|
860
865
|
apiKey: "",
|
|
@@ -862,58 +867,58 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
862
867
|
endpoint: "",
|
|
863
868
|
hmacKey: ""
|
|
864
869
|
});
|
|
865
|
-
return (
|
|
866
|
-
const s =
|
|
867
|
-
return
|
|
870
|
+
return (o, t) => {
|
|
871
|
+
const s = p("FmTextField"), f = p("FmButton"), i = p("FmForm");
|
|
872
|
+
return g(), w(i, {
|
|
868
873
|
ref: "form",
|
|
869
874
|
class: "flex flex-col gap-16",
|
|
870
875
|
onValidationSuccess: t[6] || (t[6] = () => n.onUpdate(e.value))
|
|
871
876
|
}, {
|
|
872
877
|
default: F(() => [
|
|
873
|
-
|
|
878
|
+
a(s, {
|
|
874
879
|
modelValue: e.value.endpoint,
|
|
875
|
-
"onUpdate:modelValue": t[0] || (t[0] = (
|
|
880
|
+
"onUpdate:modelValue": t[0] || (t[0] = (l) => e.value.endpoint = l),
|
|
876
881
|
label: "Endpoint",
|
|
877
|
-
rules:
|
|
882
|
+
rules: u(V)(u(A).string())
|
|
878
883
|
}, null, 8, ["modelValue", "rules"]),
|
|
879
|
-
|
|
884
|
+
a(s, {
|
|
880
885
|
modelValue: e.value.merchantAccount,
|
|
881
|
-
"onUpdate:modelValue": t[1] || (t[1] = (
|
|
886
|
+
"onUpdate:modelValue": t[1] || (t[1] = (l) => e.value.merchantAccount = l),
|
|
882
887
|
label: "Merchant Account",
|
|
883
|
-
rules:
|
|
888
|
+
rules: u(V)(u(A).string())
|
|
884
889
|
}, null, 8, ["modelValue", "rules"]),
|
|
885
|
-
|
|
890
|
+
a(s, {
|
|
886
891
|
modelValue: e.value.username,
|
|
887
|
-
"onUpdate:modelValue": t[2] || (t[2] = (
|
|
892
|
+
"onUpdate:modelValue": t[2] || (t[2] = (l) => e.value.username = l),
|
|
888
893
|
label: "Username",
|
|
889
|
-
rules:
|
|
894
|
+
rules: u(V)(u(A).string())
|
|
890
895
|
}, null, 8, ["modelValue", "rules"]),
|
|
891
|
-
|
|
896
|
+
a(s, {
|
|
892
897
|
modelValue: e.value.apiKey,
|
|
893
|
-
"onUpdate:modelValue": t[3] || (t[3] = (
|
|
898
|
+
"onUpdate:modelValue": t[3] || (t[3] = (l) => e.value.apiKey = l),
|
|
894
899
|
label: "API Key",
|
|
895
|
-
rules:
|
|
900
|
+
rules: u(V)(u(A).string())
|
|
896
901
|
}, null, 8, ["modelValue", "rules"]),
|
|
897
|
-
|
|
902
|
+
a(s, {
|
|
898
903
|
modelValue: e.value.clientKey,
|
|
899
|
-
"onUpdate:modelValue": t[4] || (t[4] = (
|
|
904
|
+
"onUpdate:modelValue": t[4] || (t[4] = (l) => e.value.clientKey = l),
|
|
900
905
|
label: "Client Key",
|
|
901
|
-
rules:
|
|
906
|
+
rules: u(V)(u(A).string())
|
|
902
907
|
}, null, 8, ["modelValue", "rules"]),
|
|
903
|
-
|
|
908
|
+
a(s, {
|
|
904
909
|
modelValue: e.value.hmacKey,
|
|
905
|
-
"onUpdate:modelValue": t[5] || (t[5] = (
|
|
910
|
+
"onUpdate:modelValue": t[5] || (t[5] = (l) => e.value.hmacKey = l),
|
|
906
911
|
label: "HMac Key"
|
|
907
912
|
}, null, 8, ["modelValue"]),
|
|
908
|
-
|
|
909
|
-
n.gateway ? (
|
|
913
|
+
r("div", Ee, [
|
|
914
|
+
n.gateway ? (g(), w(f, {
|
|
910
915
|
key: 0,
|
|
911
916
|
class: "flex-1",
|
|
912
917
|
variant: "secondary",
|
|
913
918
|
label: "Delete",
|
|
914
919
|
onclick: () => n.onDelete()
|
|
915
920
|
}, null, 8, ["onclick"])) : S("", !0),
|
|
916
|
-
|
|
921
|
+
a(f, {
|
|
917
922
|
type: "submit",
|
|
918
923
|
class: "flex-1",
|
|
919
924
|
variant: "primary",
|
|
@@ -925,7 +930,7 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
925
930
|
}, 512);
|
|
926
931
|
};
|
|
927
932
|
}
|
|
928
|
-
}),
|
|
933
|
+
}), Be = { class: "flex mt-6 space-x-6" }, Ke = /* @__PURE__ */ T({
|
|
929
934
|
__name: "KsherGateway",
|
|
930
935
|
props: {
|
|
931
936
|
gateway: {
|
|
@@ -942,41 +947,41 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
942
947
|
}
|
|
943
948
|
},
|
|
944
949
|
setup(n) {
|
|
945
|
-
var
|
|
946
|
-
const e =
|
|
950
|
+
var y;
|
|
951
|
+
const e = U(((y = n.gateway) == null ? void 0 : y.config) || {
|
|
947
952
|
appId: "",
|
|
948
953
|
privateKey: ""
|
|
949
954
|
});
|
|
950
|
-
return (
|
|
951
|
-
const s =
|
|
952
|
-
return
|
|
955
|
+
return (o, t) => {
|
|
956
|
+
const s = p("FmTextField"), f = p("FmTextarea"), i = p("FmButton"), l = p("FmForm");
|
|
957
|
+
return g(), w(l, {
|
|
953
958
|
ref: "form",
|
|
954
959
|
class: "flex flex-col gap-16",
|
|
955
960
|
onValidationSuccess: t[2] || (t[2] = () => n.onUpdate(e.value))
|
|
956
961
|
}, {
|
|
957
962
|
default: F(() => [
|
|
958
|
-
|
|
963
|
+
a(s, {
|
|
959
964
|
modelValue: e.value.appId,
|
|
960
|
-
"onUpdate:modelValue": t[0] || (t[0] = (
|
|
965
|
+
"onUpdate:modelValue": t[0] || (t[0] = (d) => e.value.appId = d),
|
|
961
966
|
label: "App ID",
|
|
962
|
-
rules:
|
|
967
|
+
rules: u(V)(u(A).string())
|
|
963
968
|
}, null, 8, ["modelValue", "rules"]),
|
|
964
|
-
|
|
969
|
+
a(f, {
|
|
965
970
|
modelValue: e.value.privateKey,
|
|
966
|
-
"onUpdate:modelValue": t[1] || (t[1] = (
|
|
971
|
+
"onUpdate:modelValue": t[1] || (t[1] = (d) => e.value.privateKey = d),
|
|
967
972
|
label: "Private Key",
|
|
968
973
|
placeholder: "Paste your private key including BEGIN and END markers",
|
|
969
|
-
rules:
|
|
974
|
+
rules: u(V)(u(A).string())
|
|
970
975
|
}, null, 8, ["modelValue", "rules"]),
|
|
971
|
-
|
|
972
|
-
n.gateway ? (
|
|
976
|
+
r("div", Be, [
|
|
977
|
+
n.gateway ? (g(), w(i, {
|
|
973
978
|
key: 0,
|
|
974
979
|
class: "flex-1",
|
|
975
980
|
variant: "secondary",
|
|
976
981
|
label: "Delete",
|
|
977
982
|
onclick: () => n.onDelete()
|
|
978
983
|
}, null, 8, ["onclick"])) : S("", !0),
|
|
979
|
-
|
|
984
|
+
a(i, {
|
|
980
985
|
type: "submit",
|
|
981
986
|
class: "flex-1",
|
|
982
987
|
variant: "primary",
|
|
@@ -988,13 +993,13 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
988
993
|
}, 512);
|
|
989
994
|
};
|
|
990
995
|
}
|
|
991
|
-
}),
|
|
996
|
+
}), Oe = {
|
|
992
997
|
key: 0,
|
|
993
998
|
className: "mt-1 my-6 text-gray-600"
|
|
994
|
-
},
|
|
999
|
+
}, qe = {
|
|
995
1000
|
key: 1,
|
|
996
1001
|
class: "flex items-center justify-center min-h-[80vh]"
|
|
997
|
-
},
|
|
1002
|
+
}, je = /* @__PURE__ */ T({
|
|
998
1003
|
__name: "PaymentGateway",
|
|
999
1004
|
props: {
|
|
1000
1005
|
payoutAccount: {
|
|
@@ -1003,120 +1008,120 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
1003
1008
|
}
|
|
1004
1009
|
},
|
|
1005
1010
|
setup(n) {
|
|
1006
|
-
const
|
|
1011
|
+
const v = ae().currentCountry, e = v.value, y = H(), { isLoading: o, startAsyncCall: t } = Y(), { gatewayTab: s } = z({
|
|
1007
1012
|
gatewayTab: ""
|
|
1008
|
-
}), f = n,
|
|
1013
|
+
}), f = n, i = [
|
|
1009
1014
|
{
|
|
1010
1015
|
label: "Fiuu",
|
|
1011
1016
|
value: "RAZER_MERCHANT_SERVICE",
|
|
1012
|
-
render:
|
|
1013
|
-
region: [
|
|
1017
|
+
render: Re,
|
|
1018
|
+
region: [_.F_COUNTRY.enum.MY, _.F_COUNTRY.enum.SG]
|
|
1014
1019
|
},
|
|
1015
1020
|
{
|
|
1016
1021
|
label: "Macau Pass",
|
|
1017
1022
|
value: "MACAU_PASS",
|
|
1018
|
-
render:
|
|
1019
|
-
region: [
|
|
1023
|
+
render: Ne,
|
|
1024
|
+
region: [_.F_COUNTRY.enum.MO]
|
|
1020
1025
|
},
|
|
1021
1026
|
{
|
|
1022
1027
|
label: "Digio",
|
|
1023
1028
|
value: "DIGIO",
|
|
1024
|
-
render:
|
|
1025
|
-
region: [
|
|
1029
|
+
render: $e,
|
|
1030
|
+
region: [_.F_COUNTRY.enum.TH]
|
|
1026
1031
|
},
|
|
1027
1032
|
{
|
|
1028
1033
|
label: "Ksher",
|
|
1029
1034
|
value: "KSHER",
|
|
1030
|
-
render:
|
|
1031
|
-
region: [
|
|
1035
|
+
render: Ke,
|
|
1036
|
+
region: [_.F_COUNTRY.enum.TH]
|
|
1032
1037
|
},
|
|
1033
1038
|
{
|
|
1034
1039
|
label: "Adyen",
|
|
1035
1040
|
value: "ADYEN",
|
|
1036
|
-
render:
|
|
1037
|
-
region: [
|
|
1041
|
+
render: Ge,
|
|
1042
|
+
region: [_.F_COUNTRY.enum.MY, _.F_COUNTRY.enum.SG]
|
|
1038
1043
|
}
|
|
1039
|
-
],
|
|
1044
|
+
], l = U(
|
|
1040
1045
|
f.payoutAccount.gateways ?? []
|
|
1041
|
-
),
|
|
1042
|
-
(
|
|
1046
|
+
), d = B(() => i.find((C) => C.value === s.value)), c = B(() => i.filter(
|
|
1047
|
+
(C) => C.region.includes(v.value ?? _.F_COUNTRY.enum.MY)
|
|
1043
1048
|
));
|
|
1044
|
-
async function
|
|
1049
|
+
async function m(C) {
|
|
1045
1050
|
await t(async () => {
|
|
1046
1051
|
try {
|
|
1047
|
-
await
|
|
1052
|
+
await $.updateGateway(f.payoutAccount._id, C), y.open({
|
|
1048
1053
|
type: "success",
|
|
1049
1054
|
title: "Payout account gateways update succesfully"
|
|
1050
|
-
}),
|
|
1051
|
-
} catch (
|
|
1052
|
-
|
|
1055
|
+
}), b.value = C.length === 0;
|
|
1056
|
+
} catch (D) {
|
|
1057
|
+
y.open({
|
|
1053
1058
|
type: "error",
|
|
1054
1059
|
title: "Error occurs when updating payout account gateways",
|
|
1055
|
-
message:
|
|
1060
|
+
message: q(D)
|
|
1056
1061
|
});
|
|
1057
1062
|
}
|
|
1058
1063
|
});
|
|
1059
1064
|
}
|
|
1060
|
-
const
|
|
1061
|
-
return (
|
|
1062
|
-
var
|
|
1063
|
-
const
|
|
1064
|
-
return
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1065
|
+
const b = U((f.payoutAccount.gateways ?? []).length === 0), x = B(() => e !== "MY" || !b.value);
|
|
1066
|
+
return (C, D) => {
|
|
1067
|
+
var O;
|
|
1068
|
+
const P = p("FmCircularProgress"), R = p("FmSwitch"), M = p("FmTabs");
|
|
1069
|
+
return g(), h(G, null, [
|
|
1070
|
+
u(e) ? (g(), h("p", Oe, [...D[2] || (D[2] = [
|
|
1071
|
+
r("b", null, "Note: ", -1),
|
|
1072
|
+
k(" There's no setup required for Malaysia Payment Gateway, once Payout Account is ready you will able to configure the payment channels. ", -1)
|
|
1068
1073
|
])])) : S("", !0),
|
|
1069
|
-
|
|
1070
|
-
|
|
1071
|
-
])) : (
|
|
1072
|
-
|
|
1074
|
+
u(o) ? (g(), h("div", qe, [
|
|
1075
|
+
a(P, { size: "xxl" })
|
|
1076
|
+
])) : (g(), h(G, { key: 2 }, [
|
|
1077
|
+
u(e) === "MY" ? (g(), w(R, {
|
|
1073
1078
|
key: 0,
|
|
1074
|
-
modelValue:
|
|
1075
|
-
"onUpdate:modelValue":
|
|
1079
|
+
modelValue: b.value,
|
|
1080
|
+
"onUpdate:modelValue": D[0] || (D[0] = (N) => b.value = N),
|
|
1076
1081
|
style: { "padding-bottom": "12px" },
|
|
1077
1082
|
label: "Use FeedMe's Fiuu Account?"
|
|
1078
1083
|
}, null, 8, ["modelValue"])) : S("", !0),
|
|
1079
|
-
|
|
1084
|
+
x.value ? (g(), w(M, {
|
|
1080
1085
|
key: 1,
|
|
1081
|
-
"model-value":
|
|
1082
|
-
"onUpdate:modelValue":
|
|
1086
|
+
"model-value": u(s),
|
|
1087
|
+
"onUpdate:modelValue": D[1] || (D[1] = (N) => j(s) ? s.value = N : null),
|
|
1083
1088
|
class: "mb-6",
|
|
1084
|
-
items:
|
|
1089
|
+
items: c.value
|
|
1085
1090
|
}, null, 8, ["model-value", "items"])) : S("", !0),
|
|
1086
|
-
|
|
1087
|
-
gateway:
|
|
1088
|
-
(
|
|
1091
|
+
x.value && u(s) ? (g(), w(J((O = d.value) == null ? void 0 : O.render), Q(W({ key: 2 }, {
|
|
1092
|
+
gateway: l.value.find(
|
|
1093
|
+
(N) => {
|
|
1089
1094
|
var E;
|
|
1090
|
-
return
|
|
1095
|
+
return N.paymentGateway === ((E = d.value) == null ? void 0 : E.value);
|
|
1091
1096
|
}
|
|
1092
1097
|
),
|
|
1093
1098
|
onDelete: async () => {
|
|
1094
|
-
|
|
1095
|
-
(
|
|
1099
|
+
l.value = l.value.filter(
|
|
1100
|
+
(N) => {
|
|
1096
1101
|
var E;
|
|
1097
|
-
return
|
|
1102
|
+
return N.paymentGateway !== ((E = d.value) == null ? void 0 : E.value);
|
|
1098
1103
|
}
|
|
1099
|
-
),
|
|
1104
|
+
), m(l.value);
|
|
1100
1105
|
},
|
|
1101
|
-
onUpdate: (
|
|
1106
|
+
onUpdate: (N) => {
|
|
1102
1107
|
var X;
|
|
1103
|
-
let E =
|
|
1108
|
+
let E = l.value.find(
|
|
1104
1109
|
(le) => {
|
|
1105
1110
|
var ee;
|
|
1106
|
-
return le.paymentGateway === ((ee =
|
|
1111
|
+
return le.paymentGateway === ((ee = d.value) == null ? void 0 : ee.value);
|
|
1107
1112
|
}
|
|
1108
1113
|
);
|
|
1109
|
-
E ? E.config =
|
|
1110
|
-
paymentGateway: (X =
|
|
1111
|
-
config:
|
|
1112
|
-
}),
|
|
1114
|
+
E ? E.config = N : l.value.push({
|
|
1115
|
+
paymentGateway: (X = d.value) == null ? void 0 : X.value,
|
|
1116
|
+
config: N
|
|
1117
|
+
}), m(l.value);
|
|
1113
1118
|
}
|
|
1114
1119
|
})), null, 16)) : S("", !0)
|
|
1115
1120
|
], 64))
|
|
1116
1121
|
], 64);
|
|
1117
1122
|
};
|
|
1118
1123
|
}
|
|
1119
|
-
}),
|
|
1124
|
+
}), Ye = { class: "flex mt-6 space-x-6" }, ze = /* @__PURE__ */ T({
|
|
1120
1125
|
__name: "GooglePayToken",
|
|
1121
1126
|
props: {
|
|
1122
1127
|
gateway: {
|
|
@@ -1133,7 +1138,7 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
1133
1138
|
}
|
|
1134
1139
|
},
|
|
1135
1140
|
setup(n) {
|
|
1136
|
-
const e =
|
|
1141
|
+
const e = U(
|
|
1137
1142
|
n.gateway || {
|
|
1138
1143
|
type: "googlePay",
|
|
1139
1144
|
gateway: "RAZER_MERCHANT_SERVICE",
|
|
@@ -1143,44 +1148,44 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
1143
1148
|
}
|
|
1144
1149
|
}
|
|
1145
1150
|
);
|
|
1146
|
-
return (
|
|
1147
|
-
const t =
|
|
1148
|
-
return
|
|
1151
|
+
return (y, o) => {
|
|
1152
|
+
const t = p("FmTextField"), s = p("FmButton"), f = p("FmForm");
|
|
1153
|
+
return g(), w(f, {
|
|
1149
1154
|
ref: "form",
|
|
1150
1155
|
class: "flex flex-col gap-16",
|
|
1151
|
-
onValidationSuccess:
|
|
1156
|
+
onValidationSuccess: o[3] || (o[3] = () => n.onUpdate(e.value))
|
|
1152
1157
|
}, {
|
|
1153
1158
|
default: F(() => [
|
|
1154
|
-
|
|
1159
|
+
a(t, {
|
|
1155
1160
|
modelValue: e.value.gateway,
|
|
1156
|
-
"onUpdate:modelValue":
|
|
1161
|
+
"onUpdate:modelValue": o[0] || (o[0] = (i) => e.value.gateway = i),
|
|
1157
1162
|
label: "Gateway",
|
|
1158
1163
|
disabled: !0,
|
|
1159
|
-
rules:
|
|
1164
|
+
rules: u(V)(u(A).string())
|
|
1160
1165
|
}, null, 8, ["modelValue", "rules"]),
|
|
1161
|
-
|
|
1166
|
+
a(t, {
|
|
1162
1167
|
modelValue: e.value.config.gateway,
|
|
1163
|
-
"onUpdate:modelValue":
|
|
1168
|
+
"onUpdate:modelValue": o[1] || (o[1] = (i) => e.value.config.gateway = i),
|
|
1164
1169
|
label: "Gateway ID",
|
|
1165
1170
|
disabled: !0,
|
|
1166
|
-
rules:
|
|
1171
|
+
rules: u(V)(u(A).string())
|
|
1167
1172
|
}, null, 8, ["modelValue", "rules"]),
|
|
1168
|
-
|
|
1173
|
+
a(t, {
|
|
1169
1174
|
modelValue: e.value.config.gatewayMerchantId,
|
|
1170
|
-
"onUpdate:modelValue":
|
|
1175
|
+
"onUpdate:modelValue": o[2] || (o[2] = (i) => e.value.config.gatewayMerchantId = i),
|
|
1171
1176
|
label: "Gateway Merchant ID",
|
|
1172
1177
|
disabled: !0,
|
|
1173
|
-
rules:
|
|
1178
|
+
rules: u(V)(u(A).string())
|
|
1174
1179
|
}, null, 8, ["modelValue", "rules"]),
|
|
1175
|
-
|
|
1176
|
-
n.gateway ? (
|
|
1180
|
+
r("div", Ye, [
|
|
1181
|
+
n.gateway ? (g(), w(s, {
|
|
1177
1182
|
key: 0,
|
|
1178
1183
|
class: "flex-1",
|
|
1179
1184
|
variant: "secondary",
|
|
1180
1185
|
label: "Delete",
|
|
1181
1186
|
onclick: () => n.onDelete()
|
|
1182
1187
|
}, null, 8, ["onclick"])) : S("", !0),
|
|
1183
|
-
|
|
1188
|
+
a(s, {
|
|
1184
1189
|
type: "submit",
|
|
1185
1190
|
class: "flex-1",
|
|
1186
1191
|
variant: "primary",
|
|
@@ -1192,7 +1197,7 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
1192
1197
|
}, 512);
|
|
1193
1198
|
};
|
|
1194
1199
|
}
|
|
1195
|
-
}),
|
|
1200
|
+
}), He = { class: "flex mt-6 space-x-6" }, Le = /* @__PURE__ */ T({
|
|
1196
1201
|
__name: "ApplePayToken",
|
|
1197
1202
|
props: {
|
|
1198
1203
|
gateway: {
|
|
@@ -1209,7 +1214,7 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
1209
1214
|
}
|
|
1210
1215
|
},
|
|
1211
1216
|
setup(n) {
|
|
1212
|
-
const e =
|
|
1217
|
+
const e = U(
|
|
1213
1218
|
n.gateway || {
|
|
1214
1219
|
type: "applePay",
|
|
1215
1220
|
gateway: "RAZER_MERCHANT_SERVICE",
|
|
@@ -1218,37 +1223,37 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
1218
1223
|
}
|
|
1219
1224
|
}
|
|
1220
1225
|
);
|
|
1221
|
-
return (
|
|
1222
|
-
const t =
|
|
1223
|
-
return
|
|
1226
|
+
return (y, o) => {
|
|
1227
|
+
const t = p("FmTextField"), s = p("FmButton"), f = p("FmForm");
|
|
1228
|
+
return g(), w(f, {
|
|
1224
1229
|
ref: "form",
|
|
1225
1230
|
class: "flex flex-col gap-16",
|
|
1226
|
-
onValidationSuccess:
|
|
1231
|
+
onValidationSuccess: o[2] || (o[2] = () => n.onUpdate(e.value))
|
|
1227
1232
|
}, {
|
|
1228
1233
|
default: F(() => [
|
|
1229
|
-
|
|
1234
|
+
a(t, {
|
|
1230
1235
|
modelValue: e.value.gateway,
|
|
1231
|
-
"onUpdate:modelValue":
|
|
1236
|
+
"onUpdate:modelValue": o[0] || (o[0] = (i) => e.value.gateway = i),
|
|
1232
1237
|
label: "Gateway",
|
|
1233
1238
|
disabled: !0,
|
|
1234
|
-
rules:
|
|
1239
|
+
rules: u(V)(u(A).string())
|
|
1235
1240
|
}, null, 8, ["modelValue", "rules"]),
|
|
1236
|
-
|
|
1241
|
+
a(t, {
|
|
1237
1242
|
modelValue: e.value.config.merchantId,
|
|
1238
|
-
"onUpdate:modelValue":
|
|
1243
|
+
"onUpdate:modelValue": o[1] || (o[1] = (i) => e.value.config.merchantId = i),
|
|
1239
1244
|
label: "Merchant ID",
|
|
1240
1245
|
disabled: !0,
|
|
1241
|
-
rules:
|
|
1246
|
+
rules: u(V)(u(A).string())
|
|
1242
1247
|
}, null, 8, ["modelValue", "rules"]),
|
|
1243
|
-
|
|
1244
|
-
n.gateway ? (
|
|
1248
|
+
r("div", He, [
|
|
1249
|
+
n.gateway ? (g(), w(s, {
|
|
1245
1250
|
key: 0,
|
|
1246
1251
|
class: "flex-1",
|
|
1247
1252
|
variant: "secondary",
|
|
1248
1253
|
label: "Delete",
|
|
1249
1254
|
onclick: () => n.onDelete()
|
|
1250
1255
|
}, null, 8, ["onclick"])) : S("", !0),
|
|
1251
|
-
|
|
1256
|
+
a(s, {
|
|
1252
1257
|
type: "submit",
|
|
1253
1258
|
class: "flex-1",
|
|
1254
1259
|
variant: "primary",
|
|
@@ -1260,10 +1265,10 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
1260
1265
|
}, 512);
|
|
1261
1266
|
};
|
|
1262
1267
|
}
|
|
1263
|
-
}),
|
|
1268
|
+
}), Ze = {
|
|
1264
1269
|
key: 0,
|
|
1265
1270
|
class: "flex items-center justify-center min-h-[80vh]"
|
|
1266
|
-
},
|
|
1271
|
+
}, Je = /* @__PURE__ */ T({
|
|
1267
1272
|
__name: "TokenGateway",
|
|
1268
1273
|
props: {
|
|
1269
1274
|
payoutAccount: {
|
|
@@ -1272,86 +1277,86 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
1272
1277
|
}
|
|
1273
1278
|
},
|
|
1274
1279
|
setup(n) {
|
|
1275
|
-
const
|
|
1280
|
+
const v = ae().currentCountry, e = H(), { isLoading: y, startAsyncCall: o } = Y(), { tokenTab: t } = z({
|
|
1276
1281
|
tokenTab: ""
|
|
1277
1282
|
}), s = n, f = [
|
|
1278
1283
|
{
|
|
1279
1284
|
label: "Google Pay",
|
|
1280
1285
|
value: "googlePay",
|
|
1281
1286
|
icon: "android",
|
|
1282
|
-
render:
|
|
1283
|
-
region: [
|
|
1287
|
+
render: ze,
|
|
1288
|
+
region: [_.F_COUNTRY.enum.MY, _.F_COUNTRY.enum.SG]
|
|
1284
1289
|
},
|
|
1285
1290
|
{
|
|
1286
1291
|
label: "Apple Pay",
|
|
1287
1292
|
value: "applePay",
|
|
1288
1293
|
icon: "iOS",
|
|
1289
|
-
render:
|
|
1290
|
-
region: [
|
|
1294
|
+
render: Le,
|
|
1295
|
+
region: [_.F_COUNTRY.enum.MY, _.F_COUNTRY.enum.SG]
|
|
1291
1296
|
}
|
|
1292
|
-
],
|
|
1293
|
-
(
|
|
1297
|
+
], i = U(s.payoutAccount.tokens ?? []), l = B(() => f.find((m) => m.value === t.value)), d = B(() => f.filter(
|
|
1298
|
+
(m) => m.region.includes(v.value ?? _.F_COUNTRY.enum.MY)
|
|
1294
1299
|
));
|
|
1295
|
-
async function
|
|
1296
|
-
await
|
|
1300
|
+
async function c(m) {
|
|
1301
|
+
await o(async () => {
|
|
1297
1302
|
try {
|
|
1298
|
-
await
|
|
1303
|
+
await $.updateTokens(s.payoutAccount._id, m), e.open({
|
|
1299
1304
|
type: "success",
|
|
1300
1305
|
title: "Payout account tokens gateway update succesfully"
|
|
1301
1306
|
});
|
|
1302
|
-
} catch (
|
|
1307
|
+
} catch (b) {
|
|
1303
1308
|
e.open({
|
|
1304
1309
|
type: "error",
|
|
1305
1310
|
title: "Error occurs when updating payout account tokens",
|
|
1306
|
-
message:
|
|
1311
|
+
message: q(b)
|
|
1307
1312
|
});
|
|
1308
1313
|
}
|
|
1309
1314
|
});
|
|
1310
1315
|
}
|
|
1311
|
-
return (
|
|
1312
|
-
var
|
|
1313
|
-
const
|
|
1314
|
-
return
|
|
1315
|
-
|
|
1316
|
-
|
|
1317
|
-
|
|
1318
|
-
|
|
1319
|
-
|
|
1320
|
-
|
|
1321
|
-
|
|
1316
|
+
return (m, b) => {
|
|
1317
|
+
var D;
|
|
1318
|
+
const x = p("FmCircularProgress"), C = p("FmTabs");
|
|
1319
|
+
return g(), h(G, null, [
|
|
1320
|
+
b[1] || (b[1] = r("p", { className: "mt-1 my-6 text-gray-600" }, [
|
|
1321
|
+
r("b", null, "Note: "),
|
|
1322
|
+
k(" Token gateways appear above other online payment channels to comply with provider branding requirements. Configuration is standardized, so you generally only need to select the provider. "),
|
|
1323
|
+
r("br"),
|
|
1324
|
+
r("br"),
|
|
1325
|
+
r("b", null, ` Token payments are automatically enabled for "Pay-First" merchants. You do not need to adjust settings here unless you're modifying for a non-Pay-First merchant who wishes to manually enable this feature. `),
|
|
1326
|
+
r("br")
|
|
1322
1327
|
], -1)),
|
|
1323
|
-
|
|
1324
|
-
|
|
1325
|
-
])) : (
|
|
1328
|
+
u(y) ? (g(), h("div", Ze, [
|
|
1329
|
+
a(x, { size: "xxl" })
|
|
1330
|
+
])) : (g(), w(C, {
|
|
1326
1331
|
key: 1,
|
|
1327
|
-
"model-value":
|
|
1328
|
-
"onUpdate:modelValue":
|
|
1332
|
+
"model-value": u(t),
|
|
1333
|
+
"onUpdate:modelValue": b[0] || (b[0] = (P) => j(t) ? t.value = P : null),
|
|
1329
1334
|
class: "mb-6 mt-6",
|
|
1330
|
-
items:
|
|
1335
|
+
items: d.value
|
|
1331
1336
|
}, null, 8, ["model-value", "items"])),
|
|
1332
|
-
|
|
1333
|
-
gateway:
|
|
1334
|
-
var
|
|
1335
|
-
return
|
|
1337
|
+
u(t) ? (g(), w(J((D = l.value) == null ? void 0 : D.render), Q(W({ key: 2 }, {
|
|
1338
|
+
gateway: i.value.find((P) => {
|
|
1339
|
+
var R;
|
|
1340
|
+
return P.type === ((R = l.value) == null ? void 0 : R.value);
|
|
1336
1341
|
}),
|
|
1337
1342
|
onDelete: async () => {
|
|
1338
|
-
|
|
1339
|
-
var
|
|
1340
|
-
return
|
|
1341
|
-
}),
|
|
1343
|
+
i.value = i.value.filter((P) => {
|
|
1344
|
+
var R;
|
|
1345
|
+
return P.type !== ((R = l.value) == null ? void 0 : R.value);
|
|
1346
|
+
}), c(i.value);
|
|
1342
1347
|
},
|
|
1343
|
-
onUpdate: (
|
|
1344
|
-
let
|
|
1345
|
-
var
|
|
1346
|
-
return
|
|
1348
|
+
onUpdate: (P) => {
|
|
1349
|
+
let R = i.value.find((M) => {
|
|
1350
|
+
var O;
|
|
1351
|
+
return M.type === ((O = l.value) == null ? void 0 : O.value);
|
|
1347
1352
|
});
|
|
1348
|
-
|
|
1353
|
+
R ? R.config = P : i.value.push(P), c(i.value);
|
|
1349
1354
|
}
|
|
1350
1355
|
})), null, 16)) : S("", !0)
|
|
1351
1356
|
], 64);
|
|
1352
1357
|
};
|
|
1353
1358
|
}
|
|
1354
|
-
}),
|
|
1359
|
+
}), mt = /* @__PURE__ */ T({
|
|
1355
1360
|
__name: "PayoutAccountSetting",
|
|
1356
1361
|
props: {
|
|
1357
1362
|
accountId: {
|
|
@@ -1360,79 +1365,79 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
1360
1365
|
}
|
|
1361
1366
|
},
|
|
1362
1367
|
setup(n) {
|
|
1363
|
-
const
|
|
1368
|
+
const v = n, { tab: e } = z({
|
|
1364
1369
|
tab: "information"
|
|
1365
|
-
}), { isLoading:
|
|
1366
|
-
async function f(
|
|
1367
|
-
await
|
|
1368
|
-
|
|
1369
|
-
|
|
1370
|
-
), s.value = await
|
|
1370
|
+
}), { isLoading: y, startAsyncCall: o } = Y(!0), t = ue(), s = U();
|
|
1371
|
+
async function f(c) {
|
|
1372
|
+
await $.updateById(
|
|
1373
|
+
v.accountId,
|
|
1374
|
+
c
|
|
1375
|
+
), s.value = await $.readById(v.accountId);
|
|
1371
1376
|
}
|
|
1372
|
-
const
|
|
1377
|
+
const i = [
|
|
1373
1378
|
{
|
|
1374
1379
|
label: "Information",
|
|
1375
1380
|
value: "information",
|
|
1376
1381
|
icon: "overview",
|
|
1377
|
-
render:
|
|
1382
|
+
render: pe
|
|
1378
1383
|
},
|
|
1379
1384
|
{
|
|
1380
1385
|
label: "Settlement",
|
|
1381
1386
|
value: "settlement",
|
|
1382
1387
|
icon: "payments",
|
|
1383
|
-
render:
|
|
1388
|
+
render: ge
|
|
1384
1389
|
},
|
|
1385
1390
|
{
|
|
1386
1391
|
label: "MDR Status",
|
|
1387
1392
|
value: "payment",
|
|
1388
1393
|
icon: "account_box",
|
|
1389
|
-
render:
|
|
1394
|
+
render: Ue
|
|
1390
1395
|
},
|
|
1391
1396
|
{
|
|
1392
1397
|
label: "Online Gateways",
|
|
1393
1398
|
icon: "assured_workload",
|
|
1394
1399
|
value: "gateways",
|
|
1395
|
-
render:
|
|
1400
|
+
render: je
|
|
1396
1401
|
},
|
|
1397
1402
|
{
|
|
1398
1403
|
label: "Token Gateways",
|
|
1399
1404
|
value: "tokens",
|
|
1400
1405
|
icon: "wallet",
|
|
1401
|
-
render:
|
|
1406
|
+
render: Je
|
|
1402
1407
|
},
|
|
1403
1408
|
{
|
|
1404
1409
|
label: "Online Channels",
|
|
1405
1410
|
icon: "shopping_cart",
|
|
1406
1411
|
value: "channels",
|
|
1407
|
-
render:
|
|
1412
|
+
render: _e
|
|
1408
1413
|
}
|
|
1409
1414
|
];
|
|
1410
|
-
function
|
|
1411
|
-
|
|
1412
|
-
s.value = await
|
|
1415
|
+
function l() {
|
|
1416
|
+
o(async () => {
|
|
1417
|
+
s.value = await $.readById(v.accountId);
|
|
1413
1418
|
});
|
|
1414
1419
|
}
|
|
1415
|
-
ne(
|
|
1416
|
-
const
|
|
1417
|
-
const
|
|
1418
|
-
return
|
|
1420
|
+
ne(l);
|
|
1421
|
+
const d = B(() => {
|
|
1422
|
+
const c = i.reduce((m, b) => m || (b.children ? b.children.find((x) => x.value === e.value) || null : b.value === e.value ? b : null), null);
|
|
1423
|
+
return c == null ? void 0 : c.render;
|
|
1419
1424
|
});
|
|
1420
|
-
return (
|
|
1421
|
-
var
|
|
1422
|
-
const
|
|
1423
|
-
return
|
|
1424
|
-
title: `Payout Account (${(
|
|
1425
|
-
loading:
|
|
1426
|
-
onBack:
|
|
1425
|
+
return (c, m) => {
|
|
1426
|
+
var x;
|
|
1427
|
+
const b = p("FmTabs");
|
|
1428
|
+
return g(), w(oe, {
|
|
1429
|
+
title: `Payout Account (${(x = s.value) == null ? void 0 : x._id})`,
|
|
1430
|
+
loading: u(y),
|
|
1431
|
+
onBack: u(t).back
|
|
1427
1432
|
}, {
|
|
1428
1433
|
default: F(() => [
|
|
1429
|
-
|
|
1430
|
-
"model-value":
|
|
1431
|
-
"onUpdate:modelValue":
|
|
1434
|
+
a(b, {
|
|
1435
|
+
"model-value": u(e),
|
|
1436
|
+
"onUpdate:modelValue": m[0] || (m[0] = (C) => j(e) ? e.value = C : null),
|
|
1432
1437
|
class: "mb-6",
|
|
1433
|
-
items:
|
|
1438
|
+
items: i
|
|
1434
1439
|
}, null, 8, ["model-value"]),
|
|
1435
|
-
|
|
1440
|
+
u(e) ? (g(), w(J(d.value), Q(W({ key: 0 }, {
|
|
1436
1441
|
payoutAccount: s.value,
|
|
1437
1442
|
onUpdate: f
|
|
1438
1443
|
})), null, 16)) : S("", !0)
|
|
@@ -1443,5 +1448,5 @@ const re = { class: "flex gap-16 mb-6" }, ie = { class: "flex gap-16 mb-6" }, ce
|
|
|
1443
1448
|
}
|
|
1444
1449
|
});
|
|
1445
1450
|
export {
|
|
1446
|
-
|
|
1451
|
+
mt as default
|
|
1447
1452
|
};
|