@feedmepos/mf-order-setting 0.0.71-dev → 0.0.72-dev.20260713T114128Z.29247002162

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 (196) hide show
  1. package/.env +1 -1
  2. package/README.md +7 -23
  3. package/dist/{KioskDevicesView-CP_cGMXE.js → KioskDevicesView-bpiEW_RP.js} +1 -1
  4. package/dist/KioskDevicesView.vue_vue_type_script_setup_true_lang-D0OW51HH.js +762 -0
  5. package/dist/{KioskSettingView-BiKYEjfe.js → KioskSettingView-CKKiFj2j.js} +220 -241
  6. package/dist/KioskView-DjvuK55H.js +362 -0
  7. package/dist/OrderSettingsView-CaTXpeVo.js +60012 -0
  8. package/dist/app-BlANZmvE.js +20761 -0
  9. package/dist/app.js +3 -3
  10. package/dist/{dayjs.min-Bml-FvS7.js → dayjs.min-BJ8rkAwJ.js} +1 -1
  11. package/dist/frontend/mf-order/src/api/index.d.ts +3 -1
  12. package/dist/frontend/mf-order/src/api/menu/index.d.ts +1 -1
  13. package/dist/frontend/mf-order/src/api/remoteOrder/index.d.ts +10 -3
  14. package/dist/frontend/mf-order/src/app.d.ts +194 -150
  15. package/dist/frontend/mf-order/src/components/GoogleMap.vue.d.ts +1 -1
  16. package/dist/frontend/mf-order/src/composables/useKioskPermission.d.ts +11 -0
  17. package/dist/frontend/mf-order/src/composables/useOrderSettingPermission.d.ts +13 -0
  18. package/dist/frontend/mf-order/src/composables/useQrOrderingEnabled.d.ts +2 -0
  19. package/dist/frontend/mf-order/src/helpers/menu.d.ts +1 -1
  20. package/dist/frontend/mf-order/src/main.d.ts +194 -150
  21. package/dist/frontend/mf-order/src/stores/kiosk/index.d.ts +21 -21
  22. package/dist/frontend/mf-order/src/stores/menu/menu.d.ts +906 -1044
  23. package/dist/frontend/mf-order/src/stores/order-setting/index.d.ts +42 -9
  24. package/dist/frontend/mf-order/src/stores/restaurant/index.d.ts +5 -2
  25. package/dist/frontend/mf-order/src/version.d.ts +7 -0
  26. package/dist/frontend/mf-order/src/views/kiosk/KioskStatePanel.vue.d.ts +19 -0
  27. package/dist/frontend/mf-order/src/views/kiosk/devices/KioskDevicesView.vue.d.ts +7 -1
  28. package/dist/frontend/mf-order/src/views/order-settings/delivery/DeliverySetting.vue.d.ts +2 -2
  29. package/dist/frontend/mf-order/src/views/order-settings/delivery/components/TaxInput.vue.d.ts +3 -8
  30. package/dist/frontend/mf-order/src/views/order-settings/delivery/delivery.d.ts +3 -1
  31. package/dist/frontend/mf-order/src/views/order-settings/delivery/delivery.data.d.ts +5 -1
  32. package/dist/frontend/mf-order/src/views/order-settings/delivery/inhouse/InHouseDelivery.vue.d.ts +21 -0
  33. package/dist/frontend/mf-order/src/views/order-settings/delivery/integrated-delivery/ExternalSetting.vue.d.ts +2 -2
  34. package/dist/frontend/mf-order/src/views/order-settings/delivery/integrated-delivery/GrabfoodSetting.vue.d.ts +1 -1
  35. package/dist/frontend/mf-order/src/views/order-settings/delivery/integrated-delivery/IntegratedDelivery.vue.d.ts +28 -2
  36. package/dist/frontend/mf-order/src/views/order-settings/delivery/integrated-delivery/LinemanSetting.vue.d.ts +46 -0
  37. package/dist/frontend/mf-order/src/views/order-settings/delivery/integrated-delivery/TngSetting.vue.d.ts +57 -0
  38. package/dist/frontend/mf-order/src/views/order-settings/pickup/PickUpSettingDialogContent.vue.d.ts +23 -1
  39. package/dist/frontend/mf-order/src/views/order-settings/pickup/Preorder.vue.d.ts +27 -0
  40. package/dist/frontend/mf-order/src/views/order-settings/servicecharge/RateInput.vue.d.ts +8 -0
  41. package/dist/frontend/mf-order/tsconfig.app.tsbuildinfo +1 -1
  42. package/dist/{index-BlKeAWPk.js → index-CfsVbPdN.js} +7 -7
  43. package/dist/index-nExuaqqq.js +665 -0
  44. package/dist/lineman-settings.dto-nIp-rO_8.js +61259 -0
  45. package/dist/package/entity/_type-assert.d.ts +7 -0
  46. package/dist/package/entity/booking/booking.dto.d.ts +24 -24
  47. package/dist/package/entity/delivery/delivery.dto.d.ts +8 -8
  48. package/dist/package/entity/delivery/delivery.enum.d.ts +12 -0
  49. package/dist/package/entity/delivery/gateway/grab.dto.d.ts +2 -2
  50. package/dist/package/entity/delivery/gateway/kosmo.dto.d.ts +16 -16
  51. package/dist/package/entity/delivery/gateway/pandago.dto.d.ts +10 -10
  52. package/dist/package/entity/food-court/order.do.d.ts +24 -4
  53. package/dist/package/entity/incoming-order/incoming-order-to-bill.dto.d.ts +13487 -4593
  54. package/dist/package/entity/incoming-order/incoming-order.do.d.ts +32 -24
  55. package/dist/package/entity/incoming-order/incoming-order.dto.d.ts +23 -11719
  56. package/dist/package/entity/incoming-order/incoming-order.enum.d.ts +2 -2
  57. package/dist/package/entity/index.d.ts +12 -0
  58. package/dist/package/entity/kiosk/kiosk.do.d.ts +140 -140
  59. package/dist/package/entity/kiosk/kiosk.dto.d.ts +168 -168
  60. package/dist/package/entity/kiosk/marketing/marketing.dto.d.ts +63 -7
  61. package/dist/package/entity/marketing/marketing.dto.d.ts +4 -4
  62. package/dist/package/entity/member/member.dto.d.ts +6 -0
  63. package/dist/package/entity/order/dine-in/dine-in.do.d.ts +8 -8
  64. package/dist/package/entity/order/effects/effect.dto.d.ts +68 -16
  65. package/dist/package/entity/order/menu/menu.dto.d.ts +45 -8
  66. package/dist/package/entity/order/order-item/order-item.dto.d.ts +358 -3853
  67. package/dist/package/entity/order/order.do.d.ts +7058 -100
  68. package/dist/package/entity/order/order.dto.d.ts +20572 -5317
  69. package/dist/package/entity/order/payment/payment.dto.d.ts +212 -172
  70. package/dist/package/entity/order-platform/base-integration.do.d.ts +8 -0
  71. package/dist/package/entity/order-platform/deliveroo/deliveroo-dto.d.ts +2 -2
  72. package/dist/package/entity/order-platform/deliveroo/deliveroo-order.do.d.ts +524 -524
  73. package/dist/package/entity/order-platform/deliveroo/deliveroo-setting.do.d.ts +2 -2
  74. package/dist/package/entity/order-platform/deliveroo/deliveroo.menu.dto.d.ts +58 -58
  75. package/dist/package/entity/order-platform/external/menu/external-master-menu.do.d.ts +224 -296
  76. package/dist/package/entity/order-platform/external/menu/external-menu.do.d.ts +331 -589
  77. package/dist/package/entity/order-platform/external/menu/external-menu.dto.d.ts +1 -1
  78. package/dist/package/entity/order-platform/external/order/external-order.do.d.ts +12 -12
  79. package/dist/package/entity/order-platform/external/order/external-order.dto.d.ts +275 -275
  80. package/dist/package/entity/order-platform/external/setting/external-setting.do.d.ts +3 -3
  81. package/dist/package/entity/order-platform/external/setting/external-setting.dto.d.ts +3 -3
  82. package/dist/package/entity/order-platform/foodpanda/foodpanda-menu.dto.d.ts +284 -284
  83. package/dist/package/entity/order-platform/foodpanda/foodpanda-order.do.d.ts +40 -40
  84. package/dist/package/entity/order-platform/foodpanda/foodpanda-order.dto.d.ts +16 -16
  85. package/dist/package/entity/order-platform/foodpanda/foodpanda-settings.do.d.ts +2 -2
  86. package/dist/package/entity/order-platform/foodpanda/foodpanda-settings.dto.d.ts +2 -2
  87. package/dist/package/entity/order-platform/gofood/gofood-order.do.d.ts +18 -18
  88. package/dist/package/entity/order-platform/gofood/gofood-settings.do.d.ts +2 -2
  89. package/dist/package/entity/order-platform/gofood/gofood-settings.dto.d.ts +2 -2
  90. package/dist/package/entity/order-platform/gofood/gofood.dto.d.ts +32 -32
  91. package/dist/package/entity/order-platform/grabfood/grabfood-edit-order.do.d.ts +12 -12
  92. package/dist/package/entity/order-platform/grabfood/grabfood-omni.do.d.ts +134 -115
  93. package/dist/package/entity/order-platform/grabfood/grabfood-order.do.d.ts +187 -165
  94. package/dist/package/entity/order-platform/grabfood/grabfood-settings.do.d.ts +8 -2
  95. package/dist/package/entity/order-platform/grabfood/grabfood-webhook.dto.d.ts +49 -42
  96. package/dist/package/entity/order-platform/grabfood/grabfood.dto.d.ts +67 -54
  97. package/dist/package/entity/order-platform/grabfood/grabfood.enum.d.ts +1 -1
  98. package/dist/package/entity/order-platform/lineman/lineman-settings.do.d.ts +37 -0
  99. package/dist/package/entity/order-platform/lineman/lineman-settings.dto.d.ts +40 -0
  100. package/dist/package/entity/order-platform/menu.dto.d.ts +716 -13887
  101. package/dist/package/entity/order-platform/order-platform.dto.d.ts +138 -4
  102. package/dist/package/entity/order-platform/order-platform.enum.d.ts +1 -1
  103. package/dist/package/entity/order-platform/shopeefood/shopeefood-order.do.d.ts +176 -176
  104. package/dist/package/entity/order-platform/shopeefood/shopeefood-order.dto.d.ts +62 -62
  105. package/dist/package/entity/order-platform/shopeefood/shopeefood-settings.do.d.ts +8 -2
  106. package/dist/package/entity/order-platform/shopeefood/shopeefood-settings.dto.d.ts +8 -2
  107. package/dist/package/entity/order-platform/tng/tng-menu.do.d.ts +1061 -0
  108. package/dist/package/entity/order-platform/tng/tng-order.do.d.ts +1915 -0
  109. package/dist/package/entity/order-platform/tng/tng-settings.do.d.ts +379 -0
  110. package/dist/package/entity/order-platform/tng/tng-settings.dto.d.ts +301 -0
  111. package/dist/package/entity/order-platform/tng/tng.dto.d.ts +1162 -0
  112. package/dist/package/entity/order-platform/tng/tng.enum.d.ts +29 -0
  113. package/dist/package/entity/order-setting/delivery/inhouse-delivery.do.d.ts +12 -0
  114. package/dist/package/entity/order-setting/delivery/inhouse-delivery.dto.d.ts +12 -0
  115. package/dist/package/entity/order-setting/dine-in/dine-in.do.d.ts +11 -0
  116. package/dist/package/entity/order-setting/dine-in/dine-in.dto.d.ts +9 -0
  117. package/dist/package/entity/order-setting/kiosk/kiosk.do.d.ts +5 -5
  118. package/dist/package/entity/order-setting/kiosk/kiosk.dto.d.ts +4 -4
  119. package/dist/package/entity/order-setting/order-setting.do.d.ts +64 -13
  120. package/dist/package/entity/order-setting/order-setting.dto.d.ts +126 -24
  121. package/dist/package/entity/order-setting/pickup/pickup.do.d.ts +12 -0
  122. package/dist/package/entity/order-setting/pickup/pickup.dto.d.ts +12 -0
  123. package/dist/package/entity/order-setting/sms/sms.do.d.ts +2 -2
  124. package/dist/package/entity/order-setting/sms/sms.dto.d.ts +2 -2
  125. package/dist/package/entity/payment/transaction.d.ts +112 -40
  126. package/dist/package/entity/printer/printer.do.d.ts +14 -14
  127. package/dist/package/entity/pubsub/ably/ably.enum.d.ts +1 -1
  128. package/dist/package/entity/queue/queue.do.d.ts +236 -1901
  129. package/dist/package/entity/queue/queue.dto.d.ts +925 -627
  130. package/dist/package/entity/restaurant/restaurant.dto.d.ts +31 -8
  131. package/dist/package/entity/websocket/websocket.dto.d.ts +20 -20
  132. package/dist/style.css +1 -0
  133. package/env.d.ts +3 -0
  134. package/golar.config.ts +20 -0
  135. package/package.json +30 -23
  136. package/src/Entry.vue +2 -10
  137. package/src/api/index.ts +5 -2
  138. package/src/api/menu/index.ts +1 -1
  139. package/src/api/remoteOrder/index.ts +176 -110
  140. package/src/app.ts +4 -0
  141. package/src/composables/useKioskPermission.ts +41 -0
  142. package/src/composables/useOrderSettingPermission.ts +34 -0
  143. package/src/composables/useQrOrderingEnabled.ts +66 -0
  144. package/src/helpers/menu.ts +1 -1
  145. package/src/locales/en-US.json +164 -147
  146. package/src/locales/ja-JP.json +1769 -1760
  147. package/src/locales/th-TH.json +409 -400
  148. package/src/locales/zh-CN.json +417 -408
  149. package/src/main.ts +14 -48
  150. package/src/modules/order-setting/kiosk/interface.ts +1 -1
  151. package/src/router/index.ts +2 -2
  152. package/src/router/routes.ts +34 -5
  153. package/src/stores/menu/menu.ts +48 -27
  154. package/src/stores/order-setting/mapper.ts +94 -94
  155. package/src/stores/restaurant/index.ts +24 -9
  156. package/src/utils/firebase-storage.ts +3 -13
  157. package/src/version.ts +21 -0
  158. package/src/views/kiosk/KioskStatePanel.vue +31 -0
  159. package/src/views/kiosk/KioskView.vue +100 -62
  160. package/src/views/kiosk/devices/KioskDeviceCard.vue +4 -0
  161. package/src/views/kiosk/devices/KioskDevicesView.vue +42 -9
  162. package/src/views/kiosk/settings/KioskPaymentTypeSection.vue +1 -19
  163. package/src/views/kiosk/settings/KioskSettingView.vue +3 -2
  164. package/src/views/order-settings/OrderSettingsView.vue +39 -16
  165. package/src/views/order-settings/delivery/DeliverySetting.vue +223 -11
  166. package/src/views/order-settings/delivery/components/TaxInput.vue +1 -1
  167. package/src/views/order-settings/delivery/delivery.data.ts +31 -10
  168. package/src/views/order-settings/delivery/delivery.ts +60 -28
  169. package/src/views/order-settings/delivery/inhouse/InHouseDelivery.vue +40 -1
  170. package/src/views/order-settings/delivery/integrated-delivery/DeliverooSetting.vue +1 -1
  171. package/src/views/order-settings/delivery/integrated-delivery/GrabfoodSetting.vue +15 -7
  172. package/src/views/order-settings/delivery/integrated-delivery/IntegratedDelivery.vue +83 -27
  173. package/src/views/order-settings/delivery/integrated-delivery/LinemanSetting.vue +79 -0
  174. package/src/views/order-settings/delivery/integrated-delivery/ShopeefoodSetting.vue +2 -0
  175. package/src/views/order-settings/delivery/integrated-delivery/TngSetting.vue +749 -0
  176. package/src/views/order-settings/dine-in/DineInSetting.vue +54 -23
  177. package/src/views/order-settings/dine-in/PaymentType.vue +9 -12
  178. package/src/views/order-settings/drive-thru/DriveThruSetting.vue +4 -4
  179. package/src/views/order-settings/general/GeneralSetting.vue +15 -6
  180. package/src/views/order-settings/pickup/PickUpSettingDialog.vue +31 -3
  181. package/src/views/order-settings/pickup/PickUpSettingDialogContent.vue +35 -8
  182. package/src/views/order-settings/pickup/Preorder.vue +13 -12
  183. package/src/views/order-settings/queue/QueueSetting.vue +30 -1
  184. package/src/views/order-settings/servicecharge/RateInput.vue +9 -7
  185. package/src/views/order-settings/servicecharge/ServiceChargeRule.vue +5 -1
  186. package/vite.config.ts +30 -17
  187. package/dist/KioskDevicesView.vue_vue_type_script_setup_true_lang-CiNLqFw6.js +0 -707
  188. package/dist/KioskView-BYxPrI7N.js +0 -343
  189. package/dist/OrderSettingsView-C7Y-_y5U.js +0 -32222
  190. package/dist/app-BN02cB5o.js +0 -18668
  191. package/dist/frontend/mf-order/src/api/auth/index.d.ts +0 -7
  192. package/dist/frontend/mf-order/src/stores/iframe/index.d.ts +0 -14
  193. package/dist/index-DZA8A0m4.js +0 -630
  194. package/dist/queue-transfer.dto-C7nRZOZH.js +0 -45618
  195. package/src/api/auth/index.ts +0 -20
  196. package/src/stores/iframe/index.ts +0 -23
