@feedmepos/mf-payment 1.0.3-beta.1 → 1.0.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.
Files changed (55) hide show
  1. package/dist/{PayoutAccount-DPDYDztu.js → PayoutAccount-DYnycBoi.js} +3 -3
  2. package/dist/{PayoutAccount-BpTmAq7L.js → PayoutAccount-DxMey5W6.js} +5 -5
  3. package/dist/{PayoutAccountSetting-Dqj5Ay8_.js → PayoutAccountSetting-C1yeSNv8.js} +4 -4
  4. package/dist/Restaurant-B02jty0J.js +262 -0
  5. package/dist/{RestaurantSetting-BeXpe5M9.js → RestaurantSetting-CWZAKz1A.js} +4 -4
  6. package/dist/{Settlement-BZevkUVD.js → Settlement-BKwie9R8.js} +3 -3
  7. package/dist/{Settlement-C5S8SCT8.js → Settlement-ByPXBNx1.js} +3 -3
  8. package/dist/{SettlementTransactions-D2Z-i4tv.js → SettlementTransactions-DVRoAUYv.js} +4 -4
  9. package/dist/{SettlementTransactions-CNFm-E92.js → SettlementTransactions-rXQceUoG.js} +4 -4
  10. package/dist/Terminal-DX8v8WpM.js +386 -0
  11. package/dist/{TerminalSetting-BgxObmZ4.js → TerminalSetting-qklmRz3H.js} +3 -3
  12. package/dist/{TerminalTransaction-DUAhQ3VJ.js → TerminalTransaction-64Bn6vh0.js} +18 -19
  13. package/dist/{TerminalTransaction-Buf0yMu-.js → TerminalTransaction-YXcGJ2ne.js} +154 -184
  14. package/dist/{Transaction-DJ62jUdZ.js → Transaction-BOc0NW9a.js} +4 -4
  15. package/dist/{Transaction-y9wPMvLS.js → Transaction-CqTKm8KP.js} +54 -83
  16. package/dist/{app-D9URbI68.js → app-D017JOF7.js} +259 -259
  17. package/dist/app.js +1 -1
  18. package/dist/{assets-C_LulpgD.js → assets-DjRoCcqv.js} +1 -1
  19. package/dist/{index-CKD2hEEa.js → index-BEFlDEyV.js} +1 -1
  20. package/dist/{index-B74aXBpn.js → index-BWFqxSU3.js} +1 -1
  21. package/dist/{index-DzBM1rDP.js → index-BerQZMQW.js} +1 -1
  22. package/dist/{index-CvqYcrBo.js → index-Bp_58SiC.js} +1 -1
  23. package/dist/{index-DBnMiisv.js → index-CKyh0nlu.js} +1 -1
  24. package/dist/{index-B6KIJrFV.js → index-CWGSYCJG.js} +1 -1
  25. package/dist/{index-CuQ0G8FE.js → index-DFePh4ct.js} +1 -1
  26. package/dist/{index-C1AMSmO9.js → index-Dj_LwPBy.js} +8151 -8295
  27. package/dist/{index.vue_vue_type_script_setup_true_lang-BmM0EooD.js → index.vue_vue_type_script_setup_true_lang-BgTr7KWF.js} +1 -1
  28. package/dist/model/payout-account.d.ts +1 -1
  29. package/dist/model/transaction.d.ts +0 -1
  30. package/dist/package.json +2 -2
  31. package/dist/{payout-account-CvnI-60K.js → payout-account-BhSP2Imp.js} +2 -2
  32. package/dist/stores/payoutAccount.d.ts +6 -6
  33. package/dist/{transaction-DNuE-yMH.js → transaction-Bxl86wzh.js} +15 -19
  34. package/dist/tsconfig.app.tsbuildinfo +1 -1
  35. package/dist/views/admin/payout-account/tabs/Information.vue.d.ts +6 -6
  36. package/dist/views/admin/payout-account/tabs/PaymentGateway.vue.d.ts +6 -6
  37. package/dist/views/admin/payout-account/tabs/PaymentStatus.vue.d.ts +6 -6
  38. package/dist/views/admin/payout-account/tabs/Settlement.vue.d.ts +6 -6
  39. package/dist/views/admin/restaurant/tabs/PaymentGateway.vue.d.ts +2 -2
  40. package/dist/views/admin/settlement/SettlementTable.vue.d.ts +12 -12
  41. package/dist/views/admin/terminal/TerminalDialog.vue.d.ts +8 -8
  42. package/dist/views/admin/terminal/tabs/FiuuGateway.vue.d.ts +8 -8
  43. package/dist/views/admin/terminal/tabs/GhlGateway.vue.d.ts +8 -8
  44. package/dist/views/admin/terminal/tabs/Information.vue.d.ts +8 -8
  45. package/dist/views/admin/terminal/tabs/TerminalGateway.vue.d.ts +8 -8
  46. package/dist/views/admin/terminal-transaction/cell/Actions.vue.d.ts +1 -3
  47. package/dist/views/admin/transaction/cell/Actions.vue.d.ts +1 -1
  48. package/dist/views/payout-account/PayoutAccountTable.vue.d.ts +12 -12
  49. package/dist/views/settlement/SettlementTable.vue.d.ts +12 -12
  50. package/package.json +2 -2
  51. package/dist/Restaurant-BouKFsha.js +0 -302
  52. package/dist/Terminal-D7EMm_un.js +0 -404
  53. package/dist/grafana-CqkYm_ru.js +0 -46
  54. package/dist/helpers/grafana.d.ts +0 -7
  55. package/dist/views/admin/restaurant/cell/LogButton.vue.d.ts +0 -5
