@feedmepos/mf-payment 1.5.45-dev → 1.5.46-dev
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{Actions.vue_vue_type_script_setup_true_lang-CSmRCpz2.js → Actions.vue_vue_type_script_setup_true_lang-imtYa6pD.js} +1 -1
- package/dist/{Chargeback-jzp79SYF.js → Chargeback-BAwE_K4Y.js} +5 -5
- package/dist/{DocumentViewer.vue_vue_type_script_setup_true_lang-3pmwclcO.js → DocumentViewer.vue_vue_type_script_setup_true_lang-C5ZtdhGx.js} +1 -1
- package/dist/{OnboardForm-CaBaW-_y.js → OnboardForm-BnOjTX3d.js} +5 -5
- package/dist/{OnboardForm-DaBVXIWr.js → OnboardForm-DjJJDppP.js} +5 -5
- package/dist/{OnboardSubmission-BE5FWMKX.js → OnboardSubmission-WnyoWr5v.js} +2 -2
- package/dist/{OnboardSubmission-O5wr2kLB.js → OnboardSubmission-XoU4v3Ml.js} +5 -5
- package/dist/{PayoutAccount-CJwtnWBv.js → PayoutAccount-C1XsctKx.js} +5 -5
- package/dist/{PayoutAccount-DJeWNoXQ.js → PayoutAccount-DzGBidQR.js} +4 -4
- package/dist/{PayoutAccountSetting-BJljfdwp.js → PayoutAccountSetting-XryMDSqp.js} +4 -4
- package/dist/{Restaurant-DN2_DdKR.js → Restaurant-C7q0wptl.js} +4 -4
- package/dist/{RestaurantSetting-f0T5REdJ.js → RestaurantSetting-C22ggesm.js} +3 -3
- package/dist/{Settlement-BN4xG-Lw.js → Settlement-B-33HHZr.js} +4 -4
- package/dist/{Settlement-Bp5hjyx1.js → Settlement-CRLtmX9T.js} +3 -3
- package/dist/{SettlementTransactions-DEoxfkFL.js → SettlementTransactions-BwwtI2Mb.js} +4 -4
- package/dist/{SettlementTransactions-DN9uCpiR.js → SettlementTransactions-C_Ibz9wJ.js} +4 -4
- package/dist/{Status.vue_vue_type_script_setup_true_lang-B41rO8q8.js → Status.vue_vue_type_script_setup_true_lang--xGDd1jJ.js} +1 -1
- package/dist/{Terminal-DuGHgfMp.js → Terminal-DEC4qMAg.js} +5 -5
- package/dist/{TerminalSetting-iXqUzSSo.js → TerminalSetting-Bg4cFHZv.js} +483 -362
- package/dist/{Transaction-CGp1ln-T.js → Transaction-BK4gt-VH.js} +9 -9
- package/dist/{Transaction-_bXdgbKw.js → Transaction-CJMmMCsK.js} +5 -5
- package/dist/{TransactionOld-BGnHifKa.js → TransactionOld-DtwXOqhV.js} +6 -6
- package/dist/{app-BQOOst0s.js → app-BE4dnWPA.js} +23 -23
- package/dist/app.js +1 -1
- package/dist/{assets-t2kJFjI9.js → assets-DzfkXhFM.js} +1 -1
- package/dist/{grafana-VY3mqepx.js → grafana-Cjaoae5w.js} +1 -1
- package/dist/{index-jfRfVr4R.js → index-CTNYHRdm.js} +1 -1
- package/dist/{index-Q0ELb0wB.js → index-Cfss7GMG.js} +1 -1
- package/dist/{index-DGqWjywh.js → index-CkPyzQ9d.js} +1 -1
- package/dist/{index-BGIv1us6.js → index-CuB75_Ym.js} +1 -1
- package/dist/{index-DhYZ6Ghe.js → index-CuHYOVxr.js} +2 -2
- package/dist/{index-T2CVm7-_.js → index-CxJSwrU1.js} +11403 -11245
- package/dist/{index-CscYwjzM.js → index-CzCUp2Ef.js} +1 -1
- package/dist/{index-Dq4IAN2N.js → index-D4o-xkBR.js} +1 -1
- package/dist/{index-_EfmUlsc.js → index-Df8oNJMI.js} +1 -1
- package/dist/{index.vue_vue_type_script_setup_true_lang-CkzD8rQP.js → index.vue_vue_type_script_setup_true_lang-anWWl6xH.js} +1 -1
- package/dist/package.json +2 -2
- package/dist/{payout-account-CblbBPVr.js → payout-account-D03bFzty.js} +3 -3
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/dist/views/admin/terminal/TerminalDialog.vue.d.ts +18 -18
- package/dist/views/admin/terminal/tabs/EcrGateway.vue.d.ts +18 -18
- package/dist/views/admin/terminal/tabs/Information.vue.d.ts +18 -18
- package/dist/views/admin/terminal/tabs/QrGateway.vue.d.ts +18 -18
- package/dist/views/admin/terminal/tabs/SettingRequest.vue.d.ts +18 -18
- package/dist/views/admin/terminal/tabs/SoftposGateway.vue.d.ts +18 -18
- package/dist/views/admin/terminal/tabs/ecr/Ghl2Gateway.vue.d.ts +18 -18
- package/dist/views/admin/terminal/tabs/ecr/Ghl3Gateway.vue.d.ts +18 -18
- package/dist/views/admin/terminal/tabs/ecr/GhlGateway.vue.d.ts +18 -18
- package/dist/views/admin/terminal/tabs/ecr/GlobalPaymentsGateway.vue.d.ts +18 -18
- package/dist/views/admin/terminal/tabs/ecr/HlbbGateway.vue.d.ts +18 -18
- package/dist/views/admin/terminal/tabs/ecr/KBankGateway.vue.d.ts +18 -18
- package/dist/views/admin/terminal/tabs/ecr/Maybank2Gateway.vue.d.ts +18 -18
- package/dist/views/admin/terminal/tabs/ecr/Maybank3Gateway.vue.d.ts +18 -18
- package/dist/views/admin/terminal/tabs/ecr/MaybankGateway.vue.d.ts +18 -18
- package/dist/views/admin/terminal/tabs/ecr/NetsGateway.vue.d.ts +18 -18
- package/dist/views/admin/terminal/tabs/ecr/OmaGateway.vue.d.ts +140 -0
- package/dist/views/admin/terminal/tabs/ecr/TerminalGateway.vue.d.ts +18 -18
- package/dist/views/admin/terminal/tabs/qr/PromptPayGateway.vue.d.ts +18 -18
- package/dist/views/admin/terminal/tabs/settings/KioskMode.vue.d.ts +18 -18
- package/package.json +2 -2
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { u as H, e as
|
|
1
|
+
import { defineComponent as C, openBlock as y, createElementBlock as V, Fragment as G, createElementVNode as _, createTextVNode as $, toDisplayString as D, ref as b, resolveComponent as f, createVNode as v, createCommentVNode as N, unref as h, computed as P, isRef as B, createBlock as I, resolveDynamicComponent as Y, normalizeProps as L, mergeProps as K, toRef as O, watch as q, onMounted as S, withCtx as M, renderList as R } from "vue";
|
|
2
|
+
import { u as H, e as k } from "./index-CxJSwrU1.js";
|
|
3
3
|
import { useRouter as W } from "vue-router";
|
|
4
|
-
import { t as A } from "./index-
|
|
4
|
+
import { t as A } from "./index-CkPyzQ9d.js";
|
|
5
5
|
import { _ as X } from "./Layout.vue_vue_type_script_setup_true_lang-BKIvkgA_.js";
|
|
6
|
-
import { u as E } from "./index-
|
|
6
|
+
import { u as E } from "./index-Cfss7GMG.js";
|
|
7
7
|
import { useSnackbar as Q } from "@feedmepos/ui-library";
|
|
8
8
|
import { u as Z } from "./error-K1CakhA9.js";
|
|
9
9
|
import { useCoreStore as j } from "@feedmepos/mf-common";
|
|
10
10
|
import { z as ee, a as ae } from "./validator-DzjyJnvv.js";
|
|
11
|
-
const le = /* @__PURE__ */
|
|
11
|
+
const le = /* @__PURE__ */ C({
|
|
12
12
|
__name: "Information",
|
|
13
13
|
props: {
|
|
14
14
|
terminal: {
|
|
@@ -17,22 +17,22 @@ const le = /* @__PURE__ */ k({
|
|
|
17
17
|
}
|
|
18
18
|
},
|
|
19
19
|
setup(F) {
|
|
20
|
-
return (
|
|
21
|
-
a[0] || (a[0] =
|
|
20
|
+
return (c, a) => (y(), V(G, null, [
|
|
21
|
+
a[0] || (a[0] = _("b", null, "Name", -1)),
|
|
22
22
|
$(": " + D(F.terminal.name), 1),
|
|
23
|
-
a[1] || (a[1] =
|
|
24
|
-
a[2] || (a[2] =
|
|
23
|
+
a[1] || (a[1] = _("br", null, null, -1)),
|
|
24
|
+
a[2] || (a[2] = _("b", null, "Status", -1)),
|
|
25
25
|
$(": " + D(F.terminal.status), 1),
|
|
26
|
-
a[3] || (a[3] =
|
|
27
|
-
a[4] || (a[4] =
|
|
26
|
+
a[3] || (a[3] = _("br", null, null, -1)),
|
|
27
|
+
a[4] || (a[4] = _("b", null, "Device ID", -1)),
|
|
28
28
|
$(": " + D(F.terminal.deviceId ?? "-"), 1),
|
|
29
|
-
a[5] || (a[5] =
|
|
30
|
-
a[6] || (a[6] =
|
|
29
|
+
a[5] || (a[5] = _("br", null, null, -1)),
|
|
30
|
+
a[6] || (a[6] = _("b", null, "Device Type", -1)),
|
|
31
31
|
$(": " + D(F.terminal.deviceType ?? "-"), 1),
|
|
32
|
-
a[7] || (a[7] =
|
|
32
|
+
a[7] || (a[7] = _("br", null, null, -1))
|
|
33
33
|
], 64));
|
|
34
34
|
}
|
|
35
|
-
}), te = { key: 0 }, ne = { class: "mt-6 space-x-6" }, oe = /* @__PURE__ */
|
|
35
|
+
}), te = { key: 0 }, ne = { class: "mt-6 space-x-6" }, oe = /* @__PURE__ */ C({
|
|
36
36
|
__name: "KioskMode",
|
|
37
37
|
props: {
|
|
38
38
|
terminal: {
|
|
@@ -41,57 +41,57 @@ const le = /* @__PURE__ */ k({
|
|
|
41
41
|
}
|
|
42
42
|
},
|
|
43
43
|
setup(F) {
|
|
44
|
-
const { isLoading:
|
|
44
|
+
const { isLoading: c, startAsyncCall: a } = H(!1), T = Q(), n = b({
|
|
45
45
|
enable: !1,
|
|
46
46
|
password: []
|
|
47
47
|
}), r = F;
|
|
48
48
|
function e() {
|
|
49
|
-
return n.value.enable && n.value.password.filter((
|
|
49
|
+
return n.value.enable && n.value.password.filter((m) => !!m).length !== 6 ? T.open({
|
|
50
50
|
type: "error",
|
|
51
51
|
message: "Unlock PIN is required when setting up kiosk mode for terminal."
|
|
52
52
|
}) : a(async () => {
|
|
53
|
-
const
|
|
54
|
-
|
|
53
|
+
const m = { enable: n.value.enable };
|
|
54
|
+
m.enable && Object.assign(m, {
|
|
55
55
|
password: n.value.password.join("")
|
|
56
56
|
});
|
|
57
|
-
const
|
|
58
|
-
if (
|
|
59
|
-
return
|
|
60
|
-
let g =
|
|
61
|
-
return
|
|
57
|
+
const d = await A.kioskModeRequest(r.terminal._id, m);
|
|
58
|
+
if (d === "OK")
|
|
59
|
+
return T.open({ type: "info", message: "Kiosk mode applied successfully." });
|
|
60
|
+
let g = d;
|
|
61
|
+
return d === "client_not_connected" && (g = "Terminal not connected to the websocket server."), d.startsWith("terminal: ") && (g = d.replaceAll("terminal: ", "")), T.open({
|
|
62
62
|
type: "error",
|
|
63
63
|
message: g
|
|
64
64
|
});
|
|
65
65
|
});
|
|
66
66
|
}
|
|
67
|
-
return (
|
|
67
|
+
return (m, d) => {
|
|
68
68
|
const g = f("FmSwitch"), s = f("FmPinField"), u = f("FmButton");
|
|
69
|
-
return y(), V(
|
|
69
|
+
return y(), V(G, null, [
|
|
70
70
|
v(g, {
|
|
71
71
|
modelValue: n.value.enable,
|
|
72
|
-
"onUpdate:modelValue":
|
|
72
|
+
"onUpdate:modelValue": d[0] || (d[0] = (l) => n.value.enable = l),
|
|
73
73
|
label: "Enable Kiosk Mode?"
|
|
74
74
|
}, null, 8, ["modelValue"]),
|
|
75
75
|
n.value.enable ? (y(), V("div", te, [
|
|
76
|
-
|
|
76
|
+
d[2] || (d[2] = _("p", { class: "mt-6" }, "Unlock PIN: ", -1)),
|
|
77
77
|
v(s, {
|
|
78
78
|
modelValue: n.value.password,
|
|
79
|
-
"onUpdate:modelValue":
|
|
79
|
+
"onUpdate:modelValue": d[1] || (d[1] = (l) => n.value.password = l)
|
|
80
80
|
}, null, 8, ["modelValue"])
|
|
81
81
|
])) : N("", !0),
|
|
82
|
-
|
|
82
|
+
_("div", ne, [
|
|
83
83
|
v(u, {
|
|
84
84
|
variant: "primary",
|
|
85
85
|
label: "Send",
|
|
86
86
|
icon: "send",
|
|
87
|
-
loading:
|
|
87
|
+
loading: h(c),
|
|
88
88
|
onclick: e
|
|
89
89
|
}, null, 8, ["loading"])
|
|
90
90
|
])
|
|
91
91
|
], 64);
|
|
92
92
|
};
|
|
93
93
|
}
|
|
94
|
-
}), re = /* @__PURE__ */
|
|
94
|
+
}), re = /* @__PURE__ */ C({
|
|
95
95
|
__name: "SettingRequest",
|
|
96
96
|
props: {
|
|
97
97
|
terminal: {
|
|
@@ -100,7 +100,7 @@ const le = /* @__PURE__ */ k({
|
|
|
100
100
|
}
|
|
101
101
|
},
|
|
102
102
|
setup(F) {
|
|
103
|
-
const { settingTab:
|
|
103
|
+
const { settingTab: c } = E({
|
|
104
104
|
settingTab: "kiosk_mode"
|
|
105
105
|
}), a = [
|
|
106
106
|
{
|
|
@@ -108,29 +108,29 @@ const le = /* @__PURE__ */ k({
|
|
|
108
108
|
value: "kiosk_mode",
|
|
109
109
|
render: oe
|
|
110
110
|
}
|
|
111
|
-
],
|
|
111
|
+
], T = F, n = P(() => a.find((r) => r.value === c.value));
|
|
112
112
|
return (r, e) => {
|
|
113
|
-
var
|
|
114
|
-
const
|
|
115
|
-
return y(), V(
|
|
116
|
-
e[1] || (e[1] =
|
|
117
|
-
|
|
113
|
+
var d;
|
|
114
|
+
const m = f("FmTabs");
|
|
115
|
+
return y(), V(G, null, [
|
|
116
|
+
e[1] || (e[1] = _("p", { className: "mt-1 my-6 text-gray-600" }, [
|
|
117
|
+
_("b", null, "Note: "),
|
|
118
118
|
$(" Setting request will perform remotely without caching so make sure terminal is connected to the network also to our websocket as well. ")
|
|
119
119
|
], -1)),
|
|
120
|
-
v(
|
|
121
|
-
"model-value":
|
|
122
|
-
"onUpdate:modelValue": e[0] || (e[0] = (g) => B(
|
|
120
|
+
v(m, {
|
|
121
|
+
"model-value": h(c),
|
|
122
|
+
"onUpdate:modelValue": e[0] || (e[0] = (g) => B(c) ? c.value = g : null),
|
|
123
123
|
class: "mb-6",
|
|
124
124
|
items: a
|
|
125
125
|
}, null, 8, ["model-value"]),
|
|
126
|
-
|
|
126
|
+
h(c) ? (y(), I(Y((d = n.value) == null ? void 0 : d.render), L(K({ key: 0 }, { terminal: T.terminal })), null, 16)) : N("", !0)
|
|
127
127
|
], 64);
|
|
128
128
|
};
|
|
129
129
|
}
|
|
130
130
|
}), ie = {
|
|
131
131
|
key: 0,
|
|
132
132
|
class: "text-sm text-gray-500"
|
|
133
|
-
}, ue = { class: "flex mt-6 space-x-6" }, se = /* @__PURE__ */
|
|
133
|
+
}, ue = { class: "flex mt-6 space-x-6" }, se = /* @__PURE__ */ C({
|
|
134
134
|
__name: "SoftposGateway",
|
|
135
135
|
props: {
|
|
136
136
|
terminal: {
|
|
@@ -143,11 +143,11 @@ const le = /* @__PURE__ */ k({
|
|
|
143
143
|
}
|
|
144
144
|
},
|
|
145
145
|
setup(F) {
|
|
146
|
-
const
|
|
146
|
+
const c = F, a = j().currentCountry, T = [
|
|
147
147
|
{
|
|
148
148
|
label: "Fiuu Malaysia",
|
|
149
149
|
value: "cc.feedme.payment.rms",
|
|
150
|
-
region:
|
|
150
|
+
region: k.F_COUNTRY.enum.MY,
|
|
151
151
|
gateway: "Fiuu",
|
|
152
152
|
isLegacy: !0,
|
|
153
153
|
isOutdated: !0
|
|
@@ -155,14 +155,14 @@ const le = /* @__PURE__ */ k({
|
|
|
155
155
|
{
|
|
156
156
|
label: "Fiuu Malaysia V2",
|
|
157
157
|
value: "cc.feedme.payment.fiuu_my",
|
|
158
|
-
region:
|
|
158
|
+
region: k.F_COUNTRY.enum.MY,
|
|
159
159
|
gateway: "Fiuu",
|
|
160
160
|
isLegacy: !0
|
|
161
161
|
},
|
|
162
162
|
{
|
|
163
163
|
label: "Fiuu Singapore",
|
|
164
164
|
value: "cc.feedme.payment.fiuu_sg",
|
|
165
|
-
region:
|
|
165
|
+
region: k.F_COUNTRY.enum.SG,
|
|
166
166
|
gateway: "Fiuu",
|
|
167
167
|
isLegacy: !0
|
|
168
168
|
},
|
|
@@ -170,27 +170,27 @@ const le = /* @__PURE__ */ k({
|
|
|
170
170
|
label: "Softspace Malaysia",
|
|
171
171
|
value: "cc.feedme.payment.softspace_my",
|
|
172
172
|
gateway: "Softspace",
|
|
173
|
-
region:
|
|
173
|
+
region: k.F_COUNTRY.enum.MY
|
|
174
174
|
},
|
|
175
175
|
{
|
|
176
176
|
label: "Digio Thailand",
|
|
177
177
|
value: "cc.feedme.payment.digio_th",
|
|
178
178
|
gateway: "Digio",
|
|
179
|
-
region:
|
|
179
|
+
region: k.F_COUNTRY.enum.TH
|
|
180
180
|
}
|
|
181
|
-
], n =
|
|
181
|
+
], n = O(() => c.terminal), r = b(), e = b({
|
|
182
182
|
packageId: "",
|
|
183
183
|
uniqueId: "",
|
|
184
184
|
developerId: "",
|
|
185
185
|
isUat: !1
|
|
186
|
-
}),
|
|
186
|
+
}), m = () => {
|
|
187
187
|
e.value.uniqueId = "", e.value.packageId = "", e.value.developerId = "";
|
|
188
|
-
},
|
|
188
|
+
}, d = () => {
|
|
189
189
|
if (!n.value.gateways || n.value.gateways.length === 0)
|
|
190
|
-
return
|
|
190
|
+
return m();
|
|
191
191
|
const l = n.value.gateways[0];
|
|
192
192
|
if (!l.config)
|
|
193
|
-
return
|
|
193
|
+
return m();
|
|
194
194
|
switch (l.gateway) {
|
|
195
195
|
case "Fiuu":
|
|
196
196
|
e.value = {
|
|
@@ -212,15 +212,15 @@ const le = /* @__PURE__ */ k({
|
|
|
212
212
|
return;
|
|
213
213
|
}
|
|
214
214
|
};
|
|
215
|
-
|
|
215
|
+
q(n, d), S(d);
|
|
216
216
|
async function g(l) {
|
|
217
217
|
var t;
|
|
218
|
-
(t = n.value.gateways) == null || t.splice(l, 1),
|
|
218
|
+
(t = n.value.gateways) == null || t.splice(l, 1), c.onUpdate(n.value);
|
|
219
219
|
}
|
|
220
|
-
const s =
|
|
220
|
+
const s = P(() => T.filter((l) => l.region === a.value)), u = P(() => s.value.find((l) => l.value === e.value.packageId));
|
|
221
221
|
return (l, t) => {
|
|
222
|
-
const i = f("FmSelect"),
|
|
223
|
-
return y(),
|
|
222
|
+
const i = f("FmSelect"), p = f("FmTextField"), x = f("FmCheckbox"), o = f("FmButton"), w = f("FmForm");
|
|
223
|
+
return y(), I(w, {
|
|
224
224
|
ref: r.value,
|
|
225
225
|
class: "flex flex-col gap-16 w-[500px]",
|
|
226
226
|
onValidationSuccess: t[5] || (t[5] = () => {
|
|
@@ -236,30 +236,30 @@ const le = /* @__PURE__ */ k({
|
|
|
236
236
|
uniqueId: z
|
|
237
237
|
}
|
|
238
238
|
};
|
|
239
|
-
(!n.value.gateways || n.value.gateways.length > 1) && (n.value.gateways = []), n.value.gateways[0] = J,
|
|
239
|
+
(!n.value.gateways || n.value.gateways.length > 1) && (n.value.gateways = []), n.value.gateways[0] = J, c.onUpdate(n.value);
|
|
240
240
|
})
|
|
241
241
|
}, {
|
|
242
|
-
default:
|
|
242
|
+
default: M(() => [
|
|
243
243
|
v(i, {
|
|
244
244
|
modelValue: e.value.packageId,
|
|
245
245
|
"onUpdate:modelValue": t[0] || (t[0] = (U) => e.value.packageId = U),
|
|
246
246
|
label: "Package ID",
|
|
247
247
|
items: s.value
|
|
248
248
|
}, null, 8, ["modelValue", "items"]),
|
|
249
|
-
u.value && u.value.isLegacy ? (y(), V(
|
|
250
|
-
v(
|
|
249
|
+
u.value && u.value.isLegacy ? (y(), V(G, { key: 0 }, [
|
|
250
|
+
v(p, {
|
|
251
251
|
modelValue: e.value.uniqueId,
|
|
252
252
|
"onUpdate:modelValue": t[1] || (t[1] = (U) => e.value.uniqueId = U),
|
|
253
253
|
label: "Unique ID (TID)"
|
|
254
254
|
}, null, 8, ["modelValue"]),
|
|
255
255
|
u.value.isOutdated ? (y(), V("span", ie, " Note: For outdated gateway is no longer continued development, please use the new gateway instead. ")) : N("", !0)
|
|
256
|
-
], 64)) : (y(), V(
|
|
257
|
-
v(
|
|
256
|
+
], 64)) : (y(), V(G, { key: 1 }, [
|
|
257
|
+
v(p, {
|
|
258
258
|
modelValue: e.value.developerId,
|
|
259
259
|
"onUpdate:modelValue": t[2] || (t[2] = (U) => e.value.developerId = U),
|
|
260
260
|
label: "Developer ID (MID)"
|
|
261
261
|
}, null, 8, ["modelValue"]),
|
|
262
|
-
v(
|
|
262
|
+
v(p, {
|
|
263
263
|
modelValue: e.value.uniqueId,
|
|
264
264
|
"onUpdate:modelValue": t[3] || (t[3] = (U) => e.value.uniqueId = U),
|
|
265
265
|
label: "Unique ID (TID)"
|
|
@@ -271,8 +271,8 @@ const le = /* @__PURE__ */ k({
|
|
|
271
271
|
value: "1"
|
|
272
272
|
}, null, 8, ["modelValue"])
|
|
273
273
|
], 64)),
|
|
274
|
-
|
|
275
|
-
n.value.gateways && n.value.gateways.length > 0 ? (y(),
|
|
274
|
+
_("div", ue, [
|
|
275
|
+
n.value.gateways && n.value.gateways.length > 0 ? (y(), I(o, {
|
|
276
276
|
key: 0,
|
|
277
277
|
class: "flex-1",
|
|
278
278
|
variant: "secondary",
|
|
@@ -294,7 +294,7 @@ const le = /* @__PURE__ */ k({
|
|
|
294
294
|
}), ce = {
|
|
295
295
|
key: 0,
|
|
296
296
|
class: "flex items-center justify-center min-h-[80vh]"
|
|
297
|
-
}, de = { class: "flex mt-6 space-x-6" }, pe = /* @__PURE__ */
|
|
297
|
+
}, de = { class: "flex mt-6 space-x-6" }, pe = /* @__PURE__ */ C({
|
|
298
298
|
__name: "TerminalGateway",
|
|
299
299
|
props: {
|
|
300
300
|
terminal: {
|
|
@@ -307,60 +307,60 @@ const le = /* @__PURE__ */ k({
|
|
|
307
307
|
}
|
|
308
308
|
},
|
|
309
309
|
setup(F) {
|
|
310
|
-
const { isLoading:
|
|
310
|
+
const { isLoading: c, startAsyncCall: a } = H(), T = F, n = O(() => T.terminal), r = b(), e = b(), m = b(-1), d = b({
|
|
311
311
|
terminalId: ""
|
|
312
312
|
}), g = () => {
|
|
313
|
-
|
|
313
|
+
d.value.terminalId = "", m.value = -1;
|
|
314
314
|
}, s = () => {
|
|
315
315
|
if (a(async () => {
|
|
316
|
-
r.value = await A.getRestaurantTerminals(
|
|
317
|
-
}), !
|
|
316
|
+
r.value = await A.getRestaurantTerminals(T.terminal.referenceId);
|
|
317
|
+
}), !T.terminal.ecrs)
|
|
318
318
|
return g();
|
|
319
|
-
const t =
|
|
319
|
+
const t = T.terminal.ecrs.findIndex((p) => p && p.gateway && p.gateway === "FeedMe");
|
|
320
320
|
if (t === -1)
|
|
321
321
|
return g();
|
|
322
|
-
|
|
323
|
-
const i =
|
|
324
|
-
i.gateway === "FeedMe" && i.config && (
|
|
322
|
+
m.value = t;
|
|
323
|
+
const i = T.terminal.ecrs.at(t);
|
|
324
|
+
i.gateway === "FeedMe" && i.config && (d.value = {
|
|
325
325
|
terminalId: i.config.terminalId
|
|
326
326
|
});
|
|
327
327
|
};
|
|
328
|
-
|
|
329
|
-
const u =
|
|
328
|
+
q(n, s), S(s);
|
|
329
|
+
const u = P(() => (r.value ?? []).map((t) => ({
|
|
330
330
|
label: t.name ?? t._id,
|
|
331
331
|
value: t._id
|
|
332
332
|
})));
|
|
333
333
|
async function l(t) {
|
|
334
334
|
var i;
|
|
335
|
-
(i =
|
|
335
|
+
(i = T.terminal.ecrs) == null || i.splice(t, 1), T.onUpdate(T.terminal);
|
|
336
336
|
}
|
|
337
337
|
return (t, i) => {
|
|
338
|
-
const
|
|
339
|
-
return
|
|
340
|
-
v(
|
|
341
|
-
])) : (y(),
|
|
338
|
+
const p = f("FmCircularProgress"), x = f("FmSelect"), o = f("FmButton"), w = f("FmForm");
|
|
339
|
+
return h(c) ? (y(), V("div", ce, [
|
|
340
|
+
v(p, { size: "xxl" })
|
|
341
|
+
])) : (y(), I(w, {
|
|
342
342
|
key: 1,
|
|
343
343
|
ref: e.value,
|
|
344
344
|
class: "flex flex-col gap-16 w-[500px]",
|
|
345
345
|
onValidationSuccess: i[1] || (i[1] = () => {
|
|
346
|
-
|
|
346
|
+
m.value > -1 ? n.value.ecrs[m.value] = { gateway: "FeedMe", config: d.value } : (n.value.ecrs || (n.value.ecrs = []), n.value.ecrs.push({ gateway: "FeedMe", config: d.value })), T.onUpdate(n.value);
|
|
347
347
|
})
|
|
348
348
|
}, {
|
|
349
|
-
default:
|
|
349
|
+
default: M(() => [
|
|
350
350
|
v(x, {
|
|
351
|
-
modelValue:
|
|
352
|
-
"onUpdate:modelValue": i[0] || (i[0] = (U) =>
|
|
351
|
+
modelValue: d.value.terminalId,
|
|
352
|
+
"onUpdate:modelValue": i[0] || (i[0] = (U) => d.value.terminalId = U),
|
|
353
353
|
label: "Terminal ID",
|
|
354
354
|
items: u.value,
|
|
355
|
-
rules:
|
|
355
|
+
rules: h(ee)(h(ae).string())
|
|
356
356
|
}, null, 8, ["modelValue", "items", "rules"]),
|
|
357
|
-
|
|
358
|
-
|
|
357
|
+
_("div", de, [
|
|
358
|
+
m.value > -1 ? (y(), I(o, {
|
|
359
359
|
key: 0,
|
|
360
360
|
class: "flex-1",
|
|
361
361
|
variant: "secondary",
|
|
362
362
|
label: "Delete",
|
|
363
|
-
onclick: () => l(
|
|
363
|
+
onclick: () => l(m.value)
|
|
364
364
|
}, null, 8, ["onclick"])) : N("", !0),
|
|
365
365
|
v(o, {
|
|
366
366
|
type: "submit",
|
|
@@ -374,7 +374,7 @@ const le = /* @__PURE__ */ k({
|
|
|
374
374
|
}, 512));
|
|
375
375
|
};
|
|
376
376
|
}
|
|
377
|
-
}), me = { class: "flex mt-6 space-x-6" }, ve = /* @__PURE__ */
|
|
377
|
+
}), me = { class: "flex mt-6 space-x-6" }, ve = /* @__PURE__ */ C({
|
|
378
378
|
__name: "GhlGateway",
|
|
379
379
|
props: {
|
|
380
380
|
terminal: {
|
|
@@ -387,13 +387,13 @@ const le = /* @__PURE__ */ k({
|
|
|
387
387
|
}
|
|
388
388
|
},
|
|
389
389
|
setup(F) {
|
|
390
|
-
const
|
|
390
|
+
const c = F, a = O(() => c.terminal), T = b(), n = b(-1), r = b({
|
|
391
391
|
merchantId: "",
|
|
392
392
|
terminalId: "",
|
|
393
393
|
privateKey: ""
|
|
394
394
|
}), e = () => {
|
|
395
395
|
r.value.merchantId = "", r.value.terminalId = "", r.value.privateKey = "", n.value = -1;
|
|
396
|
-
},
|
|
396
|
+
}, m = () => {
|
|
397
397
|
if (!a.value.ecrs)
|
|
398
398
|
return e();
|
|
399
399
|
const g = a.value.ecrs.findIndex((u) => u && u.gateway && u.gateway === "Ghl");
|
|
@@ -407,45 +407,45 @@ const le = /* @__PURE__ */ k({
|
|
|
407
407
|
privateKey: s.config.privateKey || ""
|
|
408
408
|
});
|
|
409
409
|
};
|
|
410
|
-
|
|
411
|
-
async function
|
|
410
|
+
q(a, m), S(m);
|
|
411
|
+
async function d(g) {
|
|
412
412
|
var s;
|
|
413
|
-
(s = a.value.ecrs) == null || s.splice(g, 1),
|
|
413
|
+
(s = a.value.ecrs) == null || s.splice(g, 1), c.onUpdate(a.value);
|
|
414
414
|
}
|
|
415
415
|
return (g, s) => {
|
|
416
416
|
const u = f("FmTextField"), l = f("FmTextarea"), t = f("FmButton"), i = f("FmForm");
|
|
417
|
-
return y(),
|
|
418
|
-
ref:
|
|
417
|
+
return y(), I(i, {
|
|
418
|
+
ref: T.value,
|
|
419
419
|
class: "flex flex-col gap-16 w-[500px]",
|
|
420
420
|
onValidationSuccess: s[3] || (s[3] = () => {
|
|
421
|
-
n.value > -1 ? a.value.ecrs[n.value] = { gateway: "Ghl", config: r.value } : (a.value.ecrs || (a.value.ecrs = []), a.value.ecrs.push({ gateway: "Ghl", config: r.value })),
|
|
421
|
+
n.value > -1 ? a.value.ecrs[n.value] = { gateway: "Ghl", config: r.value } : (a.value.ecrs || (a.value.ecrs = []), a.value.ecrs.push({ gateway: "Ghl", config: r.value })), c.onUpdate(a.value);
|
|
422
422
|
})
|
|
423
423
|
}, {
|
|
424
|
-
default:
|
|
424
|
+
default: M(() => [
|
|
425
425
|
v(u, {
|
|
426
426
|
modelValue: r.value.merchantId,
|
|
427
|
-
"onUpdate:modelValue": s[0] || (s[0] = (
|
|
427
|
+
"onUpdate:modelValue": s[0] || (s[0] = (p) => r.value.merchantId = p),
|
|
428
428
|
label: "Merchant ID"
|
|
429
429
|
}, null, 8, ["modelValue"]),
|
|
430
430
|
v(u, {
|
|
431
431
|
modelValue: r.value.terminalId,
|
|
432
|
-
"onUpdate:modelValue": s[1] || (s[1] = (
|
|
432
|
+
"onUpdate:modelValue": s[1] || (s[1] = (p) => r.value.terminalId = p),
|
|
433
433
|
label: "Terminal ID"
|
|
434
434
|
}, null, 8, ["modelValue"]),
|
|
435
435
|
v(l, {
|
|
436
436
|
modelValue: r.value.privateKey,
|
|
437
|
-
"onUpdate:modelValue": s[2] || (s[2] = (
|
|
437
|
+
"onUpdate:modelValue": s[2] || (s[2] = (p) => r.value.privateKey = p),
|
|
438
438
|
label: "Private Key",
|
|
439
439
|
"label-mark": "optional",
|
|
440
440
|
"label-info": "Default will use FeedMe Private Key"
|
|
441
441
|
}, null, 8, ["modelValue"]),
|
|
442
|
-
|
|
443
|
-
n.value > -1 ? (y(),
|
|
442
|
+
_("div", me, [
|
|
443
|
+
n.value > -1 ? (y(), I(t, {
|
|
444
444
|
key: 0,
|
|
445
445
|
class: "flex-1",
|
|
446
446
|
variant: "secondary",
|
|
447
447
|
label: "Delete",
|
|
448
|
-
onclick: () =>
|
|
448
|
+
onclick: () => d(n.value)
|
|
449
449
|
}, null, 8, ["onclick"])) : N("", !0),
|
|
450
450
|
v(t, {
|
|
451
451
|
type: "submit",
|
|
@@ -459,7 +459,7 @@ const le = /* @__PURE__ */ k({
|
|
|
459
459
|
}, 512);
|
|
460
460
|
};
|
|
461
461
|
}
|
|
462
|
-
}), fe = { class: "flex items-end" }, ye = { class: "flex flex-wrap gap-8 items-center mt-4" }, ge = { class: "flex mt-6 space-x-6" }, be = /* @__PURE__ */
|
|
462
|
+
}), fe = { class: "flex items-end" }, ye = { class: "flex flex-wrap gap-8 items-center mt-4" }, ge = { class: "flex mt-6 space-x-6" }, be = /* @__PURE__ */ C({
|
|
463
463
|
__name: "MaybankGateway",
|
|
464
464
|
props: {
|
|
465
465
|
terminal: {
|
|
@@ -472,19 +472,19 @@ const le = /* @__PURE__ */ k({
|
|
|
472
472
|
}
|
|
473
473
|
},
|
|
474
474
|
setup(F) {
|
|
475
|
-
const
|
|
475
|
+
const c = F, a = O(() => c.terminal), T = b(), n = b(-1), r = b(), e = b({
|
|
476
476
|
ip: "",
|
|
477
477
|
receiptName: "",
|
|
478
478
|
cardTypes: []
|
|
479
|
-
}),
|
|
479
|
+
}), m = () => {
|
|
480
480
|
e.value.ip = "", e.value.receiptName = "", e.value.cardTypes = [], n.value = -1;
|
|
481
|
-
},
|
|
481
|
+
}, d = () => {
|
|
482
482
|
var i;
|
|
483
483
|
if (!a.value.ecrIntegrations)
|
|
484
|
-
return
|
|
485
|
-
const u = a.value.ecrIntegrations, l = u.findIndex((
|
|
484
|
+
return m();
|
|
485
|
+
const u = a.value.ecrIntegrations, l = u.findIndex((p) => p && p.gateway && p.gateway === "Maybank");
|
|
486
486
|
if (l === -1)
|
|
487
|
-
return
|
|
487
|
+
return m();
|
|
488
488
|
n.value = l;
|
|
489
489
|
const t = u.at(l);
|
|
490
490
|
t.gateway === "Maybank" && t.config && (e.value = {
|
|
@@ -493,18 +493,18 @@ const le = /* @__PURE__ */ k({
|
|
|
493
493
|
cardTypes: ((i = t.dialogConfig) == null ? void 0 : i.cardTypes) ?? []
|
|
494
494
|
});
|
|
495
495
|
};
|
|
496
|
-
|
|
496
|
+
q(a, d), S(d);
|
|
497
497
|
async function g(u) {
|
|
498
498
|
var l;
|
|
499
|
-
(l = a.value.ecrIntegrations) == null || l.splice(u, 1),
|
|
499
|
+
(l = a.value.ecrIntegrations) == null || l.splice(u, 1), c.onUpdate(a.value);
|
|
500
500
|
}
|
|
501
501
|
async function s() {
|
|
502
502
|
e.value.cardTypes.push(r.value), r.value = "";
|
|
503
503
|
}
|
|
504
504
|
return (u, l) => {
|
|
505
|
-
const t = f("FmTextField"), i = f("FmButton"),
|
|
506
|
-
return y(),
|
|
507
|
-
ref:
|
|
505
|
+
const t = f("FmTextField"), i = f("FmButton"), p = f("FmChip"), x = f("FmForm");
|
|
506
|
+
return y(), I(x, {
|
|
507
|
+
ref: T.value,
|
|
508
508
|
class: "flex flex-col gap-16 w-[500px]",
|
|
509
509
|
onValidationSuccess: l[3] || (l[3] = () => {
|
|
510
510
|
var o, w;
|
|
@@ -523,10 +523,10 @@ const le = /* @__PURE__ */ k({
|
|
|
523
523
|
dialogConfig: {
|
|
524
524
|
cardTypes: e.value.cardTypes
|
|
525
525
|
}
|
|
526
|
-
})),
|
|
526
|
+
})), c.onUpdate(a.value);
|
|
527
527
|
})
|
|
528
528
|
}, {
|
|
529
|
-
default:
|
|
529
|
+
default: M(() => [
|
|
530
530
|
v(t, {
|
|
531
531
|
modelValue: e.value.ip,
|
|
532
532
|
"onUpdate:modelValue": l[0] || (l[0] = (o) => e.value.ip = o),
|
|
@@ -538,7 +538,7 @@ const le = /* @__PURE__ */ k({
|
|
|
538
538
|
label: "Receipt Payment Name",
|
|
539
539
|
"label-info": "Default receipt display will be 'TERMINAL_MAYBANK'"
|
|
540
540
|
}, null, 8, ["modelValue"]),
|
|
541
|
-
|
|
541
|
+
_("div", fe, [
|
|
542
542
|
v(t, {
|
|
543
543
|
modelValue: r.value,
|
|
544
544
|
"onUpdate:modelValue": l[2] || (l[2] = (o) => r.value = o),
|
|
@@ -551,16 +551,16 @@ const le = /* @__PURE__ */ k({
|
|
|
551
551
|
onClick: s
|
|
552
552
|
})
|
|
553
553
|
]),
|
|
554
|
-
|
|
555
|
-
(y(!0), V(
|
|
554
|
+
_("div", ye, [
|
|
555
|
+
(y(!0), V(G, null, R(e.value.cardTypes, (o) => (y(), I(p, {
|
|
556
556
|
key: o,
|
|
557
557
|
label: o,
|
|
558
558
|
removable: !0,
|
|
559
559
|
onChipClosed: () => e.value.cardTypes.splice(e.value.cardTypes.indexOf(o), 1)
|
|
560
560
|
}, null, 8, ["label", "onChipClosed"]))), 128))
|
|
561
561
|
]),
|
|
562
|
-
|
|
563
|
-
n.value > -1 ? (y(),
|
|
562
|
+
_("div", ge, [
|
|
563
|
+
n.value > -1 ? (y(), I(i, {
|
|
564
564
|
key: 0,
|
|
565
565
|
class: "flex-1",
|
|
566
566
|
variant: "secondary",
|
|
@@ -579,7 +579,7 @@ const le = /* @__PURE__ */ k({
|
|
|
579
579
|
}, 512);
|
|
580
580
|
};
|
|
581
581
|
}
|
|
582
|
-
}), _e = { class: "flex items-end" },
|
|
582
|
+
}), _e = { class: "flex items-end" }, Te = { class: "flex flex-wrap gap-8 items-center mt-4" }, Fe = { class: "flex mt-6 space-x-6" }, Ie = /* @__PURE__ */ C({
|
|
583
583
|
__name: "Maybank2Gateway",
|
|
584
584
|
props: {
|
|
585
585
|
terminal: {
|
|
@@ -592,19 +592,19 @@ const le = /* @__PURE__ */ k({
|
|
|
592
592
|
}
|
|
593
593
|
},
|
|
594
594
|
setup(F) {
|
|
595
|
-
const
|
|
595
|
+
const c = F, a = O(() => c.terminal), T = b(), n = b(-1), r = b(), e = b({
|
|
596
596
|
ip: "",
|
|
597
597
|
receiptName: "",
|
|
598
598
|
cardTypes: []
|
|
599
|
-
}),
|
|
599
|
+
}), m = () => {
|
|
600
600
|
e.value.ip = "", e.value.receiptName = "", e.value.cardTypes = [], n.value = -1;
|
|
601
|
-
},
|
|
601
|
+
}, d = () => {
|
|
602
602
|
var i;
|
|
603
603
|
if (!a.value.ecrIntegrations)
|
|
604
|
-
return
|
|
605
|
-
const u = a.value.ecrIntegrations, l = u.findIndex((
|
|
604
|
+
return m();
|
|
605
|
+
const u = a.value.ecrIntegrations, l = u.findIndex((p) => p && p.gateway && p.gateway === "Maybank2");
|
|
606
606
|
if (l === -1)
|
|
607
|
-
return
|
|
607
|
+
return m();
|
|
608
608
|
n.value = l;
|
|
609
609
|
const t = u.at(l);
|
|
610
610
|
t.gateway === "Maybank2" && t.config && (e.value = {
|
|
@@ -613,18 +613,18 @@ const le = /* @__PURE__ */ k({
|
|
|
613
613
|
cardTypes: ((i = t.dialogConfig) == null ? void 0 : i.cardTypes) ?? []
|
|
614
614
|
});
|
|
615
615
|
};
|
|
616
|
-
|
|
616
|
+
q(a, d), S(d);
|
|
617
617
|
async function g(u) {
|
|
618
618
|
var l;
|
|
619
|
-
(l = a.value.ecrIntegrations) == null || l.splice(u, 1),
|
|
619
|
+
(l = a.value.ecrIntegrations) == null || l.splice(u, 1), c.onUpdate(a.value);
|
|
620
620
|
}
|
|
621
621
|
async function s() {
|
|
622
622
|
e.value.cardTypes.push(r.value), r.value = "";
|
|
623
623
|
}
|
|
624
624
|
return (u, l) => {
|
|
625
|
-
const t = f("FmTextField"), i = f("FmButton"),
|
|
626
|
-
return y(),
|
|
627
|
-
ref:
|
|
625
|
+
const t = f("FmTextField"), i = f("FmButton"), p = f("FmChip"), x = f("FmForm");
|
|
626
|
+
return y(), I(x, {
|
|
627
|
+
ref: T.value,
|
|
628
628
|
class: "flex flex-col gap-16 w-[500px]",
|
|
629
629
|
onValidationSuccess: l[3] || (l[3] = () => {
|
|
630
630
|
var o, w;
|
|
@@ -643,10 +643,10 @@ const le = /* @__PURE__ */ k({
|
|
|
643
643
|
dialogConfig: {
|
|
644
644
|
cardTypes: e.value.cardTypes
|
|
645
645
|
}
|
|
646
|
-
})),
|
|
646
|
+
})), c.onUpdate(a.value);
|
|
647
647
|
})
|
|
648
648
|
}, {
|
|
649
|
-
default:
|
|
649
|
+
default: M(() => [
|
|
650
650
|
v(t, {
|
|
651
651
|
modelValue: e.value.ip,
|
|
652
652
|
"onUpdate:modelValue": l[0] || (l[0] = (o) => e.value.ip = o),
|
|
@@ -658,7 +658,7 @@ const le = /* @__PURE__ */ k({
|
|
|
658
658
|
label: "Receipt Payment Name",
|
|
659
659
|
"label-info": "Default receipt display will be 'TERMINAL_MAYBANK'"
|
|
660
660
|
}, null, 8, ["modelValue"]),
|
|
661
|
-
|
|
661
|
+
_("div", _e, [
|
|
662
662
|
v(t, {
|
|
663
663
|
modelValue: r.value,
|
|
664
664
|
"onUpdate:modelValue": l[2] || (l[2] = (o) => r.value = o),
|
|
@@ -671,16 +671,16 @@ const le = /* @__PURE__ */ k({
|
|
|
671
671
|
onClick: s
|
|
672
672
|
})
|
|
673
673
|
]),
|
|
674
|
-
|
|
675
|
-
(y(!0), V(
|
|
674
|
+
_("div", Te, [
|
|
675
|
+
(y(!0), V(G, null, R(e.value.cardTypes, (o) => (y(), I(p, {
|
|
676
676
|
key: o,
|
|
677
677
|
label: o,
|
|
678
678
|
removable: !0,
|
|
679
679
|
onChipClosed: () => e.value.cardTypes.splice(e.value.cardTypes.indexOf(o), 1)
|
|
680
680
|
}, null, 8, ["label", "onChipClosed"]))), 128))
|
|
681
681
|
]),
|
|
682
|
-
|
|
683
|
-
n.value > -1 ? (y(),
|
|
682
|
+
_("div", Fe, [
|
|
683
|
+
n.value > -1 ? (y(), I(i, {
|
|
684
684
|
key: 0,
|
|
685
685
|
class: "flex-1",
|
|
686
686
|
variant: "secondary",
|
|
@@ -699,7 +699,7 @@ const le = /* @__PURE__ */ k({
|
|
|
699
699
|
}, 512);
|
|
700
700
|
};
|
|
701
701
|
}
|
|
702
|
-
}), we = { class: "flex items-end" }, xe = { class: "flex flex-wrap gap-8 items-center mt-4" }, Ne = { class: "flex mt-6 space-x-6" },
|
|
702
|
+
}), we = { class: "flex items-end" }, xe = { class: "flex flex-wrap gap-8 items-center mt-4" }, Ne = { class: "flex mt-6 space-x-6" }, Ce = /* @__PURE__ */ C({
|
|
703
703
|
__name: "Maybank3Gateway",
|
|
704
704
|
props: {
|
|
705
705
|
terminal: {
|
|
@@ -712,19 +712,19 @@ const le = /* @__PURE__ */ k({
|
|
|
712
712
|
}
|
|
713
713
|
},
|
|
714
714
|
setup(F) {
|
|
715
|
-
const
|
|
715
|
+
const c = F, a = O(() => c.terminal), T = b(), n = b(-1), r = b(), e = b({
|
|
716
716
|
receiptName: "",
|
|
717
717
|
config: {},
|
|
718
718
|
cardTypes: []
|
|
719
|
-
}),
|
|
719
|
+
}), m = () => {
|
|
720
720
|
e.value.receiptName = "", e.value.cardTypes = [], n.value = -1;
|
|
721
|
-
},
|
|
721
|
+
}, d = () => {
|
|
722
722
|
var i;
|
|
723
723
|
if (!a.value.ecrIntegrations)
|
|
724
|
-
return
|
|
725
|
-
const u = a.value.ecrIntegrations, l = u.findIndex((
|
|
724
|
+
return m();
|
|
725
|
+
const u = a.value.ecrIntegrations, l = u.findIndex((p) => p && p.gateway && p.gateway === "Maybank3");
|
|
726
726
|
if (l === -1)
|
|
727
|
-
return
|
|
727
|
+
return m();
|
|
728
728
|
n.value = l;
|
|
729
729
|
const t = u.at(l);
|
|
730
730
|
t.gateway === "Maybank3" && t.config && (e.value = {
|
|
@@ -733,18 +733,18 @@ const le = /* @__PURE__ */ k({
|
|
|
733
733
|
cardTypes: ((i = t.dialogConfig) == null ? void 0 : i.cardTypes) ?? []
|
|
734
734
|
});
|
|
735
735
|
};
|
|
736
|
-
|
|
736
|
+
q(a, d), S(d);
|
|
737
737
|
async function g(u) {
|
|
738
738
|
var l;
|
|
739
|
-
(l = a.value.ecrIntegrations) == null || l.splice(u, 1),
|
|
739
|
+
(l = a.value.ecrIntegrations) == null || l.splice(u, 1), c.onUpdate(a.value);
|
|
740
740
|
}
|
|
741
741
|
async function s() {
|
|
742
742
|
e.value.cardTypes.push(r.value), r.value = "";
|
|
743
743
|
}
|
|
744
744
|
return (u, l) => {
|
|
745
|
-
const t = f("FmTextField"), i = f("FmButton"),
|
|
746
|
-
return y(),
|
|
747
|
-
ref:
|
|
745
|
+
const t = f("FmTextField"), i = f("FmButton"), p = f("FmChip"), x = f("FmForm");
|
|
746
|
+
return y(), I(x, {
|
|
747
|
+
ref: T.value,
|
|
748
748
|
class: "flex flex-col gap-16 w-[500px]",
|
|
749
749
|
onValidationSuccess: l[2] || (l[2] = () => {
|
|
750
750
|
var o, w;
|
|
@@ -763,17 +763,17 @@ const le = /* @__PURE__ */ k({
|
|
|
763
763
|
dialogConfig: {
|
|
764
764
|
cardTypes: e.value.cardTypes
|
|
765
765
|
}
|
|
766
|
-
})),
|
|
766
|
+
})), c.onUpdate(a.value);
|
|
767
767
|
})
|
|
768
768
|
}, {
|
|
769
|
-
default:
|
|
769
|
+
default: M(() => [
|
|
770
770
|
v(t, {
|
|
771
771
|
modelValue: e.value.receiptName,
|
|
772
772
|
"onUpdate:modelValue": l[0] || (l[0] = (o) => e.value.receiptName = o),
|
|
773
773
|
label: "Receipt Payment Name",
|
|
774
774
|
"label-info": "Default receipt display will be 'TERMINAL_MAYBANK'"
|
|
775
775
|
}, null, 8, ["modelValue"]),
|
|
776
|
-
|
|
776
|
+
_("div", we, [
|
|
777
777
|
v(t, {
|
|
778
778
|
modelValue: r.value,
|
|
779
779
|
"onUpdate:modelValue": l[1] || (l[1] = (o) => r.value = o),
|
|
@@ -786,16 +786,16 @@ const le = /* @__PURE__ */ k({
|
|
|
786
786
|
onClick: s
|
|
787
787
|
})
|
|
788
788
|
]),
|
|
789
|
-
|
|
790
|
-
(y(!0), V(
|
|
789
|
+
_("div", xe, [
|
|
790
|
+
(y(!0), V(G, null, R(e.value.cardTypes, (o) => (y(), I(p, {
|
|
791
791
|
key: o,
|
|
792
792
|
label: o,
|
|
793
793
|
removable: !0,
|
|
794
794
|
onChipClosed: () => e.value.cardTypes.splice(e.value.cardTypes.indexOf(o), 1)
|
|
795
795
|
}, null, 8, ["label", "onChipClosed"]))), 128))
|
|
796
796
|
]),
|
|
797
|
-
|
|
798
|
-
n.value > -1 ? (y(),
|
|
797
|
+
_("div", Ne, [
|
|
798
|
+
n.value > -1 ? (y(), I(i, {
|
|
799
799
|
key: 0,
|
|
800
800
|
class: "flex-1",
|
|
801
801
|
variant: "secondary",
|
|
@@ -814,7 +814,7 @@ const le = /* @__PURE__ */ k({
|
|
|
814
814
|
}, 512);
|
|
815
815
|
};
|
|
816
816
|
}
|
|
817
|
-
}),
|
|
817
|
+
}), ke = { class: "flex items-end" }, Ve = { class: "flex flex-wrap gap-8 items-center mt-4" }, Ue = { class: "flex mt-6 space-x-6" }, Se = /* @__PURE__ */ C({
|
|
818
818
|
__name: "NetsGateway",
|
|
819
819
|
props: {
|
|
820
820
|
terminal: {
|
|
@@ -827,19 +827,19 @@ const le = /* @__PURE__ */ k({
|
|
|
827
827
|
}
|
|
828
828
|
},
|
|
829
829
|
setup(F) {
|
|
830
|
-
const
|
|
830
|
+
const c = F, a = O(() => c.terminal), T = b(), n = b(-1), r = b(), e = b({
|
|
831
831
|
ip: "",
|
|
832
832
|
receiptName: "",
|
|
833
833
|
cardTypes: []
|
|
834
|
-
}),
|
|
834
|
+
}), m = () => {
|
|
835
835
|
e.value.ip = "", e.value.receiptName = "", e.value.cardTypes = [], n.value = -1;
|
|
836
|
-
},
|
|
836
|
+
}, d = () => {
|
|
837
837
|
var i;
|
|
838
838
|
if (!a.value.ecrIntegrations)
|
|
839
|
-
return
|
|
840
|
-
const u = a.value.ecrIntegrations, l = u.findIndex((
|
|
839
|
+
return m();
|
|
840
|
+
const u = a.value.ecrIntegrations, l = u.findIndex((p) => p && p.gateway && p.gateway === "Nets");
|
|
841
841
|
if (l === -1)
|
|
842
|
-
return
|
|
842
|
+
return m();
|
|
843
843
|
n.value = l;
|
|
844
844
|
const t = u.at(l);
|
|
845
845
|
t.gateway === "Nets" && t.config && (e.value = {
|
|
@@ -848,18 +848,18 @@ const le = /* @__PURE__ */ k({
|
|
|
848
848
|
cardTypes: ((i = t.dialogConfig) == null ? void 0 : i.cardTypes) ?? []
|
|
849
849
|
});
|
|
850
850
|
};
|
|
851
|
-
|
|
851
|
+
q(a, d), S(d);
|
|
852
852
|
async function g(u) {
|
|
853
853
|
var l;
|
|
854
|
-
(l = a.value.ecrIntegrations) == null || l.splice(u, 1),
|
|
854
|
+
(l = a.value.ecrIntegrations) == null || l.splice(u, 1), c.onUpdate(a.value);
|
|
855
855
|
}
|
|
856
856
|
async function s() {
|
|
857
857
|
e.value.cardTypes.push(r.value), r.value = "";
|
|
858
858
|
}
|
|
859
859
|
return (u, l) => {
|
|
860
|
-
const t = f("FmTextField"), i = f("FmButton"),
|
|
861
|
-
return y(),
|
|
862
|
-
ref:
|
|
860
|
+
const t = f("FmTextField"), i = f("FmButton"), p = f("FmChip"), x = f("FmForm");
|
|
861
|
+
return y(), I(x, {
|
|
862
|
+
ref: T.value,
|
|
863
863
|
class: "flex flex-col gap-16 w-[500px]",
|
|
864
864
|
onValidationSuccess: l[3] || (l[3] = () => {
|
|
865
865
|
var o, w;
|
|
@@ -878,10 +878,10 @@ const le = /* @__PURE__ */ k({
|
|
|
878
878
|
dialogConfig: {
|
|
879
879
|
cardTypes: e.value.cardTypes
|
|
880
880
|
}
|
|
881
|
-
})),
|
|
881
|
+
})), c.onUpdate(a.value);
|
|
882
882
|
})
|
|
883
883
|
}, {
|
|
884
|
-
default:
|
|
884
|
+
default: M(() => [
|
|
885
885
|
v(t, {
|
|
886
886
|
modelValue: e.value.ip,
|
|
887
887
|
"onUpdate:modelValue": l[0] || (l[0] = (o) => e.value.ip = o),
|
|
@@ -893,7 +893,7 @@ const le = /* @__PURE__ */ k({
|
|
|
893
893
|
label: "Receipt Payment Name",
|
|
894
894
|
"label-info": "Default receipt display will be 'TERMINAL_NETS'"
|
|
895
895
|
}, null, 8, ["modelValue"]),
|
|
896
|
-
|
|
896
|
+
_("div", ke, [
|
|
897
897
|
v(t, {
|
|
898
898
|
modelValue: r.value,
|
|
899
899
|
"onUpdate:modelValue": l[2] || (l[2] = (o) => r.value = o),
|
|
@@ -906,16 +906,16 @@ const le = /* @__PURE__ */ k({
|
|
|
906
906
|
onClick: s
|
|
907
907
|
})
|
|
908
908
|
]),
|
|
909
|
-
|
|
910
|
-
(y(!0), V(
|
|
909
|
+
_("div", Ve, [
|
|
910
|
+
(y(!0), V(G, null, R(e.value.cardTypes, (o) => (y(), I(p, {
|
|
911
911
|
key: o,
|
|
912
912
|
label: o,
|
|
913
913
|
removable: !0,
|
|
914
914
|
onChipClosed: () => e.value.cardTypes.splice(e.value.cardTypes.indexOf(o), 1)
|
|
915
915
|
}, null, 8, ["label", "onChipClosed"]))), 128))
|
|
916
916
|
]),
|
|
917
|
-
|
|
918
|
-
n.value > -1 ? (y(),
|
|
917
|
+
_("div", Ue, [
|
|
918
|
+
n.value > -1 ? (y(), I(i, {
|
|
919
919
|
key: 0,
|
|
920
920
|
class: "flex-1",
|
|
921
921
|
variant: "secondary",
|
|
@@ -934,7 +934,7 @@ const le = /* @__PURE__ */ k({
|
|
|
934
934
|
}, 512);
|
|
935
935
|
};
|
|
936
936
|
}
|
|
937
|
-
}), Me = { class: "flex items-end" },
|
|
937
|
+
}), Me = { class: "flex items-end" }, he = { class: "flex flex-wrap gap-8 items-center mt-4" }, Ge = { class: "flex mt-6 space-x-6" }, Oe = /* @__PURE__ */ C({
|
|
938
938
|
__name: "KBankGateway",
|
|
939
939
|
props: {
|
|
940
940
|
terminal: {
|
|
@@ -947,18 +947,18 @@ const le = /* @__PURE__ */ k({
|
|
|
947
947
|
}
|
|
948
948
|
},
|
|
949
949
|
setup(F) {
|
|
950
|
-
const
|
|
950
|
+
const c = F, a = O(() => c.terminal), T = b(), n = b(-1), r = b(), e = b({
|
|
951
951
|
receiptName: "",
|
|
952
952
|
cardTypes: []
|
|
953
|
-
}),
|
|
953
|
+
}), m = () => {
|
|
954
954
|
e.value.receiptName = "", e.value.cardTypes = [], n.value = -1;
|
|
955
|
-
},
|
|
955
|
+
}, d = () => {
|
|
956
956
|
var i;
|
|
957
957
|
if (!a.value.ecrIntegrations)
|
|
958
|
-
return
|
|
959
|
-
const u = a.value.ecrIntegrations, l = u.findIndex((
|
|
958
|
+
return m();
|
|
959
|
+
const u = a.value.ecrIntegrations, l = u.findIndex((p) => p && p.gateway && p.gateway === "Kbank");
|
|
960
960
|
if (l === -1)
|
|
961
|
-
return
|
|
961
|
+
return m();
|
|
962
962
|
n.value = l;
|
|
963
963
|
const t = u.at(l);
|
|
964
964
|
t.gateway === "Kbank" && t.config && (e.value = {
|
|
@@ -966,18 +966,18 @@ const le = /* @__PURE__ */ k({
|
|
|
966
966
|
cardTypes: ((i = t.dialogConfig) == null ? void 0 : i.cardTypes) ?? []
|
|
967
967
|
});
|
|
968
968
|
};
|
|
969
|
-
|
|
969
|
+
q(a, d), S(d);
|
|
970
970
|
async function g(u) {
|
|
971
971
|
var l;
|
|
972
|
-
(l = a.value.ecrIntegrations) == null || l.splice(u, 1),
|
|
972
|
+
(l = a.value.ecrIntegrations) == null || l.splice(u, 1), c.onUpdate(a.value);
|
|
973
973
|
}
|
|
974
974
|
async function s() {
|
|
975
975
|
e.value.cardTypes.push(r.value), r.value = "";
|
|
976
976
|
}
|
|
977
977
|
return (u, l) => {
|
|
978
|
-
const t = f("FmTextField"), i = f("FmButton"),
|
|
979
|
-
return y(),
|
|
980
|
-
ref:
|
|
978
|
+
const t = f("FmTextField"), i = f("FmButton"), p = f("FmChip"), x = f("FmForm");
|
|
979
|
+
return y(), I(x, {
|
|
980
|
+
ref: T.value,
|
|
981
981
|
class: "flex flex-col gap-16 w-[500px]",
|
|
982
982
|
onValidationSuccess: l[2] || (l[2] = () => {
|
|
983
983
|
var o, w;
|
|
@@ -996,17 +996,17 @@ const le = /* @__PURE__ */ k({
|
|
|
996
996
|
dialogConfig: {
|
|
997
997
|
cardTypes: e.value.cardTypes
|
|
998
998
|
}
|
|
999
|
-
})),
|
|
999
|
+
})), c.onUpdate(a.value);
|
|
1000
1000
|
})
|
|
1001
1001
|
}, {
|
|
1002
|
-
default:
|
|
1002
|
+
default: M(() => [
|
|
1003
1003
|
v(t, {
|
|
1004
1004
|
modelValue: e.value.receiptName,
|
|
1005
1005
|
"onUpdate:modelValue": l[0] || (l[0] = (o) => e.value.receiptName = o),
|
|
1006
1006
|
label: "Receipt Payment Name",
|
|
1007
1007
|
"label-info": "Default receipt display will be 'TERMINAL_KBANK'"
|
|
1008
1008
|
}, null, 8, ["modelValue"]),
|
|
1009
|
-
|
|
1009
|
+
_("div", Me, [
|
|
1010
1010
|
v(t, {
|
|
1011
1011
|
modelValue: r.value,
|
|
1012
1012
|
"onUpdate:modelValue": l[1] || (l[1] = (o) => r.value = o),
|
|
@@ -1019,16 +1019,16 @@ const le = /* @__PURE__ */ k({
|
|
|
1019
1019
|
onClick: s
|
|
1020
1020
|
})
|
|
1021
1021
|
]),
|
|
1022
|
-
|
|
1023
|
-
(y(!0), V(
|
|
1022
|
+
_("div", he, [
|
|
1023
|
+
(y(!0), V(G, null, R(e.value.cardTypes, (o) => (y(), I(p, {
|
|
1024
1024
|
key: o,
|
|
1025
1025
|
label: o,
|
|
1026
1026
|
removable: !0,
|
|
1027
1027
|
onChipClosed: () => e.value.cardTypes.splice(e.value.cardTypes.indexOf(o), 1)
|
|
1028
1028
|
}, null, 8, ["label", "onChipClosed"]))), 128))
|
|
1029
1029
|
]),
|
|
1030
|
-
|
|
1031
|
-
n.value > -1 ? (y(),
|
|
1030
|
+
_("div", Ge, [
|
|
1031
|
+
n.value > -1 ? (y(), I(i, {
|
|
1032
1032
|
key: 0,
|
|
1033
1033
|
class: "flex-1",
|
|
1034
1034
|
variant: "secondary",
|
|
@@ -1047,7 +1047,7 @@ const le = /* @__PURE__ */ k({
|
|
|
1047
1047
|
}, 512);
|
|
1048
1048
|
};
|
|
1049
1049
|
}
|
|
1050
|
-
}),
|
|
1050
|
+
}), qe = { class: "flex mt-6 space-x-6" }, Pe = /* @__PURE__ */ C({
|
|
1051
1051
|
__name: "Ghl2Gateway",
|
|
1052
1052
|
props: {
|
|
1053
1053
|
terminal: {
|
|
@@ -1060,12 +1060,12 @@ const le = /* @__PURE__ */ k({
|
|
|
1060
1060
|
}
|
|
1061
1061
|
},
|
|
1062
1062
|
setup(F) {
|
|
1063
|
-
const
|
|
1063
|
+
const c = F, a = O(() => c.terminal), T = b(), n = b(-1), r = b({
|
|
1064
1064
|
ip: "",
|
|
1065
1065
|
receiptName: ""
|
|
1066
1066
|
}), e = () => {
|
|
1067
1067
|
r.value.ip = "", r.value.receiptName = "", n.value = -1;
|
|
1068
|
-
},
|
|
1068
|
+
}, m = () => {
|
|
1069
1069
|
if (!a.value.ecrIntegrations)
|
|
1070
1070
|
return e();
|
|
1071
1071
|
const g = a.value.ecrIntegrations, s = g.findIndex((l) => l && l.gateway && l.gateway === "Ghl2");
|
|
@@ -1078,15 +1078,15 @@ const le = /* @__PURE__ */ k({
|
|
|
1078
1078
|
receiptName: u.receiptName ?? ""
|
|
1079
1079
|
});
|
|
1080
1080
|
};
|
|
1081
|
-
|
|
1082
|
-
async function
|
|
1081
|
+
q(a, m), S(m);
|
|
1082
|
+
async function d(g) {
|
|
1083
1083
|
var s;
|
|
1084
|
-
(s = a.value.ecrIntegrations) == null || s.splice(g, 1),
|
|
1084
|
+
(s = a.value.ecrIntegrations) == null || s.splice(g, 1), c.onUpdate(a.value);
|
|
1085
1085
|
}
|
|
1086
1086
|
return (g, s) => {
|
|
1087
1087
|
const u = f("FmTextField"), l = f("FmButton"), t = f("FmForm");
|
|
1088
|
-
return y(),
|
|
1089
|
-
ref:
|
|
1088
|
+
return y(), I(t, {
|
|
1089
|
+
ref: T.value,
|
|
1090
1090
|
class: "flex flex-col gap-16 w-[500px]",
|
|
1091
1091
|
onValidationSuccess: s[2] || (s[2] = () => {
|
|
1092
1092
|
a.value.ecrIntegrations || (a.value.ecrIntegrations = []), n.value > -1 ? a.value.ecrIntegrations[n.value] = {
|
|
@@ -1097,10 +1097,10 @@ const le = /* @__PURE__ */ k({
|
|
|
1097
1097
|
gateway: "Ghl2",
|
|
1098
1098
|
config: { ip: r.value.ip },
|
|
1099
1099
|
receiptName: r.value.receiptName
|
|
1100
|
-
}),
|
|
1100
|
+
}), c.onUpdate(a.value);
|
|
1101
1101
|
})
|
|
1102
1102
|
}, {
|
|
1103
|
-
default:
|
|
1103
|
+
default: M(() => [
|
|
1104
1104
|
v(u, {
|
|
1105
1105
|
modelValue: r.value.ip,
|
|
1106
1106
|
"onUpdate:modelValue": s[0] || (s[0] = (i) => r.value.ip = i),
|
|
@@ -1112,13 +1112,13 @@ const le = /* @__PURE__ */ k({
|
|
|
1112
1112
|
label: "Receipt Payment Name",
|
|
1113
1113
|
"label-info": "Default receipt display will be 'TERMINAL_GHL_2'"
|
|
1114
1114
|
}, null, 8, ["modelValue"]),
|
|
1115
|
-
|
|
1116
|
-
n.value > -1 ? (y(),
|
|
1115
|
+
_("div", qe, [
|
|
1116
|
+
n.value > -1 ? (y(), I(l, {
|
|
1117
1117
|
key: 0,
|
|
1118
1118
|
class: "flex-1",
|
|
1119
1119
|
variant: "secondary",
|
|
1120
1120
|
label: "Delete",
|
|
1121
|
-
onclick: () =>
|
|
1121
|
+
onclick: () => d(n.value)
|
|
1122
1122
|
}, null, 8, ["onclick"])) : N("", !0),
|
|
1123
1123
|
v(l, {
|
|
1124
1124
|
type: "submit",
|
|
@@ -1132,7 +1132,7 @@ const le = /* @__PURE__ */ k({
|
|
|
1132
1132
|
}, 512);
|
|
1133
1133
|
};
|
|
1134
1134
|
}
|
|
1135
|
-
}), Re = { class: "flex items-end" }, $e = { class: "flex flex-wrap gap-8 items-center mt-4" }, Ae = { class: "flex mt-6 space-x-6" }, De = /* @__PURE__ */
|
|
1135
|
+
}), Re = { class: "flex items-end" }, $e = { class: "flex flex-wrap gap-8 items-center mt-4" }, Ae = { class: "flex mt-6 space-x-6" }, De = /* @__PURE__ */ C({
|
|
1136
1136
|
__name: "Ghl3Gateway",
|
|
1137
1137
|
props: {
|
|
1138
1138
|
terminal: {
|
|
@@ -1145,21 +1145,21 @@ const le = /* @__PURE__ */ k({
|
|
|
1145
1145
|
}
|
|
1146
1146
|
},
|
|
1147
1147
|
setup(F) {
|
|
1148
|
-
const
|
|
1148
|
+
const c = F, a = O(() => c.terminal), T = b(), n = b(-1), r = b(), e = b({
|
|
1149
1149
|
receiptName: "",
|
|
1150
1150
|
config: {},
|
|
1151
1151
|
cardTypes: []
|
|
1152
|
-
}),
|
|
1152
|
+
}), m = () => {
|
|
1153
1153
|
e.value.receiptName = "", e.value.cardTypes = [], n.value = -1;
|
|
1154
|
-
},
|
|
1154
|
+
}, d = () => {
|
|
1155
1155
|
var i;
|
|
1156
1156
|
if (!a.value.ecrIntegrations)
|
|
1157
|
-
return
|
|
1157
|
+
return m();
|
|
1158
1158
|
const u = a.value.ecrIntegrations, l = u.findIndex(
|
|
1159
|
-
(
|
|
1159
|
+
(p) => p && p.gateway && p.gateway === "Ghl3"
|
|
1160
1160
|
);
|
|
1161
1161
|
if (l === -1)
|
|
1162
|
-
return
|
|
1162
|
+
return m();
|
|
1163
1163
|
n.value = l;
|
|
1164
1164
|
const t = u.at(l);
|
|
1165
1165
|
t.gateway === "Ghl3" && t.config && (e.value = {
|
|
@@ -1168,18 +1168,18 @@ const le = /* @__PURE__ */ k({
|
|
|
1168
1168
|
cardTypes: ((i = t.dialogConfig) == null ? void 0 : i.cardTypes) ?? []
|
|
1169
1169
|
});
|
|
1170
1170
|
};
|
|
1171
|
-
|
|
1171
|
+
q(a, d), S(d);
|
|
1172
1172
|
async function g(u) {
|
|
1173
1173
|
var l;
|
|
1174
|
-
(l = a.value.ecrIntegrations) == null || l.splice(u, 1),
|
|
1174
|
+
(l = a.value.ecrIntegrations) == null || l.splice(u, 1), c.onUpdate(a.value);
|
|
1175
1175
|
}
|
|
1176
1176
|
async function s() {
|
|
1177
1177
|
e.value.cardTypes.push(r.value), r.value = "";
|
|
1178
1178
|
}
|
|
1179
1179
|
return (u, l) => {
|
|
1180
|
-
const t = f("FmTextField"), i = f("FmButton"),
|
|
1181
|
-
return y(),
|
|
1182
|
-
ref:
|
|
1180
|
+
const t = f("FmTextField"), i = f("FmButton"), p = f("FmChip"), x = f("FmForm");
|
|
1181
|
+
return y(), I(x, {
|
|
1182
|
+
ref: T.value,
|
|
1183
1183
|
class: "flex flex-col gap-16 w-[500px]",
|
|
1184
1184
|
onValidationSuccess: l[2] || (l[2] = () => {
|
|
1185
1185
|
var o, w;
|
|
@@ -1198,17 +1198,17 @@ const le = /* @__PURE__ */ k({
|
|
|
1198
1198
|
dialogConfig: {
|
|
1199
1199
|
cardTypes: e.value.cardTypes
|
|
1200
1200
|
}
|
|
1201
|
-
})),
|
|
1201
|
+
})), c.onUpdate(a.value);
|
|
1202
1202
|
})
|
|
1203
1203
|
}, {
|
|
1204
|
-
default:
|
|
1204
|
+
default: M(() => [
|
|
1205
1205
|
v(t, {
|
|
1206
1206
|
modelValue: e.value.receiptName,
|
|
1207
1207
|
"onUpdate:modelValue": l[0] || (l[0] = (o) => e.value.receiptName = o),
|
|
1208
1208
|
label: "Receipt Payment Name",
|
|
1209
1209
|
"label-info": "Default receipt display will be 'TERMINAL_GHL'"
|
|
1210
1210
|
}, null, 8, ["modelValue"]),
|
|
1211
|
-
|
|
1211
|
+
_("div", Re, [
|
|
1212
1212
|
v(t, {
|
|
1213
1213
|
modelValue: r.value,
|
|
1214
1214
|
"onUpdate:modelValue": l[1] || (l[1] = (o) => r.value = o),
|
|
@@ -1221,16 +1221,16 @@ const le = /* @__PURE__ */ k({
|
|
|
1221
1221
|
onClick: s
|
|
1222
1222
|
})
|
|
1223
1223
|
]),
|
|
1224
|
-
|
|
1225
|
-
(y(!0), V(
|
|
1224
|
+
_("div", $e, [
|
|
1225
|
+
(y(!0), V(G, null, R(e.value.cardTypes, (o) => (y(), I(p, {
|
|
1226
1226
|
key: o,
|
|
1227
1227
|
label: o,
|
|
1228
1228
|
removable: !0,
|
|
1229
1229
|
onChipClosed: () => e.value.cardTypes.splice(e.value.cardTypes.indexOf(o), 1)
|
|
1230
1230
|
}, null, 8, ["label", "onChipClosed"]))), 128))
|
|
1231
1231
|
]),
|
|
1232
|
-
|
|
1233
|
-
n.value > -1 ? (y(),
|
|
1232
|
+
_("div", Ae, [
|
|
1233
|
+
n.value > -1 ? (y(), I(i, {
|
|
1234
1234
|
key: 0,
|
|
1235
1235
|
class: "flex-1",
|
|
1236
1236
|
variant: "secondary",
|
|
@@ -1249,7 +1249,7 @@ const le = /* @__PURE__ */ k({
|
|
|
1249
1249
|
}, 512);
|
|
1250
1250
|
};
|
|
1251
1251
|
}
|
|
1252
|
-
}), Be = { class: "flex items-end" }, Ye = { class: "flex flex-wrap gap-8 items-center mt-4" }, Le = { class: "flex mt-6 space-x-6" }, Ke = /* @__PURE__ */
|
|
1252
|
+
}), Be = { class: "flex items-end" }, Ye = { class: "flex flex-wrap gap-8 items-center mt-4" }, Le = { class: "flex mt-6 space-x-6" }, Ke = /* @__PURE__ */ C({
|
|
1253
1253
|
__name: "HlbbGateway",
|
|
1254
1254
|
props: {
|
|
1255
1255
|
terminal: {
|
|
@@ -1262,21 +1262,21 @@ const le = /* @__PURE__ */ k({
|
|
|
1262
1262
|
}
|
|
1263
1263
|
},
|
|
1264
1264
|
setup(F) {
|
|
1265
|
-
const
|
|
1265
|
+
const c = F, a = O(() => c.terminal), T = b(), n = b(-1), r = b(), e = b({
|
|
1266
1266
|
receiptName: "",
|
|
1267
1267
|
config: {},
|
|
1268
1268
|
cardTypes: []
|
|
1269
|
-
}),
|
|
1269
|
+
}), m = () => {
|
|
1270
1270
|
e.value.receiptName = "", e.value.cardTypes = [], n.value = -1;
|
|
1271
|
-
},
|
|
1271
|
+
}, d = () => {
|
|
1272
1272
|
var i;
|
|
1273
1273
|
if (!a.value.ecrIntegrations)
|
|
1274
|
-
return
|
|
1274
|
+
return m();
|
|
1275
1275
|
const u = a.value.ecrIntegrations, l = u.findIndex(
|
|
1276
|
-
(
|
|
1276
|
+
(p) => p && p.gateway && p.gateway === "Hlbb"
|
|
1277
1277
|
);
|
|
1278
1278
|
if (l === -1)
|
|
1279
|
-
return
|
|
1279
|
+
return m();
|
|
1280
1280
|
n.value = l;
|
|
1281
1281
|
const t = u.at(l);
|
|
1282
1282
|
t.gateway === "Hlbb" && t.config && (e.value = {
|
|
@@ -1285,18 +1285,18 @@ const le = /* @__PURE__ */ k({
|
|
|
1285
1285
|
cardTypes: ((i = t.dialogConfig) == null ? void 0 : i.cardTypes) ?? []
|
|
1286
1286
|
});
|
|
1287
1287
|
};
|
|
1288
|
-
|
|
1288
|
+
q(a, d), S(d);
|
|
1289
1289
|
async function g(u) {
|
|
1290
1290
|
var l;
|
|
1291
|
-
(l = a.value.ecrIntegrations) == null || l.splice(u, 1),
|
|
1291
|
+
(l = a.value.ecrIntegrations) == null || l.splice(u, 1), c.onUpdate(a.value);
|
|
1292
1292
|
}
|
|
1293
1293
|
async function s() {
|
|
1294
1294
|
e.value.cardTypes.push(r.value), r.value = "";
|
|
1295
1295
|
}
|
|
1296
1296
|
return (u, l) => {
|
|
1297
|
-
const t = f("FmTextField"), i = f("FmButton"),
|
|
1298
|
-
return y(),
|
|
1299
|
-
ref:
|
|
1297
|
+
const t = f("FmTextField"), i = f("FmButton"), p = f("FmChip"), x = f("FmForm");
|
|
1298
|
+
return y(), I(x, {
|
|
1299
|
+
ref: T.value,
|
|
1300
1300
|
class: "flex flex-col gap-16 w-[500px]",
|
|
1301
1301
|
onValidationSuccess: l[2] || (l[2] = () => {
|
|
1302
1302
|
var o, w;
|
|
@@ -1315,17 +1315,17 @@ const le = /* @__PURE__ */ k({
|
|
|
1315
1315
|
dialogConfig: {
|
|
1316
1316
|
cardTypes: e.value.cardTypes
|
|
1317
1317
|
}
|
|
1318
|
-
})),
|
|
1318
|
+
})), c.onUpdate(a.value);
|
|
1319
1319
|
})
|
|
1320
1320
|
}, {
|
|
1321
|
-
default:
|
|
1321
|
+
default: M(() => [
|
|
1322
1322
|
v(t, {
|
|
1323
1323
|
modelValue: e.value.receiptName,
|
|
1324
1324
|
"onUpdate:modelValue": l[0] || (l[0] = (o) => e.value.receiptName = o),
|
|
1325
1325
|
label: "Receipt Payment Name",
|
|
1326
1326
|
"label-info": "Default receipt display will be 'TERMINAL_MAYBANK'"
|
|
1327
1327
|
}, null, 8, ["modelValue"]),
|
|
1328
|
-
|
|
1328
|
+
_("div", Be, [
|
|
1329
1329
|
v(t, {
|
|
1330
1330
|
modelValue: r.value,
|
|
1331
1331
|
"onUpdate:modelValue": l[1] || (l[1] = (o) => r.value = o),
|
|
@@ -1338,16 +1338,16 @@ const le = /* @__PURE__ */ k({
|
|
|
1338
1338
|
onClick: s
|
|
1339
1339
|
})
|
|
1340
1340
|
]),
|
|
1341
|
-
|
|
1342
|
-
(y(!0), V(
|
|
1341
|
+
_("div", Ye, [
|
|
1342
|
+
(y(!0), V(G, null, R(e.value.cardTypes, (o) => (y(), I(p, {
|
|
1343
1343
|
key: o,
|
|
1344
1344
|
label: o,
|
|
1345
1345
|
removable: !0,
|
|
1346
1346
|
onChipClosed: () => e.value.cardTypes.splice(e.value.cardTypes.indexOf(o), 1)
|
|
1347
1347
|
}, null, 8, ["label", "onChipClosed"]))), 128))
|
|
1348
1348
|
]),
|
|
1349
|
-
|
|
1350
|
-
n.value > -1 ? (y(),
|
|
1349
|
+
_("div", Le, [
|
|
1350
|
+
n.value > -1 ? (y(), I(i, {
|
|
1351
1351
|
key: 0,
|
|
1352
1352
|
class: "flex-1",
|
|
1353
1353
|
variant: "secondary",
|
|
@@ -1366,7 +1366,7 @@ const le = /* @__PURE__ */ k({
|
|
|
1366
1366
|
}, 512);
|
|
1367
1367
|
};
|
|
1368
1368
|
}
|
|
1369
|
-
}), Ee = { class: "flex items-end" }, je = { class: "flex flex-wrap gap-8 items-center mt-4" }, He = { class: "flex mt-6 space-x-6" }, ze = /* @__PURE__ */
|
|
1369
|
+
}), Ee = { class: "flex items-end" }, je = { class: "flex flex-wrap gap-8 items-center mt-4" }, He = { class: "flex mt-6 space-x-6" }, ze = /* @__PURE__ */ C({
|
|
1370
1370
|
__name: "GlobalPaymentsGateway",
|
|
1371
1371
|
props: {
|
|
1372
1372
|
terminal: {
|
|
@@ -1379,21 +1379,21 @@ const le = /* @__PURE__ */ k({
|
|
|
1379
1379
|
}
|
|
1380
1380
|
},
|
|
1381
1381
|
setup(F) {
|
|
1382
|
-
const
|
|
1382
|
+
const c = F, a = O(() => c.terminal), T = b(), n = b(-1), r = b(), e = b({
|
|
1383
1383
|
ip: "",
|
|
1384
1384
|
receiptName: "",
|
|
1385
1385
|
cardTypes: []
|
|
1386
|
-
}),
|
|
1386
|
+
}), m = () => {
|
|
1387
1387
|
e.value.ip = "", e.value.receiptName = "", e.value.cardTypes = [], n.value = -1;
|
|
1388
|
-
},
|
|
1388
|
+
}, d = () => {
|
|
1389
1389
|
var i;
|
|
1390
1390
|
if (!a.value.ecrIntegrations)
|
|
1391
|
-
return
|
|
1391
|
+
return m();
|
|
1392
1392
|
const u = a.value.ecrIntegrations, l = u.findIndex(
|
|
1393
|
-
(
|
|
1393
|
+
(p) => p && p.gateway && p.gateway === "GlobalPayments"
|
|
1394
1394
|
);
|
|
1395
1395
|
if (l === -1)
|
|
1396
|
-
return
|
|
1396
|
+
return m();
|
|
1397
1397
|
n.value = l;
|
|
1398
1398
|
const t = u.at(l);
|
|
1399
1399
|
t.gateway === "GlobalPayments" && t.config && (e.value = {
|
|
@@ -1402,18 +1402,18 @@ const le = /* @__PURE__ */ k({
|
|
|
1402
1402
|
cardTypes: ((i = t.dialogConfig) == null ? void 0 : i.cardTypes) ?? []
|
|
1403
1403
|
});
|
|
1404
1404
|
};
|
|
1405
|
-
|
|
1405
|
+
q(a, d), S(d);
|
|
1406
1406
|
async function g(u) {
|
|
1407
1407
|
var l;
|
|
1408
|
-
(l = a.value.ecrIntegrations) == null || l.splice(u, 1),
|
|
1408
|
+
(l = a.value.ecrIntegrations) == null || l.splice(u, 1), c.onUpdate(a.value);
|
|
1409
1409
|
}
|
|
1410
1410
|
async function s() {
|
|
1411
1411
|
e.value.cardTypes.push(r.value), r.value = "";
|
|
1412
1412
|
}
|
|
1413
1413
|
return (u, l) => {
|
|
1414
|
-
const t = f("FmTextField"), i = f("FmButton"),
|
|
1415
|
-
return y(),
|
|
1416
|
-
ref:
|
|
1414
|
+
const t = f("FmTextField"), i = f("FmButton"), p = f("FmChip"), x = f("FmForm");
|
|
1415
|
+
return y(), I(x, {
|
|
1416
|
+
ref: T.value,
|
|
1417
1417
|
class: "flex flex-col gap-16 w-[500px]",
|
|
1418
1418
|
onValidationSuccess: l[3] || (l[3] = () => {
|
|
1419
1419
|
var o, w;
|
|
@@ -1432,10 +1432,10 @@ const le = /* @__PURE__ */ k({
|
|
|
1432
1432
|
dialogConfig: {
|
|
1433
1433
|
cardTypes: e.value.cardTypes
|
|
1434
1434
|
}
|
|
1435
|
-
})),
|
|
1435
|
+
})), c.onUpdate(a.value);
|
|
1436
1436
|
})
|
|
1437
1437
|
}, {
|
|
1438
|
-
default:
|
|
1438
|
+
default: M(() => [
|
|
1439
1439
|
v(t, {
|
|
1440
1440
|
modelValue: e.value.ip,
|
|
1441
1441
|
"onUpdate:modelValue": l[0] || (l[0] = (o) => e.value.ip = o),
|
|
@@ -1447,7 +1447,7 @@ const le = /* @__PURE__ */ k({
|
|
|
1447
1447
|
label: "Receipt Payment Name",
|
|
1448
1448
|
"label-info": "Default receipt display will be 'TERMINAL_GP'"
|
|
1449
1449
|
}, null, 8, ["modelValue"]),
|
|
1450
|
-
|
|
1450
|
+
_("div", Ee, [
|
|
1451
1451
|
v(t, {
|
|
1452
1452
|
modelValue: r.value,
|
|
1453
1453
|
"onUpdate:modelValue": l[2] || (l[2] = (o) => r.value = o),
|
|
@@ -1460,16 +1460,131 @@ const le = /* @__PURE__ */ k({
|
|
|
1460
1460
|
onClick: s
|
|
1461
1461
|
})
|
|
1462
1462
|
]),
|
|
1463
|
-
|
|
1464
|
-
(y(!0), V(
|
|
1463
|
+
_("div", je, [
|
|
1464
|
+
(y(!0), V(G, null, R(e.value.cardTypes, (o) => (y(), I(p, {
|
|
1465
|
+
key: o,
|
|
1466
|
+
label: o,
|
|
1467
|
+
removable: !0,
|
|
1468
|
+
onChipClosed: () => e.value.cardTypes.splice(e.value.cardTypes.indexOf(o), 1)
|
|
1469
|
+
}, null, 8, ["label", "onChipClosed"]))), 128))
|
|
1470
|
+
]),
|
|
1471
|
+
_("div", He, [
|
|
1472
|
+
n.value > -1 ? (y(), I(i, {
|
|
1473
|
+
key: 0,
|
|
1474
|
+
class: "flex-1",
|
|
1475
|
+
variant: "secondary",
|
|
1476
|
+
label: "Delete",
|
|
1477
|
+
onclick: () => g(n.value)
|
|
1478
|
+
}, null, 8, ["onclick"])) : N("", !0),
|
|
1479
|
+
v(i, {
|
|
1480
|
+
type: "submit",
|
|
1481
|
+
class: "flex-1",
|
|
1482
|
+
variant: "primary",
|
|
1483
|
+
label: "Save"
|
|
1484
|
+
})
|
|
1485
|
+
])
|
|
1486
|
+
]),
|
|
1487
|
+
_: 1
|
|
1488
|
+
}, 512);
|
|
1489
|
+
};
|
|
1490
|
+
}
|
|
1491
|
+
}), Qe = { class: "flex items-end" }, Je = { class: "flex flex-wrap gap-8 items-center mt-4" }, We = { class: "flex mt-6 space-x-6" }, Xe = /* @__PURE__ */ C({
|
|
1492
|
+
__name: "OmaGateway",
|
|
1493
|
+
props: {
|
|
1494
|
+
terminal: {
|
|
1495
|
+
type: Object,
|
|
1496
|
+
required: !0
|
|
1497
|
+
},
|
|
1498
|
+
onUpdate: {
|
|
1499
|
+
type: Function,
|
|
1500
|
+
required: !0
|
|
1501
|
+
}
|
|
1502
|
+
},
|
|
1503
|
+
setup(F) {
|
|
1504
|
+
const c = F, a = O(() => c.terminal), T = b(), n = b(-1), r = b(), e = b({
|
|
1505
|
+
receiptName: "",
|
|
1506
|
+
cardTypes: []
|
|
1507
|
+
}), m = () => {
|
|
1508
|
+
e.value.receiptName = "", e.value.cardTypes = [], n.value = -1;
|
|
1509
|
+
}, d = () => {
|
|
1510
|
+
var i;
|
|
1511
|
+
if (!a.value.ecrIntegrations)
|
|
1512
|
+
return m();
|
|
1513
|
+
const u = a.value.ecrIntegrations, l = u.findIndex(
|
|
1514
|
+
(p) => p && p.gateway && p.gateway === "Oma"
|
|
1515
|
+
);
|
|
1516
|
+
if (l === -1)
|
|
1517
|
+
return m();
|
|
1518
|
+
n.value = l;
|
|
1519
|
+
const t = u.at(l);
|
|
1520
|
+
t.gateway === "Oma" && t.config && (e.value = {
|
|
1521
|
+
receiptName: t.receiptName ?? "",
|
|
1522
|
+
cardTypes: ((i = t.dialogConfig) == null ? void 0 : i.cardTypes) ?? []
|
|
1523
|
+
});
|
|
1524
|
+
};
|
|
1525
|
+
q(a, d), S(d);
|
|
1526
|
+
async function g(u) {
|
|
1527
|
+
var l;
|
|
1528
|
+
(l = a.value.ecrIntegrations) == null || l.splice(u, 1), c.onUpdate(a.value);
|
|
1529
|
+
}
|
|
1530
|
+
async function s() {
|
|
1531
|
+
e.value.cardTypes.push(r.value), r.value = "";
|
|
1532
|
+
}
|
|
1533
|
+
return (u, l) => {
|
|
1534
|
+
const t = f("FmTextField"), i = f("FmButton"), p = f("FmChip"), x = f("FmForm");
|
|
1535
|
+
return y(), I(x, {
|
|
1536
|
+
ref: T.value,
|
|
1537
|
+
class: "flex flex-col gap-16 w-[500px]",
|
|
1538
|
+
onValidationSuccess: l[2] || (l[2] = () => {
|
|
1539
|
+
var o, w;
|
|
1540
|
+
n.value > -1 ? a.value.ecrIntegrations[n.value] = {
|
|
1541
|
+
gateway: "Oma",
|
|
1542
|
+
config: {},
|
|
1543
|
+
receiptName: e.value.receiptName,
|
|
1544
|
+
dialogConfig: {
|
|
1545
|
+
...(w = (o = a.value.ecrIntegrations) == null ? void 0 : o[n.value]) == null ? void 0 : w.dialogConfig,
|
|
1546
|
+
cardTypes: e.value.cardTypes
|
|
1547
|
+
}
|
|
1548
|
+
} : (a.value.ecrIntegrations || (a.value.ecrIntegrations = []), a.value.ecrIntegrations.push({
|
|
1549
|
+
gateway: "Oma",
|
|
1550
|
+
config: {},
|
|
1551
|
+
receiptName: e.value.receiptName,
|
|
1552
|
+
dialogConfig: {
|
|
1553
|
+
cardTypes: e.value.cardTypes
|
|
1554
|
+
}
|
|
1555
|
+
})), c.onUpdate(a.value);
|
|
1556
|
+
})
|
|
1557
|
+
}, {
|
|
1558
|
+
default: M(() => [
|
|
1559
|
+
v(t, {
|
|
1560
|
+
modelValue: e.value.receiptName,
|
|
1561
|
+
"onUpdate:modelValue": l[0] || (l[0] = (o) => e.value.receiptName = o),
|
|
1562
|
+
label: "Receipt Payment Name",
|
|
1563
|
+
"label-info": "Default receipt display will be 'TERMINAL_OMA'"
|
|
1564
|
+
}, null, 8, ["modelValue"]),
|
|
1565
|
+
_("div", Qe, [
|
|
1566
|
+
v(t, {
|
|
1567
|
+
modelValue: r.value,
|
|
1568
|
+
"onUpdate:modelValue": l[1] || (l[1] = (o) => r.value = o),
|
|
1569
|
+
label: "Fallback Card Types",
|
|
1570
|
+
"label-info": "List of cards when fallback to reconcile dialog. Default VISA, MASTER"
|
|
1571
|
+
}, null, 8, ["modelValue"]),
|
|
1572
|
+
v(i, {
|
|
1573
|
+
class: "ml-4",
|
|
1574
|
+
icon: "add",
|
|
1575
|
+
onClick: s
|
|
1576
|
+
})
|
|
1577
|
+
]),
|
|
1578
|
+
_("div", Je, [
|
|
1579
|
+
(y(!0), V(G, null, R(e.value.cardTypes, (o) => (y(), I(p, {
|
|
1465
1580
|
key: o,
|
|
1466
1581
|
label: o,
|
|
1467
1582
|
removable: !0,
|
|
1468
1583
|
onChipClosed: () => e.value.cardTypes.splice(e.value.cardTypes.indexOf(o), 1)
|
|
1469
1584
|
}, null, 8, ["label", "onChipClosed"]))), 128))
|
|
1470
1585
|
]),
|
|
1471
|
-
|
|
1472
|
-
n.value > -1 ? (y(),
|
|
1586
|
+
_("div", We, [
|
|
1587
|
+
n.value > -1 ? (y(), I(i, {
|
|
1473
1588
|
key: 0,
|
|
1474
1589
|
class: "flex-1",
|
|
1475
1590
|
variant: "secondary",
|
|
@@ -1488,7 +1603,7 @@ const le = /* @__PURE__ */ k({
|
|
|
1488
1603
|
}, 512);
|
|
1489
1604
|
};
|
|
1490
1605
|
}
|
|
1491
|
-
}),
|
|
1606
|
+
}), Ze = { class: "flex items-center" }, ea = { class: "w-[260px] self-start" }, aa = { class: "flex-1" }, la = /* @__PURE__ */ C({
|
|
1492
1607
|
__name: "EcrGateway",
|
|
1493
1608
|
props: {
|
|
1494
1609
|
terminal: {
|
|
@@ -1501,85 +1616,91 @@ const le = /* @__PURE__ */ k({
|
|
|
1501
1616
|
}
|
|
1502
1617
|
},
|
|
1503
1618
|
setup(F) {
|
|
1504
|
-
var
|
|
1505
|
-
const
|
|
1619
|
+
var m;
|
|
1620
|
+
const c = F, a = [
|
|
1506
1621
|
{
|
|
1507
1622
|
label: "FeedMe Terminal",
|
|
1508
1623
|
value: "terminal",
|
|
1509
1624
|
render: pe
|
|
1510
1625
|
},
|
|
1511
1626
|
{
|
|
1512
|
-
label: "GHL Terminal
|
|
1627
|
+
label: "GHL Terminal",
|
|
1513
1628
|
value: "ghl",
|
|
1514
1629
|
render: ve,
|
|
1515
|
-
region: [
|
|
1630
|
+
region: [k.F_COUNTRY.enum.MY]
|
|
1516
1631
|
},
|
|
1517
1632
|
{
|
|
1518
|
-
label: "
|
|
1633
|
+
label: "GHL2 Terminal",
|
|
1519
1634
|
value: "ghl2",
|
|
1520
|
-
render:
|
|
1521
|
-
region: [
|
|
1635
|
+
render: Pe,
|
|
1636
|
+
region: [k.F_COUNTRY.enum.MY]
|
|
1522
1637
|
},
|
|
1523
1638
|
{
|
|
1524
|
-
label: "Maybank Terminal
|
|
1639
|
+
label: "ITB Maybank Terminal",
|
|
1525
1640
|
value: "mb-itb",
|
|
1526
1641
|
render: be,
|
|
1527
|
-
region: [
|
|
1642
|
+
region: [k.F_COUNTRY.enum.MY]
|
|
1528
1643
|
},
|
|
1529
1644
|
{
|
|
1530
|
-
label: "Maybank Terminal
|
|
1645
|
+
label: "PMA Maybank Terminal",
|
|
1531
1646
|
value: "mb-pma",
|
|
1532
|
-
render:
|
|
1533
|
-
region: [
|
|
1647
|
+
render: Ie,
|
|
1648
|
+
region: [k.F_COUNTRY.enum.MY]
|
|
1534
1649
|
},
|
|
1535
1650
|
{
|
|
1536
|
-
label: "Maybank Terminal
|
|
1651
|
+
label: "Paysys Maybank Terminal",
|
|
1537
1652
|
value: "mb-paysys",
|
|
1538
|
-
render:
|
|
1539
|
-
region: [
|
|
1653
|
+
render: Ce,
|
|
1654
|
+
region: [k.F_COUNTRY.enum.MY]
|
|
1540
1655
|
},
|
|
1541
1656
|
{
|
|
1542
1657
|
label: "Nets Terminal",
|
|
1543
1658
|
value: "nets",
|
|
1544
1659
|
render: Se,
|
|
1545
|
-
region: [
|
|
1660
|
+
region: [k.F_COUNTRY.enum.SG]
|
|
1546
1661
|
},
|
|
1547
1662
|
{
|
|
1548
1663
|
label: "KBank Terminal",
|
|
1549
1664
|
value: "kbank",
|
|
1550
|
-
render:
|
|
1551
|
-
region: [
|
|
1665
|
+
render: Oe,
|
|
1666
|
+
region: [k.F_COUNTRY.enum.TH]
|
|
1552
1667
|
},
|
|
1553
1668
|
{
|
|
1554
1669
|
label: "GHL Terminal",
|
|
1555
1670
|
value: "ghl3",
|
|
1556
1671
|
render: De,
|
|
1557
|
-
region: [
|
|
1672
|
+
region: [k.F_COUNTRY.enum.TH]
|
|
1558
1673
|
},
|
|
1559
1674
|
{
|
|
1560
|
-
label: "HLBB Terminal
|
|
1675
|
+
label: "Paysys HLBB Terminal",
|
|
1561
1676
|
value: "hlbb",
|
|
1562
1677
|
render: Ke,
|
|
1563
|
-
region: [
|
|
1678
|
+
region: [k.F_COUNTRY.enum.MY]
|
|
1564
1679
|
},
|
|
1565
1680
|
{
|
|
1566
|
-
label: "
|
|
1681
|
+
label: "GPAP Terminal",
|
|
1567
1682
|
value: "globalpayments",
|
|
1568
1683
|
render: ze,
|
|
1569
|
-
region: [
|
|
1684
|
+
region: [k.F_COUNTRY.enum.SG]
|
|
1685
|
+
},
|
|
1686
|
+
{
|
|
1687
|
+
label: "OMA Terminal",
|
|
1688
|
+
value: "oma",
|
|
1689
|
+
render: Xe,
|
|
1690
|
+
region: [k.F_COUNTRY.enum.PK]
|
|
1570
1691
|
}
|
|
1571
|
-
],
|
|
1572
|
-
(
|
|
1692
|
+
], T = P(() => a.find((d) => d.value === e.value)), n = j().currentCountry, r = P(() => a.filter(
|
|
1693
|
+
(d) => !d.region || d.region.includes(n.value ?? k.F_COUNTRY.enum.MY)
|
|
1573
1694
|
)), { gatewayTab: e } = E({
|
|
1574
|
-
gatewayTab: (
|
|
1695
|
+
gatewayTab: (m = r.value[0]) == null ? void 0 : m.value
|
|
1575
1696
|
});
|
|
1576
|
-
return (
|
|
1697
|
+
return (d, g) => {
|
|
1577
1698
|
var u;
|
|
1578
1699
|
const s = f("FmTabs");
|
|
1579
|
-
return y(), V("div",
|
|
1580
|
-
|
|
1700
|
+
return y(), V("div", Ze, [
|
|
1701
|
+
_("div", ea, [
|
|
1581
1702
|
v(s, {
|
|
1582
|
-
"model-value":
|
|
1703
|
+
"model-value": h(e),
|
|
1583
1704
|
"onUpdate:modelValue": g[0] || (g[0] = (l) => B(e) ? e.value = l : null),
|
|
1584
1705
|
class: "mb-6",
|
|
1585
1706
|
vertical: !0,
|
|
@@ -1587,16 +1708,16 @@ const le = /* @__PURE__ */ k({
|
|
|
1587
1708
|
"show-more-at": Number.POSITIVE_INFINITY
|
|
1588
1709
|
}, null, 8, ["model-value", "items", "show-more-at"])
|
|
1589
1710
|
]),
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
terminal:
|
|
1593
|
-
onUpdate:
|
|
1711
|
+
_("div", aa, [
|
|
1712
|
+
h(e) ? (y(), I(Y((u = T.value) == null ? void 0 : u.render), L(K({ key: 0 }, {
|
|
1713
|
+
terminal: c.terminal,
|
|
1714
|
+
onUpdate: c.onUpdate
|
|
1594
1715
|
})), null, 16)) : N("", !0)
|
|
1595
1716
|
])
|
|
1596
1717
|
]);
|
|
1597
1718
|
};
|
|
1598
1719
|
}
|
|
1599
|
-
}),
|
|
1720
|
+
}), ta = { class: "flex mt-6 space-x-6" }, na = /* @__PURE__ */ C({
|
|
1600
1721
|
__name: "PromptPayGateway",
|
|
1601
1722
|
props: {
|
|
1602
1723
|
terminal: {
|
|
@@ -1609,12 +1730,12 @@ const le = /* @__PURE__ */ k({
|
|
|
1609
1730
|
}
|
|
1610
1731
|
},
|
|
1611
1732
|
setup(F) {
|
|
1612
|
-
const
|
|
1733
|
+
const c = F, a = O(() => c.terminal), T = b(), n = b(-1), r = b({
|
|
1613
1734
|
account: "",
|
|
1614
1735
|
receiptName: ""
|
|
1615
1736
|
}), e = () => {
|
|
1616
1737
|
r.value.account = "", r.value.receiptName = "", n.value = -1;
|
|
1617
|
-
},
|
|
1738
|
+
}, m = () => {
|
|
1618
1739
|
if (!a.value.qrIntegrations)
|
|
1619
1740
|
return e();
|
|
1620
1741
|
const g = a.value.qrIntegrations, s = g.findIndex((l) => l && l.gateway && l.gateway === "PROMPTPAY");
|
|
@@ -1627,21 +1748,21 @@ const le = /* @__PURE__ */ k({
|
|
|
1627
1748
|
receiptName: u.receiptName ?? ""
|
|
1628
1749
|
});
|
|
1629
1750
|
};
|
|
1630
|
-
|
|
1631
|
-
async function
|
|
1751
|
+
q(a, m), S(m);
|
|
1752
|
+
async function d(g) {
|
|
1632
1753
|
var s;
|
|
1633
|
-
(s = a.value.qrIntegrations) == null || s.splice(g, 1),
|
|
1754
|
+
(s = a.value.qrIntegrations) == null || s.splice(g, 1), c.onUpdate(a.value);
|
|
1634
1755
|
}
|
|
1635
1756
|
return (g, s) => {
|
|
1636
1757
|
const u = f("FmTextField"), l = f("FmButton"), t = f("FmForm");
|
|
1637
|
-
return y(),
|
|
1638
|
-
ref:
|
|
1758
|
+
return y(), I(t, {
|
|
1759
|
+
ref: T.value,
|
|
1639
1760
|
class: "flex flex-col gap-16 w-[500px]",
|
|
1640
1761
|
onValidationSuccess: s[2] || (s[2] = () => {
|
|
1641
|
-
n.value > -1 ? a.value.qrIntegrations[n.value] = { gateway: "PROMPTPAY", config: { account: r.value.account }, receiptName: r.value.receiptName } : (a.value.qrIntegrations || (a.value.qrIntegrations = []), a.value.qrIntegrations.push({ gateway: "PROMPTPAY", config: { account: r.value.account }, receiptName: r.value.receiptName })),
|
|
1762
|
+
n.value > -1 ? a.value.qrIntegrations[n.value] = { gateway: "PROMPTPAY", config: { account: r.value.account }, receiptName: r.value.receiptName } : (a.value.qrIntegrations || (a.value.qrIntegrations = []), a.value.qrIntegrations.push({ gateway: "PROMPTPAY", config: { account: r.value.account }, receiptName: r.value.receiptName })), c.onUpdate(a.value);
|
|
1642
1763
|
})
|
|
1643
1764
|
}, {
|
|
1644
|
-
default:
|
|
1765
|
+
default: M(() => [
|
|
1645
1766
|
v(u, {
|
|
1646
1767
|
modelValue: r.value.account,
|
|
1647
1768
|
"onUpdate:modelValue": s[0] || (s[0] = (i) => r.value.account = i),
|
|
@@ -1654,13 +1775,13 @@ const le = /* @__PURE__ */ k({
|
|
|
1654
1775
|
label: "Receipt Payment Name",
|
|
1655
1776
|
"label-info": "Default receipt display will be 'TERMINAL_MAYBANK'"
|
|
1656
1777
|
}, null, 8, ["modelValue"]),
|
|
1657
|
-
|
|
1658
|
-
n.value > -1 ? (y(),
|
|
1778
|
+
_("div", ta, [
|
|
1779
|
+
n.value > -1 ? (y(), I(l, {
|
|
1659
1780
|
key: 0,
|
|
1660
1781
|
class: "flex-1",
|
|
1661
1782
|
variant: "secondary",
|
|
1662
1783
|
label: "Delete",
|
|
1663
|
-
onclick: () =>
|
|
1784
|
+
onclick: () => d(n.value)
|
|
1664
1785
|
}, null, 8, ["onclick"])) : N("", !0),
|
|
1665
1786
|
v(l, {
|
|
1666
1787
|
type: "submit",
|
|
@@ -1674,7 +1795,7 @@ const le = /* @__PURE__ */ k({
|
|
|
1674
1795
|
}, 512);
|
|
1675
1796
|
};
|
|
1676
1797
|
}
|
|
1677
|
-
}),
|
|
1798
|
+
}), oa = { class: "flex items-center" }, ra = { class: "w-[260px] self-start" }, ia = { class: "flex-1" }, ua = /* @__PURE__ */ C({
|
|
1678
1799
|
__name: "QrGateway",
|
|
1679
1800
|
props: {
|
|
1680
1801
|
terminal: {
|
|
@@ -1687,40 +1808,40 @@ const le = /* @__PURE__ */ k({
|
|
|
1687
1808
|
}
|
|
1688
1809
|
},
|
|
1689
1810
|
setup(F) {
|
|
1690
|
-
var
|
|
1691
|
-
const
|
|
1811
|
+
var m;
|
|
1812
|
+
const c = F, a = [
|
|
1692
1813
|
{
|
|
1693
1814
|
label: "PromptPay",
|
|
1694
1815
|
value: "promptpay",
|
|
1695
|
-
render:
|
|
1696
|
-
region: [
|
|
1816
|
+
render: na,
|
|
1817
|
+
region: [k.F_COUNTRY.enum.TH]
|
|
1697
1818
|
}
|
|
1698
|
-
],
|
|
1699
|
-
gatewayTab: (
|
|
1819
|
+
], T = P(() => a.find((d) => d.value === e.value)), n = j().currentCountry, r = P(() => a.filter((d) => !d.region || d.region.includes(n.value ?? k.F_COUNTRY.enum.MY))), { gatewayTab: e } = E({
|
|
1820
|
+
gatewayTab: (m = r.value[0]) == null ? void 0 : m.value
|
|
1700
1821
|
});
|
|
1701
|
-
return (
|
|
1822
|
+
return (d, g) => {
|
|
1702
1823
|
var u;
|
|
1703
1824
|
const s = f("FmTabs");
|
|
1704
|
-
return y(), V("div",
|
|
1705
|
-
|
|
1825
|
+
return y(), V("div", oa, [
|
|
1826
|
+
_("div", ra, [
|
|
1706
1827
|
v(s, {
|
|
1707
|
-
"model-value":
|
|
1828
|
+
"model-value": h(e),
|
|
1708
1829
|
"onUpdate:modelValue": g[0] || (g[0] = (l) => B(e) ? e.value = l : null),
|
|
1709
1830
|
class: "mb-6",
|
|
1710
1831
|
vertical: !0,
|
|
1711
1832
|
items: r.value
|
|
1712
1833
|
}, null, 8, ["model-value", "items"])
|
|
1713
1834
|
]),
|
|
1714
|
-
|
|
1715
|
-
|
|
1716
|
-
terminal:
|
|
1717
|
-
onUpdate:
|
|
1835
|
+
_("div", ia, [
|
|
1836
|
+
h(e) ? (y(), I(Y((u = T.value) == null ? void 0 : u.render), L(K({ key: 0 }, {
|
|
1837
|
+
terminal: c.terminal,
|
|
1838
|
+
onUpdate: c.onUpdate
|
|
1718
1839
|
})), null, 16)) : N("", !0)
|
|
1719
1840
|
])
|
|
1720
1841
|
]);
|
|
1721
1842
|
};
|
|
1722
1843
|
}
|
|
1723
|
-
}),
|
|
1844
|
+
}), _a = /* @__PURE__ */ C({
|
|
1724
1845
|
__name: "TerminalSetting",
|
|
1725
1846
|
props: {
|
|
1726
1847
|
terminalId: {
|
|
@@ -1729,14 +1850,14 @@ const le = /* @__PURE__ */ k({
|
|
|
1729
1850
|
}
|
|
1730
1851
|
},
|
|
1731
1852
|
setup(F) {
|
|
1732
|
-
const
|
|
1853
|
+
const c = F, { tab: a } = E({
|
|
1733
1854
|
tab: "information"
|
|
1734
|
-
}), { isLoading:
|
|
1735
|
-
async function
|
|
1855
|
+
}), { isLoading: T, startAsyncCall: n } = H(!0), r = W(), e = Q(), m = b();
|
|
1856
|
+
async function d(t) {
|
|
1736
1857
|
n(async () => {
|
|
1737
1858
|
try {
|
|
1738
1859
|
await A.updateById(
|
|
1739
|
-
|
|
1860
|
+
c.terminalId,
|
|
1740
1861
|
{
|
|
1741
1862
|
name: t.name,
|
|
1742
1863
|
status: t.status,
|
|
@@ -1745,7 +1866,7 @@ const le = /* @__PURE__ */ k({
|
|
|
1745
1866
|
ecrIntegrations: t.ecrIntegrations ?? [],
|
|
1746
1867
|
qrIntegrations: t.qrIntegrations ?? []
|
|
1747
1868
|
}
|
|
1748
|
-
),
|
|
1869
|
+
), m.value = await A.readById(c.terminalId), e.open({
|
|
1749
1870
|
type: "success",
|
|
1750
1871
|
message: "Terminal updated successfully"
|
|
1751
1872
|
});
|
|
@@ -1782,49 +1903,49 @@ const le = /* @__PURE__ */ k({
|
|
|
1782
1903
|
label: "ECR Gateway",
|
|
1783
1904
|
value: "ecr",
|
|
1784
1905
|
icon: "point_of_sale",
|
|
1785
|
-
render:
|
|
1906
|
+
render: la,
|
|
1786
1907
|
onlyFor: ["POS", "KIOSK"]
|
|
1787
1908
|
},
|
|
1788
1909
|
{
|
|
1789
1910
|
label: "QR Gateway",
|
|
1790
1911
|
value: "qr",
|
|
1791
1912
|
icon: "qr_code",
|
|
1792
|
-
render:
|
|
1913
|
+
render: ua,
|
|
1793
1914
|
onlyFor: ["POS", "KIOSK"]
|
|
1794
1915
|
}
|
|
1795
1916
|
];
|
|
1796
1917
|
j().currentCountry;
|
|
1797
|
-
const s =
|
|
1918
|
+
const s = P(() => {
|
|
1798
1919
|
var t;
|
|
1799
1920
|
return (t = g.find((i) => i.value === a.value)) == null ? void 0 : t.render;
|
|
1800
1921
|
});
|
|
1801
1922
|
async function u() {
|
|
1802
1923
|
n(async () => {
|
|
1803
|
-
|
|
1924
|
+
m.value = await A.readById(c.terminalId);
|
|
1804
1925
|
});
|
|
1805
1926
|
}
|
|
1806
|
-
const l =
|
|
1927
|
+
const l = P(() => g.filter((t) => {
|
|
1807
1928
|
var i;
|
|
1808
|
-
return !t.onlyFor || t.onlyFor.includes(((i =
|
|
1929
|
+
return !t.onlyFor || t.onlyFor.includes(((i = m.value) == null ? void 0 : i.deviceType) ?? "");
|
|
1809
1930
|
}));
|
|
1810
|
-
return
|
|
1931
|
+
return S(u), (t, i) => {
|
|
1811
1932
|
var x, o;
|
|
1812
|
-
const
|
|
1813
|
-
return y(),
|
|
1814
|
-
title: `${(x =
|
|
1815
|
-
loading:
|
|
1816
|
-
onBack:
|
|
1933
|
+
const p = f("FmTabs");
|
|
1934
|
+
return y(), I(X, {
|
|
1935
|
+
title: `${(x = m.value) == null ? void 0 : x.deviceType} (${(o = m.value) == null ? void 0 : o._id})`,
|
|
1936
|
+
loading: h(T),
|
|
1937
|
+
onBack: h(r).back
|
|
1817
1938
|
}, {
|
|
1818
|
-
default:
|
|
1819
|
-
v(
|
|
1820
|
-
"model-value":
|
|
1939
|
+
default: M(() => [
|
|
1940
|
+
v(p, {
|
|
1941
|
+
"model-value": h(a),
|
|
1821
1942
|
"onUpdate:modelValue": i[0] || (i[0] = (w) => B(a) ? a.value = w : null),
|
|
1822
1943
|
class: "mb-6",
|
|
1823
1944
|
items: l.value
|
|
1824
1945
|
}, null, 8, ["model-value", "items"]),
|
|
1825
|
-
|
|
1826
|
-
terminal:
|
|
1827
|
-
onUpdate:
|
|
1946
|
+
h(a) ? (y(), I(Y(s.value), L(K({ key: 0 }, {
|
|
1947
|
+
terminal: m.value,
|
|
1948
|
+
onUpdate: d
|
|
1828
1949
|
})), null, 16)) : N("", !0)
|
|
1829
1950
|
]),
|
|
1830
1951
|
_: 1
|
|
@@ -1833,5 +1954,5 @@ const le = /* @__PURE__ */ k({
|
|
|
1833
1954
|
}
|
|
1834
1955
|
});
|
|
1835
1956
|
export {
|
|
1836
|
-
|
|
1957
|
+
_a as default
|
|
1837
1958
|
};
|