@feedmepos/mf-order-setting 0.0.76 → 0.0.77
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-H7stMDFu.js → KioskDevicesView-Dgs5_UoK.js} +1 -1
- package/dist/{KioskDevicesView.vue_vue_type_script_setup_true_lang-DgpV4oKE.js → KioskDevicesView.vue_vue_type_script_setup_true_lang-B4DXPgAV.js} +3 -3
- package/dist/KioskSettingView-BUcPNVTc.js +681 -0
- package/dist/{KioskView-Cxcc1UL1.js → KioskView-DelVMMj4.js} +137 -127
- package/dist/{OrderSettingsView-Ds2L_rbu.js → OrderSettingsView-DE2U7vqW.js} +9232 -8262
- package/dist/{app-BDlPjU4y.js → app-BIvt4NBq.js} +1476 -1302
- package/dist/app.js +1 -1
- package/dist/{dayjs.min-OJf1trOq.js → dayjs.min-B58_jBg3.js} +1 -1
- package/dist/frontend/mf-order/src/api/index.d.ts +3 -1
- package/dist/frontend/mf-order/src/api/remoteOrder/index.d.ts +65 -2
- package/dist/frontend/mf-order/src/app.d.ts +174 -0
- package/dist/frontend/mf-order/src/composables/useInternalUser.d.ts +3 -0
- package/dist/frontend/mf-order/src/main.d.ts +174 -0
- package/dist/frontend/mf-order/src/modules/order-setting/kiosk/interface.d.ts +4 -0
- package/dist/frontend/mf-order/src/stores/order-setting/index.d.ts +15 -3
- package/dist/frontend/mf-order/src/views/order-settings/delivery/integrated-delivery/AdditionalStores.vue.d.ts +16 -0
- package/dist/frontend/mf-order/src/views/order-settings/delivery/integrated-delivery/ExternalSetting.vue.d.ts +2 -2
- package/dist/frontend/mf-order/src/views/order-settings/delivery/integrated-delivery/FoodpandaAdditionalStores.vue.d.ts +10 -0
- package/dist/frontend/mf-order/src/views/order-settings/delivery/integrated-delivery/IntegratedDelivery.vue.d.ts +15 -4
- package/dist/frontend/mf-order/src/views/order-settings/delivery/integrated-delivery/IntegrationIdentityDetails.vue.d.ts +10 -0
- package/dist/frontend/mf-order/src/views/order-settings/delivery/integrated-delivery/ShopeefoodAdditionalStores.vue.d.ts +10 -0
- package/dist/frontend/mf-order/tsconfig.app.tsbuildinfo +1 -1
- package/dist/index-CLS-FSH-.js +762 -0
- package/dist/{index-gGOpbnY3.js → index-CahsmFL1.js} +1 -1
- package/dist/{lineman-settings.dto-Cny_fF4n.js → lineman-settings.dto-DBDThIb0.js} +8999 -8874
- package/dist/package/entity/delivery/delivery.enum.d.ts +1 -1
- package/dist/package/entity/incoming-order/incoming-order.do.d.ts +4 -4
- package/dist/package/entity/kiosk/marketing/marketing.dto.d.ts +11 -0
- package/dist/package/entity/order-platform/base-integration.dto.d.ts +179 -0
- package/dist/package/entity/order-platform/deliveroo/deliveroo-dto.d.ts +2 -2
- package/dist/package/entity/order-platform/deliveroo/deliveroo-setting.do.d.ts +2 -2
- package/dist/package/entity/order-platform/external/order/external-order.dto.d.ts +2 -2
- package/dist/package/entity/order-platform/external/setting/external-setting.do.d.ts +4 -4
- package/dist/package/entity/order-platform/external/setting/external-setting.dto.d.ts +4 -4
- package/dist/package/entity/order-platform/foodpanda/foodpanda-menu.dto.d.ts +1 -1
- package/dist/package/entity/order-platform/foodpanda/foodpanda-settings.do.d.ts +105 -4
- package/dist/package/entity/order-platform/foodpanda/foodpanda-settings.dto.d.ts +30 -11
- package/dist/package/entity/order-platform/gofood/gofood-settings.do.d.ts +2 -2
- package/dist/package/entity/order-platform/gofood/gofood-settings.dto.d.ts +2 -2
- package/dist/package/entity/order-platform/grabfood/grabfood-order.do.d.ts +10 -10
- package/dist/package/entity/order-platform/grabfood/grabfood-settings.do.d.ts +134 -6
- package/dist/package/entity/order-platform/grabfood/grabfood.dto.d.ts +42 -20
- package/dist/package/entity/order-platform/lineman/lineman-settings.do.d.ts +2 -2
- package/dist/package/entity/order-platform/lineman/lineman-settings.dto.d.ts +2 -2
- package/dist/package/entity/order-platform/shopeefood/shopeefood-settings.do.d.ts +102 -4
- package/dist/package/entity/order-platform/shopeefood/shopeefood-settings.dto.d.ts +66 -5
- package/dist/package/entity/order-platform/tng/tng-settings.do.d.ts +2 -2
- package/dist/package/entity/order-platform/tng/tng-settings.dto.d.ts +4 -4
- package/dist/package/entity/order-setting/dine-in/dine-in.do.d.ts +2 -2
- package/dist/package/entity/order-setting/dine-in/dine-in.dto.d.ts +2 -2
- package/dist/package/entity/order-setting/kiosk/kiosk.do.d.ts +6 -0
- package/dist/package/entity/order-setting/kiosk/kiosk.dto.d.ts +6 -0
- package/dist/package/entity/order-setting/order-setting.do.d.ts +14 -4
- package/dist/package/entity/order-setting/order-setting.dto.d.ts +28 -8
- package/dist/package/entity/restaurant/restaurant.dto.d.ts +10 -0
- package/dist/package/entity/websocket/websocket.dto.d.ts +24 -0
- package/dist/style.css +1 -1
- package/package.json +1 -1
- package/src/api/index.ts +8 -2
- package/src/api/remoteOrder/index.ts +200 -4
- package/src/composables/useInternalUser.ts +14 -0
- package/src/locales/en-US.json +43 -0
- package/src/locales/ja-JP.json +43 -0
- package/src/locales/th-TH.json +90 -45
- package/src/locales/zh-CN.json +43 -0
- package/src/modules/order-setting/kiosk/interface.ts +29 -19
- package/src/stores/order-setting/mapper.ts +65 -55
- package/src/views/kiosk/settings/KioskSettingView.vue +33 -0
- package/src/views/order-settings/delivery/DeliverySetting.vue +0 -1
- package/src/views/order-settings/delivery/delivery.data.ts +3 -0
- package/src/views/order-settings/delivery/integrated-delivery/AdditionalStores.vue +472 -0
- package/src/views/order-settings/delivery/integrated-delivery/FoodpandaAdditionalStores.vue +314 -0
- package/src/views/order-settings/delivery/integrated-delivery/FoodpandaSetting.vue +27 -8
- package/src/views/order-settings/delivery/integrated-delivery/GrabfoodSetting.vue +31 -12
- package/src/views/order-settings/delivery/integrated-delivery/IntegratedDelivery.vue +23 -11
- package/src/views/order-settings/delivery/integrated-delivery/IntegrationIdentityDetails.vue +144 -0
- package/src/views/order-settings/delivery/integrated-delivery/ShopeefoodAdditionalStores.vue +335 -0
- package/src/views/order-settings/delivery/integrated-delivery/ShopeefoodSetting.vue +29 -8
- package/src/views/order-settings/queue/QueueSetting.vue +1 -1
- package/dist/KioskSettingView-fF6k9s_q.js +0 -658
- package/dist/index-Bid9lO2x.js +0 -665
|
@@ -0,0 +1,681 @@
|
|
|
1
|
+
import { defineComponent as oe, computed as A, ref as L, onMounted as pe, resolveComponent as w, openBlock as k, createBlock as G, withCtx as T, createVNode as s, unref as a, createElementVNode as r, withDirectives as R, vShow as U, watch as ce, createElementBlock as q, toDisplayString as g, createCommentVNode as ye } from "vue";
|
|
2
|
+
import { e as le, b as re, s as se, d as fe, r as ae, f as te, h as ve } from "./app-BIvt4NBq.js";
|
|
3
|
+
import { b as m, c as be } from "./lineman-settings.dto-DBDThIb0.js";
|
|
4
|
+
import { _ as ge, u as Ie, a as Pe } from "./index-CLS-FSH-.js";
|
|
5
|
+
import { useI18n as de, FeedMeAuth as ie, useCoreStore as Se } from "@feedmepos/mf-common";
|
|
6
|
+
import { useSnackbar as xe } from "@feedmepos/ui-library";
|
|
7
|
+
const we = { class: "ml-7" }, _e = { class: "ml-7" }, Ce = { class: "flex flex-row gap-9" }, Ve = /* @__PURE__ */ oe({
|
|
8
|
+
__name: "KioskPaymentTypeSection",
|
|
9
|
+
props: {
|
|
10
|
+
paymentTypes: {
|
|
11
|
+
type: Array,
|
|
12
|
+
required: !0
|
|
13
|
+
},
|
|
14
|
+
offlinePaymentTypes: {
|
|
15
|
+
type: Array,
|
|
16
|
+
required: !0
|
|
17
|
+
},
|
|
18
|
+
allowEPayment: {
|
|
19
|
+
type: [Boolean, String],
|
|
20
|
+
required: !0
|
|
21
|
+
},
|
|
22
|
+
allowCredit: {
|
|
23
|
+
type: [Boolean, String],
|
|
24
|
+
default: !1
|
|
25
|
+
},
|
|
26
|
+
ePaymentTypes: {
|
|
27
|
+
type: Object,
|
|
28
|
+
required: !0
|
|
29
|
+
}
|
|
30
|
+
},
|
|
31
|
+
emits: ["update:paymentTypes", "update:offlinePaymentTypes", "update:ePaymentTypes"],
|
|
32
|
+
setup(i, { emit: p }) {
|
|
33
|
+
const { t: e } = de(), b = i, _ = p, P = A(() => (b.paymentTypes || []).includes(le.F_ORDER_PAYMENT_TYPE.enum.ePayment)), I = L(), y = L([]), l = L(!1), F = L(!1), C = L(!1), j = () => {
|
|
34
|
+
Object.keys(b.ePaymentTypes).length !== 0 && (b.ePaymentTypes.terminal && (F.value = !0), b.ePaymentTypes.card.terminal ? (I.value = m.enum.TERMINAL, l.value = !0) : b.ePaymentTypes.card.nfc && (I.value = m.enum.NFC, l.value = !0), b.ePaymentTypes.eWallet.qrPay && (y.value.push(m.enum.QRPAY), C.value = !0), b.ePaymentTypes.eWallet.scanPay && (y.value.push(m.enum.SCANPAY), C.value = !0));
|
|
35
|
+
};
|
|
36
|
+
j();
|
|
37
|
+
const K = (c) => {
|
|
38
|
+
const d = {
|
|
39
|
+
terminal: !1,
|
|
40
|
+
card: {
|
|
41
|
+
terminal: !1,
|
|
42
|
+
nfc: !1
|
|
43
|
+
},
|
|
44
|
+
eWallet: {
|
|
45
|
+
qrPay: !1,
|
|
46
|
+
scanPay: !1
|
|
47
|
+
}
|
|
48
|
+
};
|
|
49
|
+
P.value && (c == m.enum.TERMINAL && (d.card.terminal = !0), c == m.enum.NFC && (d.card.nfc = !0), y.value.length > 0 && (y.value.includes(m.enum.QRPAY) && (d.eWallet.qrPay = !0), y.value.includes(m.enum.SCANPAY) && (d.eWallet.scanPay = !0))), F.value && (d.terminal = !0), _("update:ePaymentTypes", d);
|
|
50
|
+
}, V = () => {
|
|
51
|
+
const c = {
|
|
52
|
+
terminal: !1,
|
|
53
|
+
card: {
|
|
54
|
+
terminal: !1,
|
|
55
|
+
nfc: !1
|
|
56
|
+
},
|
|
57
|
+
eWallet: {
|
|
58
|
+
qrPay: !1,
|
|
59
|
+
scanPay: !1,
|
|
60
|
+
terminalScanPay: !1,
|
|
61
|
+
terminalQrPay: !1
|
|
62
|
+
}
|
|
63
|
+
};
|
|
64
|
+
P.value && (I.value && (I.value === m.enum.TERMINAL && (c.card.terminal = !0), I.value === m.enum.NFC && (c.card.nfc = !0)), F.value && (c.terminal = !0), y.value.includes(m.enum.QRPAY) && (c.eWallet.qrPay = !0), y.value.includes(m.enum.SCANPAY) && (c.eWallet.scanPay = !0), y.value.includes(m.enum.TERMINAL_SCAN_PAY) && (c.eWallet.terminalScanPay = !0), y.value.includes(m.enum.TERMINAL_QR_PAY) && (c.eWallet.terminalQrPay = !0)), _("update:ePaymentTypes", c);
|
|
65
|
+
}, Q = (c) => {
|
|
66
|
+
I.value = "", c && (I.value = m.enum.TERMINAL), V();
|
|
67
|
+
}, E = (c) => {
|
|
68
|
+
y.value = [], c && (y.value = [
|
|
69
|
+
m.enum.QRPAY,
|
|
70
|
+
m.enum.SCANPAY
|
|
71
|
+
]), V();
|
|
72
|
+
}, z = (c) => {
|
|
73
|
+
_("update:paymentTypes", c), c.includes(le.F_ORDER_PAYMENT_TYPE.enum.ePayment) || (l.value = !1, C.value = !1, Q(!1), E(!1));
|
|
74
|
+
};
|
|
75
|
+
return pe(() => {
|
|
76
|
+
j();
|
|
77
|
+
}), (c, d) => {
|
|
78
|
+
const Y = w("FmSwitch"), B = w("FmRadio"), N = w("FmRadioGroup"), O = w("FmCardSection"), D = w("FmCard"), M = w("FmCheckbox");
|
|
79
|
+
return k(), G(ge, {
|
|
80
|
+
"payment-types": i.paymentTypes,
|
|
81
|
+
"offline-payment-types": i.offlinePaymentTypes,
|
|
82
|
+
"allow-e-payment": b.allowEPayment,
|
|
83
|
+
"allow-credit": b.allowCredit,
|
|
84
|
+
"onUpdate:paymentTypes": z,
|
|
85
|
+
"onUpdate:offlinePaymentTypes": d[8] || (d[8] = (f) => _("update:offlinePaymentTypes", f || []))
|
|
86
|
+
}, {
|
|
87
|
+
"e-payment-content": T(() => [
|
|
88
|
+
s(D, { variant: "outlined" }, {
|
|
89
|
+
default: T(() => [
|
|
90
|
+
s(O, null, {
|
|
91
|
+
default: T(() => [
|
|
92
|
+
s(Y, {
|
|
93
|
+
label: a(e)("order.bankCard"),
|
|
94
|
+
sublabel: a(e)("order.cardPaymentDescription"),
|
|
95
|
+
"label-placement": "right",
|
|
96
|
+
modelValue: l.value,
|
|
97
|
+
"onUpdate:modelValue": [
|
|
98
|
+
d[0] || (d[0] = (f) => l.value = f),
|
|
99
|
+
Q
|
|
100
|
+
]
|
|
101
|
+
}, null, 8, ["label", "sublabel", "modelValue"]),
|
|
102
|
+
d[9] || (d[9] = r("br", null, null, -1)),
|
|
103
|
+
R(r("div", we, [
|
|
104
|
+
s(N, {
|
|
105
|
+
modelValue: I.value,
|
|
106
|
+
"onUpdate:modelValue": [
|
|
107
|
+
d[1] || (d[1] = (f) => I.value = f),
|
|
108
|
+
K
|
|
109
|
+
],
|
|
110
|
+
inline: ""
|
|
111
|
+
}, {
|
|
112
|
+
default: T(() => [
|
|
113
|
+
s(B, {
|
|
114
|
+
label: a(e)("order.terminal"),
|
|
115
|
+
value: a(m).enum.TERMINAL
|
|
116
|
+
}, null, 8, ["label", "value"]),
|
|
117
|
+
s(B, {
|
|
118
|
+
label: a(e)("order.nfc"),
|
|
119
|
+
value: a(m).enum.NFC
|
|
120
|
+
}, null, 8, ["label", "value"])
|
|
121
|
+
]),
|
|
122
|
+
_: 1
|
|
123
|
+
}, 8, ["modelValue"])
|
|
124
|
+
], 512), [
|
|
125
|
+
[U, l.value]
|
|
126
|
+
])
|
|
127
|
+
]),
|
|
128
|
+
_: 1
|
|
129
|
+
})
|
|
130
|
+
]),
|
|
131
|
+
_: 1
|
|
132
|
+
}),
|
|
133
|
+
s(D, {
|
|
134
|
+
variant: "outlined",
|
|
135
|
+
class: "mt-2"
|
|
136
|
+
}, {
|
|
137
|
+
default: T(() => [
|
|
138
|
+
s(O, null, {
|
|
139
|
+
default: T(() => [
|
|
140
|
+
s(Y, {
|
|
141
|
+
label: a(e)("order.terminal"),
|
|
142
|
+
sublabel: a(e)("order.terminalPaymentDescription"),
|
|
143
|
+
"label-placement": "right",
|
|
144
|
+
modelValue: F.value,
|
|
145
|
+
"onUpdate:modelValue": [
|
|
146
|
+
d[2] || (d[2] = (f) => F.value = f),
|
|
147
|
+
V
|
|
148
|
+
]
|
|
149
|
+
}, null, 8, ["label", "sublabel", "modelValue"])
|
|
150
|
+
]),
|
|
151
|
+
_: 1
|
|
152
|
+
})
|
|
153
|
+
]),
|
|
154
|
+
_: 1
|
|
155
|
+
}),
|
|
156
|
+
s(D, {
|
|
157
|
+
variant: "outlined",
|
|
158
|
+
class: "mt-2"
|
|
159
|
+
}, {
|
|
160
|
+
default: T(() => [
|
|
161
|
+
s(O, null, {
|
|
162
|
+
default: T(() => [
|
|
163
|
+
s(Y, {
|
|
164
|
+
label: a(e)("order.eWallet"),
|
|
165
|
+
sublabel: a(e)("order.eWalletDescription"),
|
|
166
|
+
"label-placement": "right",
|
|
167
|
+
modelValue: C.value,
|
|
168
|
+
"onUpdate:modelValue": [
|
|
169
|
+
d[3] || (d[3] = (f) => C.value = f),
|
|
170
|
+
E
|
|
171
|
+
]
|
|
172
|
+
}, null, 8, ["label", "sublabel", "modelValue"]),
|
|
173
|
+
d[10] || (d[10] = r("br", null, null, -1)),
|
|
174
|
+
R(r("div", _e, [
|
|
175
|
+
r("div", Ce, [
|
|
176
|
+
s(M, {
|
|
177
|
+
modelValue: y.value,
|
|
178
|
+
"onUpdate:modelValue": [
|
|
179
|
+
d[4] || (d[4] = (f) => y.value = f),
|
|
180
|
+
V
|
|
181
|
+
],
|
|
182
|
+
label: a(e)("order.qrPay"),
|
|
183
|
+
value: a(m).enum.QRPAY
|
|
184
|
+
}, null, 8, ["modelValue", "label", "value"]),
|
|
185
|
+
s(M, {
|
|
186
|
+
modelValue: y.value,
|
|
187
|
+
"onUpdate:modelValue": [
|
|
188
|
+
d[5] || (d[5] = (f) => y.value = f),
|
|
189
|
+
V
|
|
190
|
+
],
|
|
191
|
+
label: a(e)("order.scanPay"),
|
|
192
|
+
value: a(m).enum.SCANPAY
|
|
193
|
+
}, null, 8, ["modelValue", "label", "value"]),
|
|
194
|
+
s(M, {
|
|
195
|
+
modelValue: y.value,
|
|
196
|
+
"onUpdate:modelValue": [
|
|
197
|
+
d[6] || (d[6] = (f) => y.value = f),
|
|
198
|
+
V
|
|
199
|
+
],
|
|
200
|
+
label: a(e)("order.terminalScanPay"),
|
|
201
|
+
value: a(m).enum.TERMINAL_SCAN_PAY
|
|
202
|
+
}, null, 8, ["modelValue", "label", "value"]),
|
|
203
|
+
s(M, {
|
|
204
|
+
modelValue: y.value,
|
|
205
|
+
"onUpdate:modelValue": [
|
|
206
|
+
d[7] || (d[7] = (f) => y.value = f),
|
|
207
|
+
V
|
|
208
|
+
],
|
|
209
|
+
label: a(e)("order.terminalQrPay"),
|
|
210
|
+
value: a(m).enum.TERMINAL_QR_PAY
|
|
211
|
+
}, null, 8, ["modelValue", "label", "value"])
|
|
212
|
+
])
|
|
213
|
+
], 512), [
|
|
214
|
+
[U, C.value]
|
|
215
|
+
])
|
|
216
|
+
]),
|
|
217
|
+
_: 1
|
|
218
|
+
})
|
|
219
|
+
]),
|
|
220
|
+
_: 1
|
|
221
|
+
})
|
|
222
|
+
]),
|
|
223
|
+
_: 1
|
|
224
|
+
}, 8, ["payment-types", "offline-payment-types", "allow-e-payment", "allow-credit"]);
|
|
225
|
+
};
|
|
226
|
+
}
|
|
227
|
+
});
|
|
228
|
+
var he = { firebase: {} }, Te = {};
|
|
229
|
+
let H = null;
|
|
230
|
+
function Ae(i) {
|
|
231
|
+
var b;
|
|
232
|
+
const p = (b = i.name.split(".").pop()) == null ? void 0 : b.toLowerCase();
|
|
233
|
+
return p && /^[a-z0-9]+$/.test(p) ? p : {
|
|
234
|
+
"image/jpeg": "jpg",
|
|
235
|
+
"image/png": "png",
|
|
236
|
+
"image/webp": "webp",
|
|
237
|
+
"image/gif": "gif"
|
|
238
|
+
}[i.type] ?? "bin";
|
|
239
|
+
}
|
|
240
|
+
function ke() {
|
|
241
|
+
var e;
|
|
242
|
+
return (((e = Te.firebase) == null ? void 0 : e.storageBucket) ?? he.firebase.storageBucket ?? "image.feedme.cc").replace(/^https?:\/\//, "").replace(/\/+$/, "");
|
|
243
|
+
}
|
|
244
|
+
function Re(i) {
|
|
245
|
+
const p = i.replace(/^\/+/, "");
|
|
246
|
+
return `https://${ke()}/${p}`;
|
|
247
|
+
}
|
|
248
|
+
async function Ue() {
|
|
249
|
+
const i = re();
|
|
250
|
+
if (!i.currentUser && (await i.authStateReady(), !i.currentUser && (H || (H = (async () => {
|
|
251
|
+
const p = await ie.getCustomToken();
|
|
252
|
+
await se(i, p);
|
|
253
|
+
})().finally(() => {
|
|
254
|
+
H = null;
|
|
255
|
+
})), await H, !i.currentUser)))
|
|
256
|
+
throw new Error("User not authenticated for image upload");
|
|
257
|
+
}
|
|
258
|
+
async function Fe() {
|
|
259
|
+
const i = re();
|
|
260
|
+
i.currentUser && await ve(i);
|
|
261
|
+
const p = await ie.getCustomToken();
|
|
262
|
+
await se(i, p);
|
|
263
|
+
}
|
|
264
|
+
async function Ee(i, p) {
|
|
265
|
+
const e = fe(), b = ae(e, i);
|
|
266
|
+
try {
|
|
267
|
+
await te(b, p, {
|
|
268
|
+
contentType: p.type || void 0
|
|
269
|
+
});
|
|
270
|
+
return;
|
|
271
|
+
} catch (P) {
|
|
272
|
+
if ((P == null ? void 0 : P.code) !== "storage/unauthorized")
|
|
273
|
+
throw P;
|
|
274
|
+
}
|
|
275
|
+
await Fe();
|
|
276
|
+
const _ = ae(e, i);
|
|
277
|
+
await te(_, p, {
|
|
278
|
+
contentType: p.type || void 0
|
|
279
|
+
});
|
|
280
|
+
}
|
|
281
|
+
async function Ne(i, p) {
|
|
282
|
+
await Ue();
|
|
283
|
+
const e = i.replace(/^\/+/, "").replace(/\/+$/, ""), b = Ae(p), _ = `${Date.now()}_${Math.random().toString(36).slice(2, 10)}.${b}`, P = `${e}/${_}`;
|
|
284
|
+
return await Ee(P, p), Re(P);
|
|
285
|
+
}
|
|
286
|
+
const Oe = {
|
|
287
|
+
key: 0,
|
|
288
|
+
class: "flex flex-col gap-32"
|
|
289
|
+
}, De = {
|
|
290
|
+
key: 0,
|
|
291
|
+
class: "flex flex-col gap-2"
|
|
292
|
+
}, Me = { class: "fm-typo-en-title-sm-600" }, We = { class: "flex flex-col gap-1 w-full md:w-1/2" }, $e = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, Le = { class: "flex flex-col gap-2" }, Ye = { class: "fm-typo-en-title-sm-600" }, Be = { class: "flex flex-col gap-5" }, qe = { class: "flex flex-col gap-16" }, je = { class: "border p-[1.5rem] fm-corner-radius-lg flex flex-col gap-2 my-5 w-11/12" }, Qe = { class: "fm-typo-en-title-sm-600" }, ze = { class: "border p-[1.5rem] fm-corner-radius-lg flex flex-col gap-2 my-5 w-11/12" }, He = { class: "fm-typo-en-title-sm-600" }, Ke = { class: "flex flex-row gap-2" }, Ge = { class: "border p-[1.5rem] fm-corner-radius-lg flex flex-col gap-2 my-5 w-11/12" }, Xe = { class: "fm-typo-en-title-sm-600" }, Ze = { class: "flex flex-col gap-2" }, Je = { class: "fm-typo-en-title-sm-600" }, el = { class: "border p-[1.5rem] fm-corner-radius-lg flex flex-col gap-2 my-5 w-11/12" }, ll = { class: "fm-typo-en-title-sm-600" }, al = { class: "flex flex-col gap-2" }, tl = { class: "fm-typo-en-title-sm-600" }, nl = { class: "flex flex-col gap-2" }, ol = { class: "fm-typo-en-title-sm-600" }, rl = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, sl = { class: "border p-[1.5rem] fm-corner-radius-lg flex flex-col gap-4 my-5 w-11/12" }, dl = { class: "fm-typo-en-body-md-600" }, il = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, ul = {
|
|
293
|
+
key: 1,
|
|
294
|
+
class: "flex flex-col gap-2"
|
|
295
|
+
}, ml = ["src", "alt"], pl = { class: "border p-[1.5rem] fm-corner-radius-lg flex flex-col gap-4 my-5 w-11/12" }, cl = { class: "fm-typo-en-body-md-600" }, yl = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, fl = {
|
|
296
|
+
key: 1,
|
|
297
|
+
class: "flex flex-col gap-2"
|
|
298
|
+
}, vl = ["src", "alt"], bl = { class: "flex flex-col gap-2" }, gl = { class: "fm-typo-en-title-sm-600" }, Il = { class: "flex flex-col gap-2" }, Pl = { class: "fm-typo-en-title-sm-600" }, Sl = { class: "flex flex-col gap-5" }, xl = { class: "flex flex-col gap-2" }, wl = { key: 1 }, ne = 10 * 1e3 * 1e3, kl = /* @__PURE__ */ oe({
|
|
299
|
+
__name: "KioskSettingView",
|
|
300
|
+
props: {
|
|
301
|
+
restaurantId: {},
|
|
302
|
+
form: {}
|
|
303
|
+
},
|
|
304
|
+
emits: ["updateKioskOrderSetting"],
|
|
305
|
+
setup(i, { emit: p }) {
|
|
306
|
+
const { t: e } = de(), b = Se(), _ = A(() => {
|
|
307
|
+
var o;
|
|
308
|
+
return ((o = b.sessionUser.value) == null ? void 0 : o.role.isAdmin) ?? !1;
|
|
309
|
+
}), P = i, I = xe(), y = p, l = L(P.form), F = (o) => {
|
|
310
|
+
l.value.autoCloseBill = o, o && l.value.printReceiptAfterClose === null && (l.value.printReceiptAfterClose = !0);
|
|
311
|
+
}, C = (o) => o < 0 ? e("order.nonNegativeRule") : !0, j = (o) => o <= (l.value.dineIn.displayStand.standSlotRange.min ?? 0) ? e("order.greaterThanMinRule") : !0, K = A(() => [C]), V = A(() => [C]), Q = A(() => [C, j]), E = A(() => {
|
|
312
|
+
var v, S, h, W, n, X, Z, J;
|
|
313
|
+
const o = l.value, t = (v = o.otaChannel) == null ? void 0 : v.trim();
|
|
314
|
+
if (o.dineIn.enabled && o.dineIn.displayStand.enabled) {
|
|
315
|
+
const { padDigit: x, standSlotRange: $ } = o.dineIn.displayStand;
|
|
316
|
+
if (!(x != null && x >= 0 && $.min != null && $.max != null && $.min <= $.max)) return null;
|
|
317
|
+
}
|
|
318
|
+
const u = o.paymentSetting;
|
|
319
|
+
if ((S = u == null ? void 0 : u.paymentTypes) != null && S.includes(be.enum.ePayment)) {
|
|
320
|
+
const x = u.ePaymentTypes;
|
|
321
|
+
if (!x) return null;
|
|
322
|
+
const $ = ((h = x.card) == null ? void 0 : h.terminal) || ((W = x.card) == null ? void 0 : W.nfc), ee = ((n = x.eWallet) == null ? void 0 : n.qrPay) || ((X = x.eWallet) == null ? void 0 : X.scanPay) || ((Z = x.eWallet) == null ? void 0 : Z.terminalScanPay) || ((J = x.eWallet) == null ? void 0 : J.terminalQrPay), me = x.terminal;
|
|
323
|
+
if (!$ && !ee && !me) return null;
|
|
324
|
+
}
|
|
325
|
+
return {
|
|
326
|
+
...o,
|
|
327
|
+
otaChannel: t || void 0,
|
|
328
|
+
dineIn: {
|
|
329
|
+
...o.dineIn,
|
|
330
|
+
displayStand: {
|
|
331
|
+
...o.dineIn.displayStand,
|
|
332
|
+
enabled: o.dineIn.enabled && o.dineIn.displayStand.enabled,
|
|
333
|
+
padDigit: o.dineIn.displayStand.padDigit ?? 0,
|
|
334
|
+
standSlotRange: {
|
|
335
|
+
min: o.dineIn.displayStand.standSlotRange.min ?? 0,
|
|
336
|
+
max: o.dineIn.displayStand.standSlotRange.max ?? 10
|
|
337
|
+
},
|
|
338
|
+
prefix: o.dineIn.displayStand.prefix ?? ""
|
|
339
|
+
}
|
|
340
|
+
}
|
|
341
|
+
};
|
|
342
|
+
}), { startAsyncCall: z } = Ie();
|
|
343
|
+
function c(o) {
|
|
344
|
+
l.value.paymentSetting.paymentTypes = o;
|
|
345
|
+
}
|
|
346
|
+
function d(o) {
|
|
347
|
+
l.value.paymentSetting.ePaymentTypes = o;
|
|
348
|
+
}
|
|
349
|
+
const Y = Pe();
|
|
350
|
+
function B(o) {
|
|
351
|
+
l.value[o] = null;
|
|
352
|
+
}
|
|
353
|
+
function N(o) {
|
|
354
|
+
const t = l.value[o];
|
|
355
|
+
if (!t) return null;
|
|
356
|
+
const u = t.trim();
|
|
357
|
+
return u.length > 0 ? u : null;
|
|
358
|
+
}
|
|
359
|
+
async function O(o, t) {
|
|
360
|
+
try {
|
|
361
|
+
const u = await z(async () => {
|
|
362
|
+
const v = `/restaurant/${P.restaurantId}/kiosk/${o}`;
|
|
363
|
+
return await Ne(v, t);
|
|
364
|
+
});
|
|
365
|
+
l.value[o] = u, I.open({
|
|
366
|
+
title: e("order.imageUploadSuccess"),
|
|
367
|
+
type: "success"
|
|
368
|
+
});
|
|
369
|
+
} catch (u) {
|
|
370
|
+
console.error(u), I.open({
|
|
371
|
+
title: e("order.imageUploadFailed"),
|
|
372
|
+
type: "error"
|
|
373
|
+
});
|
|
374
|
+
}
|
|
375
|
+
}
|
|
376
|
+
function D(o, t) {
|
|
377
|
+
var S, h;
|
|
378
|
+
const u = e(o === "coverImageLandscape" ? "order.coverImageLandscape" : "order.coverImagePortrait"), v = (h = (S = t[0]) == null ? void 0 : S.reason) == null ? void 0 : h[0];
|
|
379
|
+
I.open({
|
|
380
|
+
title: v ? `${e("order.imageUploadRejected")}: ${u} (${v})` : `${e("order.imageUploadRejected")}: ${u}`,
|
|
381
|
+
type: "error"
|
|
382
|
+
});
|
|
383
|
+
}
|
|
384
|
+
const M = A(() => Y.getRestaurantEPayment()), f = A({
|
|
385
|
+
get: () => (l.value.dineIn.displayStand.enabled && l.value.dineIn.displayStand.enablePaxDialog || l.value.dineIn.pickUp.enablePaxDialog) ?? !1,
|
|
386
|
+
set: (o) => {
|
|
387
|
+
l.value.dineIn.displayStand.enablePaxDialog = o, l.value.dineIn.pickUp.enablePaxDialog = o;
|
|
388
|
+
}
|
|
389
|
+
});
|
|
390
|
+
ce(
|
|
391
|
+
() => [
|
|
392
|
+
l.value.dineIn.enabled,
|
|
393
|
+
l.value.dineIn.pickUp.enabled,
|
|
394
|
+
l.value.dineIn.displayStand.enabled
|
|
395
|
+
],
|
|
396
|
+
([o, t, u], v) => {
|
|
397
|
+
const S = (v == null ? void 0 : v[0]) ?? !1;
|
|
398
|
+
o && !t && !u && (l.value.dineIn.pickUp.enabled = !0, S || I.open({
|
|
399
|
+
title: e("order.dineInModeAutoCorrected"),
|
|
400
|
+
type: "info"
|
|
401
|
+
}));
|
|
402
|
+
},
|
|
403
|
+
{ immediate: !0 }
|
|
404
|
+
);
|
|
405
|
+
async function ue() {
|
|
406
|
+
if (E.value) {
|
|
407
|
+
const o = E.value;
|
|
408
|
+
z(async () => {
|
|
409
|
+
await y("updateKioskOrderSetting", o);
|
|
410
|
+
});
|
|
411
|
+
} else
|
|
412
|
+
I.open({
|
|
413
|
+
title: e("order.failedToUpdateSetting"),
|
|
414
|
+
type: "error"
|
|
415
|
+
});
|
|
416
|
+
}
|
|
417
|
+
return (o, t) => {
|
|
418
|
+
const u = w("FmTextField"), v = w("FmSwitch"), S = w("FmStepperField"), h = w("FmDropField"), W = w("FmButton");
|
|
419
|
+
return l.value ? (k(), q("div", Oe, [
|
|
420
|
+
_.value ? (k(), q("div", De, [
|
|
421
|
+
r("span", Me, g(a(e)("order.otaChannel")), 1),
|
|
422
|
+
r("div", We, [
|
|
423
|
+
s(u, {
|
|
424
|
+
modelValue: l.value.otaChannel,
|
|
425
|
+
"onUpdate:modelValue": t[0] || (t[0] = (n) => l.value.otaChannel = n),
|
|
426
|
+
label: a(e)("order.otaChannel"),
|
|
427
|
+
placeholder: a(e)("order.otaChannelHint")
|
|
428
|
+
}, null, 8, ["modelValue", "label", "placeholder"]),
|
|
429
|
+
r("span", $e, g(a(e)("order.otaChannelHint")), 1)
|
|
430
|
+
])
|
|
431
|
+
])) : ye("", !0),
|
|
432
|
+
r("div", Le, [
|
|
433
|
+
r("span", Ye, g(a(e)("order.dineIn")), 1),
|
|
434
|
+
r("div", Be, [
|
|
435
|
+
s(v, {
|
|
436
|
+
modelValue: l.value.dineIn.enabled,
|
|
437
|
+
"onUpdate:modelValue": t[1] || (t[1] = (n) => l.value.dineIn.enabled = n),
|
|
438
|
+
label: a(e)("order.dineIn"),
|
|
439
|
+
"label-placement": "right"
|
|
440
|
+
}, null, 8, ["modelValue", "label"]),
|
|
441
|
+
R(r("div", qe, [
|
|
442
|
+
r("div", null, [
|
|
443
|
+
s(v, {
|
|
444
|
+
modelValue: l.value.dineIn.pickUp.enabled,
|
|
445
|
+
"onUpdate:modelValue": t[2] || (t[2] = (n) => l.value.dineIn.pickUp.enabled = n),
|
|
446
|
+
label: a(e)("order.pickAtCounter"),
|
|
447
|
+
"label-placement": "right"
|
|
448
|
+
}, null, 8, ["modelValue", "label"]),
|
|
449
|
+
R(r("div", je, [
|
|
450
|
+
r("span", Qe, g(a(e)("order.submitOrderInstruction")), 1),
|
|
451
|
+
s(u, {
|
|
452
|
+
modelValue: l.value.dineIn.pickUp.submitOrderInstruction.payAtCounter,
|
|
453
|
+
"onUpdate:modelValue": t[3] || (t[3] = (n) => l.value.dineIn.pickUp.submitOrderInstruction.payAtCounter = n),
|
|
454
|
+
label: a(e)("order.payAtCounter"),
|
|
455
|
+
placeholder: "Collect your transaction slip below and present it to the cashier"
|
|
456
|
+
}, null, 8, ["modelValue", "label"]),
|
|
457
|
+
s(u, {
|
|
458
|
+
modelValue: l.value.dineIn.pickUp.submitOrderInstruction.paid,
|
|
459
|
+
"onUpdate:modelValue": t[4] || (t[4] = (n) => l.value.dineIn.pickUp.submitOrderInstruction.paid = n),
|
|
460
|
+
label: a(e)("order.paid"),
|
|
461
|
+
placeholder: "Please wait as we prepare your food. We'll call your number when it's ready."
|
|
462
|
+
}, null, 8, ["modelValue", "label"])
|
|
463
|
+
], 512), [
|
|
464
|
+
[U, l.value.dineIn.pickUp.enabled]
|
|
465
|
+
])
|
|
466
|
+
]),
|
|
467
|
+
r("div", null, [
|
|
468
|
+
s(v, {
|
|
469
|
+
modelValue: l.value.dineIn.displayStand.enabled,
|
|
470
|
+
"onUpdate:modelValue": t[5] || (t[5] = (n) => l.value.dineIn.displayStand.enabled = n),
|
|
471
|
+
label: a(e)("order.displayStand"),
|
|
472
|
+
"label-placement": "right"
|
|
473
|
+
}, null, 8, ["modelValue", "label"]),
|
|
474
|
+
R(r("div", ze, [
|
|
475
|
+
r("span", He, g(a(e)("order.tableServiceSetting")), 1),
|
|
476
|
+
s(u, {
|
|
477
|
+
modelValue: l.value.dineIn.displayStand.prefix,
|
|
478
|
+
"onUpdate:modelValue": t[6] || (t[6] = (n) => l.value.dineIn.displayStand.prefix = n),
|
|
479
|
+
label: a(e)("order.prefix"),
|
|
480
|
+
placeholder: a(e)("order.prefix")
|
|
481
|
+
}, null, 8, ["modelValue", "label", "placeholder"]),
|
|
482
|
+
r("div", Ke, [
|
|
483
|
+
s(S, {
|
|
484
|
+
modelValue: l.value.dineIn.displayStand.standSlotRange.min,
|
|
485
|
+
"onUpdate:modelValue": t[7] || (t[7] = (n) => l.value.dineIn.displayStand.standSlotRange.min = n),
|
|
486
|
+
class: "w-1/2",
|
|
487
|
+
label: a(e)("order.start"),
|
|
488
|
+
labelMark: "required",
|
|
489
|
+
rules: V.value,
|
|
490
|
+
placeholder: a(e)("order.enterANumber")
|
|
491
|
+
}, null, 8, ["modelValue", "label", "rules", "placeholder"]),
|
|
492
|
+
s(S, {
|
|
493
|
+
modelValue: l.value.dineIn.displayStand.standSlotRange.max,
|
|
494
|
+
"onUpdate:modelValue": t[8] || (t[8] = (n) => l.value.dineIn.displayStand.standSlotRange.max = n),
|
|
495
|
+
class: "w-1/2",
|
|
496
|
+
label: a(e)("order.end"),
|
|
497
|
+
labelMark: "required",
|
|
498
|
+
rules: Q.value,
|
|
499
|
+
placeholder: a(e)("order.enterANumber")
|
|
500
|
+
}, null, 8, ["modelValue", "label", "rules", "placeholder"])
|
|
501
|
+
]),
|
|
502
|
+
s(S, {
|
|
503
|
+
modelValue: l.value.dineIn.displayStand.padDigit,
|
|
504
|
+
"onUpdate:modelValue": t[9] || (t[9] = (n) => l.value.dineIn.displayStand.padDigit = n),
|
|
505
|
+
label: a(e)("order.padDigit"),
|
|
506
|
+
labelMark: "required",
|
|
507
|
+
rules: K.value,
|
|
508
|
+
placeholder: a(e)("order.padDigit")
|
|
509
|
+
}, null, 8, ["modelValue", "label", "rules", "placeholder"])
|
|
510
|
+
], 512), [
|
|
511
|
+
[U, l.value.dineIn.displayStand.enabled]
|
|
512
|
+
]),
|
|
513
|
+
R(r("div", Ge, [
|
|
514
|
+
r("span", Xe, g(a(e)("order.submitOrderInstruction")), 1),
|
|
515
|
+
s(u, {
|
|
516
|
+
modelValue: l.value.dineIn.displayStand.submitOrderInstruction.payAtCounter,
|
|
517
|
+
"onUpdate:modelValue": t[10] || (t[10] = (n) => l.value.dineIn.displayStand.submitOrderInstruction.payAtCounter = n),
|
|
518
|
+
label: a(e)("order.payAtCounter"),
|
|
519
|
+
placeholder: "Collect your transaction slip below and present it to the cashier"
|
|
520
|
+
}, null, 8, ["modelValue", "label"]),
|
|
521
|
+
s(u, {
|
|
522
|
+
modelValue: l.value.dineIn.displayStand.submitOrderInstruction.paid,
|
|
523
|
+
"onUpdate:modelValue": t[11] || (t[11] = (n) => l.value.dineIn.displayStand.submitOrderInstruction.paid = n),
|
|
524
|
+
label: a(e)("order.paid"),
|
|
525
|
+
placeholder: "Please collect your receipt and we'll bring your food to your table once it's ready."
|
|
526
|
+
}, null, 8, ["modelValue", "label"])
|
|
527
|
+
], 512), [
|
|
528
|
+
[U, l.value.dineIn.displayStand.enabled]
|
|
529
|
+
])
|
|
530
|
+
])
|
|
531
|
+
], 512), [
|
|
532
|
+
[U, l.value.dineIn.enabled]
|
|
533
|
+
])
|
|
534
|
+
])
|
|
535
|
+
]),
|
|
536
|
+
r("div", Ze, [
|
|
537
|
+
r("span", Je, g(a(e)("order.takeawayTitle")), 1),
|
|
538
|
+
s(v, {
|
|
539
|
+
modelValue: l.value.takeaway.enabled,
|
|
540
|
+
"onUpdate:modelValue": t[12] || (t[12] = (n) => l.value.takeaway.enabled = n),
|
|
541
|
+
label: a(e)("order.takeaway"),
|
|
542
|
+
"label-placement": "right",
|
|
543
|
+
class: "mb-5"
|
|
544
|
+
}, null, 8, ["modelValue", "label"]),
|
|
545
|
+
R(r("div", el, [
|
|
546
|
+
r("span", ll, g(a(e)("order.submitOrderInstruction")), 1),
|
|
547
|
+
s(u, {
|
|
548
|
+
modelValue: l.value.takeaway.submitOrderInstruction.payAtCounter,
|
|
549
|
+
"onUpdate:modelValue": t[13] || (t[13] = (n) => l.value.takeaway.submitOrderInstruction.payAtCounter = n),
|
|
550
|
+
label: a(e)("order.payAtCounter"),
|
|
551
|
+
placeholder: "Collect your transaction slip below and present it to the cashier"
|
|
552
|
+
}, null, 8, ["modelValue", "label"]),
|
|
553
|
+
s(u, {
|
|
554
|
+
modelValue: l.value.takeaway.submitOrderInstruction.paid,
|
|
555
|
+
"onUpdate:modelValue": t[14] || (t[14] = (n) => l.value.takeaway.submitOrderInstruction.paid = n),
|
|
556
|
+
label: a(e)("order.paid"),
|
|
557
|
+
placeholder: "Please wait as we prepare your food. We'll call your number when it's ready."
|
|
558
|
+
}, null, 8, ["modelValue", "label"])
|
|
559
|
+
], 512), [
|
|
560
|
+
[U, l.value.takeaway.enabled]
|
|
561
|
+
])
|
|
562
|
+
]),
|
|
563
|
+
r("div", al, [
|
|
564
|
+
r("span", tl, g(a(e)("order.menuItem")), 1),
|
|
565
|
+
s(v, {
|
|
566
|
+
modelValue: l.value.menuItem.showAllOnly,
|
|
567
|
+
"onUpdate:modelValue": t[15] || (t[15] = (n) => l.value.menuItem.showAllOnly = n),
|
|
568
|
+
label: a(e)("order.showNotAvailableMenuItem"),
|
|
569
|
+
"label-placement": "right",
|
|
570
|
+
class: "mb-5"
|
|
571
|
+
}, null, 8, ["modelValue", "label"])
|
|
572
|
+
]),
|
|
573
|
+
r("div", nl, [
|
|
574
|
+
r("span", ol, g(a(e)("order.coverImage")), 1),
|
|
575
|
+
r("span", rl, g(a(e)("order.coverImageFallbackHint")), 1),
|
|
576
|
+
r("div", sl, [
|
|
577
|
+
r("span", dl, g(a(e)("order.coverImageLandscape")), 1),
|
|
578
|
+
r("span", il, g(a(e)("order.coverImageLandscapeHint")), 1),
|
|
579
|
+
N("coverImageLandscape") ? (k(), q("div", ul, [
|
|
580
|
+
r("img", {
|
|
581
|
+
src: N("coverImageLandscape"),
|
|
582
|
+
alt: a(e)("order.coverImageLandscape"),
|
|
583
|
+
class: "max-w-[400px] aspect-video object-cover rounded-md border border-fm-color-neutral-gray-200"
|
|
584
|
+
}, null, 8, ml),
|
|
585
|
+
s(W, {
|
|
586
|
+
variant: "tertiary",
|
|
587
|
+
class: "mr-auto",
|
|
588
|
+
label: a(e)("common.delete"),
|
|
589
|
+
onClick: t[18] || (t[18] = (n) => B("coverImageLandscape"))
|
|
590
|
+
}, null, 8, ["label"])
|
|
591
|
+
])) : (k(), G(h, {
|
|
592
|
+
key: 0,
|
|
593
|
+
accept: "image/*",
|
|
594
|
+
"max-file-size": ne,
|
|
595
|
+
"content-class": "w-full max-w-[400px] aspect-video",
|
|
596
|
+
onFileUpload: t[16] || (t[16] = (n) => O("coverImageLandscape", n)),
|
|
597
|
+
onFileRejected: t[17] || (t[17] = (n) => D("coverImageLandscape", n))
|
|
598
|
+
}))
|
|
599
|
+
]),
|
|
600
|
+
r("div", pl, [
|
|
601
|
+
r("span", cl, g(a(e)("order.coverImagePortrait")), 1),
|
|
602
|
+
r("span", yl, g(a(e)("order.coverImagePortraitHint")), 1),
|
|
603
|
+
N("coverImagePortrait") ? (k(), q("div", fl, [
|
|
604
|
+
r("img", {
|
|
605
|
+
src: N("coverImagePortrait"),
|
|
606
|
+
alt: a(e)("order.coverImagePortrait"),
|
|
607
|
+
class: "max-w-[200px] aspect-[9/16] object-cover rounded-md border border-fm-color-neutral-gray-200"
|
|
608
|
+
}, null, 8, vl),
|
|
609
|
+
s(W, {
|
|
610
|
+
variant: "tertiary",
|
|
611
|
+
class: "mr-auto",
|
|
612
|
+
label: a(e)("common.delete"),
|
|
613
|
+
onClick: t[21] || (t[21] = (n) => B("coverImagePortrait"))
|
|
614
|
+
}, null, 8, ["label"])
|
|
615
|
+
])) : (k(), G(h, {
|
|
616
|
+
key: 0,
|
|
617
|
+
accept: "image/*",
|
|
618
|
+
"max-file-size": ne,
|
|
619
|
+
"content-class": "w-[240px] aspect-[9/16]",
|
|
620
|
+
onFileUpload: t[19] || (t[19] = (n) => O("coverImagePortrait", n)),
|
|
621
|
+
onFileRejected: t[20] || (t[20] = (n) => D("coverImagePortrait", n))
|
|
622
|
+
}))
|
|
623
|
+
])
|
|
624
|
+
]),
|
|
625
|
+
r("div", bl, [
|
|
626
|
+
r("span", gl, g(a(e)("order.displayPaxDialogTitle")), 1),
|
|
627
|
+
s(v, {
|
|
628
|
+
modelValue: f.value,
|
|
629
|
+
"onUpdate:modelValue": t[22] || (t[22] = (n) => f.value = n),
|
|
630
|
+
label: a(e)("order.displayPaxDialogDescription"),
|
|
631
|
+
"label-placement": "right",
|
|
632
|
+
class: "mb-5"
|
|
633
|
+
}, null, 8, ["modelValue", "label"])
|
|
634
|
+
]),
|
|
635
|
+
r("div", Il, [
|
|
636
|
+
r("span", Pl, g(a(e)("order.orderSetting")), 1),
|
|
637
|
+
r("div", Sl, [
|
|
638
|
+
s(v, {
|
|
639
|
+
"model-value": l.value.autoCloseBill ?? !1,
|
|
640
|
+
label: a(e)("order.autoCloseBill"),
|
|
641
|
+
sublabel: a(e)("order.autoCloseBillSublabel"),
|
|
642
|
+
"label-placement": "right",
|
|
643
|
+
"onUpdate:modelValue": F
|
|
644
|
+
}, null, 8, ["model-value", "label", "sublabel"]),
|
|
645
|
+
R(s(v, {
|
|
646
|
+
"model-value": l.value.printReceiptAfterClose ?? !0,
|
|
647
|
+
"onUpdate:modelValue": t[23] || (t[23] = (n) => l.value.printReceiptAfterClose = n),
|
|
648
|
+
label: a(e)("order.printReceiptAfterClose"),
|
|
649
|
+
sublabel: a(e)("order.printReceiptAfterCloseSublabel"),
|
|
650
|
+
"label-placement": "right"
|
|
651
|
+
}, null, 8, ["model-value", "label", "sublabel"]), [
|
|
652
|
+
[U, l.value.autoCloseBill]
|
|
653
|
+
])
|
|
654
|
+
])
|
|
655
|
+
]),
|
|
656
|
+
r("div", xl, [
|
|
657
|
+
s(Ve, {
|
|
658
|
+
"payment-types": l.value.paymentSetting.paymentTypes ?? [],
|
|
659
|
+
"allow-credit": !0,
|
|
660
|
+
"allow-e-payment": M.value,
|
|
661
|
+
"offline-payment-types": l.value.paymentSetting.offlinePaymentTypes ?? [],
|
|
662
|
+
ePaymentTypes: l.value.paymentSetting.ePaymentTypes ?? {},
|
|
663
|
+
"onUpdate:paymentTypes": c,
|
|
664
|
+
"onUpdate:offlinePaymentTypes": t[24] || (t[24] = (n) => l.value.paymentSetting.offlinePaymentTypes = n),
|
|
665
|
+
"onUpdate:ePaymentTypes": d
|
|
666
|
+
}, null, 8, ["payment-types", "allow-e-payment", "offline-payment-types", "ePaymentTypes"])
|
|
667
|
+
]),
|
|
668
|
+
s(W, {
|
|
669
|
+
class: "w-1/4 mb-10",
|
|
670
|
+
variant: "primary",
|
|
671
|
+
label: a(e)("order.updateSetting"),
|
|
672
|
+
disabled: !E.value,
|
|
673
|
+
onClick: ue
|
|
674
|
+
}, null, 8, ["label", "disabled"])
|
|
675
|
+
])) : (k(), q("div", wl, g(a(e)("order.pleaseSelectRestaurant")), 1));
|
|
676
|
+
};
|
|
677
|
+
}
|
|
678
|
+
});
|
|
679
|
+
export {
|
|
680
|
+
kl as default
|
|
681
|
+
};
|