From 495d1510f9a9ebf1f488569f6ca24a6be56bc9f3 Mon Sep 17 00:00:00 2001 From: wujingjing <gersonwu@qq.com> Date: 星期四, 12 九月 2024 13:59:23 +0800 Subject: [PATCH] Revert "对接接口" --- src/views/project/ch/home/Scenario.vue | 12 +++++++++++- 1 files changed, 11 insertions(+), 1 deletions(-) diff --git a/src/views/project/ch/home/Scenario.vue b/src/views/project/ch/home/Scenario.vue index 7635386..d1ace78 100644 --- a/src/views/project/ch/home/Scenario.vue +++ b/src/views/project/ch/home/Scenario.vue @@ -8,7 +8,7 @@ <span>鏈�杩戜娇鐢�</span> </p> <div class="flex flex-wrap items-center"> - <div class="list_app" v-for="item in state.recentlyList" :key="item.ID"> + <div class="list_app" v-for="item in state.recentlyList" :key="item.ID" @click="changeApp(item)"> <img :src="item.Icon" alt="" class="w-[20px] h-[20px] mr-[14px]" /> <span class="text-[14px] text-[#333f4e]">{{ item.Name }}</span> </div> @@ -53,6 +53,7 @@ <script setup lang="ts"> import { reactive } from 'vue'; +import router from '/@/router'; let state = reactive({ recentlyList: [ { @@ -143,6 +144,15 @@ }, ], }); +//鍒囨崲鍒板簲鐢ㄥ満鏅鎯呯殑浜嬩欢 +const changeApp = (item: any) => { + console.log('馃殌 ~ item:', item); + if (item.ID === 2) { + router.push({ + name: 'ScenarioDetails', + }); + } +}; </script> <style scoped lang="scss"> .set-body { -- Gitblit v1.9.3