@feedmepos/mf-payment 1.3.20 → 1.3.21
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-BXyoazh5.js → OnboardForm-UC7FlAKc.js} +4 -4
- package/dist/{OnboardForm-Kg41JzfR.js → OnboardForm-ZIeFW3ZH.js} +4 -4
- package/dist/{OnboardSubmission-DYxlgxNk.js → OnboardSubmission-CGI_T8K6.js} +2 -2
- package/dist/{OnboardSubmission-Dc7x4iX2.js → OnboardSubmission-CUqrOqBi.js} +5 -5
- package/dist/{PayoutAccount-BGp3dZty.js → PayoutAccount-D2eUU8Qa.js} +5 -5
- package/dist/{PayoutAccount-BsG-nuC9.js → PayoutAccount-pxoe0HM6.js} +5 -5
- package/dist/{PayoutAccountSetting-BbMJO09b.js → PayoutAccountSetting-yH2ZRT-A.js} +378 -296
- package/dist/{Restaurant-CwdFy65Q.js → Restaurant-CeH2FJRT.js} +4 -4
- package/dist/{RestaurantSetting-BZ_wJvh-.js → RestaurantSetting-BV1XLh-9.js} +292 -212
- package/dist/{Settlement-PxISyjHU.js → Settlement-DzYUTaVE.js} +3 -3
- package/dist/{Settlement-ByfwQDjy.js → Settlement-L8ukHWPs.js} +3 -3
- package/dist/{SettlementTransactions-DidiqbXG.js → SettlementTransactions-C8o5Atmc.js} +3 -3
- package/dist/{SettlementTransactions-D5yeeyDP.js → SettlementTransactions-DG9nJuLQ.js} +3 -3
- package/dist/{Status.vue_vue_type_script_setup_true_lang-kehDoQ6j.js → Status.vue_vue_type_script_setup_true_lang-B7a304Y6.js} +1 -1
- package/dist/{Terminal-C--amJVv.js → Terminal-DA_mJQMD.js} +5 -5
- package/dist/{TerminalSetting-7tjf9xaV.js → TerminalSetting-GFMILaSV.js} +4 -4
- package/dist/{Transaction-Bd_4iMOT.js → Transaction-CfC0yN9P.js} +5 -5
- package/dist/{Transaction-BMc3gQy1.js → Transaction-fhDUanwr.js} +6 -6
- package/dist/{TransactionOld-8-sEspIt.js → TransactionOld-CObh3uJa.js} +4 -4
- package/dist/{TransactionTable.vue_vue_type_script_setup_true_lang-BayIh55f.js → TransactionTable.vue_vue_type_script_setup_true_lang-DPRIp0wx.js} +3 -3
- package/dist/{app-CQEW3s-w.js → app-U8rab4vJ.js} +22 -22
- package/dist/app.js +1 -1
- package/dist/{assets-CTH4trdc.js → assets-D4ayW3GC.js} +1 -1
- package/dist/{grafana-bPLmWYzm.js → grafana-BrdrOUM4.js} +1 -1
- package/dist/{index-DZYRliw9.js → index-BWjmOoX3.js} +1 -1
- package/dist/{index-CJPiBIRm.js → index-C4FfKmPS.js} +5303 -5231
- package/dist/{index-B5zEwG__.js → index-C8G7ruiF.js} +1 -1
- package/dist/{index-BA8uBmty.js → index-DJJFmavW.js} +2 -2
- package/dist/{index-cU53UWIn.js → index-DJrcobek.js} +1 -1
- package/dist/{index-98tll3Hu.js → index-ILoz50zh.js} +1 -1
- package/dist/{index-DPY6iypt.js → index-j0nww2Hf.js} +1 -1
- package/dist/{index.vue_vue_type_script_setup_true_lang-CaVufHjO.js → index.vue_vue_type_script_setup_true_lang-v7o6C5Pg.js} +1 -1
- package/dist/package.json +2 -2
- package/dist/{payout-account-D0urRPdK.js → payout-account-OFsbgQTk.js} +3 -3
- package/dist/{plugins-CHAPQLQ_.js → plugins-C0WdSJxl.js} +1 -1
- package/dist/stores/payoutAccount.d.ts +34 -18
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/dist/views/admin/payout-account/tabs/Information.vue.d.ts +34 -18
- package/dist/views/admin/payout-account/tabs/PaymentChannel.vue.d.ts +38 -22
- package/dist/views/admin/payout-account/tabs/PaymentGateway.vue.d.ts +38 -22
- package/dist/views/admin/payout-account/tabs/PaymentStatus.vue.d.ts +34 -18
- package/dist/views/admin/payout-account/tabs/Settlement.vue.d.ts +34 -18
- package/dist/views/admin/payout-account/tabs/TokenGateway.vue.d.ts +38 -22
- package/dist/views/admin/payout-account/tabs/gateway/AdyenGateway.vue.d.ts +45 -0
- package/dist/views/admin/payout-account/tabs/gateway/DigioGateway.vue.d.ts +2 -2
- package/dist/views/admin/payout-account/tabs/gateway/FiuuGateway.vue.d.ts +4 -4
- package/dist/views/admin/payout-account/tabs/gateway/MacauPassGateway.vue.d.ts +4 -4
- package/dist/views/admin/payout-account/tabs/token/GooglePayToken.vue.d.ts +2 -2
- package/dist/views/admin/restaurant/tabs/gateway/AdyenGateway.vue.d.ts +50 -0
- package/dist/views/admin/restaurant/tabs/gateway/DigioGateway.vue.d.ts +6 -6
- package/dist/views/admin/restaurant/tabs/gateway/FiuuGateway.vue.d.ts +8 -8
- package/dist/views/admin/restaurant/tabs/gateway/GhlGateway.vue.d.ts +8 -8
- package/dist/views/admin/restaurant/tabs/gateway/GrabGateway.vue.d.ts +6 -6
- package/dist/views/admin/restaurant/tabs/gateway/MacauPassGateway.vue.d.ts +8 -8
- package/dist/views/admin/restaurant/tabs/gateway/RevenueMonsterGateway.vue.d.ts +6 -6
- package/dist/views/admin/restaurant/tabs/gateway/SoftSpaceGateway.vue.d.ts +6 -6
- package/dist/views/admin/terminal/TerminalDialog.vue.d.ts +20 -20
- package/dist/views/admin/terminal/tabs/EcrGateway.vue.d.ts +20 -20
- package/dist/views/admin/terminal/tabs/Information.vue.d.ts +20 -20
- package/dist/views/admin/terminal/tabs/QrGateway.vue.d.ts +20 -20
- package/dist/views/admin/terminal/tabs/SettingRequest.vue.d.ts +20 -20
- package/dist/views/admin/terminal/tabs/SoftposGateway.vue.d.ts +20 -20
- package/dist/views/admin/terminal/tabs/ecr/GhlGateway.vue.d.ts +20 -20
- package/dist/views/admin/terminal/tabs/ecr/KBankGateway.vue.d.ts +20 -20
- package/dist/views/admin/terminal/tabs/ecr/Maybank2Gateway.vue.d.ts +20 -20
- package/dist/views/admin/terminal/tabs/ecr/Maybank3Gateway.vue.d.ts +20 -20
- package/dist/views/admin/terminal/tabs/ecr/MaybankGateway.vue.d.ts +20 -20
- package/dist/views/admin/terminal/tabs/ecr/NetsGateway.vue.d.ts +20 -20
- package/dist/views/admin/terminal/tabs/ecr/TerminalGateway.vue.d.ts +20 -20
- package/dist/views/admin/terminal/tabs/qr/PromptPayGateway.vue.d.ts +20 -20
- package/dist/views/admin/terminal/tabs/settings/KioskMode.vue.d.ts +20 -20
- package/dist/views/payout-account/PayoutAccountTable.vue.d.ts +68 -36
- package/dist/views/settlement/FiuuSettlementTable.vue.d.ts +32 -32
- package/dist/views/settlement/FiuuSettlementTransactions.vue.d.ts +16 -16
- package/package.json +2 -2
@@ -1,15 +1,15 @@
|
|
1
|
-
import { defineComponent as
|
2
|
-
import { p as
|
3
|
-
import { u as
|
1
|
+
import { defineComponent as C, resolveComponent as m, openBlock as f, createElementBlock as T, Fragment as $, createElementVNode as i, createVNode as u, withCtx as V, createTextVNode as U, toDisplayString as S, createCommentVNode as _, createBlock as w, ref as h, watch as W, computed as G, unref as o, isRef as K, h as R, onMounted as J, resolveDynamicComponent as z, normalizeProps as L, mergeProps as H } from "vue";
|
2
|
+
import { p as D } from "./index-BWjmOoX3.js";
|
3
|
+
import { u as E, e as I } from "./index-C4FfKmPS.js";
|
4
4
|
import { _ as ee } from "./Layout.vue_vue_type_script_setup_true_lang-DJm5br5a.js";
|
5
5
|
import { useRouter as te } from "vue-router";
|
6
|
-
import { u as
|
6
|
+
import { u as j } from "./index-ILoz50zh.js";
|
7
7
|
import { P as Q } from "./PDFViewer-DlSCBBxr.js";
|
8
8
|
import { useSnackbar as Y, components as ae } from "@feedmepos/ui-library";
|
9
9
|
import { u as B } from "./error-K1CakhA9.js";
|
10
|
-
import { z as
|
10
|
+
import { z as k, a as A } from "./validator-D5jtpt9A.js";
|
11
11
|
import { useCoreStore as X } from "@feedmepos/mf-common";
|
12
|
-
const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */
|
12
|
+
const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ C({
|
13
13
|
__name: "Information",
|
14
14
|
props: {
|
15
15
|
payoutAccount: {
|
@@ -18,9 +18,9 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
18
18
|
}
|
19
19
|
},
|
20
20
|
setup(n) {
|
21
|
-
return (
|
22
|
-
const
|
23
|
-
return
|
21
|
+
return (y, e) => {
|
22
|
+
const d = m("FmCardHeader"), c = m("FmCardSection"), t = m("FmCard");
|
23
|
+
return f(), T($, null, [
|
24
24
|
i("div", ne, [
|
25
25
|
u(t, {
|
26
26
|
horizontal: "",
|
@@ -28,25 +28,25 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
28
28
|
variant: "elevated"
|
29
29
|
}, {
|
30
30
|
default: V(() => [
|
31
|
-
u(
|
31
|
+
u(c, { class: "flex flex-col gap-16 justify-between" }, {
|
32
32
|
default: V(() => [
|
33
|
-
u(
|
33
|
+
u(d, {
|
34
34
|
class: "p-0",
|
35
35
|
title: "Account Info",
|
36
36
|
subtitle: ""
|
37
37
|
}),
|
38
|
-
u(
|
38
|
+
u(c, { class: "p-0" }, {
|
39
39
|
default: V(() => {
|
40
|
-
var
|
40
|
+
var l, p, s, a, r;
|
41
41
|
return [
|
42
42
|
e[0] || (e[0] = i("b", null, "For", -1)),
|
43
|
-
|
43
|
+
U(": " + S((p = (l = n.payoutAccount) == null ? void 0 : l.store) == null ? void 0 : p.event) + " ", 1),
|
44
44
|
e[1] || (e[1] = i("br", null, null, -1)),
|
45
45
|
e[2] || (e[2] = i("b", null, "Reference", -1)),
|
46
|
-
|
46
|
+
U(": " + S((a = (s = n.payoutAccount) == null ? void 0 : s.store) == null ? void 0 : a.id), 1),
|
47
47
|
e[3] || (e[3] = i("br", null, null, -1)),
|
48
48
|
e[4] || (e[4] = i("b", null, "Business", -1)),
|
49
|
-
|
49
|
+
U(": " + S((r = n.payoutAccount) == null ? void 0 : r.businessId), 1),
|
50
50
|
e[5] || (e[5] = i("br", null, null, -1))
|
51
51
|
];
|
52
52
|
}),
|
@@ -64,25 +64,25 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
64
64
|
variant: "elevated"
|
65
65
|
}, {
|
66
66
|
default: V(() => [
|
67
|
-
u(
|
67
|
+
u(c, { class: "flex flex-col gap-16 justify-between" }, {
|
68
68
|
default: V(() => [
|
69
|
-
u(
|
69
|
+
u(d, {
|
70
70
|
class: "p-0",
|
71
71
|
title: "Key Person",
|
72
72
|
subtitle: ""
|
73
73
|
}),
|
74
|
-
u(
|
74
|
+
u(c, { class: "p-0" }, {
|
75
75
|
default: V(() => {
|
76
|
-
var
|
76
|
+
var l, p, s, a, r, g, v, b;
|
77
77
|
return [
|
78
78
|
e[6] || (e[6] = i("b", null, "Email", -1)),
|
79
|
-
|
79
|
+
U(": " + S((s = (p = (l = n.payoutAccount) == null ? void 0 : l.store) == null ? void 0 : p.keyPerson) == null ? void 0 : s.email) + " ", 1),
|
80
80
|
e[7] || (e[7] = i("br", null, null, -1)),
|
81
81
|
e[8] || (e[8] = i("b", null, "Name", -1)),
|
82
|
-
|
82
|
+
U(": " + S((g = (r = (a = n.payoutAccount) == null ? void 0 : a.store) == null ? void 0 : r.keyPerson) == null ? void 0 : g.name), 1),
|
83
83
|
e[9] || (e[9] = i("br", null, null, -1)),
|
84
84
|
e[10] || (e[10] = i("b", null, "Phone", -1)),
|
85
|
-
|
85
|
+
U(": " + S((b = (v = n.payoutAccount) == null ? void 0 : v.store.keyPerson) == null ? void 0 : b.phone), 1),
|
86
86
|
e[11] || (e[11] = i("br", null, null, -1))
|
87
87
|
];
|
88
88
|
}),
|
@@ -96,14 +96,14 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
96
96
|
})
|
97
97
|
]),
|
98
98
|
e[12] || (e[12] = i("p", { class: "fm-typo-en-body-lg-600 mb-6" }, "Exterior Photo", -1)),
|
99
|
-
n.payoutAccount.store.exteriorPhoto ? (
|
99
|
+
n.payoutAccount.store.exteriorPhoto ? (f(), T("img", {
|
100
100
|
key: 0,
|
101
101
|
src: n.payoutAccount.store.exteriorPhoto
|
102
|
-
}, null, 8, le)) :
|
102
|
+
}, null, 8, le)) : _("", !0)
|
103
103
|
], 64);
|
104
104
|
};
|
105
105
|
}
|
106
|
-
}), ue = { class: "flex gap-16" }, re = { class: "flex-1" }, se = { class: "flex-1" }, ce = /* @__PURE__ */
|
106
|
+
}), ue = { class: "flex gap-16" }, re = { class: "flex-1" }, se = { class: "flex-1" }, ce = /* @__PURE__ */ C({
|
107
107
|
__name: "Settlement",
|
108
108
|
props: {
|
109
109
|
payoutAccount: {
|
@@ -112,34 +112,34 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
112
112
|
}
|
113
113
|
},
|
114
114
|
setup(n) {
|
115
|
-
return (
|
116
|
-
const
|
117
|
-
return
|
115
|
+
return (y, e) => {
|
116
|
+
const d = m("FmCardHeader"), c = m("FmCardSection"), t = m("FmCard");
|
117
|
+
return f(), T($, null, [
|
118
118
|
u(t, {
|
119
119
|
horizontal: "",
|
120
120
|
class: "flex-1 p-6 mx-6 mb-6",
|
121
121
|
variant: "elevated"
|
122
122
|
}, {
|
123
123
|
default: V(() => [
|
124
|
-
u(
|
124
|
+
u(c, { class: "flex flex-col gap-16 justify-between" }, {
|
125
125
|
default: V(() => [
|
126
|
-
u(
|
126
|
+
u(d, {
|
127
127
|
class: "p-0",
|
128
128
|
title: "Bank Info",
|
129
129
|
subtitle: ""
|
130
130
|
}),
|
131
|
-
u(
|
131
|
+
u(c, { class: "p-0" }, {
|
132
132
|
default: V(() => {
|
133
|
-
var
|
133
|
+
var l, p, s, a, r, g;
|
134
134
|
return [
|
135
135
|
e[0] || (e[0] = i("b", null, "Bank", -1)),
|
136
|
-
|
136
|
+
U(": " + S((p = (l = n.payoutAccount) == null ? void 0 : l.store.bank) == null ? void 0 : p.name), 1),
|
137
137
|
e[1] || (e[1] = i("br", null, null, -1)),
|
138
138
|
e[2] || (e[2] = i("b", null, "Name", -1)),
|
139
|
-
|
139
|
+
U(": " + S((a = (s = n.payoutAccount) == null ? void 0 : s.store.bank) == null ? void 0 : a.holderName), 1),
|
140
140
|
e[3] || (e[3] = i("br", null, null, -1)),
|
141
141
|
e[4] || (e[4] = i("b", null, "Number", -1)),
|
142
|
-
|
142
|
+
U(": " + S((g = (r = n.payoutAccount) == null ? void 0 : r.store.bank) == null ? void 0 : g.accountNumber), 1)
|
143
143
|
];
|
144
144
|
}),
|
145
145
|
_: 1
|
@@ -153,70 +153,70 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
153
153
|
i("div", ue, [
|
154
154
|
i("div", re, [
|
155
155
|
e[5] || (e[5] = i("p", { class: "fm-typo-en-body-lg-600 mb-6" }, "SSM", -1)),
|
156
|
-
n.payoutAccount.store.ssm ? (
|
156
|
+
n.payoutAccount.store.ssm ? (f(), w(Q, {
|
157
157
|
key: 0,
|
158
158
|
pdf: n.payoutAccount.store.ssm,
|
159
159
|
"disable-text-layer": !0,
|
160
160
|
"disable-annotation-layer": !0
|
161
|
-
}, null, 8, ["pdf"])) :
|
161
|
+
}, null, 8, ["pdf"])) : _("", !0)
|
162
162
|
]),
|
163
163
|
i("div", se, [
|
164
164
|
e[6] || (e[6] = i("p", { class: "fm-typo-en-body-lg-600 mb-6" }, "Bank Statement", -1)),
|
165
|
-
n.payoutAccount.store.bankStatement ? (
|
165
|
+
n.payoutAccount.store.bankStatement ? (f(), w(Q, {
|
166
166
|
key: 0,
|
167
167
|
pdf: n.payoutAccount.store.bankStatement,
|
168
168
|
"disable-text-layer": !0,
|
169
169
|
"disable-annotation-layer": !0
|
170
|
-
}, null, 8, ["pdf"])) :
|
170
|
+
}, null, 8, ["pdf"])) : _("", !0)
|
171
171
|
])
|
172
172
|
])
|
173
173
|
], 64);
|
174
174
|
};
|
175
175
|
}
|
176
|
-
}), ie = /* @__PURE__ */
|
176
|
+
}), ie = /* @__PURE__ */ C({
|
177
177
|
__name: "RateInput",
|
178
178
|
props: {
|
179
179
|
data: {},
|
180
180
|
onChange: { type: Function }
|
181
181
|
},
|
182
182
|
setup(n) {
|
183
|
-
const
|
184
|
-
return W(e, (
|
185
|
-
|
186
|
-
}), (
|
187
|
-
const t =
|
188
|
-
return
|
183
|
+
const y = n, e = h(y.data.toString());
|
184
|
+
return W(e, (d) => {
|
185
|
+
y.onChange(parseFloat(d));
|
186
|
+
}), (d, c) => {
|
187
|
+
const t = m("FmTextField");
|
188
|
+
return f(), w(t, {
|
189
189
|
inputmode: "decimal",
|
190
190
|
modelValue: e.value,
|
191
|
-
"onUpdate:modelValue":
|
191
|
+
"onUpdate:modelValue": c[0] || (c[0] = (l) => e.value = l)
|
192
192
|
}, {
|
193
|
-
append: V(() =>
|
194
|
-
|
193
|
+
append: V(() => c[1] || (c[1] = [
|
194
|
+
U("%")
|
195
195
|
])),
|
196
196
|
_: 1
|
197
197
|
}, 8, ["modelValue"]);
|
198
198
|
};
|
199
199
|
}
|
200
|
-
}),
|
200
|
+
}), me = /* @__PURE__ */ C({
|
201
201
|
__name: "TPlusInput",
|
202
202
|
props: {
|
203
203
|
data: {},
|
204
204
|
onChange: { type: Function }
|
205
205
|
},
|
206
206
|
setup(n) {
|
207
|
-
const
|
208
|
-
return W(e, (
|
209
|
-
|
210
|
-
}), (
|
211
|
-
const t =
|
212
|
-
return
|
207
|
+
const y = n, e = h(y.data.toString());
|
208
|
+
return W(e, (d) => {
|
209
|
+
y.onChange(parseInt(d));
|
210
|
+
}), (d, c) => {
|
211
|
+
const t = m("FmTextField");
|
212
|
+
return f(), w(t, {
|
213
213
|
inputmode: "numeric",
|
214
214
|
modelValue: e.value,
|
215
|
-
"onUpdate:modelValue":
|
215
|
+
"onUpdate:modelValue": c[0] || (c[0] = (l) => e.value = l)
|
216
216
|
}, null, 8, ["modelValue"]);
|
217
217
|
};
|
218
218
|
}
|
219
|
-
}),
|
219
|
+
}), de = { class: "flex gap-16 mt-6" }, pe = { class: "flex-1" }, ye = { class: "flex-1" }, ve = { class: "my-6 w-full flex justify-end" }, fe = { class: "w-[320px]" }, ge = /* @__PURE__ */ C({
|
220
220
|
__name: "PaymentStatus",
|
221
221
|
props: {
|
222
222
|
onUpdate: {
|
@@ -229,27 +229,27 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
229
229
|
}
|
230
230
|
},
|
231
231
|
setup(n) {
|
232
|
-
const
|
232
|
+
const y = n, e = h(!1), d = Y(), c = async (a) => {
|
233
233
|
try {
|
234
|
-
e.value = !0, await
|
234
|
+
e.value = !0, await y.onUpdate(a), d.open({
|
235
235
|
type: "success",
|
236
236
|
title: "Payout account update succesfully"
|
237
237
|
});
|
238
|
-
} catch (
|
239
|
-
|
238
|
+
} catch (r) {
|
239
|
+
d.open({
|
240
240
|
type: "error",
|
241
241
|
title: "Error occurs when updating payout account",
|
242
|
-
message: B(
|
242
|
+
message: B(r)
|
243
243
|
});
|
244
244
|
} finally {
|
245
245
|
e.value = !1;
|
246
246
|
}
|
247
|
-
}, { search: t } =
|
247
|
+
}, { search: t } = j({
|
248
248
|
search: ""
|
249
|
-
}),
|
250
|
-
const { ssm: a, bank:
|
251
|
-
return a &&
|
252
|
-
}),
|
249
|
+
}), l = G(() => {
|
250
|
+
const { ssm: a, bank: r, bankStatement: g } = y.payoutAccount.store;
|
251
|
+
return a && r && r.name && r.accountNumber && r.holderName && g;
|
252
|
+
}), p = h(""), s = [
|
253
253
|
{
|
254
254
|
header: () => "Payment Method",
|
255
255
|
accessorKey: "issuer",
|
@@ -259,15 +259,15 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
259
259
|
header: () => "Rate",
|
260
260
|
accessorKey: "rate",
|
261
261
|
cell: ({ row: a }) => {
|
262
|
-
let
|
263
|
-
return a.original.rate && (
|
264
|
-
data:
|
265
|
-
onChange: (
|
266
|
-
const v =
|
262
|
+
let r = 0;
|
263
|
+
return a.original.rate && (r = a.original.rate.amount / Math.pow(10, a.original.rate.precision)), R(ie, {
|
264
|
+
data: r,
|
265
|
+
onChange: (g) => {
|
266
|
+
const v = y.payoutAccount.methods.at(a.index);
|
267
267
|
v.rate || (v.rate = {
|
268
268
|
amount: 0,
|
269
269
|
precision: 4
|
270
|
-
}), v.rate.amount =
|
270
|
+
}), v.rate.amount = g * Math.pow(10, v.rate.precision);
|
271
271
|
}
|
272
272
|
});
|
273
273
|
}
|
@@ -275,35 +275,35 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
275
275
|
{
|
276
276
|
header: () => "T plus",
|
277
277
|
accessorKey: "tPlus",
|
278
|
-
cell: ({ row: a }) => R(
|
278
|
+
cell: ({ row: a }) => R(me, {
|
279
279
|
data: a.original.tPlus ?? 0,
|
280
|
-
onChange: (
|
281
|
-
const
|
282
|
-
|
280
|
+
onChange: (r) => {
|
281
|
+
const g = y.payoutAccount.methods.at(a.index);
|
282
|
+
g.tPlus = r;
|
283
283
|
}
|
284
284
|
})
|
285
285
|
}
|
286
286
|
];
|
287
|
-
return (a,
|
288
|
-
const
|
289
|
-
return
|
290
|
-
i("div",
|
287
|
+
return (a, r) => {
|
288
|
+
const g = m("FmRadio"), v = m("FmRadioGroup"), b = m("FmSwitch"), P = m("FmSearch"), N = m("FmTable"), M = m("FmButton");
|
289
|
+
return f(), T($, null, [
|
290
|
+
i("div", de, [
|
291
291
|
i("div", pe, [
|
292
292
|
u(v, {
|
293
293
|
modelValue: n.payoutAccount.status,
|
294
|
-
"onUpdate:modelValue":
|
294
|
+
"onUpdate:modelValue": r[0] || (r[0] = (F) => n.payoutAccount.status = F),
|
295
295
|
label: "Account Status"
|
296
296
|
}, {
|
297
297
|
default: V(() => [
|
298
|
-
u(
|
298
|
+
u(g, {
|
299
299
|
value: "NEW",
|
300
300
|
label: "New"
|
301
301
|
}),
|
302
|
-
u(
|
302
|
+
u(g, {
|
303
303
|
value: "PENDING",
|
304
304
|
label: "Pending"
|
305
305
|
}),
|
306
|
-
u(
|
306
|
+
u(g, {
|
307
307
|
value: "APPROVED",
|
308
308
|
label: "Approved"
|
309
309
|
})
|
@@ -314,62 +314,62 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
314
314
|
i("div", ye, [
|
315
315
|
u(b, {
|
316
316
|
modelValue: n.payoutAccount.enable,
|
317
|
-
"onUpdate:modelValue":
|
318
|
-
disabled: !
|
317
|
+
"onUpdate:modelValue": r[1] || (r[1] = (F) => n.payoutAccount.enable = F),
|
318
|
+
disabled: !l.value,
|
319
319
|
label: "Enabled",
|
320
320
|
sublabel: "Merchant can use online features such as e-payment, settlement"
|
321
321
|
}, null, 8, ["modelValue", "disabled"])
|
322
322
|
])
|
323
323
|
]),
|
324
|
-
n.payoutAccount.enable ? (
|
324
|
+
n.payoutAccount.enable ? (f(), T($, { key: 0 }, [
|
325
325
|
i("div", ve, [
|
326
326
|
i("div", fe, [
|
327
|
-
u(
|
328
|
-
modelValue:
|
329
|
-
"onUpdate:modelValue":
|
327
|
+
u(P, {
|
328
|
+
modelValue: o(t),
|
329
|
+
"onUpdate:modelValue": r[2] || (r[2] = (F) => K(t) ? t.value = F : null),
|
330
330
|
placeholder: "Search Method ..."
|
331
331
|
}, null, 8, ["modelValue"])
|
332
332
|
])
|
333
333
|
]),
|
334
|
-
u(
|
334
|
+
u(N, {
|
335
335
|
class: "mt-6",
|
336
|
-
modelValue:
|
337
|
-
"onUpdate:modelValue":
|
336
|
+
modelValue: p.value,
|
337
|
+
"onUpdate:modelValue": r[3] || (r[3] = (F) => p.value = F),
|
338
338
|
"shrink-at": !1,
|
339
|
-
"search-value":
|
339
|
+
"search-value": o(t),
|
340
340
|
"row-data": n.payoutAccount.methods,
|
341
|
-
"column-defs":
|
341
|
+
"column-defs": s
|
342
342
|
}, null, 8, ["modelValue", "search-value", "row-data"])
|
343
|
-
], 64)) :
|
343
|
+
], 64)) : _("", !0),
|
344
344
|
u(M, {
|
345
345
|
class: "w-full mt-6",
|
346
346
|
variant: "primary",
|
347
347
|
label: "Save",
|
348
348
|
loading: e.value,
|
349
|
-
onclick: () =>
|
349
|
+
onclick: () => c(n.payoutAccount)
|
350
350
|
}, null, 8, ["loading", "onclick"])
|
351
351
|
], 64);
|
352
352
|
};
|
353
353
|
}
|
354
|
-
}), be = { class: "flex" }, Fe = /* @__PURE__ */
|
354
|
+
}), be = { class: "flex" }, Fe = /* @__PURE__ */ C({
|
355
355
|
__name: "Actions",
|
356
356
|
emits: ["edit", "delete"],
|
357
|
-
setup(n, { emit:
|
358
|
-
const e =
|
359
|
-
return (
|
360
|
-
const t =
|
361
|
-
return
|
357
|
+
setup(n, { emit: y }) {
|
358
|
+
const e = y;
|
359
|
+
return (d, c) => {
|
360
|
+
const t = m("FmButton");
|
361
|
+
return f(), T("div", be, [
|
362
362
|
u(t, {
|
363
363
|
variant: "plain",
|
364
364
|
"prepend-icon": "delete",
|
365
|
-
onClick:
|
366
|
-
|
365
|
+
onClick: c[0] || (c[0] = (l) => {
|
366
|
+
l.stopPropagation(), e("delete");
|
367
367
|
})
|
368
368
|
})
|
369
369
|
]);
|
370
370
|
};
|
371
371
|
}
|
372
|
-
}), we = { class: "flex justify-end px-6 pb-6" }, xe = /* @__PURE__ */
|
372
|
+
}), we = { class: "flex justify-end px-6 pb-6" }, xe = /* @__PURE__ */ C({
|
373
373
|
__name: "PaymentChannel",
|
374
374
|
props: {
|
375
375
|
payoutAccount: {
|
@@ -378,41 +378,41 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
378
378
|
}
|
379
379
|
},
|
380
380
|
setup(n) {
|
381
|
-
const
|
382
|
-
function
|
383
|
-
|
384
|
-
t.value = await
|
381
|
+
const y = Y(), e = n, { isLoading: d, startAsyncCall: c } = E(), t = h([]);
|
382
|
+
function l() {
|
383
|
+
c(async () => {
|
384
|
+
t.value = await D.getChannels(e.payoutAccount._id);
|
385
385
|
});
|
386
386
|
}
|
387
|
-
J(
|
388
|
-
function
|
389
|
-
|
387
|
+
J(l);
|
388
|
+
function p() {
|
389
|
+
c(async () => {
|
390
390
|
try {
|
391
|
-
await
|
391
|
+
await D.updateChannels(e.payoutAccount._id, t.value), y.open({
|
392
392
|
type: "success",
|
393
393
|
title: "Payout account channels update succesfully"
|
394
394
|
});
|
395
|
-
} catch (
|
396
|
-
|
395
|
+
} catch (r) {
|
396
|
+
y.open({
|
397
397
|
type: "error",
|
398
398
|
title: "Error occurs when updating payout account channels",
|
399
|
-
message: B(
|
399
|
+
message: B(r)
|
400
400
|
});
|
401
401
|
}
|
402
402
|
});
|
403
403
|
}
|
404
|
-
function
|
405
|
-
|
404
|
+
function s() {
|
405
|
+
c(async () => {
|
406
406
|
try {
|
407
|
-
await
|
407
|
+
await D.resetChannels(e.payoutAccount._id), t.value = await D.getChannels(e.payoutAccount._id), y.open({
|
408
408
|
type: "success",
|
409
409
|
title: "Payout account channels reset succesfully"
|
410
410
|
});
|
411
|
-
} catch (
|
412
|
-
|
411
|
+
} catch (r) {
|
412
|
+
y.open({
|
413
413
|
type: "error",
|
414
414
|
title: "Error occurs when reset payout account channels",
|
415
|
-
message: B(
|
415
|
+
message: B(r)
|
416
416
|
});
|
417
417
|
}
|
418
418
|
});
|
@@ -429,27 +429,27 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
429
429
|
{
|
430
430
|
header: () => "Display",
|
431
431
|
accessorKey: "icon",
|
432
|
-
cell: ({ row:
|
432
|
+
cell: ({ row: r }) => R("img", { src: r.original.icon, width: 32, height: 32 })
|
433
433
|
},
|
434
434
|
{
|
435
435
|
header: () => "Label",
|
436
436
|
accessorKey: "label",
|
437
|
-
cell: ({ row:
|
438
|
-
modelValue:
|
439
|
-
"onUpdate:modelValue": (
|
437
|
+
cell: ({ row: r }) => R(ae.FmTextField, {
|
438
|
+
modelValue: r.original.label,
|
439
|
+
"onUpdate:modelValue": (g) => r.original.label = g
|
440
440
|
})
|
441
441
|
},
|
442
442
|
{
|
443
443
|
id: "actions",
|
444
444
|
header: () => "Actions",
|
445
|
-
cell: ({ row:
|
446
|
-
onDelete: () => t.value.splice(
|
445
|
+
cell: ({ row: r }) => R(Fe, {
|
446
|
+
onDelete: () => t.value.splice(r.index, 1)
|
447
447
|
})
|
448
448
|
}
|
449
449
|
];
|
450
|
-
return (
|
451
|
-
const v =
|
452
|
-
return
|
450
|
+
return (r, g) => {
|
451
|
+
const v = m("FmButton"), b = m("FmTable");
|
452
|
+
return f(), T($, null, [
|
453
453
|
i("div", we, [
|
454
454
|
u(v, {
|
455
455
|
class: "mx-4",
|
@@ -457,18 +457,18 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
457
457
|
size: "md",
|
458
458
|
icon: "history",
|
459
459
|
label: "Reset",
|
460
|
-
onClick:
|
460
|
+
onClick: s
|
461
461
|
}),
|
462
462
|
u(v, {
|
463
463
|
variant: "primary",
|
464
464
|
size: "md",
|
465
465
|
icon: "save",
|
466
466
|
label: "Save",
|
467
|
-
onClick:
|
467
|
+
onClick: p
|
468
468
|
})
|
469
469
|
]),
|
470
470
|
u(b, {
|
471
|
-
loading:
|
471
|
+
loading: o(d),
|
472
472
|
"row-data": t.value,
|
473
473
|
"column-defs": a,
|
474
474
|
"shrink-at": !1
|
@@ -476,7 +476,7 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
476
476
|
], 64);
|
477
477
|
};
|
478
478
|
}
|
479
|
-
}), Ve = { class: "flex mt-6 space-x-6" }, ke = /* @__PURE__ */
|
479
|
+
}), Ve = { class: "flex mt-6 space-x-6" }, ke = /* @__PURE__ */ C({
|
480
480
|
__name: "FiuuGateway",
|
481
481
|
props: {
|
482
482
|
gateway: {
|
@@ -493,47 +493,47 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
493
493
|
}
|
494
494
|
},
|
495
495
|
setup(n) {
|
496
|
-
var
|
497
|
-
const e =
|
496
|
+
var d;
|
497
|
+
const e = h(((d = n.gateway) == null ? void 0 : d.config) || {
|
498
498
|
merchantId: "",
|
499
499
|
verifyKey: "",
|
500
500
|
secretKey: ""
|
501
501
|
});
|
502
|
-
return (
|
503
|
-
const
|
504
|
-
return
|
502
|
+
return (c, t) => {
|
503
|
+
const l = m("FmTextField"), p = m("FmButton"), s = m("FmForm");
|
504
|
+
return f(), w(s, {
|
505
505
|
ref: "form",
|
506
506
|
class: "flex flex-col gap-16",
|
507
507
|
onValidationSuccess: t[3] || (t[3] = () => n.onUpdate(e.value))
|
508
508
|
}, {
|
509
509
|
default: V(() => [
|
510
|
-
u(
|
510
|
+
u(l, {
|
511
511
|
modelValue: e.value.merchantId,
|
512
512
|
"onUpdate:modelValue": t[0] || (t[0] = (a) => e.value.merchantId = a),
|
513
513
|
label: "Merchant ID",
|
514
|
-
rules:
|
514
|
+
rules: o(k)(o(A).string())
|
515
515
|
}, null, 8, ["modelValue", "rules"]),
|
516
|
-
u(
|
516
|
+
u(l, {
|
517
517
|
modelValue: e.value.verifyKey,
|
518
518
|
"onUpdate:modelValue": t[1] || (t[1] = (a) => e.value.verifyKey = a),
|
519
519
|
label: "Verify Key",
|
520
|
-
rules:
|
520
|
+
rules: o(k)(o(A).string())
|
521
521
|
}, null, 8, ["modelValue", "rules"]),
|
522
|
-
u(
|
522
|
+
u(l, {
|
523
523
|
modelValue: e.value.secretKey,
|
524
524
|
"onUpdate:modelValue": t[2] || (t[2] = (a) => e.value.secretKey = a),
|
525
525
|
label: "Secret Key",
|
526
|
-
rules:
|
526
|
+
rules: o(k)(o(A).string())
|
527
527
|
}, null, 8, ["modelValue", "rules"]),
|
528
528
|
i("div", Ve, [
|
529
|
-
n.gateway ? (
|
529
|
+
n.gateway ? (f(), w(p, {
|
530
530
|
key: 0,
|
531
531
|
class: "flex-1",
|
532
532
|
variant: "secondary",
|
533
533
|
label: "Delete",
|
534
534
|
onclick: () => n.onDelete()
|
535
|
-
}, null, 8, ["onclick"])) :
|
536
|
-
u(
|
535
|
+
}, null, 8, ["onclick"])) : _("", !0),
|
536
|
+
u(p, {
|
537
537
|
type: "submit",
|
538
538
|
class: "flex-1",
|
539
539
|
variant: "primary",
|
@@ -545,7 +545,7 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
545
545
|
}, 512);
|
546
546
|
};
|
547
547
|
}
|
548
|
-
}),
|
548
|
+
}), Ae = { class: "flex mt-6 space-x-6" }, Ce = /* @__PURE__ */ C({
|
549
549
|
__name: "MacauPassGateway",
|
550
550
|
props: {
|
551
551
|
gateway: {
|
@@ -562,61 +562,61 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
562
562
|
}
|
563
563
|
},
|
564
564
|
setup(n) {
|
565
|
-
var
|
566
|
-
const e =
|
565
|
+
var d;
|
566
|
+
const e = h(((d = n.gateway) == null ? void 0 : d.config) || {
|
567
567
|
merchantId: "",
|
568
568
|
merchantName: "",
|
569
569
|
merchantCategoryCode: "",
|
570
570
|
storeID: "",
|
571
571
|
storeName: ""
|
572
572
|
});
|
573
|
-
return (
|
574
|
-
const
|
575
|
-
return
|
573
|
+
return (c, t) => {
|
574
|
+
const l = m("FmTextField"), p = m("FmButton"), s = m("FmForm");
|
575
|
+
return f(), w(s, {
|
576
576
|
ref: "form",
|
577
577
|
class: "flex flex-col gap-16",
|
578
578
|
onValidationSuccess: t[5] || (t[5] = () => n.onUpdate(e.value))
|
579
579
|
}, {
|
580
580
|
default: V(() => [
|
581
|
-
u(
|
581
|
+
u(l, {
|
582
582
|
modelValue: e.value.merchantId,
|
583
583
|
"onUpdate:modelValue": t[0] || (t[0] = (a) => e.value.merchantId = a),
|
584
584
|
label: "Merchant ID",
|
585
|
-
rules:
|
585
|
+
rules: o(k)(o(A).string())
|
586
586
|
}, null, 8, ["modelValue", "rules"]),
|
587
|
-
u(
|
587
|
+
u(l, {
|
588
588
|
modelValue: e.value.merchantName,
|
589
589
|
"onUpdate:modelValue": t[1] || (t[1] = (a) => e.value.merchantName = a),
|
590
590
|
label: "Merchant Name",
|
591
|
-
rules:
|
591
|
+
rules: o(k)(o(A).string())
|
592
592
|
}, null, 8, ["modelValue", "rules"]),
|
593
|
-
u(
|
593
|
+
u(l, {
|
594
594
|
modelValue: e.value.merchantCategoryCode,
|
595
595
|
"onUpdate:modelValue": t[2] || (t[2] = (a) => e.value.merchantCategoryCode = a),
|
596
596
|
label: "Merchant MCC",
|
597
|
-
rules:
|
597
|
+
rules: o(k)(o(A).string())
|
598
598
|
}, null, 8, ["modelValue", "rules"]),
|
599
|
-
u(
|
599
|
+
u(l, {
|
600
600
|
modelValue: e.value.storeID,
|
601
601
|
"onUpdate:modelValue": t[3] || (t[3] = (a) => e.value.storeID = a),
|
602
602
|
label: "Store ID",
|
603
|
-
rules:
|
603
|
+
rules: o(k)(o(A).string())
|
604
604
|
}, null, 8, ["modelValue", "rules"]),
|
605
|
-
u(
|
605
|
+
u(l, {
|
606
606
|
modelValue: e.value.storeName,
|
607
607
|
"onUpdate:modelValue": t[4] || (t[4] = (a) => e.value.storeName = a),
|
608
608
|
label: "Store Name",
|
609
|
-
rules:
|
609
|
+
rules: o(k)(o(A).string())
|
610
610
|
}, null, 8, ["modelValue", "rules"]),
|
611
|
-
i("div",
|
612
|
-
n.gateway ? (
|
611
|
+
i("div", Ae, [
|
612
|
+
n.gateway ? (f(), w(p, {
|
613
613
|
key: 0,
|
614
614
|
class: "flex-1",
|
615
615
|
variant: "secondary",
|
616
616
|
label: "Delete",
|
617
617
|
onclick: () => n.onDelete()
|
618
|
-
}, null, 8, ["onclick"])) :
|
619
|
-
u(
|
618
|
+
}, null, 8, ["onclick"])) : _("", !0),
|
619
|
+
u(p, {
|
620
620
|
type: "submit",
|
621
621
|
class: "flex-1",
|
622
622
|
variant: "primary",
|
@@ -628,7 +628,7 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
628
628
|
}, 512);
|
629
629
|
};
|
630
630
|
}
|
631
|
-
}),
|
631
|
+
}), _e = { class: "flex mt-6 space-x-6" }, he = /* @__PURE__ */ C({
|
632
632
|
__name: "DigioGateway",
|
633
633
|
props: {
|
634
634
|
gateway: {
|
@@ -645,40 +645,116 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
645
645
|
}
|
646
646
|
},
|
647
647
|
setup(n) {
|
648
|
-
var
|
649
|
-
const e =
|
648
|
+
var d;
|
649
|
+
const e = h(((d = n.gateway) == null ? void 0 : d.config) || {
|
650
650
|
merchantId: "",
|
651
651
|
cardMerchantId: ""
|
652
652
|
});
|
653
|
-
return (
|
654
|
-
const
|
655
|
-
return
|
653
|
+
return (c, t) => {
|
654
|
+
const l = m("FmTextField"), p = m("FmButton"), s = m("FmForm");
|
655
|
+
return f(), w(s, {
|
656
656
|
ref: "form",
|
657
657
|
class: "flex flex-col gap-16",
|
658
658
|
onValidationSuccess: t[2] || (t[2] = () => n.onUpdate(e.value))
|
659
659
|
}, {
|
660
660
|
default: V(() => [
|
661
|
-
u(
|
661
|
+
u(l, {
|
662
662
|
modelValue: e.value.merchantId,
|
663
663
|
"onUpdate:modelValue": t[0] || (t[0] = (a) => e.value.merchantId = a),
|
664
664
|
label: "Merchant ID",
|
665
|
-
rules:
|
665
|
+
rules: o(k)(o(A).string())
|
666
666
|
}, null, 8, ["modelValue", "rules"]),
|
667
|
-
u(
|
667
|
+
u(l, {
|
668
668
|
modelValue: e.value.cardMerchantId,
|
669
669
|
"onUpdate:modelValue": t[1] || (t[1] = (a) => e.value.cardMerchantId = a),
|
670
670
|
label: "Card Merchant ID",
|
671
|
-
rules:
|
671
|
+
rules: o(k)(o(A).string())
|
672
672
|
}, null, 8, ["modelValue", "rules"]),
|
673
|
-
i("div",
|
674
|
-
n.gateway ? (
|
673
|
+
i("div", _e, [
|
674
|
+
n.gateway ? (f(), w(p, {
|
675
|
+
key: 0,
|
676
|
+
class: "flex-1",
|
677
|
+
variant: "secondary",
|
678
|
+
label: "Delete",
|
679
|
+
onclick: () => n.onDelete()
|
680
|
+
}, null, 8, ["onclick"])) : _("", !0),
|
681
|
+
u(p, {
|
682
|
+
type: "submit",
|
683
|
+
class: "flex-1",
|
684
|
+
variant: "primary",
|
685
|
+
label: "Save"
|
686
|
+
})
|
687
|
+
])
|
688
|
+
]),
|
689
|
+
_: 1
|
690
|
+
}, 512);
|
691
|
+
};
|
692
|
+
}
|
693
|
+
}), Ue = { class: "flex mt-6 space-x-6" }, Te = /* @__PURE__ */ C({
|
694
|
+
__name: "AdyenGateway",
|
695
|
+
props: {
|
696
|
+
gateway: {
|
697
|
+
type: Object,
|
698
|
+
required: !0
|
699
|
+
},
|
700
|
+
onUpdate: {
|
701
|
+
type: Function,
|
702
|
+
required: !0
|
703
|
+
},
|
704
|
+
onDelete: {
|
705
|
+
type: Function,
|
706
|
+
required: !0
|
707
|
+
}
|
708
|
+
},
|
709
|
+
setup(n) {
|
710
|
+
var d;
|
711
|
+
const e = h(((d = n.gateway) == null ? void 0 : d.config) || {
|
712
|
+
merchantAccount: "",
|
713
|
+
username: "",
|
714
|
+
apiKey: "",
|
715
|
+
clientKey: ""
|
716
|
+
});
|
717
|
+
return (c, t) => {
|
718
|
+
const l = m("FmTextField"), p = m("FmButton"), s = m("FmForm");
|
719
|
+
return f(), w(s, {
|
720
|
+
ref: "form",
|
721
|
+
class: "flex flex-col gap-16",
|
722
|
+
onValidationSuccess: t[4] || (t[4] = () => n.onUpdate(e.value))
|
723
|
+
}, {
|
724
|
+
default: V(() => [
|
725
|
+
u(l, {
|
726
|
+
modelValue: e.value.merchantAccount,
|
727
|
+
"onUpdate:modelValue": t[0] || (t[0] = (a) => e.value.merchantAccount = a),
|
728
|
+
label: "Merchant Account",
|
729
|
+
rules: o(k)(o(A).string())
|
730
|
+
}, null, 8, ["modelValue", "rules"]),
|
731
|
+
u(l, {
|
732
|
+
modelValue: e.value.username,
|
733
|
+
"onUpdate:modelValue": t[1] || (t[1] = (a) => e.value.username = a),
|
734
|
+
label: "Username",
|
735
|
+
rules: o(k)(o(A).string())
|
736
|
+
}, null, 8, ["modelValue", "rules"]),
|
737
|
+
u(l, {
|
738
|
+
modelValue: e.value.apiKey,
|
739
|
+
"onUpdate:modelValue": t[2] || (t[2] = (a) => e.value.apiKey = a),
|
740
|
+
label: "API Key",
|
741
|
+
rules: o(k)(o(A).string())
|
742
|
+
}, null, 8, ["modelValue", "rules"]),
|
743
|
+
u(l, {
|
744
|
+
modelValue: e.value.clientKey,
|
745
|
+
"onUpdate:modelValue": t[3] || (t[3] = (a) => e.value.clientKey = a),
|
746
|
+
label: "Client Key",
|
747
|
+
rules: o(k)(o(A).string())
|
748
|
+
}, null, 8, ["modelValue", "rules"]),
|
749
|
+
i("div", Ue, [
|
750
|
+
n.gateway ? (f(), w(p, {
|
675
751
|
key: 0,
|
676
752
|
class: "flex-1",
|
677
753
|
variant: "secondary",
|
678
754
|
label: "Delete",
|
679
755
|
onclick: () => n.onDelete()
|
680
|
-
}, null, 8, ["onclick"])) :
|
681
|
-
u(
|
756
|
+
}, null, 8, ["onclick"])) : _("", !0),
|
757
|
+
u(p, {
|
682
758
|
type: "submit",
|
683
759
|
class: "flex-1",
|
684
760
|
variant: "primary",
|
@@ -690,13 +766,13 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
690
766
|
}, 512);
|
691
767
|
};
|
692
768
|
}
|
693
|
-
}),
|
769
|
+
}), Pe = {
|
694
770
|
key: 0,
|
695
771
|
className: "mt-1 my-6 text-gray-600"
|
696
|
-
},
|
772
|
+
}, Se = {
|
697
773
|
key: 1,
|
698
774
|
class: "flex items-center justify-center min-h-[80vh]"
|
699
|
-
},
|
775
|
+
}, Ie = /* @__PURE__ */ C({
|
700
776
|
__name: "PaymentGateway",
|
701
777
|
props: {
|
702
778
|
payoutAccount: {
|
@@ -705,32 +781,38 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
705
781
|
}
|
706
782
|
},
|
707
783
|
setup(n) {
|
708
|
-
const
|
784
|
+
const y = X().currentCountry, e = Y(), { isLoading: d, startAsyncCall: c } = E(), { gatewayTab: t } = j({
|
709
785
|
gatewayTab: ""
|
710
|
-
}),
|
786
|
+
}), l = n, p = [
|
711
787
|
{
|
712
788
|
label: "Fiuu",
|
713
789
|
value: "RAZER_MERCHANT_SERVICE",
|
714
790
|
render: ke,
|
715
|
-
region: [
|
791
|
+
region: [I.F_COUNTRY.enum.SG]
|
716
792
|
},
|
717
793
|
{
|
718
794
|
label: "Macau Pass",
|
719
795
|
value: "MACAU_PASS",
|
720
796
|
render: Ce,
|
721
|
-
region: [
|
797
|
+
region: [I.F_COUNTRY.enum.MO]
|
722
798
|
},
|
723
799
|
{
|
724
800
|
label: "Digio",
|
725
801
|
value: "DIGIO",
|
726
802
|
render: he,
|
727
|
-
region: [
|
803
|
+
region: [I.F_COUNTRY.enum.TH]
|
804
|
+
},
|
805
|
+
{
|
806
|
+
label: "Adyen",
|
807
|
+
value: "ADYEN",
|
808
|
+
render: Te,
|
809
|
+
region: [I.F_COUNTRY.enum.SG]
|
728
810
|
}
|
729
|
-
],
|
730
|
-
async function
|
731
|
-
await
|
811
|
+
], s = h(l.payoutAccount.gateways ?? []), a = G(() => p.find((v) => v.value === t.value)), r = G(() => p.filter((v) => v.region.includes(y.value ?? I.F_COUNTRY.enum.MY)));
|
812
|
+
async function g(v) {
|
813
|
+
await c(async () => {
|
732
814
|
try {
|
733
|
-
await
|
815
|
+
await D.updateGateway(l.payoutAccount._id, v), e.open({
|
734
816
|
type: "success",
|
735
817
|
title: "Payout account gateways update succesfully"
|
736
818
|
});
|
@@ -745,48 +827,48 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
745
827
|
}
|
746
828
|
return (v, b) => {
|
747
829
|
var M;
|
748
|
-
const
|
749
|
-
return
|
750
|
-
|
830
|
+
const P = m("FmCircularProgress"), N = m("FmTabs");
|
831
|
+
return f(), T($, null, [
|
832
|
+
o(y).value === o(I.F_COUNTRY).enum.MY ? (f(), T("p", Pe, b[1] || (b[1] = [
|
751
833
|
i("b", null, "Note: ", -1),
|
752
|
-
|
753
|
-
]))) :
|
754
|
-
|
755
|
-
u(
|
756
|
-
])) : (
|
834
|
+
U(" There's no setup required for Malaysia Payment Gateway, once Payout Account is ready you will able to configure the payment channels. ")
|
835
|
+
]))) : _("", !0),
|
836
|
+
o(d) ? (f(), T("div", Se, [
|
837
|
+
u(P, { size: "xxl" })
|
838
|
+
])) : (f(), w(N, {
|
757
839
|
key: 2,
|
758
|
-
"model-value":
|
759
|
-
"onUpdate:modelValue": b[0] || (b[0] = (F) =>
|
840
|
+
"model-value": o(t),
|
841
|
+
"onUpdate:modelValue": b[0] || (b[0] = (F) => K(t) ? t.value = F : null),
|
760
842
|
class: "mb-6",
|
761
|
-
items:
|
843
|
+
items: r.value
|
762
844
|
}, null, 8, ["model-value", "items"])),
|
763
|
-
|
764
|
-
gateway:
|
845
|
+
o(t) ? (f(), w(z((M = a.value) == null ? void 0 : M.render), L(H({ key: 3 }, {
|
846
|
+
gateway: s.value.find((F) => {
|
765
847
|
var x;
|
766
848
|
return F.paymentGateway === ((x = a.value) == null ? void 0 : x.value);
|
767
849
|
}),
|
768
850
|
onDelete: async () => {
|
769
|
-
|
851
|
+
s.value = s.value.filter((F) => {
|
770
852
|
var x;
|
771
853
|
return F.paymentGateway !== ((x = a.value) == null ? void 0 : x.value);
|
772
|
-
}),
|
854
|
+
}), g(s.value);
|
773
855
|
},
|
774
856
|
onUpdate: (F) => {
|
775
|
-
var
|
776
|
-
let x =
|
857
|
+
var q;
|
858
|
+
let x = s.value.find((O) => {
|
777
859
|
var Z;
|
778
|
-
return
|
860
|
+
return O.paymentGateway === ((Z = a.value) == null ? void 0 : Z.value);
|
779
861
|
});
|
780
|
-
x ? x.config = F :
|
781
|
-
paymentGateway: (
|
862
|
+
x ? x.config = F : s.value.push({
|
863
|
+
paymentGateway: (q = a.value) == null ? void 0 : q.value,
|
782
864
|
config: F
|
783
|
-
}),
|
865
|
+
}), g(s.value);
|
784
866
|
}
|
785
|
-
})), null, 16)) :
|
867
|
+
})), null, 16)) : _("", !0)
|
786
868
|
], 64);
|
787
869
|
};
|
788
870
|
}
|
789
|
-
}),
|
871
|
+
}), De = { class: "flex mt-6 space-x-6" }, Ne = /* @__PURE__ */ C({
|
790
872
|
__name: "GooglePayToken",
|
791
873
|
props: {
|
792
874
|
gateway: {
|
@@ -803,7 +885,7 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
803
885
|
}
|
804
886
|
},
|
805
887
|
setup(n) {
|
806
|
-
const e =
|
888
|
+
const e = h(n.gateway || {
|
807
889
|
// hardcoded first since only 1 PSP supported
|
808
890
|
type: "googlePay",
|
809
891
|
gateway: "RAZER_MERCHANT_SERVICE",
|
@@ -812,44 +894,44 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
812
894
|
gatewayMerchantId: "molpay"
|
813
895
|
}
|
814
896
|
});
|
815
|
-
return (
|
816
|
-
const t =
|
817
|
-
return
|
897
|
+
return (d, c) => {
|
898
|
+
const t = m("FmTextField"), l = m("FmButton"), p = m("FmForm");
|
899
|
+
return f(), w(p, {
|
818
900
|
ref: "form",
|
819
901
|
class: "flex flex-col gap-16",
|
820
|
-
onValidationSuccess:
|
902
|
+
onValidationSuccess: c[3] || (c[3] = () => n.onUpdate(e.value))
|
821
903
|
}, {
|
822
904
|
default: V(() => [
|
823
905
|
u(t, {
|
824
906
|
modelValue: e.value.gateway,
|
825
|
-
"onUpdate:modelValue":
|
907
|
+
"onUpdate:modelValue": c[0] || (c[0] = (s) => e.value.gateway = s),
|
826
908
|
label: "Gateway",
|
827
909
|
disabled: !0,
|
828
|
-
rules:
|
910
|
+
rules: o(k)(o(A).string())
|
829
911
|
}, null, 8, ["modelValue", "rules"]),
|
830
912
|
u(t, {
|
831
913
|
modelValue: e.value.config.gateway,
|
832
|
-
"onUpdate:modelValue":
|
914
|
+
"onUpdate:modelValue": c[1] || (c[1] = (s) => e.value.config.gateway = s),
|
833
915
|
label: "Gateway ID",
|
834
916
|
disabled: !0,
|
835
|
-
rules:
|
917
|
+
rules: o(k)(o(A).string())
|
836
918
|
}, null, 8, ["modelValue", "rules"]),
|
837
919
|
u(t, {
|
838
920
|
modelValue: e.value.config.gateway,
|
839
|
-
"onUpdate:modelValue":
|
921
|
+
"onUpdate:modelValue": c[2] || (c[2] = (s) => e.value.config.gateway = s),
|
840
922
|
label: "Gateway Merchant ID",
|
841
923
|
disabled: !0,
|
842
|
-
rules:
|
924
|
+
rules: o(k)(o(A).string())
|
843
925
|
}, null, 8, ["modelValue", "rules"]),
|
844
|
-
i("div",
|
845
|
-
n.gateway ? (
|
926
|
+
i("div", De, [
|
927
|
+
n.gateway ? (f(), w(l, {
|
846
928
|
key: 0,
|
847
929
|
class: "flex-1",
|
848
930
|
variant: "secondary",
|
849
931
|
label: "Delete",
|
850
932
|
onclick: () => n.onDelete()
|
851
|
-
}, null, 8, ["onclick"])) :
|
852
|
-
u(
|
933
|
+
}, null, 8, ["onclick"])) : _("", !0),
|
934
|
+
u(l, {
|
853
935
|
type: "submit",
|
854
936
|
class: "flex-1",
|
855
937
|
variant: "primary",
|
@@ -861,10 +943,10 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
861
943
|
}, 512);
|
862
944
|
};
|
863
945
|
}
|
864
|
-
}),
|
946
|
+
}), Me = {
|
865
947
|
key: 0,
|
866
948
|
class: "flex items-center justify-center min-h-[80vh]"
|
867
|
-
},
|
949
|
+
}, $e = /* @__PURE__ */ C({
|
868
950
|
__name: "TokenGateway",
|
869
951
|
props: {
|
870
952
|
payoutAccount: {
|
@@ -873,21 +955,21 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
873
955
|
}
|
874
956
|
},
|
875
957
|
setup(n) {
|
876
|
-
const
|
958
|
+
const y = X().currentCountry, e = Y(), { isLoading: d, startAsyncCall: c } = E(), { tokenTab: t } = j({
|
877
959
|
tokenTab: ""
|
878
|
-
}),
|
960
|
+
}), l = n, p = [
|
879
961
|
{
|
880
962
|
label: "Google Pay",
|
881
963
|
value: "googlePay",
|
882
964
|
icon: "android",
|
883
|
-
render:
|
884
|
-
region: [
|
965
|
+
render: Ne,
|
966
|
+
region: [I.F_COUNTRY.enum.MY, I.F_COUNTRY.enum.SG]
|
885
967
|
}
|
886
|
-
],
|
887
|
-
async function
|
888
|
-
await
|
968
|
+
], s = h(l.payoutAccount.tokens ?? []), a = G(() => p.find((v) => v.value === t.value)), r = G(() => p.filter((v) => v.region.includes(y.value ?? I.F_COUNTRY.enum.MY)));
|
969
|
+
async function g(v) {
|
970
|
+
await c(async () => {
|
889
971
|
try {
|
890
|
-
await
|
972
|
+
await D.updateTokens(l.payoutAccount._id, v), e.open({
|
891
973
|
type: "success",
|
892
974
|
title: "Payout account tokens gateway update succesfully"
|
893
975
|
});
|
@@ -902,44 +984,44 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
902
984
|
}
|
903
985
|
return (v, b) => {
|
904
986
|
var M;
|
905
|
-
const
|
906
|
-
return
|
987
|
+
const P = m("FmCircularProgress"), N = m("FmTabs");
|
988
|
+
return f(), T($, null, [
|
907
989
|
b[1] || (b[1] = i("p", { className: "mt-1 my-6 text-gray-600" }, [
|
908
990
|
i("b", null, "Note: "),
|
909
|
-
|
991
|
+
U(" Token gateway always on the top of every other methods ( online channels ), and it's was branding requirements from each of the payment token gateway provider. For setting most of the time are the same and only need to select for which provider. ")
|
910
992
|
], -1)),
|
911
|
-
|
912
|
-
u(
|
913
|
-
])) : (
|
993
|
+
o(d) ? (f(), T("div", Me, [
|
994
|
+
u(P, { size: "xxl" })
|
995
|
+
])) : (f(), w(N, {
|
914
996
|
key: 1,
|
915
|
-
"model-value":
|
916
|
-
"onUpdate:modelValue": b[0] || (b[0] = (F) =>
|
997
|
+
"model-value": o(t),
|
998
|
+
"onUpdate:modelValue": b[0] || (b[0] = (F) => K(t) ? t.value = F : null),
|
917
999
|
class: "mb-6",
|
918
|
-
items:
|
1000
|
+
items: r.value
|
919
1001
|
}, null, 8, ["model-value", "items"])),
|
920
|
-
|
921
|
-
gateway:
|
1002
|
+
o(t) ? (f(), w(z((M = a.value) == null ? void 0 : M.render), L(H({ key: 2 }, {
|
1003
|
+
gateway: s.value.find((F) => {
|
922
1004
|
var x;
|
923
1005
|
return F.type === ((x = a.value) == null ? void 0 : x.value);
|
924
1006
|
}),
|
925
1007
|
onDelete: async () => {
|
926
|
-
|
1008
|
+
s.value = s.value.filter((F) => {
|
927
1009
|
var x;
|
928
1010
|
return F.type !== ((x = a.value) == null ? void 0 : x.value);
|
929
|
-
}),
|
1011
|
+
}), g(s.value);
|
930
1012
|
},
|
931
1013
|
onUpdate: (F) => {
|
932
|
-
let x =
|
933
|
-
var
|
934
|
-
return
|
1014
|
+
let x = s.value.find((q) => {
|
1015
|
+
var O;
|
1016
|
+
return q.type === ((O = a.value) == null ? void 0 : O.value);
|
935
1017
|
});
|
936
|
-
x ? x.config = F :
|
1018
|
+
x ? x.config = F : s.value.push(F), g(s.value);
|
937
1019
|
}
|
938
|
-
})), null, 16)) :
|
1020
|
+
})), null, 16)) : _("", !0)
|
939
1021
|
], 64);
|
940
1022
|
};
|
941
1023
|
}
|
942
|
-
}),
|
1024
|
+
}), He = /* @__PURE__ */ C({
|
943
1025
|
__name: "PayoutAccountSetting",
|
944
1026
|
props: {
|
945
1027
|
accountId: {
|
@@ -948,16 +1030,16 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
948
1030
|
}
|
949
1031
|
},
|
950
1032
|
setup(n) {
|
951
|
-
const
|
1033
|
+
const y = n, { tab: e } = j({
|
952
1034
|
tab: "information"
|
953
|
-
}), { isLoading:
|
954
|
-
async function
|
955
|
-
await
|
956
|
-
|
957
|
-
|
958
|
-
),
|
1035
|
+
}), { isLoading: d, startAsyncCall: c } = E(!0), t = te(), l = h();
|
1036
|
+
async function p(g) {
|
1037
|
+
await D.updateById(
|
1038
|
+
y.accountId,
|
1039
|
+
g
|
1040
|
+
), l.value = await D.readById(y.accountId);
|
959
1041
|
}
|
960
|
-
const
|
1042
|
+
const s = [
|
961
1043
|
{
|
962
1044
|
label: "Information",
|
963
1045
|
value: "information",
|
@@ -980,13 +1062,13 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
980
1062
|
label: "Online Gateways",
|
981
1063
|
icon: "assured_workload",
|
982
1064
|
value: "gateways",
|
983
|
-
render:
|
1065
|
+
render: Ie
|
984
1066
|
},
|
985
1067
|
{
|
986
1068
|
label: "Token Gateways",
|
987
1069
|
value: "tokens",
|
988
1070
|
icon: "wallet",
|
989
|
-
render:
|
1071
|
+
render: $e
|
990
1072
|
},
|
991
1073
|
{
|
992
1074
|
label: "Online Channels",
|
@@ -996,34 +1078,34 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
996
1078
|
}
|
997
1079
|
];
|
998
1080
|
function a() {
|
999
|
-
|
1000
|
-
|
1081
|
+
c(async () => {
|
1082
|
+
l.value = await D.readById(y.accountId);
|
1001
1083
|
});
|
1002
1084
|
}
|
1003
1085
|
J(a);
|
1004
|
-
const
|
1005
|
-
const
|
1006
|
-
return
|
1086
|
+
const r = G(() => {
|
1087
|
+
const g = s.reduce((v, b) => v || (b.children ? b.children.find((P) => P.value === e.value) || null : b.value === e.value ? b : null), null);
|
1088
|
+
return g == null ? void 0 : g.render;
|
1007
1089
|
});
|
1008
|
-
return (
|
1009
|
-
var
|
1010
|
-
const b =
|
1011
|
-
return
|
1012
|
-
title: `Payout Account (${(
|
1013
|
-
loading:
|
1014
|
-
onBack:
|
1090
|
+
return (g, v) => {
|
1091
|
+
var P;
|
1092
|
+
const b = m("FmTabs");
|
1093
|
+
return f(), w(ee, {
|
1094
|
+
title: `Payout Account (${(P = l.value) == null ? void 0 : P._id})`,
|
1095
|
+
loading: o(d),
|
1096
|
+
onBack: o(t).back
|
1015
1097
|
}, {
|
1016
1098
|
default: V(() => [
|
1017
1099
|
u(b, {
|
1018
|
-
"model-value":
|
1019
|
-
"onUpdate:modelValue": v[0] || (v[0] = (
|
1100
|
+
"model-value": o(e),
|
1101
|
+
"onUpdate:modelValue": v[0] || (v[0] = (N) => K(e) ? e.value = N : null),
|
1020
1102
|
class: "mb-6",
|
1021
|
-
items:
|
1103
|
+
items: s
|
1022
1104
|
}, null, 8, ["model-value"]),
|
1023
|
-
|
1024
|
-
payoutAccount:
|
1025
|
-
onUpdate:
|
1026
|
-
})), null, 16)) :
|
1105
|
+
o(e) ? (f(), w(z(r.value), L(H({ key: 0 }, {
|
1106
|
+
payoutAccount: l.value,
|
1107
|
+
onUpdate: p
|
1108
|
+
})), null, 16)) : _("", !0)
|
1027
1109
|
]),
|
1028
1110
|
_: 1
|
1029
1111
|
}, 8, ["title", "loading", "onBack"]);
|
@@ -1031,5 +1113,5 @@ const ne = { class: "flex gap-16 mb-6" }, le = ["src"], oe = /* @__PURE__ */ k({
|
|
1031
1113
|
}
|
1032
1114
|
});
|
1033
1115
|
export {
|
1034
|
-
|
1116
|
+
He as default
|
1035
1117
|
};
|