@feedmepos/mf-payment 1.11.16-dev → 1.11.17-dev

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (145) hide show
  1. package/dist/Actions.vue_vue_type_script_setup_true_lang-COGP4bH0.js +64 -0
  2. package/dist/{AdminBusinessSelector.vue_vue_type_script_setup_true_lang-BvhrP3i-.js → AdminBusinessSelector.vue_vue_type_script_setup_true_lang-DpSmJgWn.js} +3 -3
  3. package/dist/{AdminRestaurantSelector.vue_vue_type_script_setup_true_lang-BjGEcK8R.js → AdminRestaurantSelector.vue_vue_type_script_setup_true_lang-BVqrbU1b.js} +3 -3
  4. package/dist/{Chargeback-CCzx9M4d.js → Chargeback-BqQYNBGo.js} +6 -6
  5. package/dist/{DocumentViewer.vue_vue_type_script_setup_true_lang-Cgetk-s9.js → DocumentViewer.vue_vue_type_script_setup_true_lang-DERNbQ3k.js} +473 -473
  6. package/dist/{ExternalTerminal-BL5sEkJK.js → ExternalTerminal-fNOdfUBA.js} +7 -7
  7. package/dist/FoodCourtPayoutAccount-DNAcTdWF.js +187 -0
  8. package/dist/FoodCourtSettlement-CTtJEJ7Q.js +68 -0
  9. package/dist/FoodCourtTransaction-BaqOpZ2h.js +212 -0
  10. package/dist/Method.vue_vue_type_script_setup_true_lang-CYxMDr_T.js +58 -0
  11. package/dist/{OnboardForm-CHBL2xs2.js → OnboardForm-B4r4MFFi.js} +6 -6
  12. package/dist/{OnboardForm-CwoQ-u0X.js → OnboardForm-Bz_kBQ_2.js} +6 -6
  13. package/dist/{OnboardSubmission-De50hDlQ.js → OnboardSubmission-D_Mi1LR5.js} +6 -6
  14. package/dist/{OnboardSubmission-CwdA6Fh0.js → OnboardSubmission-GAG1q9Cu.js} +4 -4
  15. package/dist/{PaymentCheckout-C4zXAkTu.js → PaymentCheckout-BCy5_Qc8.js} +2 -2
  16. package/dist/{PayoutAccount-ChqGHuRR.js → PayoutAccount-9jZqReid.js} +7 -7
  17. package/dist/PayoutAccount-BDdUpPUJ.js +405 -0
  18. package/dist/{PayoutAccountSetting-SjFMSEu9.js → PayoutAccountSetting-CbRrZ-uL.js} +7 -7
  19. package/dist/{Restaurant-CYJ-XLRZ.js → Restaurant-yzTw6u3J.js} +5 -5
  20. package/dist/{RestaurantSetting-BdXl1yPZ.js → RestaurantSetting-LtwUZbiZ.js} +4 -4
  21. package/dist/Settlement-BTNKWaS6.js +510 -0
  22. package/dist/{Settlement-DFRxxs_m.js → Settlement-DKC-8m5B.js} +3 -3
  23. package/dist/SettlementTable.vue_vue_type_script_setup_true_lang-hjz9Xw5x.js +132 -0
  24. package/dist/{SettlementTransactions-C3Fsm_X9.js → SettlementTransactions-B0wn4zEK.js} +106 -97
  25. package/dist/{SettlementTransactions-CGBKh1GN.js → SettlementTransactions-BA8lVRms.js} +5 -5
  26. package/dist/{Status.vue_vue_type_script_setup_true_lang-B64OGluJ.js → Status.vue_vue_type_script_setup_true_lang-B8QvOL7Z.js} +1 -1
  27. package/dist/{Terminal-C-rbyBC8.js → Terminal-jqcSPL2f.js} +7 -7
  28. package/dist/{TerminalSetting-CcTRaKIt.js → TerminalSetting-IkoP5RPL.js} +8 -8
  29. package/dist/{TerminalTemplate-DLaa9wUZ.js → TerminalTemplate-kSeKVJ-C.js} +5 -5
  30. package/dist/{TerminalTemplateSetting-YzhPDF8J.js → TerminalTemplateSetting-C7Q0ofoT.js} +6 -6
  31. package/dist/{Transaction-ou3zdIBB.js → Transaction-B9E6DQye.js} +16 -15
  32. package/dist/{Transaction-Bk8usnmd.js → Transaction-CauQVnjl.js} +54 -52
  33. package/dist/{TransactionOld-0X1celu9.js → TransactionOld-fdLtZOUV.js} +10 -9
  34. package/dist/{TransactionStatus.vue_vue_type_script_setup_true_lang-BS4AYaq1.js → TransactionStatus.vue_vue_type_script_setup_true_lang-Cm-r2le1.js} +1 -1
  35. package/dist/api/document/index.d.ts +2 -0
  36. package/dist/api/food-court/index.d.ts +31 -0
  37. package/dist/{app-obftSkFb.js → app-LpRZG5SK.js} +2420 -2351
  38. package/dist/app.js +1 -1
  39. package/dist/{assets-DLPXM2Y4.js → assets-CU3fydSV.js} +1 -1
  40. package/dist/{grafana-BXLOtIvx.js → grafana-BBPv2vBQ.js} +1 -1
  41. package/dist/{index-Baec1AT2.js → index-BFqUsoWz.js} +4227 -4176
  42. package/dist/{index-a8lvAiCb.js → index-Be6BYI6Y.js} +52 -29
  43. package/dist/{index-owIgdVJd.js → index-CY-XsXFD.js} +1 -1
  44. package/dist/index-CazeCsOR.js +13 -0
  45. package/dist/{index-CJPHA9xo.js → index-CfdnF9Hu.js} +1 -1
  46. package/dist/{index-CtbE-KF0.js → index-CnXoDo29.js} +1 -1
  47. package/dist/{index-CR-HSdwu.js → index-DDRoa9oc.js} +2 -2
  48. package/dist/{index-Dlng-M3Z.js → index-DFb6LwIH.js} +2 -2
  49. package/dist/{index-CK7aA2pd.js → index-DGBA5vc9.js} +1 -1
  50. package/dist/index-DYFngO0V.js +75 -0
  51. package/dist/{index-BQadSOBj.js → index-Da1J8lF1.js} +1 -1
  52. package/dist/{index-CAT0OmJZ.js → index-DhTmRVyJ.js} +1 -1
  53. package/dist/{index-DRy36FqO.js → index-T3wrZJyq.js} +1 -1
  54. package/dist/index-j-zqgMuS.js +52 -0
  55. package/dist/{index.vue_vue_type_script_setup_true_lang-DrxOa3Bv.js → index.vue_vue_type_script_setup_true_lang-DiniY5At.js} +1 -1
  56. package/dist/{PayoutAccount-CpJaVhKj.js → mascot-side-DNc7naiM.js} +206 -598
  57. package/dist/model/payout-account.d.ts +3 -2
  58. package/dist/{onboard-submission-Dzw9Nu3k.js → onboard-submission-CYp6UpDI.js} +2 -2
  59. package/dist/package.json +3 -3
  60. package/dist/{payout-account-BXeQXNBN.js → payout-account-B8ZjV2cD.js} +179 -169
  61. package/dist/router/food-court.d.ts +3 -0
  62. package/dist/router/index.d.ts +3 -1
  63. package/dist/stores/payoutAccount.d.ts +40 -38
  64. package/dist/style.css +1 -1
  65. package/dist/tsconfig.app.tsbuildinfo +1 -1
  66. package/dist/{useQuery-COlCU4ZR.js → useQuery-BKgSfFAn.js} +1 -1
  67. package/dist/utils/food-court.d.ts +2 -0
  68. package/dist/views/admin/external-terminal/ExternalTerminalPairDialog.vue.d.ts +8 -8
  69. package/dist/views/admin/external-terminal/ExternalTerminalSideSheet.vue.d.ts +14 -14
  70. package/dist/views/admin/external-terminal/pair/BRITerminal.vue.d.ts +8 -8
  71. package/dist/views/admin/external-terminal/pair/BeamTerminal.vue.d.ts +8 -8
  72. package/dist/views/admin/onboard-submission/forms/NTTSubmission.vue.d.ts +20 -20
  73. package/dist/views/admin/onboard-submission/forms/SoftspaceSubmission.vue.d.ts +20 -20
  74. package/dist/views/admin/onboard-submission/forms/TeyaSubmission.vue.d.ts +20 -20
  75. package/dist/views/admin/onboard-submission/forms/TyroSubmission.vue.d.ts +20 -20
  76. package/dist/views/admin/payout-account/tabs/Information.vue.d.ts +40 -38
  77. package/dist/views/admin/payout-account/tabs/PaymentChannel.vue.d.ts +62 -60
  78. package/dist/views/admin/payout-account/tabs/PaymentGateway.vue.d.ts +62 -60
  79. package/dist/views/admin/payout-account/tabs/PaymentStatus.vue.d.ts +40 -38
  80. package/dist/views/admin/payout-account/tabs/Settlement.vue.d.ts +40 -38
  81. package/dist/views/admin/payout-account/tabs/TokenGateway.vue.d.ts +62 -60
  82. package/dist/views/admin/payout-account/tabs/gateway/AdyenGateway.vue.d.ts +4 -4
  83. package/dist/views/admin/payout-account/tabs/gateway/BeamGateway.vue.d.ts +2 -2
  84. package/dist/views/admin/payout-account/tabs/gateway/DigioGateway.vue.d.ts +2 -2
  85. package/dist/views/admin/payout-account/tabs/gateway/FiuuGateway.vue.d.ts +2 -2
  86. package/dist/views/admin/payout-account/tabs/gateway/KsherGateway.vue.d.ts +2 -2
  87. package/dist/views/admin/payout-account/tabs/gateway/MacauPassGateway.vue.d.ts +2 -2
  88. package/dist/views/admin/payout-account/tabs/gateway/TyroGateway.vue.d.ts +2 -2
  89. package/dist/views/admin/payout-account/tabs/token/ApplePayToken.vue.d.ts +2 -2
  90. package/dist/views/admin/payout-account/tabs/token/GooglePayToken.vue.d.ts +2 -2
  91. package/dist/views/admin/restaurant/tabs/gateway/AdyenGateway.vue.d.ts +6 -4
  92. package/dist/views/admin/restaurant/tabs/gateway/BeamGateway.vue.d.ts +6 -4
  93. package/dist/views/admin/restaurant/tabs/gateway/DigioGateway.vue.d.ts +6 -4
  94. package/dist/views/admin/restaurant/tabs/gateway/FiuuGateway.vue.d.ts +6 -4
  95. package/dist/views/admin/restaurant/tabs/gateway/GhlGateway.vue.d.ts +6 -4
  96. package/dist/views/admin/restaurant/tabs/gateway/GrabGateway.vue.d.ts +6 -4
  97. package/dist/views/admin/restaurant/tabs/gateway/KsherGateway.vue.d.ts +6 -4
  98. package/dist/views/admin/restaurant/tabs/gateway/MacauPassGateway.vue.d.ts +6 -4
  99. package/dist/views/admin/restaurant/tabs/gateway/MaybankGateway.vue.d.ts +6 -4
  100. package/dist/views/admin/restaurant/tabs/gateway/MonetapayGateway.vue.d.ts +6 -4
  101. package/dist/views/admin/restaurant/tabs/gateway/RevenueMonsterGateway.vue.d.ts +6 -4
  102. package/dist/views/admin/restaurant/tabs/gateway/SoftSpaceGateway.vue.d.ts +6 -4
  103. package/dist/views/admin/settlement/SettlementTable.vue.d.ts +4 -4
  104. package/dist/views/admin/terminal/TerminalSideSheet.vue.d.ts +22 -20
  105. package/dist/views/admin/terminal/tabs/EcrGateway.vue.d.ts +22 -20
  106. package/dist/views/admin/terminal/tabs/Information.vue.d.ts +22 -20
  107. package/dist/views/admin/terminal/tabs/PaymentCheckout.vue.d.ts +22 -20
  108. package/dist/views/admin/terminal/tabs/QrGateway.vue.d.ts +22 -20
  109. package/dist/views/admin/terminal/tabs/SettingRequest.vue.d.ts +22 -20
  110. package/dist/views/admin/terminal/tabs/SoftposGateway.vue.d.ts +22 -20
  111. package/dist/views/admin/terminal/tabs/ecr/BeamGateway.vue.d.ts +22 -20
  112. package/dist/views/admin/terminal/tabs/ecr/BriGateway.vue.d.ts +22 -20
  113. package/dist/views/admin/terminal/tabs/ecr/Ghl2Gateway.vue.d.ts +22 -20
  114. package/dist/views/admin/terminal/tabs/ecr/Ghl3Gateway.vue.d.ts +22 -20
  115. package/dist/views/admin/terminal/tabs/ecr/GhlGateway.vue.d.ts +22 -20
  116. package/dist/views/admin/terminal/tabs/ecr/GlobalPaymentsGateway.vue.d.ts +22 -20
  117. package/dist/views/admin/terminal/tabs/ecr/HlbbGateway.vue.d.ts +22 -20
  118. package/dist/views/admin/terminal/tabs/ecr/KBankGateway.vue.d.ts +22 -20
  119. package/dist/views/admin/terminal/tabs/ecr/Maybank2Gateway.vue.d.ts +22 -20
  120. package/dist/views/admin/terminal/tabs/ecr/Maybank3Gateway.vue.d.ts +22 -20
  121. package/dist/views/admin/terminal/tabs/ecr/MaybankGateway.vue.d.ts +22 -20
  122. package/dist/views/admin/terminal/tabs/ecr/NetsGateway.vue.d.ts +22 -20
  123. package/dist/views/admin/terminal/tabs/ecr/OmaGateway.vue.d.ts +22 -20
  124. package/dist/views/admin/terminal/tabs/ecr/PbbGateway.vue.d.ts +22 -20
  125. package/dist/views/admin/terminal/tabs/ecr/RevenueGateway.vue.d.ts +22 -20
  126. package/dist/views/admin/terminal/tabs/ecr/TerminalGateway.vue.d.ts +22 -20
  127. package/dist/views/admin/terminal/tabs/ecr/TeyaGateway.vue.d.ts +22 -20
  128. package/dist/views/admin/terminal/tabs/qr/PromptPayGateway.vue.d.ts +22 -20
  129. package/dist/views/admin/terminal/tabs/settings/KioskMode.vue.d.ts +22 -20
  130. package/dist/views/admin/terminal-template/TerminalTemplateSideSheet.vue.d.ts +26 -26
  131. package/dist/views/admin/terminal-template/tabs/EcrGateways.vue.d.ts +16 -16
  132. package/dist/views/admin/terminal-template/tabs/Information.vue.d.ts +16 -16
  133. package/dist/views/food-court/FoodCourtPayoutAccount.vue.d.ts +2 -0
  134. package/dist/views/food-court/FoodCourtSettlement.vue.d.ts +2 -0
  135. package/dist/views/food-court/FoodCourtTransaction.vue.d.ts +2 -0
  136. package/dist/views/onboard-submission/useTeyaConnect.d.ts +1 -1
  137. package/dist/views/payout-account/PayoutAccountTable.vue.d.ts +80 -76
  138. package/dist/views/settlement/FiuuSettlementTable.vue.d.ts +28 -28
  139. package/dist/views/settlement/FiuuSettlementTransactions.vue.d.ts +14 -14
  140. package/dist/views/settlement/SettlementTable.vue.d.ts +15 -5
  141. package/dist/views/settlement/SettlementTransactions.vue.d.ts +11 -1
  142. package/package.json +3 -3
  143. package/dist/Actions.vue_vue_type_script_setup_true_lang-C7wa3o3y.js +0 -118
  144. package/dist/Settlement-DlNwIY-o.js +0 -625
  145. package/dist/index-n58-Qewm.js +0 -62
