@@ -669,6 +687,7 @@
import {
Box,
CircleCheck,
+ Coffee,
Connection,
DataLine,
Document,
@@ -874,7 +893,7 @@ const runtimeSupportedTypes = ["1", "2"]
/** 超市和食堂业务终端,目前也是唯一会上传文件日志的设备类型。 */
const businessTerminalTypes = ["1", "2"]
/** 不适用 MQTT 和人脸配置的云设备类型编码。 */
-const terminalConfigurationExcludedTypes = ["9", "10", "11", "12"]
+const terminalConfigurationExcludedTypes = ["9", "10", "11", "12", "13"]
/** 终端日志查看权限。 */
const LOG_VIEW_PERMISSION = "hard_hardTerminalLogFile_view"
/** 终端日志预览权限。 */
@@ -896,6 +915,8 @@ const PrinterDialog = defineAsyncComponent(() => import("./printer-dialog.vue"))
const InfoSetting = defineAsyncComponent(() => import("../hard-door-manager/info-setting.vue"))
/** 智能柜音量设置弹窗。 */
const VolumeSetting = defineAsyncComponent(() => import("../hard-door-manager/volume-setting.vue"))
+/** 咖啡机接入信息与最近交易分区内容。 */
+const CoffeeMachineSection = defineAsyncComponent(() => import("./coffee-machine-section.vue"))
/** 页面内部滚动容器。 */
const detailContainerRef = ref()
@@ -968,6 +989,8 @@ const supportsFace = computed(() => !terminalConfigurationExcludedTypes.includes
const isBusinessTerminal = computed(() => businessTerminalTypes.includes(String(detail.type)))
/** 当前设备是否为无屏 EY_PRINT 打印机资产。 */
const isPrinterAsset = computed(() => String(detail.type) === "12")
+/** 当前设备是否为屋里咖啡咖啡机。 */
+const isCoffeeMachine = computed(() => String(detail.type) === "13")
/** 当前设备是否提供打印绑定或参数配置。 */
const supportsPrinter = computed(() => isBusinessTerminal.value || isPrinterAsset.value)
/** 当前设备是否为生鲜智能柜。 */
@@ -996,7 +1019,7 @@ const printerConfigured = computed(() =>
)
/** 当前设备类型适用的可配置能力数量。 */
const availableCapabilityCount = computed(
- () => Number(supportsMq.value) + Number(supportsFace.value) + Number(supportsPrinter.value) + Number(isSmartCabinet.value),
+ () => Number(supportsMq.value) + Number(supportsFace.value) + Number(supportsPrinter.value) + Number(isSmartCabinet.value) + Number(isCoffeeMachine.value),
)
/** 当前设备已完成关键项的能力数量。 */
const configuredCapabilityCount = computed(
@@ -1004,7 +1027,8 @@ const configuredCapabilityCount = computed(
Number(supportsMq.value && mqConfigured.value) +
Number(supportsFace.value && faceConfigured.value) +
Number(supportsPrinter.value && printerConfigured.value) +
- Number(isSmartCabinet.value && Boolean(hardDoorDetail.value?.id)),
+ Number(isSmartCabinet.value && Boolean(hardDoorDetail.value?.id)) +
+ Number(isCoffeeMachine.value && Boolean(detail.uniqueCode)),
)
/** 当前设备日志文件总数。 */
const logFileCount = computed(() => Number(logSummary.value?.fileCount || 0))
@@ -1016,6 +1040,7 @@ const apkVersionText = computed(() => {
/** 当前运行状态文案。 */
const runtimeStatusText = computed(() => {
if (isPrinterAsset.value) return "由业务终端代理"
+ if (isCoffeeMachine.value) return "厂商云管理"
if (!isRuntimeSupported.value) return "暂不支持"
return detail.online ? "在线" : "离线"
})
@@ -1059,6 +1084,7 @@ const sectionNavItems = computed(() => {
if (supportsPrinter.value) items.push({ key: "printer", label: "打印配置", targetId: "section-printer", icon: Printer })
if (showLogSection.value) items.push({ key: "logs", label: "终端日志", targetId: "section-logs", icon: Document })
if (isSmartCabinet.value) items.push({ key: "cabinet", label: "智能柜", targetId: "section-cabinet", icon: Box })
+ if (isCoffeeMachine.value) items.push({ key: "coffee", label: "咖啡机接入", targetId: "section-coffee", icon: Coffee })
items.push({ key: "maintenance", label: "维护信息", targetId: "section-maintenance", icon: Setting })
return items
})