feat 异常警告详情

This commit is contained in:
Ironsp
2026-09-02 16:33:32 +08:00
parent 311d90b93e
commit 1a6bd1174e
4 changed files with 74 additions and 4 deletions

View File

@@ -1,15 +1,29 @@
<script setup lang="ts">
defineProps<{
const props = defineProps<{
deviceName: string
tags: string[]
time: string
trigger: string
status?: '未处理' | '已处理'
index: number
}>()
function goToDetail() {
const data = encodeURIComponent(JSON.stringify({
deviceName: props.deviceName,
tags: props.tags,
time: props.time,
trigger: props.trigger,
status: props.status || '未处理',
}))
uni.navigateTo({
url: `/pages/warning/detail/index?data=${data}`,
})
}
</script>
<template>
<view class="warning-item">
<view class="warning-item" @tap="goToDetail">
<view class="item-header">
<text class="device-name">
{{ deviceName }}
@@ -41,7 +55,6 @@ defineProps<{
background-color: #ffffff;
border-radius: 12px;
padding: 16px;
/* border-left: 4px solid #ff4d4f; */
}
.item-header {