@@ -1,19 +1,18 @@
1
- import { defineComponent as b, resolveComponent as h, openBlock as p, createBlock as E, normalizeClass as R, withCtx as w, createElementVNode as g, toDisplayString as V, createElementBlock as A, unref as u, createVNode as d, Fragment as Y, renderList as $, ref as C, watch as v, isRef as I, h as y } from "vue";
2
- import { t as _, a as P, b as N } from "./transaction-DNuE-yMH.js";
1
+ import { defineComponent as b, resolveComponent as g, openBlock as p, createBlock as E, normalizeClass as q, withCtx as w, createElementVNode as h, toDisplayString as Y, createElementBlock as A, unref as u, createVNode as d, Fragment as $, renderList as C, ref as P, watch as N, isRef as v, h as _ } from "vue";
2
+ import { t as y, a as R, b as I } from "./transaction-Bxl86wzh.js";
3
3
  import { h as T } from "./moment-h96o7c8I.js";
4
- import { u as L } from "./index-DzBM1rDP.js";
5
- import { _ as U } from "./AdminLayout.vue_vue_type_script_setup_true_lang-BTmMOzwx.js";
6
- import { _ as B } from "./AsyncButton.vue_vue_type_script_setup_true_lang-DcjzvYwT.js";
7
- import { useSnackbar as G, useDialog as j } from "@feedmepos/ui-library";
4
+ import { u as V } from "./index-BerQZMQW.js";
5
+ import { _ as B } from "./AdminLayout.vue_vue_type_script_setup_true_lang-BTmMOzwx.js";
6
+ import { _ as L } from "./AsyncButton.vue_vue_type_script_setup_true_lang-DcjzvYwT.js";
7
+ import { useSnackbar as U, useDialog as G } from "@feedmepos/ui-library";
8
8
  import { w as D } from "./Modal-DB8M9o1T.js";
9
9
  import { u as x } from "./error-K1CakhA9.js";
