feat 增加消息报警查看画面

Co-authored-by: Copilot <copilot@github.com>
This commit is contained in:
Ironsp
2026-05-25 10:40:38 +08:00
parent 2c5b9d4fcc
commit 2b809f227b

View File

@@ -15,7 +15,7 @@
</div> </div>
<!-- 已读/未读 --> <!-- 已读/未读 -->
<!-- <span v-if="v.read" class="el-tag el-tag--success el-tag--mini read">已读</span> --> <!-- <span v-if="v.read" class="el-tag el-tag--success el-tag--mini read">已读</span> -->
<span v-if="!v.read" class="el-tag el-tag--danger el-tag--mini read">查看画面</span> <button v-if="!v.read" class="el-tag el-tag--danger el-tag--mini read" @click="handleview(v)">查看画面</button>
</div> </div>
</template> </template>
<el-empty v-else :description="'消息为空'"></el-empty> <el-empty v-else :description="'消息为空'"></el-empty>
@@ -37,6 +37,12 @@ const state = reactive({
}); });
const newsList = ref([]) as any; const newsList = ref([]) as any;
//查看画面
const handleview = (row: any) => {
console.log('查看画面', row);
// 在这里可以添加打开画面的逻辑,例如:
// window.open('https://example.com/notice/' + newsList.value[row].id);
};
/** /**
* 过滤消息只保留最新的5条 * 过滤消息只保留最新的5条
* @param messages 消息列表 * @param messages 消息列表