@feedmepos/mf-payment 1.1.0-beta.3 → 1.1.0-beta.5
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/{PayoutAccount-aXUZqVC4.js → PayoutAccount-C8TaOd4c.js} +298 -284
- package/dist/{PayoutAccount-Dm__V5FS.js → PayoutAccount-k_oj_Se3.js} +5 -5
- package/dist/{PayoutAccountSetting-EbYjEXDF.js → PayoutAccountSetting-CqkCjQZG.js} +3 -3
- package/dist/{Restaurant-DLM9C8nc.js → Restaurant-9242Ya8l.js} +4 -4
- package/dist/{RestaurantSetting-GoDOJmXC.js → RestaurantSetting-BpWnw2Jj.js} +3 -3
- package/dist/{Settlement-CsLlypA1.js → Settlement-BOKEyc5M.js} +3 -3
- package/dist/{Settlement-BCGCz02p.js → Settlement-Fk2o5a_1.js} +3 -3
- package/dist/{SettlementTransactions-DtbZ2BMA.js → SettlementTransactions-Bcg3w7Hz.js} +3 -3
- package/dist/{SettlementTransactions-BXDX1-4U.js → SettlementTransactions-lYTbe3Pj.js} +3 -3
- package/dist/{Terminal-BhZitu-W.js → Terminal-B2Awbq_j.js} +5 -5
- package/dist/{TerminalSetting-lTAsTN8h.js → TerminalSetting-S_8IxAyI.js} +27 -27
- package/dist/{Transaction-AwhwSbRY.js → Transaction-DZ-dAEJB.js} +5 -5
- package/dist/{Transaction-CCTdVAZg.js → Transaction-dJxNlcIg.js} +7 -7
- package/dist/{TransactionOld-DLjym0JG.js → TransactionOld-B7uxSwpb.js} +4 -4
- package/dist/{TransactionTable.vue_vue_type_script_setup_true_lang-xSb40MKu.js → TransactionTable.vue_vue_type_script_setup_true_lang-vH38H_Lw.js} +58 -54
- package/dist/api/terminal/index.d.ts +2 -1
- package/dist/{app-348rfspt.js → app-CmhTSkBh.js} +291 -289
- package/dist/app.d.ts +2 -0
- package/dist/app.js +1 -1
- package/dist/{assets-CizBCu1u.js → assets-BwS-N5IN.js} +2 -2
- package/dist/{grafana-NU2yqPXT.js → grafana-ysrdKpe6.js} +1 -1
- package/dist/index-Bgrrdm3Z.js +52 -0
- package/dist/{index-GlBLcdqs.js → index-CiOLWz3t.js} +1 -1
- package/dist/{index-OD8n4-_f.js → index-DDFIpPJy.js} +1 -1
- package/dist/{index-Dvg8rPAD.js → index-DloTaJJH.js} +1 -1
- package/dist/{index-DEvTHjDK.js → index-DrJyWI2l.js} +2815 -2813
- package/dist/{index-BDCzfWFu.js → index-bSRmzn11.js} +1 -1
- package/dist/{index.vue_vue_type_script_setup_true_lang-D-xbKBxe.js → index.vue_vue_type_script_setup_true_lang-Iz1uC_Gw.js} +1 -1
- package/dist/package.json +1 -1
- package/dist/{payout-account-5sqoL9UC.js → payout-account-CasV_7ez.js} +110 -110
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/dist/index-D9Cv_ZfD.js +0 -45
@@ -1,8 +1,8 @@
|
|
1
1
|
import { defineComponent as m, resolveComponent as d, openBlock as l, createBlock as f, normalizeClass as v, withCtx as y, createElementVNode as x, toDisplayString as P, createElementBlock as w, unref as E, createVNode as I, Fragment as R, renderList as V, ref as D, h as p } from "vue";
|
2
2
|
import { useSnackbar as U, useDialog as B } from "@feedmepos/ui-library";
|
3
|
-
import { g as $, a as L, t as b, c as N } from "./assets-
|
4
|
-
import { e as h } from "./index-
|
5
|
-
import { g as G } from "./grafana-
|
3
|
+
import { g as $, a as L, t as b, c as N } from "./assets-BwS-N5IN.js";
|
4
|
+
import { e as h } from "./index-DrJyWI2l.js";
|
5
|
+
import { g as G } from "./grafana-ysrdKpe6.js";
|
6
6
|
import { w as k } from "./Modal-DB8M9o1T.js";
|
7
7
|
import { u as T } from "./error-K1CakhA9.js";
|
8
8
|
import { useCoreStore as O, useI18n as Y } from "@feedmepos/mf-common";
|
@@ -12,16 +12,16 @@ const j = /* @__PURE__ */ m({
|
|
12
12
|
row: {},
|
13
13
|
data: {}
|
14
14
|
},
|
15
|
-
setup(
|
16
|
-
const
|
17
|
-
function
|
18
|
-
return
|
15
|
+
setup(o) {
|
16
|
+
const n = o;
|
17
|
+
function r() {
|
18
|
+
return n.data === h.F_PAYMENT_TRANSACTION_STATUS.Enum.PENDING ? "!w-[16px] !h-[16px] bg-yellow-400" : n.data === h.F_PAYMENT_TRANSACTION_STATUS.Enum.FAILED ? "!w-[16px] !h-[16px] bg-red-400" : n.data === h.F_PAYMENT_TRANSACTION_STATUS.Enum.REFUNDED ? "!w-[16px] !h-[16px] bg-blue-400" : "!w-[16px] !h-[16px] bg-green-400";
|
19
19
|
}
|
20
20
|
return (i, s) => {
|
21
21
|
const u = d("FmBadge");
|
22
22
|
return l(), f(u, {
|
23
23
|
inline: "",
|
24
|
-
class: v(
|
24
|
+
class: v(r())
|
25
25
|
}, {
|
26
26
|
default: y(() => [
|
27
27
|
x("div", null, P(i.data), 1)
|
@@ -36,10 +36,10 @@ const j = /* @__PURE__ */ m({
|
|
36
36
|
row: {},
|
37
37
|
data: {}
|
38
38
|
},
|
39
|
-
setup(
|
40
|
-
return (
|
39
|
+
setup(o) {
|
40
|
+
return (n, r) => (l(), w("img", {
|
41
41
|
class: "rounded-md m-auto border-transparent object-contain w-[32px] h-[32px]",
|
42
|
-
src: E($)(
|
42
|
+
src: E($)(n.row.original.gateway)
|
43
43
|
}, null, 8, z));
|
44
44
|
}
|
45
45
|
}), H = ["src"], J = /* @__PURE__ */ m({
|
@@ -48,19 +48,19 @@ const j = /* @__PURE__ */ m({
|
|
48
48
|
row: {},
|
49
49
|
data: {}
|
50
50
|
},
|
51
|
-
setup(
|
52
|
-
return (
|
51
|
+
setup(o) {
|
52
|
+
return (n, r) => {
|
53
53
|
const i = d("FmTooltip");
|
54
54
|
return l(), f(i, {
|
55
55
|
variant: "plain",
|
56
56
|
placement: "top",
|
57
|
-
content:
|
57
|
+
content: n.row.original.method.issuer,
|
58
58
|
"hide-arrow": !0
|
59
59
|
}, {
|
60
60
|
default: y(() => [
|
61
61
|
x("img", {
|
62
62
|
class: "rounded-md m-auto border-transparent w-[32px] h-[32px]",
|
63
|
-
src: E(L)(
|
63
|
+
src: E(L)(n.row.original.method.issuer, n.row.original.method.variant)
|
64
64
|
}, null, 8, H)
|
65
65
|
]),
|
66
66
|
_: 1
|
@@ -73,21 +73,21 @@ const j = /* @__PURE__ */ m({
|
|
73
73
|
onAction: { type: Function },
|
74
74
|
transaction: {}
|
75
75
|
},
|
76
|
-
setup(
|
77
|
-
const
|
78
|
-
|
76
|
+
setup(o) {
|
77
|
+
const n = [
|
78
|
+
o.transaction.flags.query && {
|
79
79
|
label: "Query",
|
80
80
|
sublabel: "Perform transaction status inquriy",
|
81
81
|
icon: "question_answer",
|
82
82
|
action: "query"
|
83
83
|
},
|
84
|
-
|
84
|
+
o.transaction.flags.refund && {
|
85
85
|
label: "Refund",
|
86
86
|
sublabel: "Perform transaction refund request",
|
87
87
|
icon: "request_page",
|
88
88
|
action: "refund"
|
89
89
|
},
|
90
|
-
|
90
|
+
o.transaction.flags.notify && {
|
91
91
|
label: "Notify",
|
92
92
|
sublabel: "Perform webhook notification for transaction",
|
93
93
|
icon: "webhook",
|
@@ -100,11 +100,11 @@ const j = /* @__PURE__ */ m({
|
|
100
100
|
action: "history"
|
101
101
|
}
|
102
102
|
];
|
103
|
-
return (
|
103
|
+
return (r, i) => {
|
104
104
|
const s = d("FmIcon"), u = d("FmMenuItem"), g = d("FmMenu");
|
105
105
|
return l(), w("div", {
|
106
|
-
onClick: i[0] || (i[0] = (
|
107
|
-
|
106
|
+
onClick: i[0] || (i[0] = (a) => {
|
107
|
+
a.stopPropagation();
|
108
108
|
})
|
109
109
|
}, [
|
110
110
|
I(g, null, {
|
@@ -112,13 +112,13 @@ const j = /* @__PURE__ */ m({
|
|
112
112
|
I(s, { name: "settings" })
|
113
113
|
]),
|
114
114
|
default: y(() => [
|
115
|
-
(l(!0), w(R, null, V(
|
115
|
+
(l(!0), w(R, null, V(n.filter((a) => !!a), (a) => (l(), f(u, {
|
116
116
|
selectable: !0,
|
117
|
-
key:
|
118
|
-
sublabel:
|
119
|
-
label:
|
120
|
-
icon:
|
121
|
-
onclick: () =>
|
117
|
+
key: a.label,
|
118
|
+
sublabel: a.sublabel,
|
119
|
+
label: a.label,
|
120
|
+
icon: a.icon,
|
121
|
+
onclick: () => r.onAction(a.action)
|
122
122
|
}, null, 8, ["sublabel", "label", "icon", "onclick"]))), 128))
|
123
123
|
]),
|
124
124
|
_: 1
|
@@ -139,13 +139,13 @@ const j = /* @__PURE__ */ m({
|
|
139
139
|
}
|
140
140
|
},
|
141
141
|
emits: ["row-click"],
|
142
|
-
setup(
|
142
|
+
setup(o, { emit: n }) {
|
143
143
|
var q;
|
144
|
-
const
|
145
|
-
async function
|
144
|
+
const r = o, i = n, s = U(), u = B(), { sessionUser: g } = O(), { t: a } = Y();
|
145
|
+
async function K(t) {
|
146
146
|
try {
|
147
147
|
const e = await b.refetchTransaction({ transactionId: t.id });
|
148
|
-
|
148
|
+
r.data.map((c) => c.id === e._id ? N(e) : c), s.open({
|
149
149
|
type: "success",
|
150
150
|
title: "Transaction queried and updated successfully."
|
151
151
|
});
|
@@ -157,7 +157,7 @@ const j = /* @__PURE__ */ m({
|
|
157
157
|
});
|
158
158
|
}
|
159
159
|
}
|
160
|
-
async function
|
160
|
+
async function S(t) {
|
161
161
|
k(
|
162
162
|
u,
|
163
163
|
"Refund Transaction",
|
@@ -169,7 +169,7 @@ const j = /* @__PURE__ */ m({
|
|
169
169
|
reason: "portal transaction refund",
|
170
170
|
amount: t.fdoAmount
|
171
171
|
});
|
172
|
-
|
172
|
+
r.data.map((c) => c.id === e._id ? N(e) : c), s.open({
|
173
173
|
type: "success",
|
174
174
|
title: "Transaction refund request initiated."
|
175
175
|
});
|
@@ -183,7 +183,7 @@ const j = /* @__PURE__ */ m({
|
|
183
183
|
}
|
184
184
|
);
|
185
185
|
}
|
186
|
-
async function
|
186
|
+
async function C(t) {
|
187
187
|
k(
|
188
188
|
u,
|
189
189
|
"Notify Transaction",
|
@@ -216,27 +216,31 @@ const j = /* @__PURE__ */ m({
|
|
216
216
|
}
|
217
217
|
const A = D(""), F = [
|
218
218
|
{
|
219
|
-
header: () =>
|
219
|
+
header: () => a("transactions.table.id"),
|
220
220
|
accessorKey: "id"
|
221
221
|
},
|
222
222
|
{
|
223
|
-
header: () =>
|
223
|
+
header: () => a("transactions.table.pay_id"),
|
224
224
|
accessorKey: "payId"
|
225
225
|
},
|
226
226
|
{
|
227
|
-
header: () =>
|
227
|
+
header: () => a("transactions.table.gateway_id"),
|
228
|
+
accessorKey: "gatewayTransactionId"
|
229
|
+
},
|
230
|
+
{
|
231
|
+
header: () => a("transactions.table.bill_seq"),
|
228
232
|
accessorKey: "seqNumber"
|
229
233
|
},
|
230
234
|
{
|
231
|
-
header: () =>
|
235
|
+
header: () => a("transactions.table.gateway"),
|
232
236
|
accessorKey: "gateway",
|
233
237
|
meta: {
|
234
238
|
textAlign: "center"
|
235
239
|
},
|
236
|
-
cell: ({ cell: t, row: e }) => e.original.
|
240
|
+
cell: ({ cell: t, row: e }) => e.original.gateway ? p(Q, { row: e, data: t.getValue() }) : ""
|
237
241
|
},
|
238
242
|
{
|
239
|
-
header: () =>
|
243
|
+
header: () => a("transactions.table.method"),
|
240
244
|
accessorKey: "method",
|
241
245
|
meta: {
|
242
246
|
textAlign: "center"
|
@@ -244,24 +248,24 @@ const j = /* @__PURE__ */ m({
|
|
244
248
|
cell: ({ cell: t, row: e }) => e.original.method ? p(J, { row: e, data: t.getValue() }) : ""
|
245
249
|
},
|
246
250
|
{
|
247
|
-
header: () =>
|
251
|
+
header: () => a("transactions.table.type"),
|
248
252
|
accessorKey: "payFor",
|
249
253
|
meta: {
|
250
254
|
textAlign: "center"
|
251
255
|
}
|
252
256
|
},
|
253
257
|
{
|
254
|
-
header: () =>
|
258
|
+
header: () => a("transactions.table.status"),
|
255
259
|
accessorKey: "status",
|
256
260
|
cell: ({ cell: t, row: e }) => p(j, { row: e, data: t.getValue() })
|
257
261
|
},
|
258
262
|
{
|
259
|
-
header: () =>
|
263
|
+
header: () => a("transactions.table.source"),
|
260
264
|
accessorKey: "source",
|
261
265
|
cell: ({ cell: t, row: e }) => `(${e.original.sourceType}) ${e.original.source}`
|
262
266
|
},
|
263
267
|
{
|
264
|
-
header: () =>
|
268
|
+
header: () => a("transactions.table.transaction_at"),
|
265
269
|
accessorKey: "transactionAt",
|
266
270
|
meta: {
|
267
271
|
width: "180px"
|
@@ -269,23 +273,23 @@ const j = /* @__PURE__ */ m({
|
|
269
273
|
cell: ({ cell: t, row: e }) => e.original.status === "REFUNDED" ? e.original.refundedAt : e.original.transactionAt
|
270
274
|
},
|
271
275
|
{
|
272
|
-
header: () =>
|
276
|
+
header: () => a("transactions.table.sales_amount"),
|
273
277
|
accessorKey: "amount"
|
274
278
|
}
|
275
279
|
];
|
276
280
|
return (q = g.value) != null && q.isInternal && F.push({
|
277
|
-
header: () =>
|
281
|
+
header: () => a("transactions.table.actions"),
|
278
282
|
accessorKey: "actions",
|
279
283
|
cell: ({ row: t }) => p(W, {
|
280
284
|
transaction: t.original,
|
281
285
|
onAction: (e) => {
|
282
286
|
switch (e) {
|
283
287
|
case "notify":
|
284
|
-
return
|
288
|
+
return C(t.original);
|
285
289
|
case "query":
|
286
|
-
return
|
290
|
+
return K(t.original);
|
287
291
|
case "refund":
|
288
|
-
return
|
292
|
+
return S(t.original);
|
289
293
|
case "history":
|
290
294
|
return M(t.original);
|
291
295
|
}
|
@@ -297,9 +301,9 @@ const j = /* @__PURE__ */ m({
|
|
297
301
|
modelValue: A.value,
|
298
302
|
"onUpdate:modelValue": e[0] || (e[0] = (_) => A.value = _),
|
299
303
|
"column-defs": F,
|
300
|
-
"row-data":
|
301
|
-
loading:
|
302
|
-
onRowClick: e[1] || (e[1] = (_) => i("row-click",
|
304
|
+
"row-data": r.data,
|
305
|
+
loading: r.loading,
|
306
|
+
onRowClick: e[1] || (e[1] = (_) => i("row-click", r.data.at(_.index)))
|
303
307
|
}, null, 8, ["modelValue", "row-data", "loading"]);
|
304
308
|
};
|
305
309
|
}
|
@@ -15,5 +15,6 @@ export declare const temrinalApi: {
|
|
15
15
|
getBindCode(id: string): Promise<string>;
|
16
16
|
unbind(id: string): Promise<any>;
|
17
17
|
delete(id: string): Promise<any>;
|
18
|
-
|
18
|
+
getBusinessTerminals(): Promise<FdoPortalTerminal[]>;
|
19
|
+
getRestaurantTerminals(restaurantId: string): Promise<FdoPortalTerminal[]>;
|
19
20
|
};
|