10
- import { _ as Q } from "./DateRangePicker.vue_vue_type_script_setup_true_lang-dP_5WjEJ.js";
11
- import { g as z } from "./grafana-CqkYm_ru.js";
12
- import { _ as H } from "./index.vue_vue_type_script_setup_true_lang-BmM0EooD.js";
13
- import { e as S } from "./index-C1AMSmO9.js";
14
- import { g as J, a as W } from "./assets-C_LulpgD.js";
15
- import { _ as X } from "./AutoCopyCell.vue_vue_type_script_setup_true_lang-CdmfrBoW.js";
16
- const Z = /* @__PURE__ */ b({
10
+ import { _ as j } from "./DateRangePicker.vue_vue_type_script_setup_true_lang-dP_5WjEJ.js";
11
+ import { _ as Q } from "./index.vue_vue_type_script_setup_true_lang-BgTr7KWF.js";
12
+ import { e as S } from "./index-Dj_LwPBy.js";
13
+ import { g as z, a as H } from "./assets-DjRoCcqv.js";
14
+ import { _ as J } from "./AutoCopyCell.vue_vue_type_script_setup_true_lang-CdmfrBoW.js";
15
+ const W = /* @__PURE__ */ b({
17
16
  __name: "Status",
18
17
  props: {
19
18
  row: {},
@@ -25,19 +24,19 @@ const Z = /* @__PURE__ */ b({
25
24
  return a.data === S.F_PAYMENT_TRANSACTION_STATUS.Enum.PENDING ? "!w-[16px] !h-[16px] bg-yellow-400" : a.data === S.F_PAYMENT_TRANSACTION_STATUS.Enum.FAILED ? "!w-[16px] !h-[16px] bg-red-400" : a.data === S.F_PAYMENT_TRANSACTION_STATUS.Enum.REFUNDED ? "!w-[16px] !h-[16px] bg-blue-400" : "!w-[16px] !h-[16px] bg-green-400";
26
25
  }
27
26
  return (i, s) => {
28
- const m = h("FmBadge");
27
+ const m = g("FmBadge");
29
28
  return p(), E(m, {
30
29
  inline: "",
31
- class: R(o())
30
+ class: q(o())
32
31
  }, {
33
32
  default: w(() => [
34
- g("div", null, V(i.data), 1)
33
+ h("div", null, Y(i.data), 1)
35
34
  ]),
36
35
  _: 1
37
36
  }, 8, ["class"]);
38
37
  };
39
38
  }
40
- }), ee = ["src"], te = /* @__PURE__ */ b({
39
+ }), X = ["src"], Z = /* @__PURE__ */ b({
41
40
  __name: "Gateway",
42
41
  props: {
43
42
  row: {},
@@ -46,10 +45,10 @@ const Z = /* @__PURE__ */ b({
46
45
  setup(f) {
47
46
  return (a, o) => (p(), A("img", {
48
47
  class: "rounded-md m-auto border-transparent object-contain w-[32px] h-[32px]",
49
- src: u(J)(a.row.original.gateway)
50
- }, null, 8, ee));
48
+ src: u(z)(a.row.original.gateway)
49
+ }, null, 8, X));
51
50
  }
52
- }), ae = ["src"], ne = /* @__PURE__ */ b({
51
+ }), ee = ["src"], te = /* @__PURE__ */ b({
53
52
  __name: "Method",
54
53
  props: {
55
54
  row: {},
@@ -58,10 +57,10 @@ const Z = /* @__PURE__ */ b({
58
57
  setup(f) {
59
58
  return (a, o) => (p(), A("img", {
60
59
  class: "rounded-md m-auto border-transparent w-[32px] h-[32px]",
61
- src: u(W)(a.row.original.method.issuer)
62
- }, null, 8, ae));
60
+ src: u(H)(a.row.original.method.issuer)
61
+ }, null, 8, ee));
63
62
  }
64
- }), re = /* @__PURE__ */ b({
63
+ }), ae = /* @__PURE__ */ b({
65
64
  __name: "Actions",
66
65
  props: {
67
66
  onAction: { type: Function }
@@ -85,16 +84,10 @@ const Z = /* @__PURE__ */ b({
85
84
  sublabel: "Perform webhook notification for transaction",
86
85
  icon: "webhook",
87
86
  action: "notify"
88
- },
89
- {
90
- label: "Log",
91
- sublabel: "Inspect transaction historical actions, requests and responses.",
92
- icon: "history",
93
- action: "history"
94
87
  }
95
88
  ];
96
89
  return (o, i) => {
97
- const s = h("FmIcon"), m = h("FmMenuItem"), F = h("FmMenu");
90
+ const s = g("FmIcon"), m = g("FmMenuItem"), F = g("FmMenu");
98
91
  return p(), A("div", {
99
92
  onClick: i[0] || (i[0] = (c) => {
100
93
  c.stopPropagation();
@@ -105,7 +98,7 @@ const Z = /* @__PURE__ */ b({
105
98
  d(s, { name: "settings" })
106
99
  ]),
107
100
  default: w(() => [
108
- (p(), A(Y, null, $(a, (c) => d(m, {
101
+ (p(), A($, null, C(a, (c) => d(m, {
109
102
  selectable: !0,
110
103
  key: c.label,
111
104
  sublabel: c.sublabel,
@@ -119,19 +112,19 @@ const Z = /* @__PURE__ */ b({
119
112
  ]);
120
113
  };
121
114
  }
122
- }), oe = { class: "flex justify-between mb-6 items-center" }, se = { class: "flex space-x-4" }, ce = { class: "flex space-x-4 self-center" }, ie = { class: "mb-6" }, xe = /* @__PURE__ */ b({
115
+ }), ne = { class: "flex justify-between mb-6 items-center" }, re = { class: "flex space-x-4" }, oe = { class: "flex space-x-4 self-center" }, se = { class: "mb-6" }, we = /* @__PURE__ */ b({
123
116
  __name: "Transaction",
124
117
  setup(f) {
125
- const a = C(), { dateRange: o, searchKey: i } = L({
118
+ const a = P(), { dateRange: o, searchKey: i } = V({
126
119
  searchKey: "",
127
120
  dateRange: {
128
121
  startDate: T().startOf("day").format("YYYY-MM-DD"),
129
122
  endDate: T().endOf("day").format("YYYY-MM-DD")
130
123
  }
131
- }), s = G(), m = j(), F = async (e, t) => {
124
+ }), s = U(), m = G(), F = async (e, t) => {
132
125
  let r = parseInt(t);
133
126
  Number.isNaN(r) && (r = 1);
134
- const n = await _.readTransactions({
127
+ const n = await y.readTransactions({
135
128
  start: T(o.value.startDate).startOf("day").toISOString(),
136
129
  end: T(o.value.endDate).endOf("day").toISOString(),
137
130
  limit: e,
@@ -139,18 +132,18 @@ const Z = /* @__PURE__ */ b({
139
132
  search: i.value
140
133
  }), l = n.length == e;
141
134
  return {
142
- data: P(n),
135
+ data: R(n),
143
136
  meta: {
144
137
  cursor: l ? (r + 1).toString() : ""
145
138
  }
146
139
  };
147
140
  };
148
- v(o, async () => {
141
+ N(o, async () => {
149
142
  var e;
150
143
  (e = a.value) == null || e.reset();
151
144
  });
152
145
  let c;
153
- v(i, async () => {
146
+ N(i, async () => {
154
147
  c && clearTimeout(c), c = setTimeout(() => {
155
148
  var e;
156
149
  (e = a.value) == null || e.reset();
@@ -168,8 +161,8 @@ const Z = /* @__PURE__ */ b({
168
161
  return;
169
162
  }
170
163
  try {
171
- const l = await _.refetchTransaction({ transactionId: t.id });
172
- (n = a.value) == null || n.replaceData(e, N(l)), s.open({
164
+ const l = await y.refetchTransaction({ transactionId: t.id });
165
+ (n = a.value) == null || n.replaceData(e, I(l)), s.open({
173
166
  type: "success",
174
167
  title: "Transaction queried and updated successfully."
175
168
  });
@@ -199,12 +192,12 @@ const Z = /* @__PURE__ */ b({
199
192
  async () => {
200
193
  var n;
201
194
  try {
202
- const l = await _.refundTransaction({
195
+ const l = await y.refundTransaction({
203
196
  transactionId: t.id,
204
197
  reason: "portal transaction refund",
205
198
  amount: t.fdoAmount
206
199
  });
207
- (n = a.value) == null || n.replaceData(e, N(l)), s.open({
200
+ (n = a.value) == null || n.replaceData(e, I(l)), s.open({
208
201
  type: "success",
209
202
  title: "Transaction refund request initiated."
210
203
  });
@@ -235,7 +228,7 @@ const Z = /* @__PURE__ */ b({
235
228
  "Are you sure to perform notify transaction?",
236
229
  async () => {
237
230
  try {
238
- await _.renotifyTransaction(t.id), s.open({
231
+ await y.renotifyTransaction(t.id), s.open({
239
232
  type: "success",
240
233
  title: "Transaction notify successfully."
241
234
  });
@@ -249,31 +242,11 @@ const Z = /* @__PURE__ */ b({
249
242
  }
250
243
  );
251
244
  }
252
- async function q(e) {
253
- var n;
254
- const t = (n = a.value) == null ? void 0 : n.pageData().at(e);
255
- if (!t) {
256
- s.open({
257
- type: "error",
258
- title: "Something went wrong",
259
- message: "Fail to find transactions from the displayed transactions."
260
- });
261
- return;
262
- }
263
- const r = z([
264
- {
265
- type: "span",
266
- queryKey: "transaction.id",
267
- queryValue: t.id
268
- }
269
- ], t.createdAt);
270
- window.open(r, "_blank");
271
- }
272
245
  const K = [
273
246
  {
274
247
  header: () => "Transaction ID",
275
248
  accessorKey: "id",
276
- cell: ({ cell: e }) => y(X, { data: e.getValue() })
249
+ cell: ({ cell: e }) => _(J, { data: e.getValue() })
277
250
  },
278
251
  {
279
252
  header: () => "Pay ID",
@@ -285,7 +258,7 @@ const Z = /* @__PURE__ */ b({
285
258
  meta: {
286
259
  textAlign: "center"
287
260
  },
288
- cell: ({ cell: e, row: t }) => t.original.method ? y(te, { row: t, data: e.getValue() }) : ""
261
+ cell: ({ cell: e, row: t }) => t.original.method ? _(Z, { row: t, data: e.getValue() }) : ""
289
262
  },
290
263
  {
291
264
  header: () => "Method",
@@ -293,7 +266,7 @@ const Z = /* @__PURE__ */ b({
293
266
  meta: {
294
267
  textAlign: "center"
295
268
  },
296
- cell: ({ cell: e, row: t }) => t.original.method ? y(ne, { row: t, data: e.getValue() }) : ""
269
+ cell: ({ cell: e, row: t }) => t.original.method ? _(te, { row: t, data: e.getValue() }) : ""
297
270
  },
298
271
  {
299
272
  header: () => "Type",
@@ -311,7 +284,7 @@ const Z = /* @__PURE__ */ b({
311
284
  {
312
285
  header: () => "Status",
313
286
  accessorKey: "status",
314
- cell: ({ cell: e, row: t }) => y(Z, { row: t, data: e.getValue() })
287
+ cell: ({ cell: e, row: t }) => _(W, { row: t, data: e.getValue() })
315
288
  },
316
289
  {
317
290
  header: () => "Transaction At",
@@ -335,7 +308,7 @@ const Z = /* @__PURE__ */ b({
335
308
  {
336
309
  header: () => "Actions",
337
310
  accessorKey: "actions",
338
- cell: ({ row: e }) => y(re, {
311
+ cell: ({ row: e }) => _(ae, {
339
312
  onAction: (t) => {
340
313
  switch (t) {
341
314
  case "notify":
@@ -344,39 +317,37 @@ const Z = /* @__PURE__ */ b({
344
317
  return k(e.index);
345
318
  case "refund":
346
319
  return M(e.index);
347
- case "history":
348
- return q(e.index);
349
320
  }
350
321
  }
351
322
  })
352
323
  }
353
324
  ];
354
325
  return (e, t) => {
355
- const r = h("FmSearch");
356
- return p(), E(U, {
326
+ const r = g("FmSearch");
327
+ return p(), E(B, {
357
328
  title: "Online Transactions",
358
329
  loading: !1
359
330
  }, {
360
331
  default: w(() => [
361
- g("div", oe, [
362
- g("div", se, [
332
+ h("div", ne, [
333
+ h("div", re, [
363
334
  d(r, {
364
335
  "model-value": u(i),
365
- "onUpdate:modelValue": t[0] || (t[0] = (n) => I(i) ? i.value = n : null),
336
+ "onUpdate:modelValue": t[0] || (t[0] = (n) => v(i) ? i.value = n : null),
366
337
  class: "mr-8",
367
338
  label: "Search",
368
339
  placeholder: "Search Transactions ..."
369
340
  }, null, 8, ["model-value"])
370
341
  ]),
371
- g("div", ce, [
372
- d(B, {
342
+ h("div", oe, [
343
+ d(L, {
373
344
  button: {
374
345
  appendIcon: "file_download",
375
346
  variant: "primary",
376
347
  label: "Export"
377
348
  },
378
349
  handler: async () => {
379
- await u(_).downloadTransactionReport({
350
+ await u(y).downloadTransactionReport({
380
351
  start: u(o).startDate,
381
352
  end: u(o).endDate
382
353
  });
@@ -384,13 +355,13 @@ const Z = /* @__PURE__ */ b({
384
355
  }, null, 8, ["handler"])
385
356
  ])
386
357
  ]),
387
- g("div", ie, [
388
- d(Q, {
358
+ h("div", se, [
359
+ d(j, {
389
360
  modelValue: u(o),
390
- "onUpdate:modelValue": t[1] || (t[1] = (n) => I(o) ? o.value = n : null)
361
+ "onUpdate:modelValue": t[1] || (t[1] = (n) => v(o) ? o.value = n : null)
391
362
  }, null, 8, ["modelValue"])
392
363
  ]),
393
- d(H, {
364
+ d(Q, {
394
365
  ref_key: "controller",
395
366
  ref: a,
396
367
  "column-defs": K,
@@ -404,5 +375,5 @@ const Z = /* @__PURE__ */ b({
404
375
  }
405
376
  });
406
377
  export {
407
- xe as default
378
+ we as default
408
379
  };