@@ -0,0 +1,762 @@
1
+ import { ref as P, defineComponent as ee, resolveComponent as S, openBlock as l, createElementBlock as u, createElementVNode as a, toDisplayString as i, unref as s, createVNode as m, computed as T, watch as pe, createCommentVNode as D, withCtx as H, Fragment as W, renderList as Z, normalizeClass as we, createBlock as L, createTextVNode as X, renderSlot as Ae } from "vue";
2
+ import { useI18n as le } from "@feedmepos/mf-common";
3
+ import { defineStore as Pe } from "pinia";
4
+ import { r as Y, g as ve } from "./lineman-settings.dto-nIp-rO_8.js";
5
+ import { useDialog as De, useSnackbar as Se } from "@feedmepos/ui-library";
6
+ import { d as ie } from "./dayjs.min-BJ8rkAwJ.js";
7
+ import { g as Ce, c as Fe, a as fe } from "./app-BlANZmvE.js";
8
+ async function Me() {
9
+ const n = await Y().get("/kiosk/otp");
10
+ return ve(n);
11
+ }
12
+ async function $e() {
13
+ const n = await Y().get("/kiosk/devices");
14
+ return ve(n);
15
+ }
16
+ async function Ee(n) {
17
+ await Y().delete(`/kiosk/unbind/${n}`);
18
+ }
19
+ async function Ve(n, e) {
20
+ await Y().put(`/kiosk/updateDevicePin/${e}`, { pinInfo: n });
21
+ }
22
+ async function Be(n, e) {
23
+ await Y().put(`/kiosk/updateDevicePin/${e}`, { remarkInfo: n });
24
+ }
25
+ const z = {
26
+ requestOtp: Me,
27
+ getDevices: $e,
28
+ unbind: Ee,
29
+ updateDevicePin: Ve,
30
+ updateDeviceRemark: Be
31
+ }, Re = (n) => ({
32
+ name: n.name ?? "N/A",
33
+ machineId: n.machineId,
34
+ config: {
35
+ scannerInfo: n.scannerInfo ?? void 0,
36
+ printerInfo: n.printerInfo ?? void 0,
37
+ terminalInfo: n.terminalInfo ?? void 0
38
+ },
39
+ activatedAt: Oe(n.token),
40
+ deviceAppType: n.deviceAppType ?? void 0,
41
+ remarkInfo: n.remarkInfo ?? void 0,
42
+ slotInfo: n.slotInfo ?? void 0,
43
+ pinInfo: n.pinInfo ?? void 0,
44
+ deviceAppVersion: n.deviceAppVersion ?? void 0,
45
+ deviceAppOTAVersion: n.deviceAppOTAVersion ?? void 0,
46
+ webviewVersion: n.webviewVersion ?? void 0,
47
+ operatingSystem: n.operatingSystem ?? void 0,
48
+ osVersion: n.osVersion ?? void 0,
49
+ lastStartup: n.lastStartup ? new Date(n.lastStartup) : void 0
50
+ });
51
+ function Oe(n) {
52
+ const e = n.substring(0, 8), v = parseInt(e, 16);
53
+ return new Date(v * 1e3);
54
+ }
55
+ const Le = {
56
+ toMfKioskDevice: Re
57
+ }, Ne = Pe("kiosk", () => {
58
+ const n = P({
59
+ otp: "",
60
+ devices: []
61
+ });
62
+ async function e() {
63
+ const p = await z.requestOtp();
64
+ n.value.otp = p.otp;
65
+ }
66
+ async function v() {
67
+ const p = await z.getDevices();
68
+ n.value.devices = p.map((y) => Le.toMfKioskDevice(y));
69
+ }
70
+ async function w(p) {
71
+ await z.unbind(p), await v();
72
+ }
73
+ async function k(p, y) {
74
+ await z.updateDevicePin(p, y), await v();
75
+ }
76
+ async function c(p, y) {
77
+ await z.updateDeviceRemark(p, y), await v();
78
+ }
79
+ return {
80
+ state: n.value,
81
+ requestOtp: e,
82
+ getDevices: v,
83
+ unbind: w,
84
+ updateDevicePin: k,
85
+ updateDeviceRemark: c
86
+ };
87
+ });
88
+ var ye = { exports: {} };
89
+ (function(n, e) {
90
+ (function(v, w) {
91
+ n.exports = w();
92
+ })(Fe, function() {
93
+ return function(v, w, k) {
94
+ v = v || {};
95
+ var c = w.prototype, p = { future: "in %s", past: "%s ago", s: "a few seconds", m: "a minute", mm: "%d minutes", h: "an hour", hh: "%d hours", d: "a day", dd: "%d days", M: "a month", MM: "%d months", y: "a year", yy: "%d years" };
96
+ function y(r, d, f, A) {
97
+ return c.fromToBase(r, d, f, A);
98
+ }
99
+ k.en.relativeTime = p, c.fromToBase = function(r, d, f, A, B) {
100
+ for (var h, $, C, R = f.$locale().relativeTime || p, O = v.thresholds || [{ l: "s", r: 44, d: "second" }, { l: "m", r: 89 }, { l: "mm", r: 44, d: "minute" }, { l: "h", r: 89 }, { l: "hh", r: 21, d: "hour" }, { l: "d", r: 35 }, { l: "dd", r: 25, d: "day" }, { l: "M", r: 45 }, { l: "MM", r: 10, d: "month" }, { l: "y", r: 17 }, { l: "yy", d: "year" }], te = O.length, E = 0; E < te; E += 1) {
101
+ var F = O[E];
102
+ F.d && (h = A ? k(r).diff(f, F.d, !0) : f.diff(r, F.d, !0));
103
+ var V = (v.rounding || Math.round)(Math.abs(h));
104
+ if (C = h > 0, V <= F.r || !F.r) {
105
+ V <= 1 && E > 0 && (F = O[E - 1]);
106
+ var U = R[F.l];
107
+ B && (V = B("" + V)), $ = typeof U == "string" ? U.replace("%d", V) : U(V, d, F.l, C);
108
+ break;
109
+ }
110
+ }
111
+ if (d) return $;
112
+ var M = C ? R.future : R.past;
113
+ return typeof M == "function" ? M($) : M.replace("%s", $);
114
+ }, c.to = function(r, d) {
115
+ return y(r, d, this, !0);
116
+ }, c.from = function(r, d) {
117
+ return y(r, d, this);
118
+ };
119
+ var o = function(r) {
120
+ return r.$u ? k.utc() : k();
121
+ };
122
+ c.toNow = function(r) {
123
+ return this.to(o(this), r);
124
+ }, c.fromNow = function(r) {
125
+ return this.from(o(this), r);
126
+ };
127
+ };
128
+ });
129
+ })(ye);
130
+ var Ue = ye.exports;
131
+ const Ke = /* @__PURE__ */ Ce(Ue), je = /* @__PURE__ */ ee({
132
+ __name: "KioskUnbindConfirm",
133
+ props: {
134
+ machineId: {}
135
+ },
136
+ emits: ["update:modelValue"],
137
+ setup(n, { emit: e }) {
138
+ const { t: v } = le(), w = e, k = P("");
139
+ function c(p) {
140
+ w("update:modelValue", p);
141
+ }
142
+ return (p, y) => {
143
+ const o = S("FmTextField");
144
+ return l(), u("div", null, [
145
+ a("span", null, i(s(v)("order.unbindKioskDeviceWarning", { machineId: n.machineId })), 1),
146
+ m(o, {
147
+ "model-value": k.value,
148
+ "onUpdate:modelValue": c,
149
+ placeholder: n.machineId
150
+ }, null, 8, ["model-value", "placeholder"])
151
+ ]);
152
+ };
153
+ }
154
+ }), qe = { class: "border fm-corner-radius-lg p-12 hover:bg-fm-color-neutral-gray-50 transition-colors" }, ze = { class: "flex items-center justify-between mb-2" }, He = { class: "flex items-center gap-2" }, We = { class: "px-2 py-1 fm-corner-radius-md fm-typo-en-body-sm-600 uppercase bg-fm-color-neutral-gray-200 text-fm-color-typo-secondary" }, Ye = {
155
+ key: 0,
156
+ class: "fm-typo-en-body-md-600 text-fm-color-typo-primary"
157
+ }, Ge = { class: "flex items-center gap-1" }, Qe = {
158
+ key: 0,
159
+ class: "py-[0.5rem] flex flex-col gap-[1.5rem] pr-2"
160
+ }, Je = {
161
+ key: 0,
162
+ class: "w-full border p-[1.5rem] fm-corner-radius-lg flex flex-col gap-4"
163
+ }, Xe = { class: "fm-typo-en-title-sm-600 mb-3" }, Ze = { class: "grid grid-cols-1 md:grid-cols-2 gap-x-6 gap-y-4" }, et = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, tt = { class: "flex flex-col gap-2" }, nt = { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, ot = { class: "flex items-center justify-between gap-2" }, at = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-tertiary" }, rt = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-tertiary" }, st = {
164
+ key: 1,
165
+ class: "w-full border p-[1.5rem] fm-corner-radius-lg flex flex-col gap-4"
166
+ }, it = { class: "fm-typo-en-title-sm-600" }, lt = { class: "fm-typo-en-body-md-600 text-fm-color-typo-primary" }, ct = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, dt = { class: "fm-typo-en-body-md-600 text-fm-color-typo-primary break-all" }, ut = { key: 1 }, pt = { class: "py-[1rem] flex flex-col gap-6 text-center items-center" }, mt = { class: "flex flex-col gap-1 mb-2" }, vt = { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, ft = { class: "mt-5 block" }, yt = ["title"], ht = ["title"], bt = ["title"], kt = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-tertiary font-mono" }, gt = { class: "flex items-center gap-3 flex-wrap fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, _t = { class: "flex items-center gap-1" }, xt = {
167
+ key: 0,
168
+ class: "flex items-center gap-1"
169
+ }, It = { class: "flex items-center gap-1" }, Tt = ["title"], wt = /* @__PURE__ */ ee({
170
+ __name: "KioskDeviceCard",
171
+ props: {
172
+ device: {}
173
+ },
174
+ setup(n) {
175
+ ie.extend(Ke);
176
+ const { t: e } = le(), { canManageDevices: v, canBindDevice: w } = fe(), k = De(), c = Se(), p = Ne(), y = P(!1), o = n, r = P(""), d = T(() => {
177
+ var t;
178
+ return ((t = o.device) == null ? void 0 : t.deviceAppType) === "TABLET_APP" ? e("order.tabletOnly") : e("order.kioskOnly");
179
+ }), f = T(() => {
180
+ const t = [], b = B(), _ = h();
181
+ return b.length > 0 && t.push({
182
+ key: "scannerInfo",
183
+ title: e("order.scannerInfo"),
184
+ entries: b
185
+ }), _.length > 0 && t.push({
186
+ key: "printerInfo",
187
+ title: e("order.printerInfo"),
188
+ entries: _
189
+ }), t;
190
+ }), A = T(() => f.value.length > 0);
191
+ function B() {
192
+ var _;
193
+ const t = o.device.config.scannerInfo;
194
+ if (!t || o.device.deviceAppType === "TABLET_APP")
195
+ return [];
196
+ const b = [
197
+ {
198
+ label: "Type",
199
+ value: $(t.type)
200
+ }
201
+ ];
202
+ return t.type === "CAPACITOR" && t.lensFacing && b.push({
203
+ label: "Lens Facing",
204
+ value: t.lensFacing === "FRONT" ? "Front" : "Back"
205
+ }), t.type === "SUNMI" && b.push({
206
+ label: "Connection",
207
+ value: ((_ = t.connection) == null ? void 0 : _.type) ?? "-"
208
+ }), b;
209
+ }
210
+ function h() {
211
+ var j, J;
212
+ const t = o.device.config.printerInfo;
213
+ if (!t)
214
+ return [];
215
+ const b = ((j = t.id) == null ? void 0 : j.trim()) ?? "", _ = ((J = t.name) == null ? void 0 : J.trim()) ?? "";
216
+ if (!b || !_)
217
+ return [];
218
+ const g = [
219
+ { label: "Name", value: _ },
220
+ { label: "Printer ID", value: b }
221
+ ], x = t.hardware;
222
+ switch (g.push({ label: "Connection Type", value: x.connection.type }), x.connection.type) {
223
+ case "IP":
224
+ case "BLUETOOTH":
225
+ case "DRIVER":
226
+ g.push({ label: "Path", value: x.connection.path });
227
+ break;
228
+ case "STAR":
229
+ g.push({ label: "Port Name", value: x.connection.portName }), g.push({ label: "Emulation Mode", value: x.connection.emulationMode });
230
+ break;
231
+ case "USB":
232
+ g.push({ label: "Vendor ID", value: x.connection.vendorId }), g.push({ label: "Product ID", value: x.connection.productId });
233
+ break;
234
+ }
235
+ return g.push({ label: "Encoder Type", value: x.encoderConfig.type }), g.push({ label: "DPI", value: String(x.encoderConfig.dpi) }), g.push({ label: "Paper Width (mm)", value: String(x.encoderConfig.paperWidthInMm) }), x.encoderConfig.type === "TSPL" && g.push({ label: "Paper Height (mm)", value: String(x.encoderConfig.paperHeightInMm) }), t.backup && (g.push({ label: "Backup Type", value: t.backup.type }), t.backup.type === "PRINTER_ID" && g.push({ label: "Backup Printer ID", value: t.backup.printerId })), g;
236
+ }
237
+ function $(t) {
238
+ switch (t) {
239
+ case "IMIN":
240
+ return "IMIN";
241
+ case "SUNMI":
242
+ return "SUNMI";
243
+ case "CAPACITOR":
244
+ return "Camera (Capacitor)";
245
+ case "KEYBOARD":
246
+ return "Keyboard";
247
+ default:
248
+ return t;
249
+ }
250
+ }
251
+ const C = T(() => {
252
+ var t;
253
+ return ((t = o.device) == null ? void 0 : t.deviceAppType) === "TABLET_APP";
254
+ }), R = T(() => {
255
+ const t = o.device.machineId;
256
+ return !t || t.length <= 16 ? t : `${t.slice(0, 8)}...${t.slice(-4)}`;
257
+ });
258
+ async function O() {
259
+ try {
260
+ await navigator.clipboard.writeText(o.device.machineId), c.open({
261
+ type: "success",
262
+ message: e("order.machineIdCopied"),
263
+ position: "bottom"
264
+ });
265
+ } catch {
266
+ c.open({
267
+ type: "error",
268
+ message: e("order.copyFailed"),
269
+ position: "bottom"
270
+ });
271
+ }
272
+ }
273
+ function te(t) {
274
+ return ie(t).fromNow();
275
+ }
276
+ function E(t) {
277
+ return ie(t).format("DD MMM YYYY HH:mm:ss");
278
+ }
279
+ function F() {
280
+ r.value = "", k.open({
281
+ title: e("order.unbindKioskDevice"),
282
+ contentComponent: je,
283
+ contentComponentProps: {
284
+ machineId: o.device.machineId,
285
+ "onUpdate:modelValue": (t) => {
286
+ r.value = t;
287
+ }
288
+ },
289
+ dismissAway: !1,
290
+ primaryActions: {
291
+ text: e("order.unbind"),
292
+ variant: "destructive",
293
+ close: !1
294
+ },
295
+ secondaryActions: {
296
+ text: e("order.cancel"),
297
+ variant: "tertiary",
298
+ close: !0
299
+ }
300
+ }).onPrimary(async () => {
301
+ r.value == o.device.machineId ? (await Te(), c.open({
302
+ type: "success",
303
+ message: e("order.unbindSuccess"),
304
+ position: "bottom"
305
+ }), k.close()) : c.open({
306
+ type: "warning",
307
+ message: e("order.unbindWarning"),
308
+ position: "bottom"
309
+ });
310
+ });
311
+ }
312
+ const V = T(() => {
313
+ var t;
314
+ return (t = o.device) == null ? void 0 : t.pinInfo;
315
+ }), U = T(() => M.value ? e("order.reEnterNewPin") : e("order.enterNewPin")), M = P(!1), G = P(), ne = P(), oe = P(!1), K = P(o.device.remarkInfo ?? ""), N = P("app"), he = T(() => {
316
+ const t = [
317
+ {
318
+ label: e("order.deviceAppInfo"),
319
+ value: "app"
320
+ }
321
+ ];
322
+ return A.value && t.push({
323
+ label: e("order.other"),
324
+ value: "other"
325
+ }), t;
326
+ }), Q = T(() => {
327
+ var t;
328
+ return ((t = o.device.remarkInfo) == null ? void 0 : t.trim()) ?? "";
329
+ }), be = T(() => {
330
+ const t = [
331
+ {
332
+ label: e("order.deviceType"),
333
+ value: d.value
334
+ },
335
+ {
336
+ label: e("order.machineId"),
337
+ value: o.device.machineId,
338
+ isMono: !0
339
+ },
340
+ {
341
+ label: e("order.version"),
342
+ value: o.device.deviceAppVersion ?? "Below 0.0.42"
343
+ },
344
+ {
345
+ label: e("order.deviceOtaVersion"),
346
+ value: o.device.deviceAppOTAVersion ?? e("order.notSet")
347
+ },
348
+ {
349
+ label: e("order.devicePinCode"),
350
+ value: V.value ? e("order.pinSet") : e("order.noPin")
351
+ },
352
+ {
353
+ label: e("order.activatedDate"),
354
+ value: E(o.device.activatedAt)
355
+ },
356
+ {
357
+ label: e("order.webviewVersion"),
358
+ value: o.device.webviewVersion || e("order.notSet")
359
+ },
360
+ {
361
+ label: e("order.operatingSystem"),
362
+ value: o.device.operatingSystem || e("order.notSet")
363
+ },
364
+ {
365
+ label: e("order.osVersion"),
366
+ value: o.device.osVersion || e("order.notSet")
367
+ }
368
+ ];
369
+ return C.value && t.push({
370
+ label: e("order.deviceSlot"),
371
+ value: o.device.slotInfo || e("order.notSet")
372
+ }), o.device.lastStartup && t.push({
373
+ label: e("order.lastStartupAt"),
374
+ value: E(o.device.lastStartup)
375
+ }), t;
376
+ }), ae = T(() => K.value.trim()), ce = T(() => ae.value !== Q.value);
377
+ pe(
378
+ () => o.device.remarkInfo,
379
+ (t) => {
380
+ K.value = t ?? "";
381
+ }
382
+ ), pe(
383
+ () => A.value,
384
+ (t) => {
385
+ !t && N.value === "other" && (N.value = "app");
386
+ }
387
+ );
388
+ function ke() {
389
+ y.value = !0;
390
+ }
391
+ function re() {
392
+ M.value = !1, G.value = null, ne.value = null, y.value = !1, N.value = "app";
393
+ }
394
+ function de(t) {
395
+ M.value ? (ne.value = t, ge()) : (G.value = t, M.value = !0);
396
+ }
397
+ async function ge() {
398
+ G.value === ne.value ? (await Ie(), c.open({
399
+ type: "success",
400
+ message: "Successfuly update device PIN",
401
+ position: "top"
402
+ })) : c.open({
403
+ type: "error",
404
+ message: "Entered PIN not the same, please try again",
405
+ position: "top"
406
+ }), re();
407
+ }
408
+ function _e(t) {
409
+ K.value = t.slice(0, 50);
410
+ }
411
+ async function xe() {
412
+ if (ce.value) {
413
+ oe.value = !0;
414
+ try {
415
+ await p.updateDeviceRemark(ae.value === "" ? null : ae.value, o.device.machineId), c.open({
416
+ type: "success",
417
+ message: e("order.deviceRemarkUpdated"),
418
+ position: "top"
419
+ });
420
+ } catch {
421
+ c.open({
422
+ type: "error",
423
+ message: e("order.deviceRemarkUpdateFailed"),
424
+ position: "top"
425
+ });
426
+ } finally {
427
+ oe.value = !1;
428
+ }
429
+ }
430
+ }
431
+ async function Ie() {
432
+ await p.updateDevicePin(G.value, o.device.machineId);
433
+ }
434
+ async function Te() {
435
+ await p.unbind(o.device.machineId);
436
+ }
437
+ return (t, b) => {
438
+ const _ = S("FmButton"), g = S("FmTabs"), x = S("FmTextField"), j = S("FmPinField"), J = S("FmSideSheet"), q = S("FmIcon");
439
+ return l(), u("div", qe, [
440
+ a("div", ze, [
441
+ a("div", He, [
442
+ a("span", We, i(C.value ? "Tablet" : "Kiosk"), 1),
443
+ C.value && n.device.slotInfo ? (l(), u("span", Ye, i(n.device.slotInfo), 1)) : D("", !0)
444
+ ]),
445
+ a("div", Ge, [
446
+ m(J, {
447
+ header: n.device.name,
448
+ "dismiss-away": "",
449
+ maxWidth: 700,
450
+ "onOn:clickedAway": re
451
+ }, {
452
+ "side-sheet-button": H(() => [
453
+ m(_, {
454
+ variant: "tertiary",
455
+ icon: "more_vert"
456
+ })
457
+ ]),
458
+ default: H(() => {
459
+ var ue;
460
+ return [
461
+ y.value ? (l(), u("div", ut, [
462
+ a("div", pt, [
463
+ a("div", mt, [
464
+ a("span", vt, i(U.value), 1),
465
+ a("span", ft, [
466
+ M.value ? D("", !0) : (l(), L(j, {
467
+ key: 0,
468
+ length: 4,
469
+ onComplete: b[1] || (b[1] = (I) => de(I))
470
+ })),
471
+ M.value ? (l(), L(j, {
472
+ key: 1,
473
+ length: 4,
474
+ onComplete: b[2] || (b[2] = (I) => de(I))
475
+ })) : D("", !0)
476
+ ])
477
+ ]),
478
+ m(_, {
479
+ class: "w-1/3",
480
+ variant: "secondary",
481
+ label: s(e)("order.cancelResetPin"),
482
+ onClick: re
483
+ }, null, 8, ["label"])
484
+ ])
485
+ ])) : (l(), u("div", Qe, [
486
+ a("div", null, [
487
+ m(g, {
488
+ "model-value": N.value,
489
+ "onUpdate:modelValue": b[0] || (b[0] = (I) => N.value = I),
490
+ items: he.value,
491
+ showMoreAt: 99
492
+ }, null, 8, ["model-value", "items"])
493
+ ]),
494
+ N.value === "app" ? (l(), u("div", Je, [
495
+ a("span", Xe, i(s(e)("order.deviceAppInfo")), 1),
496
+ a("div", Ze, [
497
+ (l(!0), u(W, null, Z(be.value, (I) => (l(), u("div", {
498
+ key: I.label,
499
+ class: "flex flex-col gap-1"
500
+ }, [
501
+ a("span", et, i(I.label), 1),
502
+ a("span", {
503
+ class: we(["fm-typo-en-body-md-600 text-fm-color-typo-primary break-all", I.isMono ? "font-mono text-sm" : ""])
504
+ }, i(I.value), 3)
505
+ ]))), 128))
506
+ ]),
507
+ a("div", tt, [
508
+ a("span", nt, i(s(e)("order.deviceRemark")), 1),
509
+ m(x, {
510
+ "model-value": K.value,
511
+ placeholder: s(e)("order.deviceRemarkPlaceholder"),
512
+ "onUpdate:modelValue": _e
513
+ }, null, 8, ["model-value", "placeholder"]),
514
+ a("div", ot, [
515
+ a("span", at, i(K.value.length) + "/50 ", 1),
516
+ m(_, {
517
+ class: "w-auto",
518
+ variant: "secondary",
519
+ label: s(e)("order.saveDeviceRemark"),
520
+ disabled: !ce.value || oe.value,
521
+ onClick: xe
522
+ }, null, 8, ["label", "disabled"])
523
+ ]),
524
+ a("span", rt, i(s(e)("order.current")) + ": " + i(Q.value || s(e)("order.notSet")), 1)
525
+ ]),
526
+ s(v) ? (l(), L(_, {
527
+ key: 0,
528
+ class: "w-full",
529
+ variant: "primary",
530
+ label: (ue = n.device) != null && ue.pinInfo ? s(e)("order.resetDevicePin") : s(e)("order.setDevicePin"),
531
+ onClick: ke
532
+ }, null, 8, ["label"])) : D("", !0)
533
+ ])) : N.value === "other" && A.value ? (l(), u("div", st, [
534
+ a("span", it, i(s(e)("order.other")), 1),
535
+ (l(!0), u(W, null, Z(f.value, (I) => (l(), u("div", {
536
+ key: I.key,
537
+ class: "flex flex-col gap-2"
538
+ }, [
539
+ a("span", lt, i(I.title), 1),
540
+ (l(!0), u(W, null, Z(I.entries, (se) => (l(), u("div", {
541
+ key: se.label,
542
+ class: "flex flex-col gap-1"
543
+ }, [
544
+ a("span", ct, i(se.label), 1),
545
+ a("span", dt, i(se.value), 1)
546
+ ]))), 128))
547
+ ]))), 128))
548
+ ])) : D("", !0)
549
+ ]))
550
+ ];
551
+ }),
552
+ _: 1
553
+ }, 8, ["header"]),
554
+ s(w) ? (l(), L(_, {
555
+ key: 0,
556
+ variant: "plain",
557
+ icon: "link_off",
558
+ class: "text-fm-color-system-error-300",
559
+ onClick: F
560
+ })) : D("", !0)
561
+ ])
562
+ ]),
563
+ a("div", {
564
+ class: "fm-typo-en-body-md-600 text-fm-color-typo-primary mb-1 overflow-hidden text-ellipsis whitespace-nowrap",
565
+ title: n.device.name
566
+ }, i(n.device.name), 9, yt),
567
+ a("div", {
568
+ class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary mb-1 overflow-hidden text-ellipsis whitespace-nowrap",
569
+ title: Q.value || s(e)("order.notSet")
570
+ }, i(s(e)("order.deviceRemark")) + ": " + i(Q.value || s(e)("order.notSet")), 9, ht),
571
+ a("div", {
572
+ class: "flex items-center gap-1 mb-2 cursor-pointer group",
573
+ onClick: O,
574
+ title: s(e)("order.clickToCopy")
575
+ }, [
576
+ a("span", kt, i(R.value), 1),
577
+ m(q, {
578
+ name: "content_copy",
579
+ class: "text-fm-color-typo-tertiary opacity-0 group-hover:opacity-100 transition-opacity"
580
+ })
581
+ ], 8, bt),
582
+ a("div", gt, [
583
+ a("span", _t, [
584
+ m(q, { name: "smartphone" }),
585
+ X(" v" + i(n.device.deviceAppVersion ?? "?"), 1)
586
+ ]),
587
+ n.device.deviceAppOTAVersion ? (l(), u("span", xt, [
588
+ m(q, { name: "system_update" }),
589
+ X(" " + i(n.device.deviceAppOTAVersion), 1)
590
+ ])) : D("", !0),
591
+ a("span", It, [
592
+ m(q, { name: "lock" }),
593
+ X(" " + i(V.value ? s(e)("order.pinSet") : s(e)("order.noPin")), 1)
594
+ ]),
595
+ n.device.lastStartup ? (l(), u("span", {
596
+ key: 1,
597
+ class: "flex items-center gap-1",
598
+ title: E(n.device.lastStartup)
599
+ }, [
600
+ m(q, { name: "schedule" }),
601
+ X(" " + i(te(n.device.lastStartup)), 1)
602
+ ], 8, Tt)) : D("", !0)
603
+ ])
604
+ ]);
605
+ };
606
+ }
607
+ }), At = { class: "flex flex-col items-center justify-center gap-3 py-16 text-center col-span-2" }, Pt = { class: "flex items-center justify-center w-16 h-16 rounded-full bg-fm-color-surface-secondary" }, Dt = { class: "fm-typo-en-title-sm-600 block" }, St = { class: "fm-typo-en-body-md-400 block text-fm-color-typo-tertiary max-w-[360px]" }, Ct = {
608
+ key: 0,
609
+ class: "pt-2"
610
+ }, me = /* @__PURE__ */ ee({
611
+ __name: "KioskStatePanel",
612
+ props: {
613
+ title: {},
614
+ message: {},
615
+ icon: { default: "info" }
616
+ },
617
+ setup(n) {
618
+ return (e, v) => {
619
+ const w = S("FmIcon");
620
+ return l(), u("div", At, [
621
+ a("div", Pt, [
622
+ m(w, {
623
+ name: n.icon,
624
+ size: "xl",
625
+ class: "text-fm-color-typo-tertiary"
626
+ }, null, 8, ["name"])
627
+ ]),
628
+ a("span", Dt, i(n.title), 1),
629
+ a("span", St, i(n.message), 1),
630
+ e.$slots.default ? (l(), u("div", Ct, [
631
+ Ae(e.$slots, "default")
632
+ ])) : D("", !0)
633
+ ]);
634
+ };
635
+ }
636
+ }), Ft = { class: "flex flex-col gap-4" }, Mt = { class: "flex items-center justify-between" }, $t = { class: "flex flex-col gap-2" }, Et = { class: "fm-typo-en-title-sm-600 block" }, Vt = { class: "fm-typo-en-body-md-400 block" }, Bt = { class: "flex items-center gap-3 flex-wrap" }, Rt = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-tertiary" }, Ot = { class: "grid grid-cols-2 gap-2 py-8" }, Lt = {
637
+ key: 0,
638
+ class: "text-center py-8 text-fm-color-typo-tertiary fm-typo-en-body-md-400 col-span-2"
639
+ }, Nt = {
640
+ key: 1,
641
+ class: "text-center py-8 text-fm-color-typo-tertiary fm-typo-en-body-md-400 col-span-2"
642
+ }, Yt = /* @__PURE__ */ ee({
643
+ __name: "KioskDevicesView",
644
+ props: {
645
+ devices: {},
646
+ loadError: { default: null }
647
+ },
648
+ emits: ["requestOtp", "retry"],
649
+ setup(n) {
650
+ const { t: e } = le(), { canBindDevice: v } = fe(), w = n, k = P(""), c = P("all"), p = T(() => {
651
+ switch (c.value) {
652
+ case "tablet":
653
+ return e("order.tabletOnly");
654
+ case "kiosk":
655
+ return e("order.kioskOnly");
656
+ default:
657
+ return e("order.allTypes");
658
+ }
659
+ }), y = T(() => {
660
+ let o = w.devices;
661
+ c.value === "tablet" ? o = o.filter((d) => d.deviceAppType === "TABLET_APP") : c.value === "kiosk" && (o = o.filter((d) => d.deviceAppType !== "TABLET_APP"));
662
+ const r = k.value.toLowerCase().trim();
663
+ return r && (o = o.filter((d) => {
664
+ var $, C, R, O;
665
+ const f = (($ = d.name) == null ? void 0 : $.toLowerCase()) || "", A = ((C = d.machineId) == null ? void 0 : C.toLowerCase()) || "", B = ((R = d.slotInfo) == null ? void 0 : R.toLowerCase()) || "", h = ((O = d.remarkInfo) == null ? void 0 : O.toLowerCase()) || "";
666
+ return f.includes(r) || A.includes(r) || B.includes(r) || h.includes(r);
667
+ })), o.sort((d, f) => d.deviceAppType === "TABLET_APP" && f.deviceAppType !== "TABLET_APP" ? -1 : d.deviceAppType !== "TABLET_APP" && f.deviceAppType === "TABLET_APP" ? 1 : d.deviceAppType === "TABLET_APP" && f.deviceAppType === "TABLET_APP" ? (d.slotInfo || "").localeCompare(f.slotInfo || "") : (d.name || "").localeCompare(f.name || ""));
668
+ });
669
+ return (o, r) => {
670
+ const d = S("FmButton"), f = S("FmSearch"), A = S("FmMenuItem"), B = S("FmMenu");
671
+ return l(), u("div", null, [
672
+ a("div", Ft, [
673
+ a("div", Mt, [
674
+ a("div", $t, [
675
+ a("span", Et, i(s(e)("order.kioskDisplay")), 1),
676
+ a("span", Vt, i(s(e)("order.kioskDisplayDescription")), 1)
677
+ ]),
678
+ s(v) ? (l(), L(d, {
679
+ key: 0,
680
+ variant: "primary",
681
+ label: s(e)("order.bindDevice"),
682
+ size: "md",
683
+ "prepend-icon": "link",
684
+ onClick: r[0] || (r[0] = (h) => o.$emit("requestOtp"))
685
+ }, null, 8, ["label"])) : D("", !0)
686
+ ]),
687
+ n.loadError === "forbidden" ? (l(), L(me, {
688
+ key: 0,
689
+ icon: "lock",
690
+ title: s(e)("order.deviceAccessDeniedTitle"),
691
+ message: s(e)("order.deviceAccessDeniedMessage")
692
+ }, null, 8, ["title", "message"])) : n.loadError === "error" ? (l(), L(me, {
693
+ key: 1,
694
+ icon: "error",
695
+ title: s(e)("order.deviceLoadErrorTitle"),
696
+ message: s(e)("order.deviceLoadErrorMessage")
697
+ }, {
698
+ default: H(() => [
699
+ m(d, {
700
+ variant: "secondary",
701
+ label: s(e)("order.retry"),
702
+ "prepend-icon": "refresh",
703
+ onClick: r[1] || (r[1] = (h) => o.$emit("retry"))
704
+ }, null, 8, ["label"])
705
+ ]),
706
+ _: 1
707
+ }, 8, ["title", "message"])) : (l(), u(W, { key: 2 }, [
708
+ a("div", Bt, [
709
+ m(f, {
710
+ "model-value": k.value,
711
+ "onUpdate:modelValue": r[2] || (r[2] = (h) => k.value = h),
712
+ class: "flex-1 min-w-[200px] max-w-[400px]",
713
+ placeholder: s(e)("order.searchDevices")
714
+ }, null, 8, ["model-value", "placeholder"]),
715
+ m(B, null, {
716
+ "menu-button": H(() => [
717
+ m(d, {
718
+ variant: "tertiary",
719
+ "prepend-icon": "filter_list",
720
+ label: p.value,
721
+ class: "fm-typo-en-body-md-600"
722
+ }, null, 8, ["label"])
723
+ ]),
724
+ default: H(() => [
725
+ m(A, {
726
+ "model-value": c.value === "all",
727
+ label: s(e)("order.allTypes"),
728
+ onClick: r[3] || (r[3] = (h) => c.value = "all")
729
+ }, null, 8, ["model-value", "label"]),
730
+ m(A, {
731
+ "model-value": c.value === "tablet",
732
+ label: s(e)("order.tabletOnly"),
733
+ onClick: r[4] || (r[4] = (h) => c.value = "tablet")
734
+ }, null, 8, ["model-value", "label"]),
735
+ m(A, {
736
+ "model-value": c.value === "kiosk",
737
+ label: s(e)("order.kioskOnly"),
738
+ onClick: r[5] || (r[5] = (h) => c.value = "kiosk")
739
+ }, null, 8, ["model-value", "label"])
740
+ ]),
741
+ _: 1
742
+ }),
743
+ a("span", Rt, i(s(e)("order.showingDevices", { count: y.value.length, total: n.devices.length })), 1)
744
+ ]),
745
+ a("div", Ot, [
746
+ (l(!0), u(W, null, Z(y.value, (h) => (l(), L(wt, {
747
+ key: h.machineId,
748
+ device: h
749
+ }, null, 8, ["device"]))), 128)),
750
+ y.value.length === 0 && n.devices.length > 0 ? (l(), u("div", Lt, i(s(e)("order.noDevicesMatch")), 1)) : D("", !0),
751
+ n.devices.length === 0 ? (l(), u("div", Nt, i(s(e)("order.noDevicesBound")), 1)) : D("", !0)
752
+ ])
753
+ ], 64))
754
+ ])
755
+ ]);
756
+ };
757
+ }
758
+ });
759
+ export {
760
+ Yt as _,
761
+ Ne as u
762
+ };