@@ -1,7 +1,8 @@
1
- import { b as i, c } from "./index-Baec1AT2.js";
2
- async function g(e) {
1
+ import { b as c, c as d } from "./index-BFqUsoWz.js";
2
+ import { a as p } from "./index-DYFngO0V.js";
3
+ async function w(e) {
3
4
  if (e.type !== "image/png") return e;
4
- const t = await w(e), n = document.createElement("canvas");
5
+ const t = await g(e), n = document.createElement("canvas");
5
6
  n.width = t.width, n.height = t.height;
6
7
  const a = n.getContext("2d");
7
8
  if (!a) throw new Error("Failed to get 2D canvas context");
@@ -17,7 +18,7 @@ async function g(e) {
17
18
  }, "image/png");
18
19
  });
19
20
  }
20
- function w(e) {
21
+ function g(e) {
21
22
  return new Promise((t, n) => {
22
23
  const a = new Image();
23
24
  a.onload = () => {
@@ -27,48 +28,48 @@ function w(e) {
27
28
  }, a.src = URL.createObjectURL(e);
28
29
  });
29
30
  }
30
- const u = 2e3, h = 0.8, d = /\.(png|jpe?g|gif|bmp|webp|heic|heif)$/i;
31
- async function l(e) {
31
+ const h = 2e3, l = 0.8, m = /\.(png|jpe?g|gif|bmp|webp|heic|heif)$/i;
32
+ async function f(e) {
32
33
  if (!e.type.startsWith("image/")) return e;
33
34
  try {
34
- const t = await f(e), n = y(t), a = await E(n);
35
- return new File([a], m(e.name), {
35
+ const t = await y(e), n = E(t), a = await U(n);
36
+ return new File([a], u(e.name), {
36
37
  type: "image/jpeg",
37
38
  lastModified: e.lastModified
38
39
  });
39
40
  } catch {
40
- return await g(e);
41
+ return await w(e);
41
42
  }
42
43
  }
43
- function m(e) {
44
- return d.test(e) ? e.replace(d, ".jpg") : e;
44
+ function u(e) {
45
+ return m.test(e) ? e.replace(m, ".jpg") : e;
45
46
  }
46
- async function f(e) {
47
+ async function y(e) {
47
48
  try {
48
49
  return await createImageBitmap(e, { imageOrientation: "from-image" });
49
50
  } catch {
50
- return await U(e);
51
+ return await R(e);
51
52
  }
52
53
  }
53
- function y(e) {
54
- const t = Math.min(1, u / Math.max(e.width, e.height)), n = document.createElement("canvas");
54
+ function E(e) {
55
+ const t = Math.min(1, h / Math.max(e.width, e.height)), n = document.createElement("canvas");
55
56
  n.width = Math.max(1, Math.round(e.width * t)), n.height = Math.max(1, Math.round(e.height * t));
56
57
  const a = n.getContext("2d");
57
58
  if (!a) throw new Error("Failed to get 2D canvas context");
58
59
  return a.imageSmoothingQuality = "high", a.fillStyle = "#ffffff", a.fillRect(0, 0, n.width, n.height), a.drawImage(e, 0, 0, n.width, n.height), "close" in e && e.close(), n;
59
60
  }
60
- function E(e) {
61
+ function U(e) {
61
62
  return new Promise((t, n) => {
62
63
  e.toBlob(
63
64
  (a) => {
64
65
  a ? t(a) : n(new Error("Canvas JPEG export failed"));
65
66
  },
66
67
  "image/jpeg",
67
- h
68
+ l
68
69
  );
69
70
  });
70
71
  }
71
- function U(e) {
72
+ function R(e) {
72
73
  return new Promise((t, n) => {
73
74
  const a = new Image();
74
75
  a.onload = () => {
@@ -78,14 +79,14 @@ function U(e) {
78
79
  }, a.src = URL.createObjectURL(e);
79
80
  });
80
81
  }
81
- async function p(e, t) {
82
- const n = await l(t);
83
- return n === t ? { file: e, blob: t } : { file: m(e), blob: n };
82
+ async function i(e, t) {
83
+ const n = await f(t);
84
+ return n === t ? { file: e, blob: t } : { file: u(e), blob: n };
84
85
  }
85
- const v = {
86
+ const I = {
86
87
  async upload(e, t, n) {
87
- ({ file: e, blob: t } = await p(e, t));
88
- const o = (await c().post("/document/presign", {
88
+ ({ file: e, blob: t } = await i(e, t));
89
+ const o = (await d().post("/document/presign", {
89
90
  file: e,
90
91
  restaurantId: n
91
92
  })).data.url;
@@ -100,8 +101,8 @@ const v = {
100
101
  return e;
101
102
  },
102
103
  async adminUpload(e, t, n, a) {
103
- ({ file: e, blob: t } = await p(e, t));
104
- const r = (await i().post(
104
+ ({ file: e, blob: t } = await i(e, t));
105
+ const r = (await c().post(
105
106
  `/businesses/${n}/document/presign`,
106
107
  {
107
108
  file: e,
@@ -118,14 +119,36 @@ const v = {
118
119
  throw new Error("Failed to upload document");
119
120
  return e;
120
121
  },
122
+ async foodCourtUpload(e, t) {
123
+ ({ file: e, blob: t } = await i(e, t));
124
+ const n = await p().post(
125
+ "/document/presign",
126
+ { file: e }
127
+ );
128
+ if (!(await fetch(n.data.url, {
129
+ method: "PUT",
130
+ body: t,
131
+ headers: {
132
+ "Content-Type": t.type || "application/octet-stream"
133
+ }
134
+ })).ok)
135
+ throw new Error("Failed to upload document");
136
+ return e;
137
+ },
138
+ async foodCourtView(e) {
139
+ return (await p().post(
140
+ "/document/view",
141
+ { file: e }
142
+ )).data.url;
143
+ },
121
144
  async view(e, t) {
122
- return (await c().post("/document/view", {
145
+ return (await d().post("/document/view", {
123
146
  file: e,
124
147
  restaurantId: t
125
148
  })).data.url;
126
149
  },
127
150
  async adminView(e, t, n) {
128
- return (await i().post(
151
+ return (await c().post(
129
152
  `/businesses/${t}/document/view`,
130
153
  {
131
154
  file: e,
@@ -135,5 +158,5 @@ const v = {
135
158
  }
136
159
  };
137
160
  export {
138
- v as d
161
+ I as d
139
162
  };
@@ -1,4 +1,4 @@
1
- import { g as t, b as n, c as u, a as e } from "./index-Baec1AT2.js";
1
+ import { g as t, b as n, c as u, a as e } from "./index-BFqUsoWz.js";
2
2
  const o = {
3
3
  async read(a) {
4
4
  return e(
@@ -0,0 +1,13 @@
1
+ import { useCoreStore as r } from "@feedmepos/mf-common";
2
+ const s = () => {
3
+ const { currentCountry: n } = r();
4
+ return {
5
+ getBillLink: (e) => {
6
+ var u;
7
+ return !((u = e.billId) != null && u.startsWith("bill_")) || !e.restaurantId || e.restaurantId == "" || !e.businessId || e.businessId == "" || n.value == null ? null : `/restaurant-operation/transaction/${encodeURIComponent(e.billId)}?restaurantId=${encodeURIComponent(e.restaurantId)}&businessId=${encodeURIComponent(e.businessId)}&country=${encodeURIComponent(n.value)}`;
8
+ }
9
+ };
10
+ };
11
+ export {
12
+ s as u
13
+ };
@@ -1,4 +1,4 @@
1
- import { g as e, b as a, a as n } from "./index-Baec1AT2.js";
1
+ import { g as e, b as a, a as n } from "./index-BFqUsoWz.js";
2
2
  const i = {
3
3
  async create(t) {
4
4
  return e(
@@ -1,4 +1,4 @@
1
- import { d as l, c as s, g as o, b as i, l as c, f as d, e as y } from "./index-Baec1AT2.js";
1
+ import { d as l, c as s, g as o, b as i, l as c, f as d, e as y } from "./index-BFqUsoWz.js";
2
2
  import { h as r } from "./moment-h96o7c8I.js";
3
3
  import { d as p } from "./dinero-CIVmXLL-.js";
4
4
  function* f(t, a) {
@@ -1,5 +1,5 @@
1
- import "./app-obftSkFb.js";
2
- import { a as s, b as e, g as r } from "./index-Baec1AT2.js";
1
+ import "./app-LpRZG5SK.js";
2
+ import { a as s, b as e, g as r } from "./index-BFqUsoWz.js";
3
3
  const u = {
4
4
  async readRestaurantById(a) {
5
5
  const t = await e().get(`/payments/restaurants/${a}`);
@@ -1,6 +1,6 @@
1
- import { g as n, b as a, o as u, a as d } from "./index-Baec1AT2.js";
1
+ import { g as n, b as a, o as u, a as d } from "./index-BFqUsoWz.js";
2
2
  import { h as m } from "./moment-h96o7c8I.js";
3
- import { d as b } from "./index-a8lvAiCb.js";
3
+ import { d as b } from "./index-Be6BYI6Y.js";
4
4
  const w = {
5
5
  async read(s) {
6
6
  return d(
@@ -1,4 +1,4 @@
1
- import { g as s, b as e, a as o, d as I, l as m, c as d, r as f } from "./index-Baec1AT2.js";
1
+ import { g as s, b as e, a as o, d as I, l as m, c as d, r as f } from "./index-BFqUsoWz.js";
2
2
  import { h as n } from "./moment-h96o7c8I.js";
3
3
  const A = {
4
4
  async readBySettlementId(t) {
@@ -0,0 +1,75 @@
1
+ import { b as o, d as n, g as r, a as s } from "./index-BFqUsoWz.js";
2
+ import { h as e } from "./moment-h96o7c8I.js";
3
+ import { w as c } from "./app-LpRZG5SK.js";
4
+ const a = () => {
5
+ const t = c();
6
+ if (!t)
7
+ throw new Error("Invalid food court");
8
+ return o(`/food-courts/${t}`);
9
+ }, y = {
10
+ async readPayoutAccount() {
11
+ try {
12
+ return r(await a().get("/payout-account"));
13
+ } catch {
14
+ return;
15
+ }
16
+ },
17
+ async createPayoutAccount(t) {
18
+ return r(
19
+ await a().post("/payout-account", t)
20
+ );
21
+ },
22
+ async updatePayoutAccount(t) {
23
+ return r(
24
+ await a().put("/payout-account", t)
25
+ );
26
+ },
27
+ async readTransactions(t) {
28
+ return s(
29
+ await a().get("/transactions", {
30
+ params: {
31
+ status: t.status,
32
+ limit: t.limit,
33
+ cursor: t.cursor,
34
+ search: t.search,
35
+ start: e(t.start).startOf("day").toISOString(),
36
+ end: e(t.end).endOf("day").toISOString()
37
+ }
38
+ })
39
+ );
40
+ },
41
+ async readSettlements(t) {
42
+ return r(
43
+ await a().get("/settlements", {
44
+ params: t
45
+ })
46
+ );
47
+ },
48
+ async readSettlementById(t) {
49
+ return r(
50
+ await a().get(`/settlements/${t}`)
51
+ );
52
+ },
53
+ async readTransactionsBySettlementId(t) {
54
+ return r(
55
+ await a().get(
56
+ `/settlements/transactions/${t}`
57
+ )
58
+ );
59
+ },
60
+ async downloadSettlementReport(t) {
61
+ return n(
62
+ await a().get("/settlements/report", {
63
+ params: {
64
+ start: e(t.start).startOf("day").toISOString(),
65
+ end: e(t.end).endOf("day").toISOString()
66
+ }
67
+ }),
68
+ `settlement-report-${t.start}-${t.end}.xlsx`
69
+ );
70
+ }
71
+ };
72
+ export {
73
+ a,
74
+ y as f
75
+ };
@@ -1,4 +1,4 @@
1
- import { g as t, b as e, p as r, c as i, a as s } from "./index-Baec1AT2.js";
1
+ import { g as t, b as e, p as r, c as i, a as s } from "./index-BFqUsoWz.js";
2
2
  const m = {
3
3
  async create(a) {
4
4
  return s(
@@ -1,6 +1,6 @@
1
1
  import { ref as b, watch as w } from "vue";
2
2
  import { useRoute as A, useRouter as m } from "vue-router";
3
- import { w as y } from "./app-obftSkFb.js";
3
+ import { x as y } from "./app-LpRZG5SK.js";
4
4
  var d = {};
5
5
  (function(s) {
6
6
  (function(c) {
@@ -1,4 +1,4 @@
1
- import { g as t, b as e, a as r } from "./index-Baec1AT2.js";
1
+ import { g as t, b as e, a as r } from "./index-BFqUsoWz.js";
2
2
  const i = {
3
3
  async create(a) {
4
4
  return t(
@@ -0,0 +1,52 @@
1
+ import { h as g } from "./moment-h96o7c8I.js";
2
+ import { ref as D } from "vue";
3
+ import { useSnackbar as I } from "@feedmepos/ui-library";
4
+ const d = /^[a-f\d]{24}$/i, p = ({
5
+ searchKey: u,
6
+ dateRange: e,
7
+ onBeforeApply: o
8
+ }) => {
9
+ const r = I(), s = D(null), c = () => {
10
+ const t = u.value.trim();
11
+ return d.test(t) ? t : null;
12
+ }, a = () => {
13
+ if (!s.value)
14
+ return;
15
+ const t = s.value;
16
+ s.value = null, r.close(t);
17
+ }, i = () => {
18
+ s.value = null;
19
+ }, l = (t) => {
20
+ const n = parseInt(t.slice(0, 8), 16);
21
+ return g.unix(n).format("YYYY-MM-DD");
22
+ }, m = () => {
23
+ const t = c();
24
+ if (!t) {
25
+ a();
26
+ return;
27
+ }
28
+ o == null || o();
29
+ const n = l(t);
30
+ (e.value.startDate !== n || e.value.endDate !== n) && (e.value = {
31
+ ...e.value,
32
+ startDate: n,
33
+ endDate: n
34
+ }), a();
35
+ };
36
+ return {
37
+ promptSuggestion: () => {
38
+ a(), c() && (s.value = r.open({
39
+ title: "Are you searching for transaction ID ?",
40
+ message: "We can auto-set the date range from this ID to help narrow down the results.",
41
+ action: "Apply",
42
+ type: "info",
43
+ onAction: m,
44
+ onClose: i
45
+ }, 5e3));
46
+ },
47
+ closeSuggestion: a
48
+ };
49
+ };
50
+ export {
51
+ p as u
52
+ };
@@ -1,5 +1,5 @@
1
1
  import { defineComponent as q, ref as r, resolveComponent as f, openBlock as g, createBlock as z, withCtx as I, createElementVNode as i, normalizeStyle as E, createElementBlock as M, Fragment as N, renderList as O, createVNode as c, computed as _, watch as L, onMounted as R, unref as D, toDisplayString as B, createCommentVNode as G, nextTick as H, normalizeClass as J } from "vue";
2
- import { u as K } from "./index-Baec1AT2.js";
2
+ import { u as K } from "./index-BFqUsoWz.js";
3
3
  import "@feedmepos/ui-library";
4
4
  const Q = ["id"], U = /* @__PURE__ */ q({
5
5
  __name: "FmTableSelection",