@feedmepos/mf-payment 1.10.1 → 1.10.3
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-Usbgr7kF.js → Actions.vue_vue_type_script_setup_true_lang-DXXEAGNv.js} +1 -1
- package/dist/{AdminBusinessSelector.vue_vue_type_script_setup_true_lang-BL0YSULz.js → AdminBusinessSelector.vue_vue_type_script_setup_true_lang-DtDcZPiM.js} +3 -3
- package/dist/{AdminRestaurantSelector.vue_vue_type_script_setup_true_lang-Dr3ukTqT.js → AdminRestaurantSelector.vue_vue_type_script_setup_true_lang-DzfC4Ydq.js} +2 -2
- package/dist/{Chargeback-R3C9hCdW.js → Chargeback-CeT1Lhsx.js} +5 -5
- package/dist/{DocumentViewer.vue_vue_type_script_setup_true_lang-BA0tliZY.js → DocumentViewer.vue_vue_type_script_setup_true_lang-Anj6Ov3T.js} +1 -1
- package/dist/{ExternalTerminal-Ddh92c0F.js → ExternalTerminal-CVwXtIQi.js} +6 -6
- package/dist/{OnboardForm-CLjI-GP2.js → OnboardForm-CwNYDJWa.js} +479 -464
- package/dist/{OnboardForm-BsGjofaE.js → OnboardForm-DIDPFAwq.js} +6 -6
- package/dist/{OnboardSubmission-BQhzQfe9.js → OnboardSubmission-CMjrVivi.js} +3 -3
- package/dist/{OnboardSubmission-DuQfgTqo.js → OnboardSubmission-DbCS8yrY.js} +6 -6
- package/dist/{PayoutAccount-C5WL89y2.js → PayoutAccount-BQmYnRti.js} +7 -7
- package/dist/{PayoutAccount-CSZugVuH.js → PayoutAccount-DAyjFYUb.js} +5 -5
- package/dist/{PayoutAccountSetting-DQI4lLoZ.js → PayoutAccountSetting-B2GvHok3.js} +722 -715
- package/dist/{Restaurant-qbYHDe7-.js → Restaurant-BQYJBsl7.js} +4 -4
- package/dist/{RestaurantSetting-v8GFyIFz.js → RestaurantSetting-BAGLuDkq.js} +3 -3
- package/dist/{Settlement-BSOG3EUJ.js → Settlement-ChindqhG.js} +4 -4
- package/dist/{Settlement-BlSzZ4WA.js → Settlement-DRAn74x0.js} +3 -3
- package/dist/{SettlementTransactions-B4I5CJw7.js → SettlementTransactions-BQr5WvYC.js} +5 -5
- package/dist/{SettlementTransactions-hKOJ_dvI.js → SettlementTransactions-CIGKFRsD.js} +5 -5
- package/dist/{Status.vue_vue_type_script_setup_true_lang-9owCIn7j.js → Status.vue_vue_type_script_setup_true_lang-D0RTxbYt.js} +1 -1
- package/dist/{Terminal-6wkTv7Qg.js → Terminal-ITG71-h5.js} +6 -6
- package/dist/{TerminalSetting-CwuYBf2Q.js → TerminalSetting-DALz7UOI.js} +6 -6
- package/dist/{Transaction-B9J9Jm36.js → Transaction-CMlbLJ40.js} +10 -10
- package/dist/{Transaction-Ba1Yvx6P.js → Transaction-CNczRMks.js} +11 -11
- package/dist/{TransactionOld-Oil317DD.js → TransactionOld-Vc0BxLst.js} +7 -7
- package/dist/{TransactionStatus.vue_vue_type_script_setup_true_lang-COzutx3-.js → TransactionStatus.vue_vue_type_script_setup_true_lang-D0IHQIDw.js} +1 -1
- package/dist/{app-_eJTNh14.js → app-DIXzt9ON.js} +24 -24
- package/dist/app.js +1 -1
- package/dist/{assets-DWG3k-R6.js → assets-D6PvbkZQ.js} +1 -1
- package/dist/{grafana-DU0SqBMy.js → grafana-CIUpjt-p.js} +1 -1
- package/dist/{index-BjGftD0Z.js → index-6ArggUS4.js} +1 -1
- package/dist/{index-CYECWgNT.js → index-BJz6amD9.js} +2 -1
- package/dist/{index-BnAD1CHo.js → index-BtizhJgd.js} +1 -1
- package/dist/{index-CaVNfSJd.js → index-DSTvbZSY.js} +1 -1
- package/dist/{index-BNYl5gy7.js → index-DSzEV9Z2.js} +1 -1
- package/dist/{index-CL1MBNYX.js → index-Dd0_PteU.js} +1 -1
- package/dist/{index-BxLU42iO.js → index-Dhl-wJsD.js} +1 -1
- package/dist/{index-ClxJT-vp.js → index-Gru3oQsi.js} +1 -1
- package/dist/{index-CaRLBdsz.js → index-VP68zTCg.js} +1 -1
- package/dist/{index-D-zfRxxy.js → index-cVqHUVQr.js} +2 -2
- package/dist/{index.vue_vue_type_script_setup_true_lang-Dru_cUnL.js → index.vue_vue_type_script_setup_true_lang-i75zV-qk.js} +1 -1
- package/dist/model/payout-account.d.ts +2 -2
- package/dist/{onboard-submission-_jgECm5X.js → onboard-submission-CaLG3ujz.js} +1 -1
- package/dist/package.json +2 -2
- package/dist/{payout-account-BBgOCiI9.js → payout-account-BuF5FTeH.js} +3 -3
- package/dist/stores/payoutAccount.d.ts +16 -16
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/dist/views/admin/onboard-submission/forms/NTTSubmission.vue.d.ts +12 -12
- package/dist/views/admin/onboard-submission/forms/SoftspaceSubmission.vue.d.ts +12 -12
- package/dist/views/admin/onboard-submission/forms/TyroSubmission.vue.d.ts +12 -12
- package/dist/views/admin/payout-account/tabs/Information.vue.d.ts +16 -16
- package/dist/views/admin/payout-account/tabs/PaymentChannel.vue.d.ts +38 -38
- package/dist/views/admin/payout-account/tabs/PaymentGateway.vue.d.ts +38 -38
- package/dist/views/admin/payout-account/tabs/PaymentStatus.vue.d.ts +16 -16
- package/dist/views/admin/payout-account/tabs/Settlement.vue.d.ts +16 -16
- package/dist/views/admin/payout-account/tabs/TokenGateway.vue.d.ts +38 -38
- package/dist/views/admin/payout-account/tabs/token/ApplePayToken.vue.d.ts +2 -2
- package/dist/views/admin/payout-account/tabs/token/GooglePayToken.vue.d.ts +2 -2
- package/dist/views/admin/settlement/SettlementTable.vue.d.ts +32 -32
- package/dist/views/admin/terminal/TerminalSideSheet.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/PaymentCheckout.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/BeamGateway.vue.d.ts +18 -18
- package/dist/views/admin/terminal/tabs/ecr/BriGateway.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 +18 -18
- package/dist/views/admin/terminal/tabs/ecr/PbbGateway.vue.d.ts +18 -18
- package/dist/views/admin/terminal/tabs/ecr/RevenueGateway.vue.d.ts +18 -18
- 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/dist/views/payout-account/PayoutAccountTable.vue.d.ts +32 -32
- package/dist/views/settlement/FiuuSettlementTable.vue.d.ts +80 -80
- package/dist/views/settlement/FiuuSettlementTransactions.vue.d.ts +40 -40
- package/dist/views/settlement/SettlementTable.vue.d.ts +32 -32
- package/package.json +2 -2
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { defineComponent as Z, ref as
|
|
2
|
-
import { o as H } from "./index-
|
|
3
|
-
import { u as
|
|
4
|
-
import { useRouter as
|
|
1
|
+
import { defineComponent as Z, ref as j, computed as W, resolveComponent as N, openBlock as p, createElementBlock as x, createElementVNode as n, toDisplayString as U, createBlock as A, withCtx as f, createCommentVNode as O, createVNode as o, unref as e, Fragment as J, renderList as _, createTextVNode as z, onMounted as ce, resolveDynamicComponent as ye } from "vue";
|
|
2
|
+
import { o as H } from "./index-cVqHUVQr.js";
|
|
3
|
+
import { u as le, p as re } from "./index-BJz6amD9.js";
|
|
4
|
+
import { useRouter as ge } from "vue-router";
|
|
5
5
|
import { z as u, a as d } from "./validator-CTlVogBQ.js";
|
|
6
|
-
import { P as
|
|
7
|
-
import { a as
|
|
8
|
-
import { _ as
|
|
9
|
-
import { s as
|
|
10
|
-
import { _ as
|
|
11
|
-
import { useSnackbar as
|
|
6
|
+
import { P as ve } from "./payout-account-BuF5FTeH.js";
|
|
7
|
+
import { a as Ve } from "./onboard-submission-CaLG3ujz.js";
|
|
8
|
+
import { _ as ie } from "./DocumentViewer.vue_vue_type_script_setup_true_lang-Anj6Ov3T.js";
|
|
9
|
+
import { s as fe } from "./vue-signature-pad.esm-IXPjf4fL.js";
|
|
10
|
+
import { _ as ue } from "./Status.vue_vue_type_script_setup_true_lang-D0RTxbYt.js";
|
|
11
|
+
import { useSnackbar as se } from "@feedmepos/ui-library";
|
|
12
12
|
import { u as Q } from "./error-K1CakhA9.js";
|
|
13
|
-
const
|
|
13
|
+
const ke = ["src"], P = /* @__PURE__ */ Z({
|
|
14
14
|
__name: "UploadButton",
|
|
15
15
|
props: {
|
|
16
16
|
modelValue: {},
|
|
@@ -19,53 +19,53 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
19
19
|
restaurantId: {}
|
|
20
20
|
},
|
|
21
21
|
emits: ["update:modelValue"],
|
|
22
|
-
setup(m, { emit:
|
|
23
|
-
const
|
|
22
|
+
setup(m, { emit: L }) {
|
|
23
|
+
const V = m, k = j(V.modelValue), g = L, q = (a) => {
|
|
24
24
|
const i = new FileReader();
|
|
25
|
-
i.onload = (
|
|
26
|
-
var
|
|
27
|
-
k.value = (
|
|
25
|
+
i.onload = (I) => {
|
|
26
|
+
var v;
|
|
27
|
+
k.value = (v = I.target) == null ? void 0 : v.result, g("update:modelValue", a);
|
|
28
28
|
}, i.readAsDataURL(a);
|
|
29
29
|
}, c = (a) => {
|
|
30
30
|
window.open(a, "_blank", "noopener,noreferrer");
|
|
31
|
-
},
|
|
31
|
+
}, T = W(() => V.type === "image" ? ".png, .jpg, .jpeg" : ".pdf");
|
|
32
32
|
return (a, i) => {
|
|
33
|
-
const
|
|
34
|
-
return
|
|
33
|
+
const I = N("FmButton"), v = N("FmDropField");
|
|
34
|
+
return p(), x("div", null, [
|
|
35
35
|
n("p", null, U(m.label), 1),
|
|
36
|
-
k.value ? (
|
|
36
|
+
k.value ? (p(), A(ie, {
|
|
37
37
|
key: 0,
|
|
38
38
|
document: k.value,
|
|
39
39
|
"restaurant-id": m.restaurantId
|
|
40
40
|
}, {
|
|
41
|
-
default: f(({ src:
|
|
42
|
-
m.type === "image" ? (
|
|
41
|
+
default: f(({ src: D }) => [
|
|
42
|
+
m.type === "image" ? (p(), x("img", {
|
|
43
43
|
key: 0,
|
|
44
|
-
src:
|
|
45
|
-
}, null, 8,
|
|
46
|
-
m.type === "pdf" ? (
|
|
44
|
+
src: D
|
|
45
|
+
}, null, 8, ke)) : O("", !0),
|
|
46
|
+
m.type === "pdf" ? (p(), A(I, {
|
|
47
47
|
key: 1,
|
|
48
48
|
class: "mt-4 w-full",
|
|
49
49
|
"prepend-icon": "manage_accounts",
|
|
50
50
|
label: "View Document",
|
|
51
51
|
variant: "primary",
|
|
52
|
-
onVnodeMounted: () => c(
|
|
53
|
-
onClick: () => c(
|
|
54
|
-
}, null, 8, ["onVnodeMounted", "onClick"])) :
|
|
52
|
+
onVnodeMounted: () => c(D),
|
|
53
|
+
onClick: () => c(D)
|
|
54
|
+
}, null, 8, ["onVnodeMounted", "onClick"])) : O("", !0)
|
|
55
55
|
]),
|
|
56
56
|
_: 1
|
|
57
|
-
}, 8, ["document", "restaurant-id"])) : (
|
|
57
|
+
}, 8, ["document", "restaurant-id"])) : (p(), A(v, {
|
|
58
58
|
key: 1,
|
|
59
|
-
accept:
|
|
60
|
-
onFileUpload:
|
|
59
|
+
accept: T.value,
|
|
60
|
+
onFileUpload: q
|
|
61
61
|
}, null, 8, ["accept"]))
|
|
62
62
|
]);
|
|
63
63
|
};
|
|
64
64
|
}
|
|
65
|
-
}),
|
|
65
|
+
}), Ce = ["src"], Ne = {
|
|
66
66
|
key: 0,
|
|
67
67
|
class: "text-center text-red-700 py-4"
|
|
68
|
-
},
|
|
68
|
+
}, Se = { class: "flex justify-evenly py-3" }, we = /* @__PURE__ */ Z({
|
|
69
69
|
__name: "SignatureBoard",
|
|
70
70
|
props: {
|
|
71
71
|
modelValue: {},
|
|
@@ -73,73 +73,73 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
73
73
|
restaurantId: {}
|
|
74
74
|
},
|
|
75
75
|
emits: ["update:modelValue"],
|
|
76
|
-
setup(m, { emit:
|
|
77
|
-
const
|
|
78
|
-
function a(
|
|
79
|
-
var
|
|
80
|
-
const
|
|
81
|
-
let
|
|
82
|
-
const
|
|
83
|
-
for (;
|
|
84
|
-
|
|
85
|
-
return new File([
|
|
76
|
+
setup(m, { emit: L }) {
|
|
77
|
+
const V = m, k = L, g = j(V.modelValue), q = j(!1), c = j(), T = j(!1);
|
|
78
|
+
function a(I, v) {
|
|
79
|
+
var B;
|
|
80
|
+
const D = I.split(","), E = ((B = D[0].match(/:(.*?);/)) == null ? void 0 : B[1]) || "", F = atob(D[1]);
|
|
81
|
+
let R = F.length;
|
|
82
|
+
const b = new Uint8Array(R);
|
|
83
|
+
for (; R--; )
|
|
84
|
+
b[R] = F.charCodeAt(R);
|
|
85
|
+
return new File([b], v, { type: E });
|
|
86
86
|
}
|
|
87
87
|
const i = function() {
|
|
88
|
-
const { isEmpty:
|
|
89
|
-
if (
|
|
90
|
-
return
|
|
91
|
-
g.value =
|
|
88
|
+
const { isEmpty: I, data: v } = c.value.saveSignature();
|
|
89
|
+
if (I)
|
|
90
|
+
return q.value = !0;
|
|
91
|
+
g.value = v, T.value = !1, k("update:modelValue", a(v, "signature.png"));
|
|
92
92
|
};
|
|
93
|
-
return (
|
|
94
|
-
const
|
|
95
|
-
return
|
|
93
|
+
return (I, v) => {
|
|
94
|
+
const D = N("FmButton"), E = N("FmDialog");
|
|
95
|
+
return p(), x("div", null, [
|
|
96
96
|
n("p", null, U(m.label), 1),
|
|
97
|
-
g.value ? (
|
|
97
|
+
g.value ? (p(), A(ie, {
|
|
98
98
|
key: 0,
|
|
99
99
|
document: g.value,
|
|
100
100
|
"restaurant-id": m.restaurantId
|
|
101
101
|
}, {
|
|
102
|
-
default: f(({ src:
|
|
102
|
+
default: f(({ src: F }) => [
|
|
103
103
|
n("img", {
|
|
104
|
-
src:
|
|
104
|
+
src: F,
|
|
105
105
|
alt: "Signature Preview",
|
|
106
106
|
class: "w-full h-auto"
|
|
107
|
-
}, null, 8,
|
|
107
|
+
}, null, 8, Ce)
|
|
108
108
|
]),
|
|
109
109
|
_: 1
|
|
110
|
-
}, 8, ["document", "restaurant-id"])) :
|
|
111
|
-
g.value ?
|
|
110
|
+
}, 8, ["document", "restaurant-id"])) : O("", !0),
|
|
111
|
+
g.value ? O("", !0) : (p(), A(E, {
|
|
112
112
|
key: 1,
|
|
113
|
-
modelValue:
|
|
114
|
-
"onUpdate:modelValue":
|
|
113
|
+
modelValue: T.value,
|
|
114
|
+
"onUpdate:modelValue": v[1] || (v[1] = (F) => T.value = F)
|
|
115
115
|
}, {
|
|
116
116
|
"dialog-button": f(() => [
|
|
117
|
-
|
|
117
|
+
o(D, {
|
|
118
118
|
"prepend-icon": "signature",
|
|
119
119
|
class: "w-full",
|
|
120
120
|
label: "Signature"
|
|
121
121
|
})
|
|
122
122
|
]),
|
|
123
|
-
"dialog-header": f(() => [...
|
|
123
|
+
"dialog-header": f(() => [...v[2] || (v[2] = [
|
|
124
124
|
n("div", null, "Signature Board", -1)
|
|
125
125
|
])]),
|
|
126
126
|
default: f(() => [
|
|
127
|
-
|
|
127
|
+
o(e(fe), {
|
|
128
128
|
ref_key: "signaturePad",
|
|
129
129
|
ref: c,
|
|
130
130
|
height: "300px",
|
|
131
131
|
customStyle: { border: "2px solid #ccc", borderRadius: "3px" },
|
|
132
132
|
options: { penColor: "#000000" }
|
|
133
133
|
}, null, 512),
|
|
134
|
-
|
|
135
|
-
n("div",
|
|
136
|
-
|
|
134
|
+
q.value ? (p(), x("p", Ne, " Please sign your signature before saving. ")) : O("", !0),
|
|
135
|
+
n("div", Se, [
|
|
136
|
+
o(D, {
|
|
137
137
|
variant: "destructive",
|
|
138
138
|
label: "Clear",
|
|
139
139
|
"prepend-icon": "delete",
|
|
140
|
-
onClick:
|
|
140
|
+
onClick: v[0] || (v[0] = (F) => c.value.clearSignature())
|
|
141
141
|
}),
|
|
142
|
-
|
|
142
|
+
o(D, {
|
|
143
143
|
label: "Save",
|
|
144
144
|
"prepend-icon": "save",
|
|
145
145
|
onClick: i
|
|
@@ -151,13 +151,13 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
151
151
|
]);
|
|
152
152
|
};
|
|
153
153
|
}
|
|
154
|
-
}),
|
|
154
|
+
}), qe = { class: "space-y-2" }, Fe = { class: "text-gray-900" }, Pe = { class: "text-gray-900" }, xe = { class: "text-gray-900" }, Ue = { class: "text-gray-900" }, Ie = { class: "text-gray-900" }, De = { class: "text-gray-900" }, Re = { class: "grid grid-cols-4 gap-6" }, Te = ["src"], Be = {
|
|
155
155
|
key: 1,
|
|
156
156
|
class: "mt-2 truncate text-gray-700"
|
|
157
|
-
},
|
|
157
|
+
}, Ae = { key: 0 }, Ee = {
|
|
158
158
|
key: 0,
|
|
159
159
|
class: "w-full flex justify-end mt-6"
|
|
160
|
-
},
|
|
160
|
+
}, $e = { class: "mt-6 grid grid-cols-4 gap-24" }, je = { class: "grid grid-cols-4 gap-6" }, Oe = { class: "w-full flex justify-end mt-6" }, Le = { class: "mt-6 grid grid-cols-4 gap-24" }, Me = { class: "col-span-2" }, He = { class: "col-span-2" }, ze = { class: "col-span-2" }, We = { class: "col-span-2" }, Je = { class: "col-span-2" }, Qe = { class: "col-span-2" }, Ke = { class: "col-span-2" }, Ge = { class: "col-start-1 col-span-2" }, Ye = { class: "col-span-2" }, Xe = { class: "col-span-2" }, Ze = { class: "col-span-2" }, he = { class: "mt-6 grid grid-cols-4 gap-6" }, _e = { class: "mt-6 grid grid-cols-2 gap-24" }, oe = 30, el = /* @__PURE__ */ Z({
|
|
161
161
|
__name: "SoftspaceSubmission",
|
|
162
162
|
props: {
|
|
163
163
|
submission: {
|
|
@@ -166,10 +166,13 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
166
166
|
}
|
|
167
167
|
},
|
|
168
168
|
emits: ["update:submission"],
|
|
169
|
-
setup(m, { emit:
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
169
|
+
setup(m, { emit: L }) {
|
|
170
|
+
var ee;
|
|
171
|
+
const V = m, k = L, g = se(), q = j(!1), { isLoading: c, startAsyncCall: T } = le(), { fields: a, documents: i, restaurantId: I, profile: v, status: D, statusReason: E } = V.submission, F = j(""), R = j(
|
|
172
|
+
parseInt(((ee = V.submission.fields) == null ? void 0 : ee.numberOfDevices) ?? 1)
|
|
173
|
+
), b = j(
|
|
174
|
+
V.submission.rates ? Object.fromEntries(
|
|
175
|
+
Object.entries(V.submission.rates).map(([y, l]) => [y, `${l}`])
|
|
173
176
|
) : {
|
|
174
177
|
duitNow: "0.8",
|
|
175
178
|
mydebitCard: "0.5",
|
|
@@ -179,46 +182,46 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
179
182
|
jcbStandard: "2.2",
|
|
180
183
|
jcbPlatinum: "2.2"
|
|
181
184
|
}
|
|
182
|
-
),
|
|
183
|
-
() => Object.values(
|
|
184
|
-
), { isLoading:
|
|
185
|
-
() => Object.keys(
|
|
186
|
-
),
|
|
187
|
-
() =>
|
|
188
|
-
),
|
|
189
|
-
if (!(
|
|
185
|
+
), B = W(
|
|
186
|
+
() => Object.values(b.value).every((y) => parseFloat(y) > 0)
|
|
187
|
+
), { isLoading: G, startAsyncCall: te } = le(), M = j([]), h = (y) => Number(y.replace("additionalDocument", "")), Y = W(
|
|
188
|
+
() => Object.keys(V.submission.documents).filter((y) => /^additionalDocument\d+$/.test(y)).sort((y, l) => h(y) - h(l))
|
|
189
|
+
), C = W(
|
|
190
|
+
() => Y.value.length + M.value.length
|
|
191
|
+
), s = (y) => {
|
|
192
|
+
if (!(C.value >= oe)) {
|
|
190
193
|
if (y.type.startsWith("image/")) {
|
|
191
194
|
const l = new FileReader();
|
|
192
|
-
l.onload = (
|
|
193
|
-
var
|
|
195
|
+
l.onload = (r) => {
|
|
196
|
+
var $;
|
|
194
197
|
return M.value.push({
|
|
195
198
|
file: y,
|
|
196
|
-
preview: String(((
|
|
199
|
+
preview: String((($ = r.target) == null ? void 0 : $.result) ?? "")
|
|
197
200
|
});
|
|
198
201
|
}, l.readAsDataURL(y);
|
|
199
202
|
return;
|
|
200
203
|
}
|
|
201
204
|
M.value.push({ file: y, preview: "" });
|
|
202
205
|
}
|
|
203
|
-
},
|
|
206
|
+
}, S = () => te(async () => {
|
|
204
207
|
try {
|
|
205
|
-
let y =
|
|
206
|
-
(
|
|
208
|
+
let y = Y.value.reduce(
|
|
209
|
+
(r, $) => Math.max(r, h($)),
|
|
207
210
|
0
|
|
208
211
|
);
|
|
209
212
|
const l = {};
|
|
210
|
-
for (const { file:
|
|
211
|
-
const
|
|
212
|
-
l[
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
213
|
+
for (const { file: r } of M.value) {
|
|
214
|
+
const $ = `additionalDocument${++y}`;
|
|
215
|
+
l[$] = await H.uploadDocument(
|
|
216
|
+
I,
|
|
217
|
+
$,
|
|
218
|
+
r
|
|
216
219
|
);
|
|
217
220
|
}
|
|
218
221
|
k(
|
|
219
222
|
"update:submission",
|
|
220
223
|
await H.addAdditionalDocuments(
|
|
221
|
-
|
|
224
|
+
V.submission._id,
|
|
222
225
|
l
|
|
223
226
|
)
|
|
224
227
|
), M.value = [], g.open({ type: "success", title: "Documents saved" });
|
|
@@ -229,24 +232,25 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
229
232
|
message: Q(y)
|
|
230
233
|
});
|
|
231
234
|
}
|
|
232
|
-
}),
|
|
235
|
+
}), X = () => T(async () => {
|
|
233
236
|
try {
|
|
234
237
|
const y = await H.reviewById(
|
|
235
|
-
|
|
238
|
+
V.submission._id,
|
|
236
239
|
{
|
|
240
|
+
numberOfDevices: R.value.toString(),
|
|
237
241
|
rates: {
|
|
238
|
-
duitNow: parseFloat(
|
|
239
|
-
mydebitCard: parseFloat(
|
|
240
|
-
localDebit: parseFloat(
|
|
241
|
-
localCredit: parseFloat(
|
|
242
|
-
foreignCard: parseFloat(
|
|
243
|
-
jcbStandard: parseFloat(
|
|
244
|
-
jcbPlatinum: parseFloat(
|
|
242
|
+
duitNow: parseFloat(b.value.duitNow),
|
|
243
|
+
mydebitCard: parseFloat(b.value.mydebitCard),
|
|
244
|
+
localDebit: parseFloat(b.value.localDebit),
|
|
245
|
+
localCredit: parseFloat(b.value.localCredit),
|
|
246
|
+
foreignCard: parseFloat(b.value.foreignCard),
|
|
247
|
+
jcbStandard: parseFloat(b.value.jcbStandard),
|
|
248
|
+
jcbPlatinum: parseFloat(b.value.jcbPlatinum)
|
|
245
249
|
},
|
|
246
250
|
status: "approved"
|
|
247
251
|
}
|
|
248
252
|
);
|
|
249
|
-
k("update:submission", y),
|
|
253
|
+
k("update:submission", y), q.value = !1, g.open({
|
|
250
254
|
type: "success",
|
|
251
255
|
title: "Submission updated successfully"
|
|
252
256
|
});
|
|
@@ -257,16 +261,16 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
257
261
|
message: Q(y)
|
|
258
262
|
});
|
|
259
263
|
}
|
|
260
|
-
}),
|
|
264
|
+
}), ae = () => T(async () => {
|
|
261
265
|
try {
|
|
262
266
|
const y = await H.reviewById(
|
|
263
|
-
|
|
267
|
+
V.submission._id,
|
|
264
268
|
{
|
|
265
269
|
status: "rejected",
|
|
266
|
-
statusReason:
|
|
270
|
+
statusReason: F.value
|
|
267
271
|
}
|
|
268
272
|
);
|
|
269
|
-
k("update:submission", y),
|
|
273
|
+
k("update:submission", y), q.value = !1, g.open({
|
|
270
274
|
type: "success",
|
|
271
275
|
title: "Submission updated successfully"
|
|
272
276
|
});
|
|
@@ -279,86 +283,86 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
279
283
|
}
|
|
280
284
|
});
|
|
281
285
|
return (y, l) => {
|
|
282
|
-
const
|
|
283
|
-
return
|
|
284
|
-
n("div",
|
|
286
|
+
const r = N("FmButton"), $ = N("FmDropField"), w = N("FmTextField"), de = N("FmTextarea"), me = N("FmDialog"), pe = N("FmPhoneNumber"), ne = N("FmSelect"), be = N("FmForm");
|
|
287
|
+
return p(), x(J, null, [
|
|
288
|
+
n("div", qe, [
|
|
285
289
|
n("div", null, [
|
|
286
|
-
l[
|
|
287
|
-
n("span",
|
|
290
|
+
l[35] || (l[35] = n("span", { class: "w-40 font-medium text-gray-600" }, "Restaurant: ", -1)),
|
|
291
|
+
n("span", Fe, U(e(I)), 1)
|
|
288
292
|
]),
|
|
289
293
|
n("div", null, [
|
|
290
|
-
l[
|
|
291
|
-
n("span",
|
|
294
|
+
l[36] || (l[36] = n("span", { class: "w-40 font-medium text-gray-600" }, "Profile: ", -1)),
|
|
295
|
+
n("span", Pe, U(e(v).name) + " ( " + U(e(v).legalName) + " )", 1)
|
|
292
296
|
]),
|
|
293
297
|
n("div", null, [
|
|
294
|
-
l[
|
|
295
|
-
n("span",
|
|
298
|
+
l[37] || (l[37] = n("span", { class: "w-40 font-medium text-gray-600" }, "Email: ", -1)),
|
|
299
|
+
n("span", xe, U(e(v).email), 1)
|
|
296
300
|
]),
|
|
297
301
|
n("div", null, [
|
|
298
|
-
l[
|
|
299
|
-
n("span",
|
|
302
|
+
l[38] || (l[38] = n("span", { class: "w-40 font-medium text-gray-600" }, "Phone: ", -1)),
|
|
303
|
+
n("span", Ue, U(e(v).phoneNo), 1)
|
|
300
304
|
]),
|
|
301
305
|
n("div", null, [
|
|
302
|
-
l[
|
|
303
|
-
n("span",
|
|
304
|
-
|
|
306
|
+
l[39] || (l[39] = n("span", { class: "w-40 font-medium text-gray-600" }, "Status: ", -1)),
|
|
307
|
+
n("span", Ie, [
|
|
308
|
+
o(ue, { data: e(D) }, null, 8, ["data"])
|
|
305
309
|
])
|
|
306
310
|
]),
|
|
307
311
|
n("div", null, [
|
|
308
|
-
l[
|
|
309
|
-
n("span",
|
|
312
|
+
l[40] || (l[40] = n("span", { class: "w-40 font-medium text-gray-600" }, "Status Reason: ", -1)),
|
|
313
|
+
n("span", De, U(e(E)), 1)
|
|
310
314
|
])
|
|
311
315
|
]),
|
|
312
|
-
l[
|
|
313
|
-
n("div",
|
|
314
|
-
(
|
|
316
|
+
l[52] || (l[52] = n("h3", { class: "font-semibold text-lg border-b pb-1 mt-6 mb-4" }, " Additional Documents ", -1)),
|
|
317
|
+
n("div", Re, [
|
|
318
|
+
(p(!0), x(J, null, _(Y.value, (t) => (p(), A(P, {
|
|
315
319
|
key: t,
|
|
316
320
|
label: t.replace("additionalDocument", "Document "),
|
|
317
|
-
type: /\.pdf$/i.test(
|
|
318
|
-
modelValue:
|
|
319
|
-
"onUpdate:modelValue": (
|
|
320
|
-
"restaurant-id": e(
|
|
321
|
+
type: /\.pdf$/i.test(V.submission.documents[t]) ? "pdf" : "image",
|
|
322
|
+
modelValue: V.submission.documents[t],
|
|
323
|
+
"onUpdate:modelValue": (K) => V.submission.documents[t] = K,
|
|
324
|
+
"restaurant-id": e(I)
|
|
321
325
|
}, null, 8, ["label", "type", "modelValue", "onUpdate:modelValue", "restaurant-id"]))), 128)),
|
|
322
|
-
(
|
|
323
|
-
key: `new-${
|
|
326
|
+
(p(!0), x(J, null, _(M.value, (t, K) => (p(), x("div", {
|
|
327
|
+
key: `new-${K}`
|
|
324
328
|
}, [
|
|
325
|
-
n("p", null, "Document " + U(
|
|
326
|
-
t.file.type.startsWith("image/") ? (
|
|
329
|
+
n("p", null, "Document " + U(Y.value.length + K + 1), 1),
|
|
330
|
+
t.file.type.startsWith("image/") ? (p(), x("img", {
|
|
327
331
|
key: 0,
|
|
328
332
|
src: t.preview,
|
|
329
333
|
class: "mt-2 rounded border"
|
|
330
|
-
}, null, 8,
|
|
331
|
-
r
|
|
334
|
+
}, null, 8, Te)) : (p(), x("p", Be, U(t.file.name), 1)),
|
|
335
|
+
o(r, {
|
|
332
336
|
class: "mt-4",
|
|
333
337
|
"prepend-icon": "delete",
|
|
334
338
|
label: "Remove",
|
|
335
339
|
variant: "destructive",
|
|
336
|
-
onClick: (
|
|
340
|
+
onClick: (xl) => M.value.splice(K, 1)
|
|
337
341
|
}, null, 8, ["onClick"])
|
|
338
342
|
]))), 128)),
|
|
339
|
-
|
|
340
|
-
n("p", null, "Document " + U(
|
|
341
|
-
|
|
343
|
+
C.value < oe ? (p(), x("div", Ae, [
|
|
344
|
+
n("p", null, "Document " + U(C.value + 1), 1),
|
|
345
|
+
o($, {
|
|
342
346
|
accept: ".png, .jpg, .jpeg, .pdf",
|
|
343
|
-
onFileUpload:
|
|
347
|
+
onFileUpload: s
|
|
344
348
|
})
|
|
345
|
-
])) :
|
|
349
|
+
])) : O("", !0)
|
|
346
350
|
]),
|
|
347
|
-
M.value.length ? (
|
|
348
|
-
r
|
|
351
|
+
M.value.length ? (p(), x("div", Ee, [
|
|
352
|
+
o(r, {
|
|
349
353
|
type: "button",
|
|
350
354
|
variant: "primary",
|
|
351
355
|
"prepend-icon": "cloud_upload",
|
|
352
356
|
label: "Save documents",
|
|
353
|
-
loading: e(
|
|
354
|
-
onClick:
|
|
357
|
+
loading: e(G),
|
|
358
|
+
onClick: S
|
|
355
359
|
}, null, 8, ["loading"])
|
|
356
|
-
])) :
|
|
357
|
-
l[
|
|
358
|
-
n("div",
|
|
359
|
-
|
|
360
|
-
modelValue:
|
|
361
|
-
"onUpdate:modelValue": l[0] || (l[0] = (t) =>
|
|
360
|
+
])) : O("", !0),
|
|
361
|
+
l[53] || (l[53] = n("h3", { class: "font-semibold text-lg border-b pb-1 mt-6 mb-4" }, "Rate Settings", -1)),
|
|
362
|
+
n("div", $e, [
|
|
363
|
+
o(w, {
|
|
364
|
+
modelValue: b.value.duitNow,
|
|
365
|
+
"onUpdate:modelValue": l[0] || (l[0] = (t) => b.value.duitNow = t),
|
|
362
366
|
label: "DuitNow QR",
|
|
363
367
|
"label-mark": "required",
|
|
364
368
|
type: "number",
|
|
@@ -368,14 +372,14 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
368
372
|
e(d).string().min(1, "Rate is required").transform((t) => parseFloat(t)).refine((t) => !isNaN(t), { message: "Rate must be a number" })
|
|
369
373
|
)
|
|
370
374
|
}, {
|
|
371
|
-
append: f(() => [...l[
|
|
375
|
+
append: f(() => [...l[41] || (l[41] = [
|
|
372
376
|
z("%", -1)
|
|
373
377
|
])]),
|
|
374
378
|
_: 1
|
|
375
379
|
}, 8, ["modelValue", "rules"]),
|
|
376
|
-
|
|
377
|
-
modelValue:
|
|
378
|
-
"onUpdate:modelValue": l[1] || (l[1] = (t) =>
|
|
380
|
+
o(w, {
|
|
381
|
+
modelValue: b.value.mydebitCard,
|
|
382
|
+
"onUpdate:modelValue": l[1] || (l[1] = (t) => b.value.mydebitCard = t),
|
|
379
383
|
label: "myDebit Card",
|
|
380
384
|
"label-mark": "required",
|
|
381
385
|
type: "number",
|
|
@@ -385,14 +389,14 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
385
389
|
e(d).string().min(1, "Rate is required").transform((t) => parseFloat(t)).refine((t) => !isNaN(t), { message: "Rate must be a number" })
|
|
386
390
|
)
|
|
387
391
|
}, {
|
|
388
|
-
append: f(() => [...l[
|
|
392
|
+
append: f(() => [...l[42] || (l[42] = [
|
|
389
393
|
z("%", -1)
|
|
390
394
|
])]),
|
|
391
395
|
_: 1
|
|
392
396
|
}, 8, ["modelValue", "rules"]),
|
|
393
|
-
|
|
394
|
-
modelValue:
|
|
395
|
-
"onUpdate:modelValue": l[2] || (l[2] = (t) =>
|
|
397
|
+
o(w, {
|
|
398
|
+
modelValue: b.value.localDebit,
|
|
399
|
+
"onUpdate:modelValue": l[2] || (l[2] = (t) => b.value.localDebit = t),
|
|
396
400
|
label: "Local Debit Card",
|
|
397
401
|
"label-mark": "required",
|
|
398
402
|
type: "number",
|
|
@@ -402,14 +406,14 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
402
406
|
e(d).string().min(1, "Rate is required").transform((t) => parseFloat(t)).refine((t) => !isNaN(t), { message: "Rate must be a number" })
|
|
403
407
|
)
|
|
404
408
|
}, {
|
|
405
|
-
append: f(() => [...l[
|
|
409
|
+
append: f(() => [...l[43] || (l[43] = [
|
|
406
410
|
z("%", -1)
|
|
407
411
|
])]),
|
|
408
412
|
_: 1
|
|
409
413
|
}, 8, ["modelValue", "rules"]),
|
|
410
|
-
|
|
411
|
-
modelValue:
|
|
412
|
-
"onUpdate:modelValue": l[3] || (l[3] = (t) =>
|
|
414
|
+
o(w, {
|
|
415
|
+
modelValue: b.value.localCredit,
|
|
416
|
+
"onUpdate:modelValue": l[3] || (l[3] = (t) => b.value.localCredit = t),
|
|
413
417
|
label: "Local Credit Card",
|
|
414
418
|
"label-mark": "required",
|
|
415
419
|
type: "number",
|
|
@@ -419,14 +423,14 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
419
423
|
e(d).string().min(1, "Rate is required").transform((t) => parseFloat(t)).refine((t) => !isNaN(t), { message: "Rate must be a number" })
|
|
420
424
|
)
|
|
421
425
|
}, {
|
|
422
|
-
append: f(() => [...l[
|
|
426
|
+
append: f(() => [...l[44] || (l[44] = [
|
|
423
427
|
z("%", -1)
|
|
424
428
|
])]),
|
|
425
429
|
_: 1
|
|
426
430
|
}, 8, ["modelValue", "rules"]),
|
|
427
|
-
|
|
428
|
-
modelValue:
|
|
429
|
-
"onUpdate:modelValue": l[4] || (l[4] = (t) =>
|
|
431
|
+
o(w, {
|
|
432
|
+
modelValue: b.value.foreignCard,
|
|
433
|
+
"onUpdate:modelValue": l[4] || (l[4] = (t) => b.value.foreignCard = t),
|
|
430
434
|
label: "Foreign Card",
|
|
431
435
|
"label-mark": "required",
|
|
432
436
|
type: "number",
|
|
@@ -436,14 +440,14 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
436
440
|
e(d).string().min(1, "Rate is required").transform((t) => parseFloat(t)).refine((t) => !isNaN(t), { message: "Rate must be a number" })
|
|
437
441
|
)
|
|
438
442
|
}, {
|
|
439
|
-
append: f(() => [...l[
|
|
443
|
+
append: f(() => [...l[45] || (l[45] = [
|
|
440
444
|
z("%", -1)
|
|
441
445
|
])]),
|
|
442
446
|
_: 1
|
|
443
447
|
}, 8, ["modelValue", "rules"]),
|
|
444
|
-
|
|
445
|
-
modelValue:
|
|
446
|
-
"onUpdate:modelValue": l[5] || (l[5] = (t) =>
|
|
448
|
+
o(w, {
|
|
449
|
+
modelValue: b.value.jcbStandard,
|
|
450
|
+
"onUpdate:modelValue": l[5] || (l[5] = (t) => b.value.jcbStandard = t),
|
|
447
451
|
label: "JCB Standard",
|
|
448
452
|
"label-mark": "required",
|
|
449
453
|
type: "number",
|
|
@@ -453,14 +457,14 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
453
457
|
e(d).string().min(1, "Rate is required").transform((t) => parseFloat(t)).refine((t) => !isNaN(t), { message: "Rate must be a number" })
|
|
454
458
|
)
|
|
455
459
|
}, {
|
|
456
|
-
append: f(() => [...l[
|
|
460
|
+
append: f(() => [...l[46] || (l[46] = [
|
|
457
461
|
z("%", -1)
|
|
458
462
|
])]),
|
|
459
463
|
_: 1
|
|
460
464
|
}, 8, ["modelValue", "rules"]),
|
|
461
|
-
|
|
462
|
-
modelValue:
|
|
463
|
-
"onUpdate:modelValue": l[6] || (l[6] = (t) =>
|
|
465
|
+
o(w, {
|
|
466
|
+
modelValue: b.value.jcbPlatinum,
|
|
467
|
+
"onUpdate:modelValue": l[6] || (l[6] = (t) => b.value.jcbPlatinum = t),
|
|
464
468
|
label: "JCB Platinum",
|
|
465
469
|
"label-mark": "required",
|
|
466
470
|
type: "number",
|
|
@@ -470,19 +474,30 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
470
474
|
e(d).string().min(1, "Rate is required").transform((t) => parseFloat(t)).refine((t) => !isNaN(t), { message: "Rate must be a number" })
|
|
471
475
|
)
|
|
472
476
|
}, {
|
|
473
|
-
append: f(() => [...l[
|
|
477
|
+
append: f(() => [...l[47] || (l[47] = [
|
|
474
478
|
z("%", -1)
|
|
475
479
|
])]),
|
|
476
480
|
_: 1
|
|
477
481
|
}, 8, ["modelValue", "rules"])
|
|
478
482
|
]),
|
|
479
|
-
n("
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
+
l[54] || (l[54] = n("h3", { class: "font-semibold text-lg border-b pb-1 mt-6 mb-4" }, "Extra Settings", -1)),
|
|
484
|
+
n("div", je, [
|
|
485
|
+
o(w, {
|
|
486
|
+
modelValue: R.value,
|
|
487
|
+
"onUpdate:modelValue": l[7] || (l[7] = (t) => R.value = t),
|
|
488
|
+
label: "Number of Devices",
|
|
489
|
+
"label-mark": "required",
|
|
490
|
+
type: "number",
|
|
491
|
+
inputmode: "numeric"
|
|
492
|
+
}, null, 8, ["modelValue"])
|
|
493
|
+
]),
|
|
494
|
+
n("div", Oe, [
|
|
495
|
+
o(me, {
|
|
496
|
+
modelValue: q.value,
|
|
497
|
+
"onUpdate:modelValue": l[9] || (l[9] = (t) => q.value = t)
|
|
483
498
|
}, {
|
|
484
499
|
"dialog-button": f(() => [
|
|
485
|
-
r
|
|
500
|
+
o(r, {
|
|
486
501
|
class: "mr-6",
|
|
487
502
|
type: "button",
|
|
488
503
|
variant: "destructive",
|
|
@@ -491,65 +506,65 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
491
506
|
label: "Reject Submission"
|
|
492
507
|
}, null, 8, ["loading"])
|
|
493
508
|
]),
|
|
494
|
-
"dialog-header": f(() => [...l[
|
|
509
|
+
"dialog-header": f(() => [...l[48] || (l[48] = [
|
|
495
510
|
n("div", null, "Rejecting Submission", -1)
|
|
496
511
|
])]),
|
|
497
512
|
default: f(() => [
|
|
498
|
-
|
|
499
|
-
modelValue:
|
|
500
|
-
"onUpdate:modelValue": l[
|
|
513
|
+
o(de, {
|
|
514
|
+
modelValue: F.value,
|
|
515
|
+
"onUpdate:modelValue": l[8] || (l[8] = (t) => F.value = t),
|
|
501
516
|
label: "Reason for Rejection",
|
|
502
517
|
"label-mark": "optional",
|
|
503
518
|
"helper-text": "Please provide a reason for rejection."
|
|
504
519
|
}, null, 8, ["modelValue"]),
|
|
505
|
-
r
|
|
520
|
+
o(r, {
|
|
506
521
|
class: "mb-2 mt-6 w-full",
|
|
507
522
|
label: "Submit",
|
|
508
523
|
"prepend-icon": "save",
|
|
509
|
-
onClick:
|
|
524
|
+
onClick: ae,
|
|
510
525
|
loading: e(c)
|
|
511
526
|
}, null, 8, ["loading"])
|
|
512
527
|
]),
|
|
513
528
|
_: 1
|
|
514
529
|
}, 8, ["modelValue"]),
|
|
515
|
-
r
|
|
530
|
+
o(r, {
|
|
516
531
|
type: "button",
|
|
517
532
|
variant: "primary",
|
|
518
533
|
"prepend-icon": "approval",
|
|
519
|
-
disabled: !
|
|
534
|
+
disabled: !B.value,
|
|
520
535
|
label: "Approve Submission with Rates",
|
|
521
|
-
onClick:
|
|
536
|
+
onClick: X,
|
|
522
537
|
loading: e(c)
|
|
523
538
|
}, null, 8, ["disabled", "loading"])
|
|
524
539
|
]),
|
|
525
|
-
|
|
540
|
+
o(be, { disabled: !0 }, {
|
|
526
541
|
default: f(() => [
|
|
527
|
-
l[
|
|
528
|
-
n("div",
|
|
529
|
-
n("div",
|
|
530
|
-
|
|
542
|
+
l[49] || (l[49] = n("h3", { class: "font-semibold text-lg border-b pb-1 mt-6 mb-4" }, " Outlet Information ", -1)),
|
|
543
|
+
n("div", Le, [
|
|
544
|
+
n("div", Me, [
|
|
545
|
+
o(w, {
|
|
531
546
|
modelValue: e(a).picName,
|
|
532
|
-
"onUpdate:modelValue": l[
|
|
547
|
+
"onUpdate:modelValue": l[10] || (l[10] = (t) => e(a).picName = t),
|
|
533
548
|
label: "Owner/Director Name",
|
|
534
549
|
placeholder: "Enter your name",
|
|
535
550
|
"label-mark": "required",
|
|
536
551
|
rules: e(u)(e(d).string().min(1, "Owner/Director Name is required"))
|
|
537
552
|
}, null, 8, ["modelValue", "rules"])
|
|
538
553
|
]),
|
|
539
|
-
n("div",
|
|
540
|
-
|
|
554
|
+
n("div", He, [
|
|
555
|
+
o(w, {
|
|
541
556
|
modelValue: e(a).picRole,
|
|
542
|
-
"onUpdate:modelValue": l[
|
|
557
|
+
"onUpdate:modelValue": l[11] || (l[11] = (t) => e(a).picRole = t),
|
|
543
558
|
label: "Owner/Director Role",
|
|
544
559
|
placeholder: "Enter your role",
|
|
545
560
|
"label-mark": "required",
|
|
546
561
|
rules: e(u)(e(d).string().min(1, "Owner/Director Role is required"))
|
|
547
562
|
}, null, 8, ["modelValue", "rules"])
|
|
548
563
|
]),
|
|
549
|
-
n("div",
|
|
550
|
-
|
|
564
|
+
n("div", ze, [
|
|
565
|
+
o(w, {
|
|
551
566
|
modelValue: e(a).picEmail,
|
|
552
|
-
"onUpdate:modelValue": l[
|
|
567
|
+
"onUpdate:modelValue": l[12] || (l[12] = (t) => e(a).picEmail = t),
|
|
553
568
|
label: "Owner/Director Email",
|
|
554
569
|
type: "email",
|
|
555
570
|
placeholder: "Enter your email address",
|
|
@@ -557,74 +572,74 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
557
572
|
rules: e(u)(e(d).string().min(1, "Owner/Director Email is required"))
|
|
558
573
|
}, null, 8, ["modelValue", "rules"])
|
|
559
574
|
]),
|
|
560
|
-
n("div",
|
|
561
|
-
|
|
575
|
+
n("div", We, [
|
|
576
|
+
o(pe, {
|
|
562
577
|
"model-value": e(a).picContact,
|
|
563
|
-
"onUpdate:modelValue": l[
|
|
578
|
+
"onUpdate:modelValue": l[13] || (l[13] = (t) => e(a).picContact = t),
|
|
564
579
|
"default-country": "MY",
|
|
565
580
|
label: "Owner/Director Contact",
|
|
566
581
|
"label-mark": "required",
|
|
567
582
|
rules: e(u)(e(d).string().min(1, "Owner/Director Contact is required"))
|
|
568
583
|
}, null, 8, ["model-value", "rules"])
|
|
569
584
|
]),
|
|
570
|
-
n("div",
|
|
571
|
-
|
|
585
|
+
n("div", Je, [
|
|
586
|
+
o(w, {
|
|
572
587
|
modelValue: e(a).tradingName,
|
|
573
|
-
"onUpdate:modelValue": l[
|
|
588
|
+
"onUpdate:modelValue": l[14] || (l[14] = (t) => e(a).tradingName = t),
|
|
574
589
|
label: "Trading Name",
|
|
575
590
|
placeholder: "Enter trading name",
|
|
576
591
|
"label-mark": "required",
|
|
577
592
|
rules: e(u)(e(d).string().min(1, "Trading Name is required"))
|
|
578
593
|
}, null, 8, ["modelValue", "rules"])
|
|
579
594
|
]),
|
|
580
|
-
n("div",
|
|
581
|
-
|
|
595
|
+
n("div", Qe, [
|
|
596
|
+
o(w, {
|
|
582
597
|
modelValue: e(a).outletName,
|
|
583
|
-
"onUpdate:modelValue": l[
|
|
598
|
+
"onUpdate:modelValue": l[15] || (l[15] = (t) => e(a).outletName = t),
|
|
584
599
|
label: "Registered Name",
|
|
585
600
|
placeholder: "Enter registered name",
|
|
586
601
|
"label-mark": "required",
|
|
587
602
|
rules: e(u)(e(d).string().min(1, "Registered Name is required"))
|
|
588
603
|
}, null, 8, ["modelValue", "rules"])
|
|
589
604
|
]),
|
|
590
|
-
n("div",
|
|
591
|
-
|
|
605
|
+
n("div", Ke, [
|
|
606
|
+
o(w, {
|
|
592
607
|
modelValue: e(a).outletAddress,
|
|
593
|
-
"onUpdate:modelValue": l[
|
|
608
|
+
"onUpdate:modelValue": l[16] || (l[16] = (t) => e(a).outletAddress = t),
|
|
594
609
|
label: "Outlet Address",
|
|
595
610
|
placeholder: "Enter outlet address",
|
|
596
611
|
"label-mark": "required",
|
|
597
612
|
rules: e(u)(e(d).string().min(1, "Address is required"))
|
|
598
613
|
}, null, 8, ["modelValue", "rules"])
|
|
599
614
|
]),
|
|
600
|
-
|
|
615
|
+
o(w, {
|
|
601
616
|
modelValue: e(a).outletPostCode,
|
|
602
|
-
"onUpdate:modelValue": l[
|
|
617
|
+
"onUpdate:modelValue": l[17] || (l[17] = (t) => e(a).outletPostCode = t),
|
|
603
618
|
label: "Postal Code",
|
|
604
619
|
placeholder: "Enter postal code",
|
|
605
620
|
"label-mark": "required",
|
|
606
621
|
rules: e(u)(e(d).string().min(1, "Postal Code is required"))
|
|
607
622
|
}, null, 8, ["modelValue", "rules"]),
|
|
608
|
-
|
|
623
|
+
o(w, {
|
|
609
624
|
modelValue: e(a).outletState,
|
|
610
|
-
"onUpdate:modelValue": l[
|
|
625
|
+
"onUpdate:modelValue": l[18] || (l[18] = (t) => e(a).outletState = t),
|
|
611
626
|
label: "State",
|
|
612
627
|
placeholder: "Enter state",
|
|
613
628
|
"label-mark": "required",
|
|
614
629
|
rules: e(u)(e(d).string().min(1, "State is required"))
|
|
615
630
|
}, null, 8, ["modelValue", "rules"]),
|
|
616
|
-
|
|
631
|
+
o(w, {
|
|
617
632
|
modelValue: e(a).outletCity,
|
|
618
|
-
"onUpdate:modelValue": l[
|
|
633
|
+
"onUpdate:modelValue": l[19] || (l[19] = (t) => e(a).outletCity = t),
|
|
619
634
|
label: "City",
|
|
620
635
|
placeholder: "Enter city",
|
|
621
636
|
"label-mark": "required",
|
|
622
637
|
rules: e(u)(e(d).string().min(1, "City is required"))
|
|
623
638
|
}, null, 8, ["modelValue", "rules"]),
|
|
624
|
-
n("div",
|
|
625
|
-
|
|
639
|
+
n("div", Ge, [
|
|
640
|
+
o(ne, {
|
|
626
641
|
modelValue: e(a).businessType,
|
|
627
|
-
"onUpdate:modelValue": l[
|
|
642
|
+
"onUpdate:modelValue": l[20] || (l[20] = (t) => e(a).businessType = t),
|
|
628
643
|
label: "Type",
|
|
629
644
|
placeholder: "Select business type",
|
|
630
645
|
"label-mark": "required",
|
|
@@ -643,132 +658,132 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
643
658
|
]
|
|
644
659
|
}, null, 8, ["modelValue", "rules"])
|
|
645
660
|
]),
|
|
646
|
-
n("div",
|
|
647
|
-
|
|
661
|
+
n("div", Ye, [
|
|
662
|
+
o(w, {
|
|
648
663
|
modelValue: e(a).businessRegNo,
|
|
649
|
-
"onUpdate:modelValue": l[
|
|
664
|
+
"onUpdate:modelValue": l[21] || (l[21] = (t) => e(a).businessRegNo = t),
|
|
650
665
|
label: "Registration No",
|
|
651
666
|
placeholder: "Enter registration number",
|
|
652
667
|
"label-mark": "required",
|
|
653
668
|
rules: e(u)(e(d).string().min(1, "Reg No is required"))
|
|
654
669
|
}, null, 8, ["modelValue", "rules"])
|
|
655
670
|
]),
|
|
656
|
-
n("div",
|
|
657
|
-
|
|
671
|
+
n("div", Xe, [
|
|
672
|
+
o(w, {
|
|
658
673
|
modelValue: e(a).tinNo,
|
|
659
|
-
"onUpdate:modelValue": l[
|
|
674
|
+
"onUpdate:modelValue": l[22] || (l[22] = (t) => e(a).tinNo = t),
|
|
660
675
|
label: "Tax Identification No (TIN)",
|
|
661
676
|
placeholder: "Enter your TIN number",
|
|
662
677
|
"label-mark": "required",
|
|
663
678
|
rules: e(u)(e(d).string().min(1, "TIN is required"))
|
|
664
679
|
}, null, 8, ["modelValue", "rules"])
|
|
665
680
|
]),
|
|
666
|
-
n("div",
|
|
667
|
-
|
|
681
|
+
n("div", Ze, [
|
|
682
|
+
o(w, {
|
|
668
683
|
modelValue: e(a).sstNo,
|
|
669
|
-
"onUpdate:modelValue": l[
|
|
684
|
+
"onUpdate:modelValue": l[23] || (l[23] = (t) => e(a).sstNo = t),
|
|
670
685
|
label: "SST Registration No (SST)",
|
|
671
686
|
placeholder: "Enter your SST number",
|
|
672
687
|
"label-mark": "optional"
|
|
673
688
|
}, null, 8, ["modelValue"])
|
|
674
689
|
])
|
|
675
690
|
]),
|
|
676
|
-
l[
|
|
677
|
-
n("div",
|
|
678
|
-
|
|
691
|
+
l[50] || (l[50] = n("h3", { class: "font-semibold text-lg border-b pb-1 mt-6 mb-4" }, " Payout Information & Documents ", -1)),
|
|
692
|
+
n("div", he, [
|
|
693
|
+
o(ne, {
|
|
679
694
|
modelValue: e(a).bankName,
|
|
680
|
-
"onUpdate:modelValue": l[
|
|
695
|
+
"onUpdate:modelValue": l[24] || (l[24] = (t) => e(a).bankName = t),
|
|
681
696
|
label: "Bank",
|
|
682
697
|
placeholder: "Select bank type",
|
|
683
698
|
"label-mark": "required",
|
|
684
699
|
rules: e(u)(e(d).string().min(1, "Bank Type is required")),
|
|
685
|
-
items: e(
|
|
700
|
+
items: e(ve).bankNameOptions()
|
|
686
701
|
}, null, 8, ["modelValue", "rules", "items"]),
|
|
687
|
-
|
|
702
|
+
o(w, {
|
|
688
703
|
modelValue: e(a).bankHolderName,
|
|
689
|
-
"onUpdate:modelValue": l[
|
|
704
|
+
"onUpdate:modelValue": l[25] || (l[25] = (t) => e(a).bankHolderName = t),
|
|
690
705
|
label: "Beneficiary Name",
|
|
691
706
|
placeholder: "Enter Beneficiary Name",
|
|
692
707
|
"label-mark": "required",
|
|
693
708
|
rules: e(u)(e(d).string().min(1, "Beneficiary Name is required"))
|
|
694
709
|
}, null, 8, ["modelValue", "rules"]),
|
|
695
|
-
|
|
710
|
+
o(w, {
|
|
696
711
|
modelValue: e(a).bankAccountNo,
|
|
697
|
-
"onUpdate:modelValue": l[
|
|
712
|
+
"onUpdate:modelValue": l[26] || (l[26] = (t) => e(a).bankAccountNo = t),
|
|
698
713
|
label: "Account Number",
|
|
699
714
|
placeholder: "Enter Account Number",
|
|
700
715
|
"label-mark": "required",
|
|
701
716
|
rules: e(u)(e(d).string().min(1, "Account Number is required"))
|
|
702
717
|
}, null, 8, ["modelValue", "rules"]),
|
|
703
|
-
|
|
718
|
+
o(P, {
|
|
704
719
|
label: "Authorized Person ID",
|
|
705
720
|
modelValue: e(i).authorizedPersonID,
|
|
706
|
-
"onUpdate:modelValue": l[
|
|
721
|
+
"onUpdate:modelValue": l[27] || (l[27] = (t) => e(i).authorizedPersonID = t),
|
|
707
722
|
type: "image",
|
|
708
723
|
"restaurant-id": m.submission.restaurantId
|
|
709
724
|
}, null, 8, ["modelValue", "restaurant-id"]),
|
|
710
|
-
|
|
725
|
+
o(P, {
|
|
711
726
|
label: "Outlet Photo",
|
|
712
727
|
modelValue: e(i).outletPhoto,
|
|
713
|
-
"onUpdate:modelValue": l[
|
|
728
|
+
"onUpdate:modelValue": l[28] || (l[28] = (t) => e(i).outletPhoto = t),
|
|
714
729
|
type: "image",
|
|
715
730
|
"restaurant-id": m.submission.restaurantId
|
|
716
731
|
}, null, 8, ["modelValue", "restaurant-id"]),
|
|
717
|
-
(
|
|
732
|
+
(p(!0), x(J, null, _([1, 2, 3, 4, 5].filter(
|
|
718
733
|
(t) => !!e(i)[`onsitePhoto${t}`]
|
|
719
|
-
), (t) => (
|
|
734
|
+
), (t) => (p(), A(P, {
|
|
720
735
|
key: t,
|
|
721
|
-
label: e(
|
|
736
|
+
label: e(Ve)[t - 1],
|
|
722
737
|
modelValue: e(i)[`onsitePhoto${t}`],
|
|
723
|
-
"onUpdate:modelValue": (
|
|
738
|
+
"onUpdate:modelValue": (K) => e(i)[`onsitePhoto${t}`] = K,
|
|
724
739
|
type: "image",
|
|
725
740
|
"restaurant-id": m.submission.restaurantId
|
|
726
741
|
}, null, 8, ["label", "modelValue", "onUpdate:modelValue", "restaurant-id"]))), 128)),
|
|
727
|
-
e(i).interiorPhoto ? (
|
|
742
|
+
e(i).interiorPhoto ? (p(), A(P, {
|
|
728
743
|
key: 0,
|
|
729
744
|
label: "Interior Photo",
|
|
730
745
|
modelValue: e(i).interiorPhoto,
|
|
731
|
-
"onUpdate:modelValue": l[
|
|
746
|
+
"onUpdate:modelValue": l[29] || (l[29] = (t) => e(i).interiorPhoto = t),
|
|
732
747
|
type: "image",
|
|
733
748
|
"restaurant-id": m.submission.restaurantId
|
|
734
|
-
}, null, 8, ["modelValue", "restaurant-id"])) :
|
|
735
|
-
|
|
749
|
+
}, null, 8, ["modelValue", "restaurant-id"])) : O("", !0),
|
|
750
|
+
o(P, {
|
|
736
751
|
label: "Latest Bank Statement",
|
|
737
752
|
modelValue: e(i).bankStatement,
|
|
738
|
-
"onUpdate:modelValue": l[
|
|
753
|
+
"onUpdate:modelValue": l[30] || (l[30] = (t) => e(i).bankStatement = t),
|
|
739
754
|
type: "pdf",
|
|
740
755
|
"restaurant-id": m.submission.restaurantId
|
|
741
756
|
}, null, 8, ["modelValue", "restaurant-id"]),
|
|
742
|
-
e(a).businessType === "private_limited" || e(a).businessType === "public_limited" ? (
|
|
757
|
+
e(a).businessType === "private_limited" || e(a).businessType === "public_limited" ? (p(), A(P, {
|
|
743
758
|
key: 1,
|
|
744
759
|
label: "Superform",
|
|
745
760
|
type: "pdf",
|
|
746
761
|
modelValue: e(i).certificate,
|
|
747
|
-
"onUpdate:modelValue": l[
|
|
762
|
+
"onUpdate:modelValue": l[31] || (l[31] = (t) => e(i).certificate = t),
|
|
748
763
|
"restaurant-id": m.submission.restaurantId
|
|
749
|
-
}, null, 8, ["modelValue", "restaurant-id"])) :
|
|
750
|
-
e(a).businessType === "sole_proprietorship" || e(a).businessType === "partnership" ? (
|
|
764
|
+
}, null, 8, ["modelValue", "restaurant-id"])) : O("", !0),
|
|
765
|
+
e(a).businessType === "sole_proprietorship" || e(a).businessType === "partnership" ? (p(), A(P, {
|
|
751
766
|
key: 2,
|
|
752
767
|
label: "SSM Certificate & Info",
|
|
753
768
|
type: "pdf",
|
|
754
769
|
modelValue: e(i).certificate,
|
|
755
|
-
"onUpdate:modelValue": l[
|
|
770
|
+
"onUpdate:modelValue": l[32] || (l[32] = (t) => e(i).certificate = t),
|
|
756
771
|
"restaurant-id": m.submission.restaurantId
|
|
757
|
-
}, null, 8, ["modelValue", "restaurant-id"])) :
|
|
772
|
+
}, null, 8, ["modelValue", "restaurant-id"])) : O("", !0)
|
|
758
773
|
]),
|
|
759
|
-
l[
|
|
760
|
-
n("div",
|
|
761
|
-
|
|
774
|
+
l[51] || (l[51] = n("h3", { class: "font-semibold text-lg border-b pb-1 mt-6 mb-4" }, " Declaration Information ", -1)),
|
|
775
|
+
n("div", _e, [
|
|
776
|
+
o(we, {
|
|
762
777
|
modelValue: e(i).signature,
|
|
763
|
-
"onUpdate:modelValue": l[
|
|
778
|
+
"onUpdate:modelValue": l[33] || (l[33] = (t) => e(i).signature = t),
|
|
764
779
|
"restaurant-id": m.submission.restaurantId,
|
|
765
780
|
label: "Signature"
|
|
766
781
|
}, null, 8, ["modelValue", "restaurant-id"]),
|
|
767
|
-
|
|
782
|
+
o(P, {
|
|
768
783
|
label: "Company Stamp",
|
|
769
784
|
type: "image",
|
|
770
785
|
modelValue: e(i).companyStamp,
|
|
771
|
-
"onUpdate:modelValue": l[
|
|
786
|
+
"onUpdate:modelValue": l[34] || (l[34] = (t) => e(i).companyStamp = t),
|
|
772
787
|
"restaurant-id": m.submission.restaurantId
|
|
773
788
|
}, null, 8, ["modelValue", "restaurant-id"])
|
|
774
789
|
])
|
|
@@ -778,7 +793,7 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
778
793
|
], 64);
|
|
779
794
|
};
|
|
780
795
|
}
|
|
781
|
-
}),
|
|
796
|
+
}), ll = { class: "space-y-2" }, tl = { class: "text-gray-900" }, al = { class: "text-gray-900" }, sl = { class: "text-gray-900" }, nl = { class: "text-gray-900" }, ol = { class: "text-gray-900" }, rl = { class: "text-gray-900" }, il = { class: "mt-6 grid grid-cols-4 gap-24" }, ul = { class: "w-full flex justify-end mt-6" }, dl = { class: "mt-6 grid grid-cols-4 gap-24" }, ml = { class: "col-span-2" }, pl = { class: "col-span-2" }, bl = { class: "col-span-2" }, cl = { class: "col-span-2" }, yl = { class: "mt-6 grid grid-cols-4 gap-24" }, gl = { class: "mt-6 grid grid-cols-4 gap-24" }, vl = { class: "mt-6 grid grid-cols-4 gap-24" }, Vl = { class: "col-span-2" }, fl = { class: "col-span-2" }, kl = { class: "col-span-2" }, Cl = { class: "col-span-2" }, Nl = { class: "col-span-2" }, Sl = { class: "col-span-2" }, wl = /* @__PURE__ */ Z({
|
|
782
797
|
__name: "NTTSubmission",
|
|
783
798
|
props: {
|
|
784
799
|
submission: {
|
|
@@ -787,8 +802,8 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
787
802
|
}
|
|
788
803
|
},
|
|
789
804
|
emits: ["update:submission"],
|
|
790
|
-
setup(m, { emit:
|
|
791
|
-
const
|
|
805
|
+
setup(m, { emit: L }) {
|
|
806
|
+
const V = m, k = L, g = se(), q = j(!1), { isLoading: c, startAsyncCall: T } = le(), { fields: a, documents: i, restaurantId: I, profile: v, status: D, statusReason: E } = V.submission, F = j(""), R = [
|
|
792
807
|
{ key: "localCardDebit", label: "Local Card (Debit)", defaultValue: "2.3" },
|
|
793
808
|
{
|
|
794
809
|
key: "localCardStandard",
|
|
@@ -820,123 +835,123 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
820
835
|
{ key: "shopeePay", label: "ShopeePay", defaultValue: "2.3" },
|
|
821
836
|
{ key: "linePay", label: "LinePay", defaultValue: "2.1" },
|
|
822
837
|
{ key: "thaiQr", label: "ThaiQR", defaultValue: "0.5" }
|
|
823
|
-
],
|
|
824
|
-
|
|
825
|
-
),
|
|
826
|
-
|
|
827
|
-
Object.entries(
|
|
828
|
-
) : { ...
|
|
829
|
-
),
|
|
830
|
-
() => Object.values(
|
|
831
|
-
),
|
|
838
|
+
], b = Object.fromEntries(
|
|
839
|
+
R.map((C) => [C.key, C.defaultValue])
|
|
840
|
+
), B = j(
|
|
841
|
+
V.submission.rates ? Object.fromEntries(
|
|
842
|
+
Object.entries(V.submission.rates).map(([C, s]) => [C, `${s}`])
|
|
843
|
+
) : { ...b }
|
|
844
|
+
), G = W(
|
|
845
|
+
() => Object.values(B.value).every((C) => parseFloat(C) > 0)
|
|
846
|
+
), te = W(() => a.businessType === "juristic" ? "Juristic" : a.businessType === "individual" ? "Individual" : a.businessType || "-"), M = () => T(async () => {
|
|
832
847
|
try {
|
|
833
|
-
const
|
|
834
|
-
|
|
848
|
+
const C = await H.reviewById(
|
|
849
|
+
V.submission._id,
|
|
835
850
|
{
|
|
836
|
-
status:
|
|
851
|
+
status: re.FdoOnboardStatus.enum.ready
|
|
837
852
|
}
|
|
838
853
|
);
|
|
839
|
-
k("update:submission",
|
|
854
|
+
k("update:submission", C), g.open({
|
|
840
855
|
type: "success",
|
|
841
856
|
title: "Submission marked as ready"
|
|
842
857
|
});
|
|
843
|
-
} catch (
|
|
858
|
+
} catch (C) {
|
|
844
859
|
g.open({
|
|
845
860
|
type: "error",
|
|
846
861
|
title: "Error occurs when marking submission as ready",
|
|
847
|
-
message: Q(
|
|
862
|
+
message: Q(C)
|
|
848
863
|
});
|
|
849
864
|
}
|
|
850
|
-
}), h = () =>
|
|
865
|
+
}), h = () => T(async () => {
|
|
851
866
|
try {
|
|
852
|
-
const
|
|
853
|
-
|
|
867
|
+
const C = await H.reviewById(
|
|
868
|
+
V.submission._id,
|
|
854
869
|
{
|
|
855
870
|
rates: Object.fromEntries(
|
|
856
|
-
|
|
871
|
+
R.map((s) => [
|
|
857
872
|
s.key,
|
|
858
|
-
parseFloat(
|
|
873
|
+
parseFloat(B.value[s.key])
|
|
859
874
|
])
|
|
860
875
|
),
|
|
861
876
|
status: "approved"
|
|
862
877
|
}
|
|
863
878
|
);
|
|
864
|
-
k("update:submission",
|
|
879
|
+
k("update:submission", C), g.open({
|
|
865
880
|
type: "success",
|
|
866
881
|
title: "Submission updated successfully"
|
|
867
882
|
});
|
|
868
|
-
} catch (
|
|
883
|
+
} catch (C) {
|
|
869
884
|
g.open({
|
|
870
885
|
type: "error",
|
|
871
886
|
title: "Error occurs when updating submission",
|
|
872
|
-
message: Q(
|
|
887
|
+
message: Q(C)
|
|
873
888
|
});
|
|
874
889
|
}
|
|
875
|
-
}),
|
|
890
|
+
}), Y = () => T(async () => {
|
|
876
891
|
try {
|
|
877
|
-
const
|
|
878
|
-
|
|
892
|
+
const C = await H.reviewById(
|
|
893
|
+
V.submission._id,
|
|
879
894
|
{
|
|
880
895
|
status: "rejected",
|
|
881
|
-
statusReason:
|
|
896
|
+
statusReason: F.value
|
|
882
897
|
}
|
|
883
898
|
);
|
|
884
|
-
k("update:submission",
|
|
899
|
+
k("update:submission", C), q.value = !1, g.open({
|
|
885
900
|
type: "success",
|
|
886
901
|
title: "Submission updated successfully"
|
|
887
902
|
});
|
|
888
|
-
} catch (
|
|
903
|
+
} catch (C) {
|
|
889
904
|
g.open({
|
|
890
905
|
type: "error",
|
|
891
906
|
title: "Error occurs when updating submission",
|
|
892
|
-
message: Q(
|
|
907
|
+
message: Q(C)
|
|
893
908
|
});
|
|
894
909
|
}
|
|
895
910
|
});
|
|
896
|
-
return (
|
|
897
|
-
const
|
|
898
|
-
return
|
|
899
|
-
n("div",
|
|
911
|
+
return (C, s) => {
|
|
912
|
+
const S = N("FmTextField"), X = N("FmButton"), ae = N("FmTextarea"), ee = N("FmDialog"), y = N("FmPhoneNumber"), l = N("FmForm");
|
|
913
|
+
return p(), x(J, null, [
|
|
914
|
+
n("div", ll, [
|
|
900
915
|
n("div", null, [
|
|
901
916
|
s[31] || (s[31] = n("span", { class: "w-40 font-medium text-gray-600" }, "Restaurant: ", -1)),
|
|
902
|
-
n("span",
|
|
917
|
+
n("span", tl, U(e(I)), 1)
|
|
903
918
|
]),
|
|
904
919
|
n("div", null, [
|
|
905
920
|
s[32] || (s[32] = n("span", { class: "w-40 font-medium text-gray-600" }, "Profile: ", -1)),
|
|
906
|
-
n("span",
|
|
921
|
+
n("span", al, U(e(v).name) + " ( " + U(e(v).legalName) + " )", 1)
|
|
907
922
|
]),
|
|
908
923
|
n("div", null, [
|
|
909
924
|
s[33] || (s[33] = n("span", { class: "w-40 font-medium text-gray-600" }, "Email: ", -1)),
|
|
910
|
-
n("span",
|
|
925
|
+
n("span", sl, U(e(v).email), 1)
|
|
911
926
|
]),
|
|
912
927
|
n("div", null, [
|
|
913
928
|
s[34] || (s[34] = n("span", { class: "w-40 font-medium text-gray-600" }, "Phone: ", -1)),
|
|
914
|
-
n("span",
|
|
929
|
+
n("span", nl, U(e(v).phoneNo), 1)
|
|
915
930
|
]),
|
|
916
931
|
n("div", null, [
|
|
917
932
|
s[35] || (s[35] = n("span", { class: "w-40 font-medium text-gray-600" }, "Status: ", -1)),
|
|
918
|
-
n("span",
|
|
919
|
-
|
|
933
|
+
n("span", ol, [
|
|
934
|
+
o(ue, { data: e(D) }, null, 8, ["data"])
|
|
920
935
|
])
|
|
921
936
|
]),
|
|
922
937
|
n("div", null, [
|
|
923
938
|
s[36] || (s[36] = n("span", { class: "w-40 font-medium text-gray-600" }, "Status Reason: ", -1)),
|
|
924
|
-
n("span",
|
|
939
|
+
n("span", rl, U(e(E)), 1)
|
|
925
940
|
])
|
|
926
941
|
]),
|
|
927
942
|
s[43] || (s[43] = n("h3", { class: "font-semibold text-lg border-b pb-1 mt-6 mb-4" }, "Rate Settings", -1)),
|
|
928
|
-
n("div",
|
|
929
|
-
(
|
|
930
|
-
key:
|
|
931
|
-
modelValue:
|
|
932
|
-
"onUpdate:modelValue": (
|
|
933
|
-
label:
|
|
943
|
+
n("div", il, [
|
|
944
|
+
(p(), x(J, null, _(R, (r) => o(S, {
|
|
945
|
+
key: r.key,
|
|
946
|
+
modelValue: B.value[r.key],
|
|
947
|
+
"onUpdate:modelValue": ($) => B.value[r.key] = $,
|
|
948
|
+
label: r.label,
|
|
934
949
|
"label-mark": "required",
|
|
935
950
|
type: "number",
|
|
936
951
|
inputmode: "numeric",
|
|
937
952
|
decimal: 2,
|
|
938
953
|
rules: e(u)(
|
|
939
|
-
e(d).string().min(1, "Rate is required").transform((
|
|
954
|
+
e(d).string().min(1, "Rate is required").transform(($) => parseFloat($)).refine(($) => !isNaN($), { message: "Rate must be a number" })
|
|
940
955
|
)
|
|
941
956
|
}, {
|
|
942
957
|
append: f(() => [...s[37] || (s[37] = [
|
|
@@ -945,13 +960,13 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
945
960
|
_: 1
|
|
946
961
|
}, 8, ["modelValue", "onUpdate:modelValue", "label", "rules"])), 64))
|
|
947
962
|
]),
|
|
948
|
-
n("div",
|
|
949
|
-
|
|
950
|
-
modelValue:
|
|
951
|
-
"onUpdate:modelValue": s[1] || (s[1] = (
|
|
963
|
+
n("div", ul, [
|
|
964
|
+
o(ee, {
|
|
965
|
+
modelValue: q.value,
|
|
966
|
+
"onUpdate:modelValue": s[1] || (s[1] = (r) => q.value = r)
|
|
952
967
|
}, {
|
|
953
968
|
"dialog-button": f(() => [
|
|
954
|
-
|
|
969
|
+
o(X, {
|
|
955
970
|
class: "mr-6",
|
|
956
971
|
type: "button",
|
|
957
972
|
variant: "destructive",
|
|
@@ -964,285 +979,285 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
964
979
|
n("div", null, "Rejecting Submission", -1)
|
|
965
980
|
])]),
|
|
966
981
|
default: f(() => [
|
|
967
|
-
|
|
968
|
-
modelValue:
|
|
969
|
-
"onUpdate:modelValue": s[0] || (s[0] = (
|
|
982
|
+
o(ae, {
|
|
983
|
+
modelValue: F.value,
|
|
984
|
+
"onUpdate:modelValue": s[0] || (s[0] = (r) => F.value = r),
|
|
970
985
|
label: "Reason for Rejection",
|
|
971
986
|
"label-mark": "optional",
|
|
972
987
|
"helper-text": "Please provide a reason for rejection."
|
|
973
988
|
}, null, 8, ["modelValue"]),
|
|
974
|
-
|
|
989
|
+
o(X, {
|
|
975
990
|
class: "mb-2 mt-6 w-full",
|
|
976
991
|
label: "Submit",
|
|
977
992
|
"prepend-icon": "save",
|
|
978
|
-
onClick:
|
|
993
|
+
onClick: Y,
|
|
979
994
|
loading: e(c)
|
|
980
995
|
}, null, 8, ["loading"])
|
|
981
996
|
]),
|
|
982
997
|
_: 1
|
|
983
998
|
}, 8, ["modelValue"]),
|
|
984
|
-
|
|
999
|
+
o(X, {
|
|
985
1000
|
type: "button",
|
|
986
1001
|
variant: "primary",
|
|
987
1002
|
"prepend-icon": "approval",
|
|
988
1003
|
label: "Approve Submission with Rates",
|
|
989
|
-
disabled: !
|
|
1004
|
+
disabled: !G.value,
|
|
990
1005
|
onClick: h,
|
|
991
1006
|
loading: e(c)
|
|
992
1007
|
}, null, 8, ["disabled", "loading"]),
|
|
993
|
-
e(
|
|
1008
|
+
e(D) === "approved" ? (p(), A(X, {
|
|
994
1009
|
key: 0,
|
|
995
1010
|
type: "button",
|
|
996
1011
|
variant: "secondary",
|
|
997
1012
|
"prepend-icon": "check_circle",
|
|
998
1013
|
label: "Mark as Ready",
|
|
999
1014
|
class: "ml-6",
|
|
1000
|
-
onClick:
|
|
1015
|
+
onClick: M,
|
|
1001
1016
|
loading: e(c)
|
|
1002
|
-
}, null, 8, ["loading"])) :
|
|
1017
|
+
}, null, 8, ["loading"])) : O("", !0)
|
|
1003
1018
|
]),
|
|
1004
|
-
|
|
1019
|
+
o(l, { disabled: !0 }, {
|
|
1005
1020
|
default: f(() => [
|
|
1006
1021
|
s[39] || (s[39] = n("h3", { class: "font-semibold text-lg border-b pb-1 mt-6 mb-4" }, " Outlet Information ", -1)),
|
|
1007
|
-
n("div",
|
|
1008
|
-
n("div",
|
|
1009
|
-
|
|
1022
|
+
n("div", dl, [
|
|
1023
|
+
n("div", ml, [
|
|
1024
|
+
o(S, {
|
|
1010
1025
|
modelValue: e(a).companyName,
|
|
1011
|
-
"onUpdate:modelValue": s[2] || (s[2] = (
|
|
1026
|
+
"onUpdate:modelValue": s[2] || (s[2] = (r) => e(a).companyName = r),
|
|
1012
1027
|
label: "Company Name",
|
|
1013
1028
|
"label-mark": "required",
|
|
1014
1029
|
rules: e(u)(e(d).string().min(1, "Company Name is required"))
|
|
1015
1030
|
}, null, 8, ["modelValue", "rules"])
|
|
1016
1031
|
]),
|
|
1017
|
-
n("div",
|
|
1018
|
-
|
|
1032
|
+
n("div", pl, [
|
|
1033
|
+
o(S, {
|
|
1019
1034
|
modelValue: e(a).outletName,
|
|
1020
|
-
"onUpdate:modelValue": s[3] || (s[3] = (
|
|
1035
|
+
"onUpdate:modelValue": s[3] || (s[3] = (r) => e(a).outletName = r),
|
|
1021
1036
|
label: "Outlet Name (Thai)",
|
|
1022
1037
|
"label-mark": "required",
|
|
1023
1038
|
rules: e(u)(e(d).string().min(1, "Outlet Name is required"))
|
|
1024
1039
|
}, null, 8, ["modelValue", "rules"])
|
|
1025
1040
|
]),
|
|
1026
|
-
n("div",
|
|
1027
|
-
|
|
1041
|
+
n("div", bl, [
|
|
1042
|
+
o(S, {
|
|
1028
1043
|
modelValue: e(a).outletNameEnglish,
|
|
1029
|
-
"onUpdate:modelValue": s[4] || (s[4] = (
|
|
1044
|
+
"onUpdate:modelValue": s[4] || (s[4] = (r) => e(a).outletNameEnglish = r),
|
|
1030
1045
|
label: "Outlet Name (English)",
|
|
1031
1046
|
"label-mark": "required",
|
|
1032
1047
|
rules: e(u)(e(d).string().min(1, "Outlet Name English is required"))
|
|
1033
1048
|
}, null, 8, ["modelValue", "rules"])
|
|
1034
1049
|
]),
|
|
1035
|
-
n("div",
|
|
1036
|
-
|
|
1050
|
+
n("div", cl, [
|
|
1051
|
+
o(S, {
|
|
1037
1052
|
modelValue: e(a).outletAddress,
|
|
1038
|
-
"onUpdate:modelValue": s[5] || (s[5] = (
|
|
1053
|
+
"onUpdate:modelValue": s[5] || (s[5] = (r) => e(a).outletAddress = r),
|
|
1039
1054
|
label: "Outlet Address",
|
|
1040
1055
|
"label-mark": "required",
|
|
1041
1056
|
rules: e(u)(e(d).string().min(1, "Outlet Address is required"))
|
|
1042
1057
|
}, null, 8, ["modelValue", "rules"])
|
|
1043
1058
|
]),
|
|
1044
|
-
|
|
1059
|
+
o(S, {
|
|
1045
1060
|
modelValue: e(a).outletPostCode,
|
|
1046
|
-
"onUpdate:modelValue": s[6] || (s[6] = (
|
|
1061
|
+
"onUpdate:modelValue": s[6] || (s[6] = (r) => e(a).outletPostCode = r),
|
|
1047
1062
|
label: "Post Code",
|
|
1048
1063
|
"label-mark": "required",
|
|
1049
1064
|
rules: e(u)(e(d).string().min(1, "Post Code is required"))
|
|
1050
1065
|
}, null, 8, ["modelValue", "rules"]),
|
|
1051
|
-
|
|
1066
|
+
o(S, {
|
|
1052
1067
|
modelValue: e(a).outletState,
|
|
1053
|
-
"onUpdate:modelValue": s[7] || (s[7] = (
|
|
1068
|
+
"onUpdate:modelValue": s[7] || (s[7] = (r) => e(a).outletState = r),
|
|
1054
1069
|
label: "State",
|
|
1055
1070
|
"label-mark": "required",
|
|
1056
1071
|
rules: e(u)(e(d).string().min(1, "State is required"))
|
|
1057
1072
|
}, null, 8, ["modelValue", "rules"]),
|
|
1058
|
-
|
|
1073
|
+
o(S, {
|
|
1059
1074
|
modelValue: e(a).outletCity,
|
|
1060
|
-
"onUpdate:modelValue": s[8] || (s[8] = (
|
|
1075
|
+
"onUpdate:modelValue": s[8] || (s[8] = (r) => e(a).outletCity = r),
|
|
1061
1076
|
label: "City",
|
|
1062
1077
|
"label-mark": "required",
|
|
1063
1078
|
rules: e(u)(e(d).string().min(1, "City is required"))
|
|
1064
1079
|
}, null, 8, ["modelValue", "rules"]),
|
|
1065
|
-
|
|
1066
|
-
"model-value":
|
|
1080
|
+
o(S, {
|
|
1081
|
+
"model-value": te.value,
|
|
1067
1082
|
label: "Business Type",
|
|
1068
1083
|
"label-mark": "required"
|
|
1069
1084
|
}, null, 8, ["model-value"]),
|
|
1070
|
-
|
|
1085
|
+
o(S, {
|
|
1071
1086
|
modelValue: e(a).numberOfDevices,
|
|
1072
|
-
"onUpdate:modelValue": s[9] || (s[9] = (
|
|
1087
|
+
"onUpdate:modelValue": s[9] || (s[9] = (r) => e(a).numberOfDevices = r),
|
|
1073
1088
|
label: "Number of Devices",
|
|
1074
1089
|
"label-mark": "required"
|
|
1075
1090
|
}, null, 8, ["modelValue"])
|
|
1076
1091
|
]),
|
|
1077
1092
|
s[40] || (s[40] = n("h3", { class: "font-semibold text-lg border-b pb-1 mt-6 mb-4" }, " Payout Information ", -1)),
|
|
1078
|
-
n("div",
|
|
1079
|
-
|
|
1093
|
+
n("div", yl, [
|
|
1094
|
+
o(S, {
|
|
1080
1095
|
modelValue: e(a).bankName,
|
|
1081
|
-
"onUpdate:modelValue": s[10] || (s[10] = (
|
|
1096
|
+
"onUpdate:modelValue": s[10] || (s[10] = (r) => e(a).bankName = r),
|
|
1082
1097
|
label: "Bank Name",
|
|
1083
1098
|
"label-mark": "required",
|
|
1084
1099
|
rules: e(u)(e(d).string().min(1, "Bank Name is required"))
|
|
1085
1100
|
}, null, 8, ["modelValue", "rules"]),
|
|
1086
|
-
|
|
1101
|
+
o(S, {
|
|
1087
1102
|
modelValue: e(a).bankHolderName,
|
|
1088
|
-
"onUpdate:modelValue": s[11] || (s[11] = (
|
|
1103
|
+
"onUpdate:modelValue": s[11] || (s[11] = (r) => e(a).bankHolderName = r),
|
|
1089
1104
|
label: "Bank Holder Name",
|
|
1090
1105
|
"label-mark": "required",
|
|
1091
1106
|
rules: e(u)(e(d).string().min(1, "Bank Holder Name is required"))
|
|
1092
1107
|
}, null, 8, ["modelValue", "rules"]),
|
|
1093
|
-
|
|
1108
|
+
o(S, {
|
|
1094
1109
|
modelValue: e(a).bankAccountNo,
|
|
1095
|
-
"onUpdate:modelValue": s[12] || (s[12] = (
|
|
1110
|
+
"onUpdate:modelValue": s[12] || (s[12] = (r) => e(a).bankAccountNo = r),
|
|
1096
1111
|
label: "Bank Account No",
|
|
1097
1112
|
"label-mark": "required",
|
|
1098
1113
|
rules: e(u)(e(d).string().min(1, "Bank Account No is required"))
|
|
1099
1114
|
}, null, 8, ["modelValue", "rules"]),
|
|
1100
|
-
|
|
1115
|
+
o(S, {
|
|
1101
1116
|
modelValue: e(a).bankBranch,
|
|
1102
|
-
"onUpdate:modelValue": s[13] || (s[13] = (
|
|
1117
|
+
"onUpdate:modelValue": s[13] || (s[13] = (r) => e(a).bankBranch = r),
|
|
1103
1118
|
label: "Bank Branch",
|
|
1104
1119
|
"label-mark": "required",
|
|
1105
1120
|
rules: e(u)(e(d).string().min(1, "Bank Branch is required"))
|
|
1106
1121
|
}, null, 8, ["modelValue", "rules"]),
|
|
1107
|
-
|
|
1122
|
+
o(S, {
|
|
1108
1123
|
modelValue: e(a).bankBranchCode,
|
|
1109
|
-
"onUpdate:modelValue": s[14] || (s[14] = (
|
|
1124
|
+
"onUpdate:modelValue": s[14] || (s[14] = (r) => e(a).bankBranchCode = r),
|
|
1110
1125
|
label: "Bank Branch Code",
|
|
1111
1126
|
"label-mark": "required",
|
|
1112
1127
|
rules: e(u)(e(d).string().min(1, "Bank Branch Code is required"))
|
|
1113
1128
|
}, null, 8, ["modelValue", "rules"])
|
|
1114
1129
|
]),
|
|
1115
1130
|
s[41] || (s[41] = n("h3", { class: "font-semibold text-lg border-b pb-1 mt-6 mb-4" }, "Documents", -1)),
|
|
1116
|
-
n("div",
|
|
1117
|
-
|
|
1131
|
+
n("div", gl, [
|
|
1132
|
+
o(P, {
|
|
1118
1133
|
label: "Authorized Person ID",
|
|
1119
1134
|
modelValue: e(i).authorizedPersonID,
|
|
1120
|
-
"onUpdate:modelValue": s[15] || (s[15] = (
|
|
1135
|
+
"onUpdate:modelValue": s[15] || (s[15] = (r) => e(i).authorizedPersonID = r),
|
|
1121
1136
|
type: "image",
|
|
1122
1137
|
"restaurant-id": m.submission.restaurantId
|
|
1123
1138
|
}, null, 8, ["modelValue", "restaurant-id"]),
|
|
1124
|
-
|
|
1139
|
+
o(P, {
|
|
1125
1140
|
label: "Outlet Photo",
|
|
1126
1141
|
modelValue: e(i).outletPhoto,
|
|
1127
|
-
"onUpdate:modelValue": s[16] || (s[16] = (
|
|
1142
|
+
"onUpdate:modelValue": s[16] || (s[16] = (r) => e(i).outletPhoto = r),
|
|
1128
1143
|
type: "image",
|
|
1129
1144
|
"restaurant-id": m.submission.restaurantId
|
|
1130
1145
|
}, null, 8, ["modelValue", "restaurant-id"]),
|
|
1131
|
-
|
|
1146
|
+
o(P, {
|
|
1132
1147
|
label: "Interior Photo",
|
|
1133
1148
|
modelValue: e(i).interiorPhoto,
|
|
1134
|
-
"onUpdate:modelValue": s[17] || (s[17] = (
|
|
1149
|
+
"onUpdate:modelValue": s[17] || (s[17] = (r) => e(i).interiorPhoto = r),
|
|
1135
1150
|
type: "image",
|
|
1136
1151
|
"restaurant-id": m.submission.restaurantId
|
|
1137
1152
|
}, null, 8, ["modelValue", "restaurant-id"]),
|
|
1138
|
-
|
|
1153
|
+
o(P, {
|
|
1139
1154
|
label: "Bank Statement",
|
|
1140
1155
|
modelValue: e(i).bankStatement,
|
|
1141
|
-
"onUpdate:modelValue": s[18] || (s[18] = (
|
|
1156
|
+
"onUpdate:modelValue": s[18] || (s[18] = (r) => e(i).bankStatement = r),
|
|
1142
1157
|
type: "pdf",
|
|
1143
1158
|
"restaurant-id": m.submission.restaurantId
|
|
1144
1159
|
}, null, 8, ["modelValue", "restaurant-id"]),
|
|
1145
|
-
e(a).businessType === "juristic" ? (
|
|
1160
|
+
e(a).businessType === "juristic" ? (p(), A(P, {
|
|
1146
1161
|
key: 0,
|
|
1147
1162
|
label: "Company Certificate",
|
|
1148
1163
|
type: "pdf",
|
|
1149
1164
|
modelValue: e(i).companyCertificate,
|
|
1150
|
-
"onUpdate:modelValue": s[19] || (s[19] = (
|
|
1165
|
+
"onUpdate:modelValue": s[19] || (s[19] = (r) => e(i).companyCertificate = r),
|
|
1151
1166
|
"restaurant-id": m.submission.restaurantId
|
|
1152
|
-
}, null, 8, ["modelValue", "restaurant-id"])) :
|
|
1153
|
-
e(a).businessType === "juristic" ? (
|
|
1167
|
+
}, null, 8, ["modelValue", "restaurant-id"])) : O("", !0),
|
|
1168
|
+
e(a).businessType === "juristic" ? (p(), A(P, {
|
|
1154
1169
|
key: 1,
|
|
1155
1170
|
label: "VAT Certificate",
|
|
1156
1171
|
type: "pdf",
|
|
1157
1172
|
modelValue: e(i).vatCertificate,
|
|
1158
|
-
"onUpdate:modelValue": s[20] || (s[20] = (
|
|
1173
|
+
"onUpdate:modelValue": s[20] || (s[20] = (r) => e(i).vatCertificate = r),
|
|
1159
1174
|
"restaurant-id": m.submission.restaurantId
|
|
1160
|
-
}, null, 8, ["modelValue", "restaurant-id"])) :
|
|
1161
|
-
e(a).businessType === "individual" ? (
|
|
1175
|
+
}, null, 8, ["modelValue", "restaurant-id"])) : O("", !0),
|
|
1176
|
+
e(a).businessType === "individual" ? (p(), A(P, {
|
|
1162
1177
|
key: 2,
|
|
1163
1178
|
label: "Commercial Certificate",
|
|
1164
1179
|
type: "pdf",
|
|
1165
1180
|
modelValue: e(i).commercialCertificate,
|
|
1166
|
-
"onUpdate:modelValue": s[21] || (s[21] = (
|
|
1181
|
+
"onUpdate:modelValue": s[21] || (s[21] = (r) => e(i).commercialCertificate = r),
|
|
1167
1182
|
"restaurant-id": m.submission.restaurantId
|
|
1168
|
-
}, null, 8, ["modelValue", "restaurant-id"])) :
|
|
1183
|
+
}, null, 8, ["modelValue", "restaurant-id"])) : O("", !0)
|
|
1169
1184
|
]),
|
|
1170
1185
|
s[42] || (s[42] = n("h3", { class: "font-semibold text-lg border-b pb-1 mt-6 mb-4" }, " Declaration Information ", -1)),
|
|
1171
|
-
n("div",
|
|
1172
|
-
n("div",
|
|
1173
|
-
|
|
1186
|
+
n("div", vl, [
|
|
1187
|
+
n("div", Vl, [
|
|
1188
|
+
o(S, {
|
|
1174
1189
|
modelValue: e(a).picName,
|
|
1175
|
-
"onUpdate:modelValue": s[22] || (s[22] = (
|
|
1190
|
+
"onUpdate:modelValue": s[22] || (s[22] = (r) => e(a).picName = r),
|
|
1176
1191
|
label: "PIC Name",
|
|
1177
1192
|
"label-mark": "required",
|
|
1178
1193
|
rules: e(u)(e(d).string().min(1, "PIC Name is required"))
|
|
1179
1194
|
}, null, 8, ["modelValue", "rules"])
|
|
1180
1195
|
]),
|
|
1181
|
-
n("div",
|
|
1182
|
-
|
|
1196
|
+
n("div", fl, [
|
|
1197
|
+
o(S, {
|
|
1183
1198
|
modelValue: e(a).picRole,
|
|
1184
|
-
"onUpdate:modelValue": s[23] || (s[23] = (
|
|
1199
|
+
"onUpdate:modelValue": s[23] || (s[23] = (r) => e(a).picRole = r),
|
|
1185
1200
|
label: "PIC Role",
|
|
1186
1201
|
"label-mark": "required",
|
|
1187
1202
|
rules: e(u)(e(d).string().min(1, "PIC Role is required"))
|
|
1188
1203
|
}, null, 8, ["modelValue", "rules"])
|
|
1189
1204
|
]),
|
|
1190
|
-
n("div",
|
|
1191
|
-
|
|
1205
|
+
n("div", kl, [
|
|
1206
|
+
o(S, {
|
|
1192
1207
|
modelValue: e(a).picEmail,
|
|
1193
|
-
"onUpdate:modelValue": s[24] || (s[24] = (
|
|
1208
|
+
"onUpdate:modelValue": s[24] || (s[24] = (r) => e(a).picEmail = r),
|
|
1194
1209
|
label: "PIC Email",
|
|
1195
1210
|
"label-mark": "required",
|
|
1196
1211
|
rules: e(u)(e(d).string().min(1, "PIC Email is required"))
|
|
1197
1212
|
}, null, 8, ["modelValue", "rules"])
|
|
1198
1213
|
]),
|
|
1199
|
-
n("div",
|
|
1200
|
-
|
|
1214
|
+
n("div", Cl, [
|
|
1215
|
+
o(y, {
|
|
1201
1216
|
"model-value": e(a).picContact,
|
|
1202
|
-
"onUpdate:modelValue": s[25] || (s[25] = (
|
|
1217
|
+
"onUpdate:modelValue": s[25] || (s[25] = (r) => e(a).picContact = r),
|
|
1203
1218
|
"default-country": "TH",
|
|
1204
1219
|
label: "PIC Contact",
|
|
1205
1220
|
"label-mark": "required",
|
|
1206
1221
|
rules: e(u)(e(d).string().min(1, "PIC Contact is required"))
|
|
1207
1222
|
}, null, 8, ["model-value", "rules"])
|
|
1208
1223
|
]),
|
|
1209
|
-
n("div",
|
|
1210
|
-
|
|
1224
|
+
n("div", Nl, [
|
|
1225
|
+
o(S, {
|
|
1211
1226
|
modelValue: e(a).witnessName,
|
|
1212
|
-
"onUpdate:modelValue": s[26] || (s[26] = (
|
|
1227
|
+
"onUpdate:modelValue": s[26] || (s[26] = (r) => e(a).witnessName = r),
|
|
1213
1228
|
label: "Witness Name",
|
|
1214
1229
|
"label-mark": "required",
|
|
1215
1230
|
rules: e(u)(e(d).string().min(1, "Witness Name is required"))
|
|
1216
1231
|
}, null, 8, ["modelValue", "rules"])
|
|
1217
1232
|
]),
|
|
1218
|
-
n("div",
|
|
1219
|
-
|
|
1233
|
+
n("div", Sl, [
|
|
1234
|
+
o(S, {
|
|
1220
1235
|
modelValue: e(a).witnessRole,
|
|
1221
|
-
"onUpdate:modelValue": s[27] || (s[27] = (
|
|
1236
|
+
"onUpdate:modelValue": s[27] || (s[27] = (r) => e(a).witnessRole = r),
|
|
1222
1237
|
label: "Witness Role",
|
|
1223
1238
|
"label-mark": "required",
|
|
1224
1239
|
rules: e(u)(e(d).string().min(1, "Witness Role is required"))
|
|
1225
1240
|
}, null, 8, ["modelValue", "rules"])
|
|
1226
1241
|
]),
|
|
1227
|
-
|
|
1242
|
+
o(P, {
|
|
1228
1243
|
label: "Signature",
|
|
1229
1244
|
type: "image",
|
|
1230
1245
|
modelValue: e(i).signature,
|
|
1231
|
-
"onUpdate:modelValue": s[28] || (s[28] = (
|
|
1246
|
+
"onUpdate:modelValue": s[28] || (s[28] = (r) => e(i).signature = r),
|
|
1232
1247
|
"restaurant-id": m.submission.restaurantId
|
|
1233
1248
|
}, null, 8, ["modelValue", "restaurant-id"]),
|
|
1234
|
-
|
|
1249
|
+
o(P, {
|
|
1235
1250
|
label: "Witness Signature",
|
|
1236
1251
|
type: "image",
|
|
1237
1252
|
modelValue: e(i).witnessSignature,
|
|
1238
|
-
"onUpdate:modelValue": s[29] || (s[29] = (
|
|
1253
|
+
"onUpdate:modelValue": s[29] || (s[29] = (r) => e(i).witnessSignature = r),
|
|
1239
1254
|
"restaurant-id": m.submission.restaurantId
|
|
1240
1255
|
}, null, 8, ["modelValue", "restaurant-id"]),
|
|
1241
|
-
|
|
1256
|
+
o(P, {
|
|
1242
1257
|
label: "Company Stamp",
|
|
1243
1258
|
type: "image",
|
|
1244
1259
|
modelValue: e(i).companyStamp,
|
|
1245
|
-
"onUpdate:modelValue": s[30] || (s[30] = (
|
|
1260
|
+
"onUpdate:modelValue": s[30] || (s[30] = (r) => e(i).companyStamp = r),
|
|
1246
1261
|
"restaurant-id": m.submission.restaurantId
|
|
1247
1262
|
}, null, 8, ["modelValue", "restaurant-id"])
|
|
1248
1263
|
])
|
|
@@ -1252,7 +1267,7 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
1252
1267
|
], 64);
|
|
1253
1268
|
};
|
|
1254
1269
|
}
|
|
1255
|
-
}),
|
|
1270
|
+
}), ql = /* @__PURE__ */ Z({
|
|
1256
1271
|
__name: "TyroSubmission",
|
|
1257
1272
|
props: {
|
|
1258
1273
|
submission: {
|
|
@@ -1262,8 +1277,8 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
1262
1277
|
},
|
|
1263
1278
|
emits: ["update:submission"],
|
|
1264
1279
|
setup(m) {
|
|
1265
|
-
const
|
|
1266
|
-
const k =
|
|
1280
|
+
const L = m, V = W(() => {
|
|
1281
|
+
const k = L.submission.fields || {}, g = (q) => k[q] || "N/A";
|
|
1267
1282
|
return [
|
|
1268
1283
|
{
|
|
1269
1284
|
label: "Tyro POS Reference ID",
|
|
@@ -1284,22 +1299,22 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
1284
1299
|
];
|
|
1285
1300
|
});
|
|
1286
1301
|
return (k, g) => {
|
|
1287
|
-
const
|
|
1288
|
-
return
|
|
1302
|
+
const q = N("FmCardHeader"), c = N("FmCardSection"), T = N("FmCard");
|
|
1303
|
+
return p(), A(T, {
|
|
1289
1304
|
class: "max-w-3xl mt-8 p-6",
|
|
1290
1305
|
variant: "elevated"
|
|
1291
1306
|
}, {
|
|
1292
1307
|
default: f(() => [
|
|
1293
|
-
|
|
1308
|
+
o(c, { class: "flex flex-col gap-16 justify-between" }, {
|
|
1294
1309
|
default: f(() => [
|
|
1295
|
-
|
|
1310
|
+
o(q, {
|
|
1296
1311
|
class: "p-0",
|
|
1297
1312
|
title: "Tyro Authorisation",
|
|
1298
1313
|
subtitle: ""
|
|
1299
1314
|
}),
|
|
1300
|
-
|
|
1315
|
+
o(c, { class: "p-0" }, {
|
|
1301
1316
|
default: f(() => [
|
|
1302
|
-
(
|
|
1317
|
+
(p(!0), x(J, null, _(V.value, (a) => (p(), x("p", {
|
|
1303
1318
|
key: a.label,
|
|
1304
1319
|
class: "text-sm text-gray-900 break-all mb-4 last:mb-0"
|
|
1305
1320
|
}, [
|
|
@@ -1317,10 +1332,10 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
1317
1332
|
});
|
|
1318
1333
|
};
|
|
1319
1334
|
}
|
|
1320
|
-
}),
|
|
1335
|
+
}), Fl = {
|
|
1321
1336
|
key: 0,
|
|
1322
1337
|
class: "flex items-center justify-center min-h-[80vh]"
|
|
1323
|
-
},
|
|
1338
|
+
}, Pl = { class: "px-32 pb-32" }, Ml = /* @__PURE__ */ Z({
|
|
1324
1339
|
__name: "OnboardForm",
|
|
1325
1340
|
props: {
|
|
1326
1341
|
submissionId: {
|
|
@@ -1329,20 +1344,20 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
1329
1344
|
}
|
|
1330
1345
|
},
|
|
1331
1346
|
setup(m) {
|
|
1332
|
-
const { startAsyncCall:
|
|
1347
|
+
const { startAsyncCall: L, isLoading: V } = le(), k = se(), g = m, q = ge(), c = j(null), T = W(
|
|
1333
1348
|
() => {
|
|
1334
|
-
var
|
|
1335
|
-
return ((
|
|
1349
|
+
var E;
|
|
1350
|
+
return ((E = c.value) == null ? void 0 : E.type) === re.FdoOnboardType.enum.tyro;
|
|
1336
1351
|
}
|
|
1337
1352
|
), a = () => {
|
|
1338
1353
|
if (window.history.length > 1) {
|
|
1339
|
-
|
|
1354
|
+
q.back();
|
|
1340
1355
|
return;
|
|
1341
1356
|
}
|
|
1342
|
-
|
|
1357
|
+
q.push({ name: "mf-payment-admin.onboard-submission" });
|
|
1343
1358
|
};
|
|
1344
|
-
|
|
1345
|
-
|
|
1359
|
+
ce(() => {
|
|
1360
|
+
L(async () => {
|
|
1346
1361
|
c.value = await H.readById(g.submissionId);
|
|
1347
1362
|
});
|
|
1348
1363
|
});
|
|
@@ -1350,39 +1365,39 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
1350
1365
|
if (!c.value) return null;
|
|
1351
1366
|
switch (c.value.type) {
|
|
1352
1367
|
case "softspace":
|
|
1353
|
-
return
|
|
1368
|
+
return el;
|
|
1354
1369
|
case "ntt":
|
|
1355
|
-
return
|
|
1370
|
+
return wl;
|
|
1356
1371
|
case "tyro":
|
|
1357
|
-
return
|
|
1372
|
+
return ql;
|
|
1358
1373
|
default:
|
|
1359
1374
|
return null;
|
|
1360
1375
|
}
|
|
1361
|
-
}),
|
|
1362
|
-
function
|
|
1363
|
-
c.value =
|
|
1376
|
+
}), I = j(0);
|
|
1377
|
+
function v(E) {
|
|
1378
|
+
c.value = E, I.value = Date.now();
|
|
1364
1379
|
}
|
|
1365
|
-
const
|
|
1366
|
-
var
|
|
1380
|
+
const D = async (E) => {
|
|
1381
|
+
var F, R;
|
|
1367
1382
|
if (c.value)
|
|
1368
|
-
switch (
|
|
1383
|
+
switch (E) {
|
|
1369
1384
|
case "preview":
|
|
1370
|
-
let
|
|
1385
|
+
let b;
|
|
1371
1386
|
try {
|
|
1372
|
-
|
|
1387
|
+
b = k.open({
|
|
1373
1388
|
message: "Generating preview document...",
|
|
1374
1389
|
type: "info"
|
|
1375
1390
|
}), await H.previewDocument(
|
|
1376
|
-
(
|
|
1391
|
+
(F = c.value) == null ? void 0 : F._id
|
|
1377
1392
|
);
|
|
1378
|
-
} catch (
|
|
1393
|
+
} catch (B) {
|
|
1379
1394
|
k.open({
|
|
1380
1395
|
type: "error",
|
|
1381
1396
|
title: "Error occurs when generating submission document",
|
|
1382
|
-
message: Q(
|
|
1397
|
+
message: Q(B)
|
|
1383
1398
|
});
|
|
1384
1399
|
} finally {
|
|
1385
|
-
|
|
1400
|
+
b && k.close(b);
|
|
1386
1401
|
}
|
|
1387
1402
|
break;
|
|
1388
1403
|
case "send":
|
|
@@ -1391,34 +1406,34 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
1391
1406
|
message: "Sending onboarding document...",
|
|
1392
1407
|
type: "info"
|
|
1393
1408
|
}), await H.sendDocument(
|
|
1394
|
-
(
|
|
1409
|
+
(R = c.value) == null ? void 0 : R._id
|
|
1395
1410
|
), k.open({
|
|
1396
1411
|
type: "success",
|
|
1397
1412
|
title: "Submission documents send successfully"
|
|
1398
1413
|
});
|
|
1399
|
-
} catch (
|
|
1414
|
+
} catch (B) {
|
|
1400
1415
|
k.open({
|
|
1401
1416
|
type: "error",
|
|
1402
1417
|
title: "Error occurs when sending document",
|
|
1403
|
-
message: Q(
|
|
1418
|
+
message: Q(B)
|
|
1404
1419
|
});
|
|
1405
1420
|
}
|
|
1406
1421
|
break;
|
|
1407
1422
|
}
|
|
1408
1423
|
};
|
|
1409
|
-
return (
|
|
1410
|
-
var
|
|
1411
|
-
const
|
|
1412
|
-
return e(
|
|
1413
|
-
|
|
1414
|
-
])) : (
|
|
1415
|
-
|
|
1416
|
-
title: `Submission - ${(
|
|
1417
|
-
description: `ID - ${(
|
|
1424
|
+
return (E, F) => {
|
|
1425
|
+
var B, G;
|
|
1426
|
+
const R = N("FmCircularProgress"), b = N("FmPageHead");
|
|
1427
|
+
return e(V) ? (p(), x("div", Fl, [
|
|
1428
|
+
o(R, { size: "xxl" })
|
|
1429
|
+
])) : (p(), x(J, { key: 1 }, [
|
|
1430
|
+
o(b, {
|
|
1431
|
+
title: `Submission - ${(B = c.value) == null ? void 0 : B.type}`,
|
|
1432
|
+
description: `ID - ${(G = c.value) == null ? void 0 : G._id}`,
|
|
1418
1433
|
"back-button": !0,
|
|
1419
1434
|
"onClick:back": a,
|
|
1420
|
-
"onClick:action":
|
|
1421
|
-
actions:
|
|
1435
|
+
"onClick:action": D,
|
|
1436
|
+
actions: T.value ? [] : [
|
|
1422
1437
|
{
|
|
1423
1438
|
label: "Preview Document",
|
|
1424
1439
|
value: "preview",
|
|
@@ -1432,11 +1447,11 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
1432
1447
|
}
|
|
1433
1448
|
]
|
|
1434
1449
|
}, null, 8, ["title", "description", "actions"]),
|
|
1435
|
-
n("div",
|
|
1436
|
-
(
|
|
1437
|
-
key:
|
|
1450
|
+
n("div", Pl, [
|
|
1451
|
+
(p(), A(ye(i.value), {
|
|
1452
|
+
key: I.value,
|
|
1438
1453
|
submission: c.value,
|
|
1439
|
-
"onUpdate:submission":
|
|
1454
|
+
"onUpdate:submission": v
|
|
1440
1455
|
}, null, 40, ["submission"]))
|
|
1441
1456
|
])
|
|
1442
1457
|
], 64));
|
|
@@ -1444,5 +1459,5 @@ const ve = ["src"], F = /* @__PURE__ */ Z({
|
|
|
1444
1459
|
}
|
|
1445
1460
|
});
|
|
1446
1461
|
export {
|
|
1447
|
-
|
|
1462
|
+
Ml as default
|
|
1448
1463
|
};
|