@feedmepos/mf-order-setting 0.0.49 → 0.0.51
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/{KioskDevicesView-Ch_mWJz9.js → KioskDevicesView-TIls1ag1.js} +1 -1
- package/dist/KioskDevicesView.vue_vue_type_script_setup_true_lang-B2gjPfOJ.js +501 -0
- package/dist/KioskSettingView-UPE-q-Zd.js +573 -0
- package/dist/KioskView-B0Jj2sOl.js +477 -0
- package/dist/{OrderSettingsView-CRgoLOD2.js → OrderSettingsView-Ca4y2PNF.js} +4 -4
- package/dist/{app-CDTAjXj9.js → app-JqOEacuf.js} +75 -19
- package/dist/app.js +1 -1
- package/dist/{dayjs.min-dI_j30pv.js → dayjs.min-B42nUieJ.js} +1 -1
- package/dist/frontend/mf-order/src/app.d.ts +56 -0
- package/dist/frontend/mf-order/src/main.d.ts +56 -0
- package/dist/frontend/mf-order/src/modules/kiosk/interface.d.ts +1 -0
- package/dist/frontend/mf-order/src/modules/order-setting/kiosk/interface.d.ts +2 -0
- package/dist/frontend/mf-order/src/stores/kiosk/index.d.ts +3 -0
- package/dist/frontend/mf-order/src/stores/order-setting/index.d.ts +6 -0
- package/dist/frontend/mf-order/src/views/kiosk/devices/KioskDevicesView.vue.d.ts +6 -3
- package/dist/frontend/mf-order/src/views/order-settings/servicecharge/ServiceChargeRule.vue.d.ts +2 -2
- package/dist/frontend/mf-order/tsconfig.app.tsbuildinfo +1 -1
- package/dist/{index-B8U5Sawr.js → index-B0teNm7_.js} +2 -2
- package/dist/{menu.dto-qVeqpSdz.js → menu.dto-DFTxveX1.js} +6355 -6287
- package/dist/package/entity/incoming-order/incoming-order-to-bill.dto.d.ts +119 -12
- package/dist/package/entity/incoming-order/incoming-order.dto.d.ts +124 -6
- package/dist/package/entity/kiosk/kiosk.do.d.ts +32 -0
- package/dist/package/entity/kiosk/kiosk.dto.d.ts +44 -0
- package/dist/package/entity/order/order-item/order-item.dto.d.ts +30 -0
- package/dist/package/entity/order/order.do.d.ts +8 -0
- package/dist/package/entity/order/order.dto.d.ts +118 -0
- package/dist/package/entity/order/order.enum.d.ts +2 -0
- package/dist/package/entity/order-platform/external/menu/external-master-menu.do.d.ts +20 -0
- package/dist/package/entity/order-platform/external/menu/external-menu.do.d.ts +23 -0
- package/dist/package/entity/order-platform/external/order/external-order.do.d.ts +62 -0
- package/dist/package/entity/order-platform/external/order/external-order.dto.d.ts +178 -0
- package/dist/package/entity/order-platform/grabfood/grabfood-menu.do.d.ts +15 -0
- package/dist/package/entity/order-platform/grabfood/grabfood-omni.do.d.ts +1834 -15
- package/dist/package/entity/order-platform/grabfood/grabfood-order.do.d.ts +13 -13
- package/dist/package/entity/order-platform/grabfood/grabfood-settings.do.d.ts +3 -0
- package/dist/package/entity/order-platform/grabfood/grabfood-webhook.dto.d.ts +528 -805
- package/dist/package/entity/order-platform/grabfood/grabfood.dto.d.ts +8 -5
- package/dist/package/entity/order-platform/grabfood/grabfood.enum.d.ts +1 -1
- package/dist/package/entity/order-platform/menu.dto.d.ts +34 -0
- package/dist/package/entity/order-platform/order-platform.dto.d.ts +0 -20
- package/dist/package/entity/order-setting/kiosk/kiosk.do.d.ts +3 -0
- package/dist/package/entity/order-setting/kiosk/kiosk.dto.d.ts +3 -0
- package/dist/package/entity/order-setting/order-setting.do.d.ts +5 -0
- package/dist/package/entity/order-setting/order-setting.dto.d.ts +10 -0
- package/dist/package/entity/queue/queue.dto.d.ts +45 -0
- package/dist/package/entity/restaurant/restaurant.dto.d.ts +5 -0
- package/dist/package/entity/websocket/websocket.dto.d.ts +12 -0
- package/package.json +1 -1
- package/src/locales/en-US.json +15 -1
- package/src/locales/ja-JP.json +23 -9
- package/src/locales/th-TH.json +15 -1
- package/src/locales/zh-CN.json +15 -1
- package/src/modules/kiosk/interface.ts +1 -0
- package/src/modules/order-setting/kiosk/interface.ts +15 -13
- package/src/stores/kiosk/mapper.ts +1 -0
- package/src/stores/order-setting/mapper.ts +16 -13
- package/src/views/kiosk/KioskSummary.vue +37 -31
- package/src/views/kiosk/KioskView.vue +4 -1
- package/src/views/kiosk/devices/KioskDeviceCard.vue +205 -89
- package/src/views/kiosk/devices/KioskDevicesView.vue +133 -17
- package/src/views/kiosk/settings/KioskSettingView.vue +43 -23
- package/dist/KioskDevicesView.vue_vue_type_script_setup_true_lang-DV2HYd8u.js +0 -306
- package/dist/KioskSettingView-CaBhf48e.js +0 -553
- package/dist/KioskView-BGm-emCw.js +0 -452
|
@@ -1,8 +1,23 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div v-if="!!kioskOrderSettingForm" class="flex flex-col gap-32">
|
|
3
|
-
<!--
|
|
4
|
-
<div class="flex flex-col gap-2">
|
|
5
|
-
<span class="fm-typo-en-title-sm-600">{{ t('order.
|
|
1
|
+
<template>
|
|
2
|
+
<div v-if="!!kioskOrderSettingForm" class="flex flex-col gap-32">
|
|
3
|
+
<!-- OTA Channel Section -->
|
|
4
|
+
<div v-if="isAdmin" class="flex flex-col gap-2">
|
|
5
|
+
<span class="fm-typo-en-title-sm-600">{{ t('order.otaChannel') }}</span>
|
|
6
|
+
<div class="flex flex-col gap-1 w-full md:w-1/2">
|
|
7
|
+
<FmTextField
|
|
8
|
+
v-model="kioskOrderSettingForm.otaChannel"
|
|
9
|
+
:label="t('order.otaChannel')"
|
|
10
|
+
:placeholder="t('order.otaChannelHint')"
|
|
11
|
+
/>
|
|
12
|
+
<span class="fm-typo-en-body-sm-400 text-fm-color-typo-secondary">
|
|
13
|
+
{{ t('order.otaChannelHint') }}
|
|
14
|
+
</span>
|
|
15
|
+
</div>
|
|
16
|
+
</div>
|
|
17
|
+
|
|
18
|
+
<!-- Dine In Section -->
|
|
19
|
+
<div class="flex flex-col gap-2">
|
|
20
|
+
<span class="fm-typo-en-title-sm-600">{{ t('order.dineIn') }}</span>
|
|
6
21
|
<div class="flex flex-col gap-5">
|
|
7
22
|
<FmSwitch
|
|
8
23
|
v-model="kioskOrderSettingForm.dineIn.enabled"
|
|
@@ -183,19 +198,22 @@
|
|
|
183
198
|
</template>
|
|
184
199
|
<script setup lang="ts">
|
|
185
200
|
import { computed, ref } from 'vue'
|
|
186
|
-
import KioskPaymentTypeSection from './KioskPaymentTypeSection.vue'
|
|
187
|
-
import { FdoOfflinePaymentMethod } from '@feedmepos/core/entity'
|
|
188
|
-
import { FdoEPaymentMethod, F_ORDER_PAYMENT_TYPE } from '@entity'
|
|
189
|
-
import type {
|
|
190
|
-
MfKioskOrderSetting,
|
|
201
|
+
import KioskPaymentTypeSection from './KioskPaymentTypeSection.vue'
|
|
202
|
+
import { FdoOfflinePaymentMethod } from '@feedmepos/core/entity'
|
|
203
|
+
import { FdoEPaymentMethod, F_ORDER_PAYMENT_TYPE } from '@entity'
|
|
204
|
+
import type {
|
|
205
|
+
MfKioskOrderSetting,
|
|
191
206
|
MfKioskOrderSettingForm,
|
|
192
207
|
KioskPaymentTypesForm
|
|
193
208
|
} from '@/modules/order-setting/kiosk/interface'
|
|
194
|
-
import { useLoading } from '@/composables/loading'
|
|
195
|
-
import { useSnackbar } from '@feedmepos/ui-library'
|
|
196
|
-
import { useI18n } from '@feedmepos/mf-common'
|
|
197
|
-
|
|
198
|
-
|
|
209
|
+
import { useLoading } from '@/composables/loading'
|
|
210
|
+
import { useSnackbar } from '@feedmepos/ui-library'
|
|
211
|
+
import { useI18n } from '@feedmepos/mf-common'
|
|
212
|
+
import { useCoreStore } from '@feedmepos/mf-common'
|
|
213
|
+
|
|
214
|
+
const { t } = useI18n()
|
|
215
|
+
const CoreStore = useCoreStore()
|
|
216
|
+
const isAdmin = computed(() => CoreStore.sessionUser.value?.role.isAdmin ?? false)
|
|
199
217
|
|
|
200
218
|
interface Props {
|
|
201
219
|
restaurantId: string
|
|
@@ -231,8 +249,9 @@ const padDigitRules = computed(() => [nonNegativeRule])
|
|
|
231
249
|
const minRules = computed(() => [nonNegativeRule])
|
|
232
250
|
const maxRules = computed(() => [nonNegativeRule, greaterThanMinRule])
|
|
233
251
|
|
|
234
|
-
const validKioskOrderSetting = computed<MfKioskOrderSetting | null>(() => {
|
|
235
|
-
const f = kioskOrderSettingForm.value
|
|
252
|
+
const validKioskOrderSetting = computed<MfKioskOrderSetting | null>(() => {
|
|
253
|
+
const f = kioskOrderSettingForm.value
|
|
254
|
+
const otaChannel = f.otaChannel?.trim()
|
|
236
255
|
|
|
237
256
|
// Validate display stand settings if both dineIn and displayStand are enabled
|
|
238
257
|
if (f.dineIn.enabled && f.dineIn.displayStand.enabled) {
|
|
@@ -247,12 +266,13 @@ const validKioskOrderSetting = computed<MfKioskOrderSetting | null>(() => {
|
|
|
247
266
|
if (!isValid) return null
|
|
248
267
|
}
|
|
249
268
|
|
|
250
|
-
// Return the form as-is if valid, with display stand disabled when dineIn is disabled
|
|
251
|
-
return {
|
|
252
|
-
...f,
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
269
|
+
// Return the form as-is if valid, with display stand disabled when dineIn is disabled
|
|
270
|
+
return {
|
|
271
|
+
...f,
|
|
272
|
+
otaChannel: otaChannel || undefined,
|
|
273
|
+
dineIn: {
|
|
274
|
+
...f.dineIn,
|
|
275
|
+
displayStand: {
|
|
256
276
|
...f.dineIn.displayStand,
|
|
257
277
|
enabled: f.dineIn.enabled && f.dineIn.displayStand.enabled,
|
|
258
278
|
padDigit: f.dineIn.displayStand.padDigit ?? 0,
|
|
@@ -1,306 +0,0 @@
|
|
|
1
|
-
import { defineComponent as S, ref as f, resolveComponent as b, createElementBlock as d, openBlock as l, createElementVNode as n, createVNode as v, toDisplayString as r, unref as y, computed as h, withCtx as M, Fragment as V, renderList as T, createCommentVNode as x, createBlock as N } from "vue";
|
|
2
|
-
import { useDialog as J, useSnackbar as Q } from "@feedmepos/ui-library";
|
|
3
|
-
import { useI18n as K } from "@feedmepos/mf-common";
|
|
4
|
-
import { defineStore as X } from "pinia";
|
|
5
|
-
import { r as w, g as U, d as Z } from "./dayjs.min-dI_j30pv.js";
|
|
6
|
-
import "./menu.dto-qVeqpSdz.js";
|
|
7
|
-
const ee = /* @__PURE__ */ S({
|
|
8
|
-
__name: "KioskUnbindConfirm",
|
|
9
|
-
props: {
|
|
10
|
-
machineId: {}
|
|
11
|
-
},
|
|
12
|
-
emits: ["update:modelValue"],
|
|
13
|
-
setup(e, { emit: t }) {
|
|
14
|
-
const { t: c } = K(), u = t, m = f("");
|
|
15
|
-
function s(i) {
|
|
16
|
-
u("update:modelValue", i);
|
|
17
|
-
}
|
|
18
|
-
return (i, k) => {
|
|
19
|
-
const D = b("FmTextField");
|
|
20
|
-
return l(), d("div", null, [
|
|
21
|
-
n("span", null, r(y(c)("order.unbindKioskDeviceWarning", { machineId: i.machineId })), 1),
|
|
22
|
-
v(D, {
|
|
23
|
-
"model-value": m.value,
|
|
24
|
-
"onUpdate:modelValue": s,
|
|
25
|
-
placeholder: i.machineId
|
|
26
|
-
}, null, 8, ["model-value", "placeholder"])
|
|
27
|
-
]);
|
|
28
|
-
};
|
|
29
|
-
}
|
|
30
|
-
});
|
|
31
|
-
async function ne() {
|
|
32
|
-
const e = await w().get("/kiosk/otp");
|
|
33
|
-
return U(e);
|
|
34
|
-
}
|
|
35
|
-
async function te() {
|
|
36
|
-
const e = await w().get("/kiosk/devices");
|
|
37
|
-
return U(e);
|
|
38
|
-
}
|
|
39
|
-
async function oe(e) {
|
|
40
|
-
await w().delete(`/kiosk/unbind/${e}`);
|
|
41
|
-
}
|
|
42
|
-
async function se(e, t) {
|
|
43
|
-
await w().put(`/kiosk/updateDevicePin/${t}`, { pinInfo: e });
|
|
44
|
-
}
|
|
45
|
-
const I = {
|
|
46
|
-
requestOtp: ne,
|
|
47
|
-
getDevices: te,
|
|
48
|
-
unbind: oe,
|
|
49
|
-
updateDevicePin: se
|
|
50
|
-
}, ie = (e) => ({
|
|
51
|
-
name: e.name ?? "N/A",
|
|
52
|
-
machineId: e.machineId,
|
|
53
|
-
config: {
|
|
54
|
-
scannerInfo: e.scannerInfo ?? void 0,
|
|
55
|
-
printerInfo: e.printerInfo ?? void 0,
|
|
56
|
-
terminalInfo: e.terminalInfo ?? void 0
|
|
57
|
-
},
|
|
58
|
-
activatedAt: ae(e.token),
|
|
59
|
-
deviceAppType: e.deviceAppType ?? void 0,
|
|
60
|
-
slotInfo: e.slotInfo ?? void 0,
|
|
61
|
-
pinInfo: e.pinInfo ?? void 0,
|
|
62
|
-
deviceAppVersion: e.deviceAppVersion ?? void 0,
|
|
63
|
-
deviceAppOTAVersion: e.deviceAppOTAVersion ?? void 0
|
|
64
|
-
});
|
|
65
|
-
function ae(e) {
|
|
66
|
-
const t = e.substring(0, 8), c = parseInt(t, 16);
|
|
67
|
-
return new Date(c * 1e3);
|
|
68
|
-
}
|
|
69
|
-
const le = {
|
|
70
|
-
toMfKioskDevice: ie
|
|
71
|
-
}, ce = X("kiosk", () => {
|
|
72
|
-
const e = f({
|
|
73
|
-
otp: "",
|
|
74
|
-
devices: []
|
|
75
|
-
});
|
|
76
|
-
async function t() {
|
|
77
|
-
const s = await I.requestOtp();
|
|
78
|
-
e.value.otp = s.otp;
|
|
79
|
-
}
|
|
80
|
-
async function c() {
|
|
81
|
-
const s = await I.getDevices();
|
|
82
|
-
e.value.devices = s.map((i) => le.toMfKioskDevice(i));
|
|
83
|
-
}
|
|
84
|
-
async function u(s) {
|
|
85
|
-
await I.unbind(s), await c();
|
|
86
|
-
}
|
|
87
|
-
async function m(s, i) {
|
|
88
|
-
await I.updateDevicePin(s, i);
|
|
89
|
-
}
|
|
90
|
-
return {
|
|
91
|
-
state: e.value,
|
|
92
|
-
requestOtp: t,
|
|
93
|
-
getDevices: c,
|
|
94
|
-
unbind: u,
|
|
95
|
-
updateDevicePin: m
|
|
96
|
-
};
|
|
97
|
-
}), re = { class: "border fm-corner-radius-lg flex justify-between pr-[1rem] w-11/12" }, de = {
|
|
98
|
-
key: 0,
|
|
99
|
-
class: "py-[1rem] flex flex-col gap-6"
|
|
100
|
-
}, pe = { class: "fm-typo-en-title-sm-600" }, ue = { class: "w-full border p-[1.5rem] fm-corner-radius-lg flex flex-col gap-2" }, me = { class: "flex flex-col gap-1 mb-2" }, fe = { class: "fm-typo-en-body-lg-600 block" }, ve = { class: "flex flex-col gap-1 mb-2" }, ye = { class: "fm-typo-en-body-lg-600 block" }, _e = { class: "flex flex-col gap-1 mb-2" }, be = { class: "fm-typo-en-body-lg-600 block" }, ke = { class: "flex flex-col gap-1 mb-2" }, ge = { class: "fm-typo-en-body-lg-600 block" }, he = { class: "w-full border p-[1.5rem] fm-corner-radius-lg flex flex-col gap-2" }, xe = {
|
|
101
|
-
key: 0,
|
|
102
|
-
class: "fm-typo-en-title-sm-600"
|
|
103
|
-
}, Ie = { class: "flex flex-col gap-1" }, we = { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, De = { class: "fm-typo-en-body-lg-600 block" }, Ae = { key: 1 }, Pe = { class: "py-[1rem] flex flex-col gap-6 text-center items-center" }, Fe = { class: "flex flex-col gap-1 mb-2" }, Ce = { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, Ve = { class: "mt-5 block" }, Te = /* @__PURE__ */ S({
|
|
104
|
-
__name: "KioskDeviceCard",
|
|
105
|
-
props: {
|
|
106
|
-
device: {}
|
|
107
|
-
},
|
|
108
|
-
setup(e) {
|
|
109
|
-
const { t } = K(), c = J(), u = Q(), m = ce(), s = f(!1), i = e, k = f(""), D = h(() => Object.entries(i.device.config)), E = h(() => {
|
|
110
|
-
var o;
|
|
111
|
-
return ((o = i.device) == null ? void 0 : o.deviceAppType) === "TABLET_APP" ? "Tablet App" : "Kiosk App";
|
|
112
|
-
});
|
|
113
|
-
function q() {
|
|
114
|
-
k.value = "", c.open({
|
|
115
|
-
title: t("order.unbindKioskDevice"),
|
|
116
|
-
contentComponent: ee,
|
|
117
|
-
contentComponentProps: {
|
|
118
|
-
machineId: i.device.machineId,
|
|
119
|
-
"onUpdate:modelValue": (o) => {
|
|
120
|
-
k.value = o;
|
|
121
|
-
}
|
|
122
|
-
},
|
|
123
|
-
dismissAway: !1,
|
|
124
|
-
primaryActions: {
|
|
125
|
-
text: t("order.unbind"),
|
|
126
|
-
variant: "destructive",
|
|
127
|
-
close: !1
|
|
128
|
-
},
|
|
129
|
-
secondaryActions: {
|
|
130
|
-
text: t("order.cancel"),
|
|
131
|
-
variant: "tertiary",
|
|
132
|
-
close: !0
|
|
133
|
-
}
|
|
134
|
-
}).onPrimary(async () => {
|
|
135
|
-
k.value == i.device.machineId ? (await R(), u.open({
|
|
136
|
-
type: "success",
|
|
137
|
-
message: t("order.unbindSuccess"),
|
|
138
|
-
position: "bottom"
|
|
139
|
-
}), c.close()) : u.open({
|
|
140
|
-
type: "warning",
|
|
141
|
-
message: t("order.unbindWarning"),
|
|
142
|
-
position: "bottom"
|
|
143
|
-
});
|
|
144
|
-
});
|
|
145
|
-
}
|
|
146
|
-
const Y = h(() => {
|
|
147
|
-
var o;
|
|
148
|
-
return (o = i.device) == null ? void 0 : o.pinInfo;
|
|
149
|
-
}), j = h(() => _.value ? "Re-enter new PIN" : "Enter new PIN"), _ = f(!1), g = f(), A = f();
|
|
150
|
-
function L() {
|
|
151
|
-
s.value = !0;
|
|
152
|
-
}
|
|
153
|
-
function P() {
|
|
154
|
-
_.value = !1, g.value = null, A.value = null, s.value = !1;
|
|
155
|
-
}
|
|
156
|
-
function O(o) {
|
|
157
|
-
_.value ? (A.value = o, W()) : (g.value = o, _.value = !0);
|
|
158
|
-
}
|
|
159
|
-
async function W() {
|
|
160
|
-
g.value === A.value ? (await H(), u.open({
|
|
161
|
-
type: "success",
|
|
162
|
-
message: "Successfuly update device PIN",
|
|
163
|
-
position: "top"
|
|
164
|
-
})) : u.open({
|
|
165
|
-
type: "error",
|
|
166
|
-
message: "Entered PIN not the same, please try again",
|
|
167
|
-
position: "top"
|
|
168
|
-
}), P();
|
|
169
|
-
}
|
|
170
|
-
async function H() {
|
|
171
|
-
await m.updateDevicePin(g.value, i.device.machineId);
|
|
172
|
-
}
|
|
173
|
-
async function R() {
|
|
174
|
-
await m.unbind(i.device.machineId);
|
|
175
|
-
}
|
|
176
|
-
return (o, a) => {
|
|
177
|
-
const z = b("FmListItem"), F = b("FmButton"), $ = b("FmPinField"), G = b("FmSideSheet");
|
|
178
|
-
return l(), d("div", re, [
|
|
179
|
-
v(G, {
|
|
180
|
-
header: y(t)("order.deviceDetails"),
|
|
181
|
-
"dismiss-away": "",
|
|
182
|
-
class: "w-full",
|
|
183
|
-
maxWidth: 700,
|
|
184
|
-
"onOn:clickedAway": P
|
|
185
|
-
}, {
|
|
186
|
-
"side-sheet-button": M(() => [
|
|
187
|
-
v(z, {
|
|
188
|
-
class: "flex-1",
|
|
189
|
-
label: o.device.name,
|
|
190
|
-
sublabel: `${y(t)("order.activatedDate")}: ${y(Z)(o.device.activatedAt).format("DD MMM YYYY HH:mm")}`
|
|
191
|
-
}, null, 8, ["label", "sublabel"])
|
|
192
|
-
]),
|
|
193
|
-
default: M(() => {
|
|
194
|
-
var B;
|
|
195
|
-
return [
|
|
196
|
-
s.value ? (l(), d("div", Ae, [
|
|
197
|
-
n("div", Pe, [
|
|
198
|
-
n("div", Fe, [
|
|
199
|
-
n("span", Ce, r(j.value), 1),
|
|
200
|
-
n("span", Ve, [
|
|
201
|
-
_.value ? x("", !0) : (l(), N($, {
|
|
202
|
-
key: 0,
|
|
203
|
-
length: 4,
|
|
204
|
-
onComplete: a[0] || (a[0] = (p) => O(p))
|
|
205
|
-
})),
|
|
206
|
-
_.value ? (l(), N($, {
|
|
207
|
-
key: 1,
|
|
208
|
-
length: 4,
|
|
209
|
-
onComplete: a[1] || (a[1] = (p) => O(p))
|
|
210
|
-
})) : x("", !0)
|
|
211
|
-
])
|
|
212
|
-
]),
|
|
213
|
-
v(F, {
|
|
214
|
-
class: "w-1/3",
|
|
215
|
-
variant: "secondary",
|
|
216
|
-
label: "Cancel reset PIN",
|
|
217
|
-
onClick: P
|
|
218
|
-
})
|
|
219
|
-
])
|
|
220
|
-
])) : (l(), d("div", de, [
|
|
221
|
-
n("span", pe, r(o.device.name), 1),
|
|
222
|
-
n("div", ue, [
|
|
223
|
-
a[6] || (a[6] = n("span", { class: "fm-typo-en-title-sm-600 mb-3" }, "App Info", -1)),
|
|
224
|
-
n("div", me, [
|
|
225
|
-
a[2] || (a[2] = n("span", { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, "Type", -1)),
|
|
226
|
-
n("span", fe, r(E.value), 1)
|
|
227
|
-
]),
|
|
228
|
-
n("div", ve, [
|
|
229
|
-
a[3] || (a[3] = n("span", { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, "Version", -1)),
|
|
230
|
-
n("span", ye, r(o.device.deviceAppVersion ?? "Below 0.0.42"), 1)
|
|
231
|
-
]),
|
|
232
|
-
n("div", _e, [
|
|
233
|
-
a[4] || (a[4] = n("span", { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, "OTA Version", -1)),
|
|
234
|
-
n("span", be, r(o.device.deviceAppOTAVersion ?? "Not available"), 1)
|
|
235
|
-
]),
|
|
236
|
-
n("div", ke, [
|
|
237
|
-
a[5] || (a[5] = n("span", { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, "PIN Code", -1)),
|
|
238
|
-
n("span", ge, r(Y.value ? "Yes" : "No"), 1)
|
|
239
|
-
]),
|
|
240
|
-
v(F, {
|
|
241
|
-
class: "w-auto",
|
|
242
|
-
variant: "primary",
|
|
243
|
-
label: (B = o.device) != null && B.pinInfo ? "Reset Device PIN" : "Set Device PIN",
|
|
244
|
-
onClick: L
|
|
245
|
-
}, null, 8, ["label"])
|
|
246
|
-
]),
|
|
247
|
-
(l(!0), d(V, null, T(D.value.filter((p) => p[1]), (p) => (l(), d("div", he, [
|
|
248
|
-
p[1] ? (l(), d("span", xe, r(p[0]), 1)) : x("", !0),
|
|
249
|
-
p[1] ? (l(!0), d(V, { key: 1 }, T(Object.entries(p[1]), (C) => (l(), d("div", Ie, [
|
|
250
|
-
n("span", we, r(C[0]), 1),
|
|
251
|
-
n("span", De, r(C[1] == "" ? "-" : C[1]), 1)
|
|
252
|
-
]))), 256)) : x("", !0)
|
|
253
|
-
]))), 256))
|
|
254
|
-
]))
|
|
255
|
-
];
|
|
256
|
-
}),
|
|
257
|
-
_: 1
|
|
258
|
-
}, 8, ["header"]),
|
|
259
|
-
v(F, {
|
|
260
|
-
variant: "plain",
|
|
261
|
-
"append-icon": "link_off",
|
|
262
|
-
class: "text-fm-color-system-error-300 align-middle my-auto",
|
|
263
|
-
onClick: q
|
|
264
|
-
})
|
|
265
|
-
]);
|
|
266
|
-
};
|
|
267
|
-
}
|
|
268
|
-
}), Ne = { class: "flex flex-col gap-2" }, Se = { class: "flex flex-col gap-2" }, Ke = { class: "fm-typo-en-title-sm-600 block" }, Oe = { class: "fm-typo-en-body-md-400 block" }, $e = { class: "flex flex-col gap-6" }, je = /* @__PURE__ */ S({
|
|
269
|
-
__name: "KioskDevicesView",
|
|
270
|
-
props: {
|
|
271
|
-
devices: {},
|
|
272
|
-
requestOtp: { type: Function }
|
|
273
|
-
},
|
|
274
|
-
setup(e) {
|
|
275
|
-
const { t } = K();
|
|
276
|
-
return (c, u) => {
|
|
277
|
-
const m = b("FmButton");
|
|
278
|
-
return l(), d("div", null, [
|
|
279
|
-
n("div", Ne, [
|
|
280
|
-
n("div", Se, [
|
|
281
|
-
n("span", Ke, r(y(t)("order.kioskDisplay")), 1),
|
|
282
|
-
n("span", Oe, r(y(t)("order.kioskDisplayDescription")), 1)
|
|
283
|
-
]),
|
|
284
|
-
n("div", $e, [
|
|
285
|
-
(l(!0), d(V, null, T(c.devices, (s) => (l(), N(Te, {
|
|
286
|
-
key: s.machineId,
|
|
287
|
-
device: s
|
|
288
|
-
}, null, 8, ["device"]))), 128)),
|
|
289
|
-
v(m, {
|
|
290
|
-
variant: "plain",
|
|
291
|
-
class: "w-[10rem] border border-fm-color-primary fm-corner-radius-lg",
|
|
292
|
-
label: y(t)("order.bindDevice"),
|
|
293
|
-
size: "md",
|
|
294
|
-
"prepend-icon": "link",
|
|
295
|
-
onClick: c.requestOtp
|
|
296
|
-
}, null, 8, ["label", "onClick"])
|
|
297
|
-
])
|
|
298
|
-
])
|
|
299
|
-
]);
|
|
300
|
-
};
|
|
301
|
-
}
|
|
302
|
-
});
|
|
303
|
-
export {
|
|
304
|
-
je as _,
|
|
305
|
-
ce as u
|
|
306
|
-
};
|