@feedmepos/mf-payment 1.0.0-beta.1 → 1.0.0-beta.11
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/README.md +11 -1
- package/dist/DateRangePicker.vue_vue_type_script_setup_true_lang-dP_5WjEJ.js +31 -0
- package/dist/PDFViewer-xrBtzrlR.js +22426 -0
- package/dist/{PayoutAccount-Bj5zvmoj.js → PayoutAccount-BCWthHjR.js} +93 -83
- package/dist/{PayoutAccount-BHRhEZ9h.js → PayoutAccount-BU2ocKJ0.js} +6 -6
- package/dist/{PayoutAccountSetting-kUQLeAcb.js → PayoutAccountSetting-CmgVLhdp.js} +4 -4
- package/dist/SelectAll.vue_vue_type_script_setup_true_lang-DA4rs3tk.js +42 -0
- package/dist/{Settlement-JHOJNkhd.js → Settlement-B1-WmCwC.js} +43 -44
- package/dist/Settlement-BSOQRlp1.js +145 -0
- package/dist/{SettlementTransactions-daWMAmtz.js → SettlementTransactions-Cqd2raea.js} +4 -4
- package/dist/{SettlementTransactions-BxuLXUR-.js → SettlementTransactions-JTwD_Vuq.js} +4 -4
- package/dist/{Terminal-gxGnjFGc.js → Terminal-De69bTKY.js} +43 -42
- package/dist/TerminalSetting-DlRHaEZh.js +387 -0
- package/dist/TerminalTransaction-4rE-cikT.js +261 -0
- package/dist/TerminalTransaction-BGzVHOHQ.js +485 -0
- package/dist/{Transaction-8LlOLPeZ.js → Transaction-B3ZWKg6Q.js} +119 -120
- package/dist/Transaction-B_0nUmpf.js +238 -0
- package/dist/{app-DjzULXn3.js → app-B86KsI6c.js} +228 -228
- package/dist/app.js +1 -1
- package/dist/{assets-NrCec-W0.js → assets-BCAivOTo.js} +1 -1
- package/dist/components/AdminLayout.vue.d.ts +8 -13
- package/dist/components/AutoCopyCell.vue.d.ts +3 -4
- package/dist/components/DateRangePicker.vue.d.ts +13 -0
- package/dist/components/Layout.vue.d.ts +8 -13
- package/dist/components/PDFViewer.vue.d.ts +1 -1
- package/dist/components/RouteCell.vue.d.ts +5 -6
- package/dist/components/SelectAll.vue.d.ts +57 -0
- package/dist/helpers/idToDate.d.ts +1 -1
- package/dist/{index-CWaKb7bG.js → index-4meiCsRz.js} +1566 -1556
- package/dist/{index-BwcJZFsi.js → index-BFYq3eq8.js} +1 -1
- package/dist/{index-7KNaibcq.js → index-BwFHcZlm.js} +1 -1
- package/dist/{index-BWUtjGg7.js → index-CBa6eapm.js} +1 -1
- package/dist/{index-CojhNtuG.js → index-CETCXB6X.js} +1 -1
- package/dist/{index-DbJpbpSs.js → index-CbsnpMWl.js} +1 -1
- package/dist/{index.vue_vue_type_script_setup_true_lang-JdAFa8vy.js → index.vue_vue_type_script_setup_true_lang-CKOlikHb.js} +1 -1
- package/dist/package.json +1 -1
- package/dist/{payout-account-CBT1rfSS.js → payout-account-CSEKeh4S.js} +2 -2
- package/dist/stores/iframe.d.ts +1 -1
- package/dist/stores/payoutAccount.d.ts +1 -1
- package/dist/{transaction-CQiT7Y_s.js → transaction-COjHU7aN.js} +26 -16
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/dist/views/admin/payout-account/cell/Bank.vue.d.ts +3 -5
- package/dist/views/admin/payout-account/cell/IsActive.vue.d.ts +3 -5
- package/dist/views/admin/payout-account/cell/PersonInCharge.vue.d.ts +3 -5
- package/dist/views/admin/payout-account/cell/RateInput.vue.d.ts +3 -5
- package/dist/views/admin/payout-account/cell/Status.vue.d.ts +3 -5
- package/dist/views/admin/payout-account/cell/TPlusInput.vue.d.ts +3 -5
- package/dist/views/admin/settlement/cell/Actions.vue.d.ts +4 -6
- package/dist/views/admin/settlement/cell/Gateway.vue.d.ts +3 -5
- package/dist/views/admin/settlement/cell/Method.vue.d.ts +3 -5
- package/dist/views/admin/settlement/cell/Status.vue.d.ts +3 -5
- package/dist/views/admin/terminal/TerminalBindCodeDialog.vue.d.ts +1 -1
- package/dist/views/admin/terminal/cell/Actions.vue.d.ts +7 -79
- package/dist/views/admin/terminal/cell/ID.vue.d.ts +3 -5
- package/dist/views/admin/terminal-transaction/cell/Actions.vue.d.ts +3 -4
- package/dist/views/admin/terminal-transaction/cell/Gateway.vue.d.ts +3 -5
- package/dist/views/admin/terminal-transaction/cell/Status.vue.d.ts +3 -5
- package/dist/views/admin/terminal-transaction/cell/Timestamp.vue.d.ts +7 -0
- package/dist/views/admin/transaction/cell/Actions.vue.d.ts +3 -4
- package/dist/views/admin/transaction/cell/Gateway.vue.d.ts +3 -5
- package/dist/views/admin/transaction/cell/Method.vue.d.ts +3 -5
- package/dist/views/admin/transaction/cell/Status.vue.d.ts +3 -5
- package/dist/views/payout-account/cell/Bank.vue.d.ts +3 -5
- package/dist/views/payout-account/cell/IsActive.vue.d.ts +3 -5
- package/dist/views/payout-account/cell/PersonInCharge.vue.d.ts +3 -5
- package/dist/views/payout-account/cell/Status.vue.d.ts +3 -5
- package/dist/views/settlement/cell/Actions.vue.d.ts +4 -6
- package/dist/views/settlement/cell/Gateway.vue.d.ts +3 -5
- package/dist/views/settlement/cell/Method.vue.d.ts +3 -5
- package/dist/views/settlement/cell/Status.vue.d.ts +3 -5
- package/dist/views/terminal-transaction/cell/Gateway.vue.d.ts +3 -5
- package/dist/views/terminal-transaction/cell/Status.vue.d.ts +3 -5
- package/dist/views/transaction/cell/Gateway.vue.d.ts +3 -5
- package/dist/views/transaction/cell/Method.vue.d.ts +3 -5
- package/dist/views/transaction/cell/Status.vue.d.ts +3 -5
- package/package.json +1 -1
- package/dist/PDFViewer-CjH_C1uT.js +0 -21792
- package/dist/Settlement-Crdfq22j.js +0 -149
- package/dist/TerminalSetting--ZAJJ_Hf.js +0 -379
- package/dist/TerminalTransaction---9nk_4q.js +0 -249
- package/dist/TerminalTransaction-B77YK3hF.js +0 -425
- package/dist/Transaction-DRQ_uZ30.js +0 -241
@@ -1,133 +1,134 @@
|
|
1
|
-
import { defineComponent as
|
2
|
-
import { u as S } from "./index-
|
3
|
-
import { _ as O } from "./index-
|
1
|
+
import { defineComponent as g, resolveComponent as i, openBlock as h, createBlock as y, normalizeClass as N, withCtx as _, createElementVNode as P, toDisplayString as C, createVNode as p, computed as x, ref as E, watch as F, unref as s, isRef as b, h as v } from "vue";
|
2
|
+
import { u as S } from "./index-BwFHcZlm.js";
|
3
|
+
import { _ as O } from "./index-4meiCsRz.js";
|
4
4
|
import { _ as K } from "./AdminLayout.vue_vue_type_script_setup_true_lang-BTmMOzwx.js";
|
5
|
-
import { P as V } from "./payout-account-
|
6
|
-
import { p as
|
5
|
+
import { P as V } from "./payout-account-CSEKeh4S.js";
|
6
|
+
import { p as $ } from "./index-BFYq3eq8.js";
|
7
7
|
import "@feedmepos/ui-library";
|
8
|
-
import { _ as
|
9
|
-
import { useRouter as
|
10
|
-
|
8
|
+
import { _ as D } from "./index.vue_vue_type_script_setup_true_lang-CKOlikHb.js";
|
9
|
+
import { useRouter as T } from "vue-router";
|
10
|
+
import { _ as U } from "./SelectAll.vue_vue_type_script_setup_true_lang-DA4rs3tk.js";
|
11
|
+
const G = /* @__PURE__ */ g({
|
11
12
|
__name: "Status",
|
12
13
|
props: {
|
13
14
|
row: {},
|
14
15
|
data: {}
|
15
16
|
},
|
16
17
|
setup(d) {
|
17
|
-
const
|
18
|
+
const o = d;
|
18
19
|
function t() {
|
19
|
-
return
|
20
|
+
return o.data === "NEW" ? "!w-[16px] !h-[16px] bg-yellow-400" : o.data === "PENDING" ? "!w-[16px] !h-[16px] bg-red-400" : "!w-[16px] !h-[16px] bg-green-400";
|
20
21
|
}
|
21
|
-
return (
|
22
|
-
const
|
23
|
-
return
|
22
|
+
return (m, c) => {
|
23
|
+
const r = i("FmBadge");
|
24
|
+
return h(), y(r, {
|
24
25
|
inline: "",
|
25
26
|
class: N(t())
|
26
27
|
}, {
|
27
|
-
default:
|
28
|
-
P("div", null, C(
|
28
|
+
default: _(() => [
|
29
|
+
P("div", null, C(m.data), 1)
|
29
30
|
]),
|
30
31
|
_: 1
|
31
32
|
}, 8, ["class"]);
|
32
33
|
};
|
33
34
|
}
|
34
|
-
}),
|
35
|
+
}), L = /* @__PURE__ */ g({
|
35
36
|
__name: "IsActive",
|
36
37
|
props: {
|
37
38
|
row: {},
|
38
39
|
data: {}
|
39
40
|
},
|
40
41
|
setup(d) {
|
41
|
-
const
|
42
|
+
const o = d;
|
42
43
|
function t() {
|
43
|
-
return
|
44
|
+
return o.data ? "#66BB6A" : "#EF5350";
|
44
45
|
}
|
45
|
-
function
|
46
|
-
return
|
46
|
+
function m() {
|
47
|
+
return o.data ? "check" : "close";
|
47
48
|
}
|
48
|
-
return (
|
49
|
-
const
|
50
|
-
return
|
51
|
-
name:
|
49
|
+
return (c, r) => {
|
50
|
+
const l = i("FmIcon");
|
51
|
+
return h(), y(l, {
|
52
|
+
name: m(),
|
52
53
|
color: t(),
|
53
54
|
size: "lg"
|
54
55
|
}, null, 8, ["name", "color"]);
|
55
56
|
};
|
56
57
|
}
|
57
|
-
}),
|
58
|
+
}), W = /* @__PURE__ */ g({
|
58
59
|
__name: "Bank",
|
59
60
|
props: {
|
60
61
|
row: {},
|
61
62
|
data: {}
|
62
63
|
},
|
63
64
|
setup(d) {
|
64
|
-
function
|
65
|
+
function o(t) {
|
65
66
|
return t ? "!w-[16px] !h-[16px] bg-green-400" : "!w-[16px] !h-[16px] bg-red-400";
|
66
67
|
}
|
67
|
-
return (t,
|
68
|
-
const
|
69
|
-
return
|
68
|
+
return (t, m) => {
|
69
|
+
const c = i("FmBadge"), r = i("FmListItem");
|
70
|
+
return h(), y(r, {
|
70
71
|
label: t.row.original.holderName,
|
71
72
|
sublabel: t.row.original.bankName + " - " + t.row.original.bankNumber,
|
72
73
|
clickable: !1,
|
73
74
|
tag: "label"
|
74
75
|
}, {
|
75
|
-
append:
|
76
|
-
c
|
76
|
+
append: _(() => [
|
77
|
+
p(c, {
|
77
78
|
inline: "",
|
78
|
-
class: N(
|
79
|
+
class: N(o(t.row.original.bankReady))
|
79
80
|
}, null, 8, ["class"])
|
80
81
|
]),
|
81
82
|
_: 1
|
82
83
|
}, 8, ["label", "sublabel"]);
|
83
84
|
};
|
84
85
|
}
|
85
|
-
}),
|
86
|
+
}), j = /* @__PURE__ */ g({
|
86
87
|
__name: "PersonInCharge",
|
87
88
|
props: {
|
88
89
|
row: {},
|
89
90
|
data: {}
|
90
91
|
},
|
91
92
|
setup(d) {
|
92
|
-
function
|
93
|
+
function o(t) {
|
93
94
|
return t ? "!w-[16px] !h-[16px] bg-green-400" : "!w-[16px] !h-[16px] bg-red-400";
|
94
95
|
}
|
95
|
-
return (t,
|
96
|
-
const
|
97
|
-
return
|
96
|
+
return (t, m) => {
|
97
|
+
const c = i("FmBadge"), r = i("FmListItem");
|
98
|
+
return h(), y(r, {
|
98
99
|
label: t.row.original.picName,
|
99
100
|
sublabel: t.row.original.picEmail + " - " + t.row.original.picPhone,
|
100
101
|
clickable: !1,
|
101
102
|
tag: "label"
|
102
103
|
}, {
|
103
|
-
append:
|
104
|
-
c
|
104
|
+
append: _(() => [
|
105
|
+
p(c, {
|
105
106
|
inline: "",
|
106
|
-
class: N(
|
107
|
+
class: N(o(t.row.original.picReady))
|
107
108
|
}, null, 8, ["class"])
|
108
109
|
]),
|
109
110
|
_: 1
|
110
111
|
}, 8, ["label", "sublabel"]);
|
111
112
|
};
|
112
113
|
}
|
113
|
-
}),
|
114
|
+
}), q = { class: "flex items-start mb-6" }, te = /* @__PURE__ */ g({
|
114
115
|
__name: "PayoutAccount",
|
115
116
|
setup(d) {
|
116
|
-
const
|
117
|
+
const o = x(() => V.storeEventOptions), t = x(() => V.statusOptions), m = E(), c = T(), { event: r, status: l, searchKey: u } = S({
|
117
118
|
searchKey: "",
|
118
119
|
event: O.F_PAYOUT_FOR.Enum.ORDERING,
|
119
120
|
status: t.value.map((e) => e.value)
|
120
121
|
});
|
121
|
-
F([
|
122
|
+
F([r, l], () => {
|
122
123
|
var e;
|
123
|
-
return (e =
|
124
|
+
return (e = m.value) == null ? void 0 : e.reset();
|
124
125
|
});
|
125
|
-
let
|
126
|
-
F(
|
127
|
-
|
126
|
+
let w;
|
127
|
+
F(u, async () => {
|
128
|
+
w && clearTimeout(w), w = setTimeout(
|
128
129
|
() => {
|
129
130
|
var e;
|
130
|
-
return (e =
|
131
|
+
return (e = m.value) == null ? void 0 : e.reset();
|
131
132
|
},
|
132
133
|
700
|
133
134
|
);
|
@@ -145,27 +146,27 @@ const G = /* @__PURE__ */ b({
|
|
145
146
|
bankName: e.store.bank.name,
|
146
147
|
holderName: e.store.bank.holderName
|
147
148
|
});
|
148
|
-
const
|
149
|
+
const f = {
|
149
150
|
picReady: !1,
|
150
151
|
picName: "",
|
151
152
|
picPhone: "",
|
152
153
|
picEmail: ""
|
153
154
|
};
|
154
|
-
e.store.keyPerson && Object.assign(
|
155
|
+
e.store.keyPerson && Object.assign(f, {
|
155
156
|
picReady: !0,
|
156
157
|
picName: e.store.keyPerson.name,
|
157
158
|
picPhone: e.store.keyPerson.phone,
|
158
159
|
picEmail: e.store.keyPerson.email
|
159
160
|
});
|
160
|
-
let
|
161
|
-
return e.store.event === "ORDERING" && (
|
161
|
+
let k = e.ref.name;
|
162
|
+
return e.store.event === "ORDERING" && (k = e.ref.profile.name), {
|
162
163
|
_id: e._id,
|
163
164
|
event: e.store.event,
|
164
|
-
name:
|
165
|
+
name: k,
|
165
166
|
status: e.status,
|
166
167
|
isActive: e.enable,
|
167
168
|
...a,
|
168
|
-
...
|
169
|
+
...f
|
169
170
|
};
|
170
171
|
}, R = [
|
171
172
|
{
|
@@ -182,7 +183,7 @@ const G = /* @__PURE__ */ b({
|
|
182
183
|
{
|
183
184
|
header: () => "Status",
|
184
185
|
accessorKey: "status",
|
185
|
-
cell: ({ cell: e, row: a }) =>
|
186
|
+
cell: ({ cell: e, row: a }) => v(G, { row: a, data: e.getValue() }),
|
186
187
|
meta: {
|
187
188
|
maxWidth: "108px",
|
188
189
|
textAlign: "right"
|
@@ -194,70 +195,79 @@ const G = /* @__PURE__ */ b({
|
|
194
195
|
meta: {
|
195
196
|
maxWidth: "64px"
|
196
197
|
},
|
197
|
-
cell: ({ cell: e, row: a }) =>
|
198
|
+
cell: ({ cell: e, row: a }) => v(L, { row: a, data: e.getValue() })
|
198
199
|
},
|
199
200
|
{
|
200
201
|
header: () => "Bank Details",
|
201
202
|
accessorKey: "bank",
|
202
|
-
cell: ({ cell: e, row: a }) =>
|
203
|
+
cell: ({ cell: e, row: a }) => v(W, { row: a, data: e.getValue() })
|
203
204
|
},
|
204
205
|
{
|
205
206
|
header: () => "Person In-Charge (PIC)",
|
206
207
|
accessorKey: "pic",
|
207
|
-
cell: ({ cell: e, row: a }) =>
|
208
|
+
cell: ({ cell: e, row: a }) => v(j, { row: a, data: e.getValue() })
|
208
209
|
}
|
209
210
|
];
|
210
211
|
return (e, a) => {
|
211
|
-
const
|
212
|
-
return
|
212
|
+
const f = i("FmSelect"), k = i("FmSearch"), B = i("FmFormGroup");
|
213
|
+
return h(), y(K, {
|
213
214
|
title: "Payout Accounts",
|
214
215
|
loading: !1
|
215
216
|
}, {
|
216
|
-
default:
|
217
|
-
P("div",
|
218
|
-
|
219
|
-
modelValue:
|
220
|
-
"onUpdate:modelValue": a[0] || (a[0] = (
|
217
|
+
default: _(() => [
|
218
|
+
P("div", q, [
|
219
|
+
p(f, {
|
220
|
+
modelValue: s(r),
|
221
|
+
"onUpdate:modelValue": a[0] || (a[0] = (n) => b(r) ? r.value = n : null),
|
221
222
|
class: "mr-6 w-[128px]",
|
222
223
|
label: "Type",
|
223
224
|
"label-mark": "required",
|
224
|
-
items:
|
225
|
+
items: o.value
|
225
226
|
}, null, 8, ["modelValue", "items"]),
|
226
|
-
|
227
|
-
modelValue: l
|
228
|
-
"onUpdate:modelValue": a[
|
227
|
+
p(f, {
|
228
|
+
modelValue: s(l),
|
229
|
+
"onUpdate:modelValue": a[2] || (a[2] = (n) => b(l) ? l.value = n : null),
|
229
230
|
class: "mr-6 w-[300px]",
|
230
231
|
label: "Status",
|
231
232
|
"label-mark": "required",
|
232
233
|
multiselect: "",
|
233
234
|
items: t.value
|
234
|
-
},
|
235
|
-
|
235
|
+
}, {
|
236
|
+
"prepend-menu": _(() => [
|
237
|
+
p(U, {
|
238
|
+
modelValue: s(l),
|
239
|
+
"onUpdate:modelValue": a[1] || (a[1] = (n) => b(l) ? l.value = n : null),
|
240
|
+
items: t.value
|
241
|
+
}, null, 8, ["modelValue", "items"])
|
242
|
+
]),
|
243
|
+
_: 1
|
244
|
+
}, 8, ["modelValue", "items"]),
|
245
|
+
p(B, {
|
236
246
|
class: "w-[300px]",
|
237
|
-
modelValue:
|
238
|
-
"onUpdate:modelValue": a[
|
247
|
+
modelValue: s(u),
|
248
|
+
"onUpdate:modelValue": a[4] || (a[4] = (n) => b(u) ? u.value = n : null),
|
239
249
|
label: "Search"
|
240
250
|
}, {
|
241
|
-
default:
|
242
|
-
|
243
|
-
modelValue:
|
244
|
-
"onUpdate:modelValue": a[
|
251
|
+
default: _(() => [
|
252
|
+
p(k, {
|
253
|
+
modelValue: s(u),
|
254
|
+
"onUpdate:modelValue": a[3] || (a[3] = (n) => b(u) ? u.value = n : null),
|
245
255
|
placeholder: "Search accounts ..."
|
246
256
|
}, null, 8, ["modelValue"])
|
247
257
|
]),
|
248
258
|
_: 1
|
249
259
|
}, 8, ["modelValue"])
|
250
260
|
]),
|
251
|
-
|
261
|
+
p(D, {
|
252
262
|
ref_key: "controller",
|
253
|
-
ref:
|
263
|
+
ref: m,
|
254
264
|
"column-defs": R,
|
255
265
|
"rows-defs": I,
|
256
|
-
paginate: (
|
257
|
-
onRowClick: a[
|
266
|
+
paginate: (n, A) => s($).read({ event: s(r), status: s(l), searchKey: s(u), limit: n, cursor: A }),
|
267
|
+
onRowClick: a[5] || (a[5] = (n) => s(c).push({
|
258
268
|
name: "mf-payment-admin.payout-account-settings",
|
259
269
|
params: {
|
260
|
-
accountId:
|
270
|
+
accountId: n._id
|
261
271
|
}
|
262
272
|
}))
|
263
273
|
}, null, 8, ["paginate"])
|
@@ -268,5 +278,5 @@ const G = /* @__PURE__ */ b({
|
|
268
278
|
}
|
269
279
|
});
|
270
280
|
export {
|
271
|
-
|
281
|
+
te as default
|
272
282
|
};
|
@@ -1,19 +1,19 @@
|
|
1
1
|
import { defineComponent as f, ref as W, reactive as k, computed as j, watch as p, resolveComponent as Y, openBlock as n, createBlock as u, withCtx as E, createElementVNode as r, createVNode as D, unref as w, createCommentVNode as I, createElementBlock as N, normalizeClass as U, toDisplayString as R, h as O, onMounted as T, Fragment as L } from "vue";
|
2
|
-
import { p as z } from "./index-
|
3
|
-
import { _ as y, u as S, e as K } from "./index-
|
2
|
+
import { p as z } from "./index-BFYq3eq8.js";
|
3
|
+
import { _ as y, u as S, e as K } from "./index-4meiCsRz.js";
|
4
4
|
import { defineStore as _ } from "pinia";
|
5
5
|
import { useCoreStore as $ } from "@feedmepos/mf-common";
|
6
|
-
import { c as AA, P as v } from "./payout-account-
|
6
|
+
import { c as AA, P as v } from "./payout-account-CSEKeh4S.js";
|
7
7
|
import { useDialogChild as sA, useDialog as eA } from "@feedmepos/ui-library";
|
8
8
|
import { z as X, a as x } from "./validator-D5jtpt9A.js";
|
9
|
-
import { P as J } from "./PDFViewer-
|
9
|
+
import { P as J } from "./PDFViewer-xrBtzrlR.js";
|
10
10
|
import { _ as tA } from "./Layout.vue_vue_type_script_setup_true_lang-DJm5br5a.js";
|
11
11
|
function aA() {
|
12
12
|
return {
|
13
13
|
businessPayoutAccounts: []
|
14
14
|
};
|
15
15
|
}
|
16
|
-
const gA = _("payoutAccount", {
|
16
|
+
const gA = _("mf-payment-payoutAccount", {
|
17
17
|
state: () => aA(),
|
18
18
|
getters: {
|
19
19
|
getBusinessPayoutAccounts: (a) => a.businessPayoutAccounts
|
@@ -512,7 +512,7 @@ const gA = _("payoutAccount", {
|
|
512
512
|
}, YA = { class: "hidden mr-6 lg:block lg:w-1/6" }, GA = ["src"], mA = { class: "w-full max-w-lg text-left" }, dA = { class: "py-4" }, CA = { class: "flex justify-end items-center mb-6" }, VA = { class: "flex space-x-4 items-center" }, jA = /* @__PURE__ */ f({
|
513
513
|
__name: "PayoutAccount",
|
514
514
|
setup(a) {
|
515
|
-
const { currentBusiness: o, restaurants: g } = $(), { isLoading: d, startAsyncCall: s } = S(!0), G = eA(), m = gA(), e = j(() => m.getBusinessPayoutAccounts), B = j(() => g.value.filter((c) => e.value.
|
515
|
+
const { currentBusiness: o, restaurants: g } = $(), { isLoading: d, startAsyncCall: s } = S(!0), G = eA(), m = gA(), e = j(() => m.getBusinessPayoutAccounts), B = j(() => g.value.filter((c) => e.value.findIndex((t) => t.store.id === c._id) === -1).map((c) => ({ label: c.profile.name, value: c._id }))), M = j(() => {
|
516
516
|
var c, t;
|
517
517
|
return [{ label: (c = o.value) == null ? void 0 : c.name, value: (t = o.value) == null ? void 0 : t._id }];
|
518
518
|
}), V = j(() => B.value.length > 0 || !e.value.find((c) => c.store.event === "MARKETING"));
|
@@ -1,10 +1,10 @@
|
|
1
1
|
import { defineComponent as I, resolveComponent as m, openBlock as g, createElementBlock as R, Fragment as D, createElementVNode as s, createVNode as u, withCtx as x, createTextVNode as C, toDisplayString as P, createCommentVNode as U, createBlock as V, ref as k, watch as O, computed as K, unref as r, isRef as j, h as q, onMounted as Y, resolveDynamicComponent as z, normalizeProps as H, mergeProps as L } from "vue";
|
2
|
-
import { p as N } from "./index-
|
3
|
-
import { g as B, b as E, u as Q, e as $ } from "./index-
|
2
|
+
import { p as N } from "./index-BFYq3eq8.js";
|
3
|
+
import { g as B, b as E, u as Q, e as $ } from "./index-4meiCsRz.js";
|
4
4
|
import { _ as Z } from "./Layout.vue_vue_type_script_setup_true_lang-DJm5br5a.js";
|
5
5
|
import { useRouter as J } from "vue-router";
|
6
|
-
import { u as W } from "./index-
|
7
|
-
import { P as M } from "./PDFViewer-
|
6
|
+
import { u as W } from "./index-BwFHcZlm.js";
|
7
|
+
import { P as M } from "./PDFViewer-xrBtzrlR.js";
|
8
8
|
import { useSnackbar as X } from "@feedmepos/ui-library";
|
9
9
|
import { u as h } from "./error-K1CakhA9.js";
|
10
10
|
import { z as A, a as S } from "./validator-D5jtpt9A.js";
|
@@ -0,0 +1,42 @@
|
|
1
|
+
import { defineComponent as c, mergeModels as r, useModel as s, computed as i, resolveComponent as d, openBlock as p, createBlock as v } from "vue";
|
2
|
+
import "@feedmepos/ui-library";
|
3
|
+
const h = /* @__PURE__ */ c({
|
4
|
+
__name: "SelectAll",
|
5
|
+
props: /* @__PURE__ */ r({
|
6
|
+
label: {
|
7
|
+
type: String
|
8
|
+
},
|
9
|
+
items: {
|
10
|
+
type: Array,
|
11
|
+
required: !0
|
12
|
+
}
|
13
|
+
}, {
|
14
|
+
modelValue: {
|
15
|
+
required: !0,
|
16
|
+
type: Array
|
17
|
+
},
|
18
|
+
modelModifiers: {}
|
19
|
+
}),
|
20
|
+
emits: ["update:modelValue"],
|
21
|
+
setup(e) {
|
22
|
+
const l = s(e, "modelValue"), t = e, o = i(() => {
|
23
|
+
const a = l.value;
|
24
|
+
return t.items.filter((n) => a.includes(n.value)).length === t.items.length;
|
25
|
+
});
|
26
|
+
return (a, n) => {
|
27
|
+
const u = d("FmMenuItem");
|
28
|
+
return p(), v(u, {
|
29
|
+
"model-value": o.value,
|
30
|
+
"has-checkbox": "",
|
31
|
+
key: "select-all",
|
32
|
+
label: e.label ?? "All",
|
33
|
+
onclick: () => {
|
34
|
+
o.value ? l.value = [] : l.value = e.items.map((m) => m.value);
|
35
|
+
}
|
36
|
+
}, null, 8, ["model-value", "label", "onclick"]);
|
37
|
+
};
|
38
|
+
}
|
39
|
+
});
|
40
|
+
export {
|
41
|
+
h as _
|
42
|
+
};
|
@@ -1,15 +1,16 @@
|
|
1
|
-
import { defineComponent as
|
2
|
-
import { u as
|
3
|
-
import { h as
|
4
|
-
import { s as
|
1
|
+
import { defineComponent as C, ref as h, computed as x, resolveComponent as d, openBlock as k, createBlock as A, h as B, watch as V, onMounted as I, unref as a, withCtx as b, createElementVNode as y, createVNode as s, isRef as $, createElementBlock as L, Fragment as K, renderList as E } from "vue";
|
2
|
+
import { u as D } from "./index-4meiCsRz.js";
|
3
|
+
import { h as g } from "./moment-h96o7c8I.js";
|
4
|
+
import { s as c } from "./index-CETCXB6X.js";
|
5
5
|
import { useSnackbar as T } from "@feedmepos/ui-library";
|
6
|
-
import { d as
|
7
|
-
import { _ as
|
6
|
+
import { d as v } from "./dinero-CIVmXLL-.js";
|
7
|
+
import { _ as P } from "./AutoCopyCell.vue_vue_type_script_setup_true_lang-GXPXBEf5.js";
|
8
8
|
import { useRouter as q } from "vue-router";
|
9
9
|
import { _ as N } from "./AdminLayout.vue_vue_type_script_setup_true_lang-BTmMOzwx.js";
|
10
|
-
import { u as
|
11
|
-
import { u as
|
12
|
-
|
10
|
+
import { u as O } from "./index-BwFHcZlm.js";
|
11
|
+
import { u as U } from "./error-K1CakhA9.js";
|
12
|
+
import { _ as j } from "./DateRangePicker.vue_vue_type_script_setup_true_lang-dP_5WjEJ.js";
|
13
|
+
const z = /* @__PURE__ */ C({
|
13
14
|
__name: "SettlementTable",
|
14
15
|
props: {
|
15
16
|
data: {
|
@@ -23,11 +24,11 @@ const z = /* @__PURE__ */ h({
|
|
23
24
|
},
|
24
25
|
emits: ["row-click"],
|
25
26
|
setup(w, { emit: u }) {
|
26
|
-
const r = w,
|
27
|
+
const r = w, i = u, o = h(""), p = [
|
27
28
|
{
|
28
29
|
header: () => "Settlement ID",
|
29
30
|
accessorKey: "id",
|
30
|
-
cell: ({ cell: e }) =>
|
31
|
+
cell: ({ cell: e }) => B(P, { data: e.getValue() })
|
31
32
|
},
|
32
33
|
{
|
33
34
|
header: () => "Created At",
|
@@ -48,38 +49,38 @@ const z = /* @__PURE__ */ h({
|
|
48
49
|
header: () => "Settlement Amount",
|
49
50
|
accessorKey: "payout"
|
50
51
|
}
|
51
|
-
], f =
|
52
|
+
], f = x(() => r.data.map((e) => ({
|
52
53
|
id: e._id,
|
53
|
-
transactionAt:
|
54
|
-
amount:
|
55
|
-
fee:
|
56
|
-
payout:
|
54
|
+
transactionAt: g(e.createdAt).format("YYYY-MM-DD"),
|
55
|
+
amount: v(e.totalAmount).toFormat("$0.00"),
|
56
|
+
fee: v(e.totalFee).toFormat("$0.00"),
|
57
|
+
payout: v(e.totalPayout).toFormat("$0.00")
|
57
58
|
})));
|
58
59
|
return (e, n) => {
|
59
|
-
const _ =
|
60
|
-
return k(),
|
60
|
+
const _ = d("FmTable");
|
61
|
+
return k(), A(_, {
|
61
62
|
modelValue: o.value,
|
62
63
|
"onUpdate:modelValue": n[0] || (n[0] = (l) => o.value = l),
|
63
64
|
"row-data": f.value,
|
64
65
|
"column-defs": p,
|
65
66
|
loading: r.loading,
|
66
|
-
onRowClick: n[1] || (n[1] = (l) =>
|
67
|
+
onRowClick: n[1] || (n[1] = (l) => i("row-click", r.data.at(l.index)))
|
67
68
|
}, null, 8, ["modelValue", "row-data", "loading"]);
|
68
69
|
};
|
69
70
|
}
|
70
|
-
}), G = { class: "flex justify-between items-center mb-6" }, Q = { class: "flex space-x-4 items-center" }, H = { class: "flex space-x-4
|
71
|
+
}), G = { class: "flex justify-between items-center mb-6" }, Q = { class: "flex space-x-4 items-center" }, H = { class: "flex space-x-4" }, ie = /* @__PURE__ */ C({
|
71
72
|
__name: "Settlement",
|
72
73
|
setup(w) {
|
73
|
-
const { isLoading: u, startAsyncCall: r } =
|
74
|
+
const { isLoading: u, startAsyncCall: r } = D(!0), i = D(!1), o = h([]), p = q(), f = T(), { dateRange: e } = O({
|
74
75
|
dateRange: {
|
75
|
-
startDate:
|
76
|
-
endDate:
|
76
|
+
startDate: g().startOf("day").format("YYYY-MM-DD"),
|
77
|
+
endDate: g().endOf("day").format("YYYY-MM-DD")
|
77
78
|
}
|
78
79
|
});
|
79
|
-
|
80
|
+
V(e, n);
|
80
81
|
async function n() {
|
81
82
|
await r(async () => {
|
82
|
-
const F = await
|
83
|
+
const F = await c.readByDate(
|
83
84
|
{
|
84
85
|
start: e.value.startDate,
|
85
86
|
end: e.value.endDate
|
@@ -91,14 +92,14 @@ const z = /* @__PURE__ */ h({
|
|
91
92
|
function _() {
|
92
93
|
n();
|
93
94
|
}
|
94
|
-
|
95
|
+
I(_);
|
95
96
|
const l = [
|
96
97
|
{
|
97
98
|
label: "Audit Report",
|
98
99
|
sublabel: "Full transactions details report from each payment providers.",
|
99
100
|
icon: "file_download",
|
100
101
|
value: "auditReport",
|
101
|
-
onClick: () =>
|
102
|
+
onClick: () => c.downloadSettlementReport({
|
102
103
|
start: e.value.startDate,
|
103
104
|
end: e.value.endDate
|
104
105
|
})
|
@@ -108,7 +109,7 @@ const z = /* @__PURE__ */ h({
|
|
108
109
|
sublabel: "Summarized settlement information for each payout accounts.",
|
109
110
|
icon: "account_balance",
|
110
111
|
value: "summaryReport",
|
111
|
-
onClick: () =>
|
112
|
+
onClick: () => c.downloadSummaryReport(o.value, {
|
112
113
|
start: e.value.startDate,
|
113
114
|
end: e.value.endDate
|
114
115
|
})
|
@@ -118,51 +119,49 @@ const z = /* @__PURE__ */ h({
|
|
118
119
|
sublabel: "Generate bank instruction file based on bank formats.",
|
119
120
|
icon: "description",
|
120
121
|
value: "bankInstructionFile",
|
121
|
-
onClick: () =>
|
122
|
+
onClick: () => c.downloadBankInstructionFile(o.value)
|
122
123
|
}
|
123
124
|
];
|
124
|
-
return (F,
|
125
|
-
const
|
126
|
-
return k(),
|
125
|
+
return (F, m) => {
|
126
|
+
const M = d("FmButton"), R = d("FmMenuItem"), S = d("FmMenu");
|
127
|
+
return k(), A(N, {
|
127
128
|
title: "Settlements",
|
128
129
|
loading: a(u)
|
129
130
|
}, {
|
130
131
|
default: b(() => [
|
131
132
|
y("div", G, [
|
132
133
|
y("div", Q, [
|
133
|
-
s(
|
134
|
+
s(j, {
|
134
135
|
modelValue: a(e),
|
135
|
-
"onUpdate:modelValue":
|
136
|
-
"show-predefined-range": ""
|
136
|
+
"onUpdate:modelValue": m[0] || (m[0] = (t) => $(e) ? e.value = t : null)
|
137
137
|
}, null, 8, ["modelValue"])
|
138
138
|
]),
|
139
139
|
y("div", H, [
|
140
|
-
s(
|
140
|
+
s(S, { trigger: "click" }, {
|
141
141
|
"menu-button": b(() => [
|
142
|
-
s(
|
143
|
-
class: "w-full mt-6",
|
142
|
+
s(M, {
|
144
143
|
variant: "primary",
|
145
144
|
"append-icon": "arrow_drop_down",
|
146
145
|
label: "Actions",
|
147
|
-
loading: a(
|
146
|
+
loading: a(i).isLoading.value
|
148
147
|
}, null, 8, ["loading"])
|
149
148
|
]),
|
150
149
|
default: b(() => [
|
151
|
-
(k(),
|
150
|
+
(k(), L(K, null, E(l, (t) => s(R, {
|
152
151
|
key: t.value,
|
153
152
|
label: t.label,
|
154
153
|
icon: t.icon,
|
155
154
|
sublabel: t.sublabel,
|
156
155
|
selectable: !0,
|
157
156
|
onClick: (J) => {
|
158
|
-
a(
|
157
|
+
a(i).startAsyncCall(async () => {
|
159
158
|
try {
|
160
159
|
await t.onClick();
|
161
|
-
} catch (
|
160
|
+
} catch (Y) {
|
162
161
|
a(f).open({
|
163
162
|
type: "error",
|
164
163
|
title: "Error",
|
165
|
-
message: a(
|
164
|
+
message: a(U)(Y)
|
166
165
|
});
|
167
166
|
}
|
168
167
|
});
|
@@ -176,7 +175,7 @@ const z = /* @__PURE__ */ h({
|
|
176
175
|
s(z, {
|
177
176
|
loading: a(u),
|
178
177
|
data: o.value,
|
179
|
-
onRowClick:
|
178
|
+
onRowClick: m[1] || (m[1] = (t) => a(p).push({
|
180
179
|
name: "mf-payment-admin.settlement-transaction",
|
181
180
|
params: {
|
182
181
|
settlementId: t._id
|