From 09c1dbd55d2dea339f4dac92624ba87c83e716d5 Mon Sep 17 00:00:00 2001 From: Lazy <2211717435@qq.com> Date: Wed, 18 Oct 2023 13:54:24 +0800 Subject: [PATCH] Feat: to Page Terminal, FileManager --- frontend/src/widgets/NodeList.vue | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/frontend/src/widgets/NodeList.vue b/frontend/src/widgets/NodeList.vue index 6cd62ec3..e8f15da5 100644 --- a/frontend/src/widgets/NodeList.vue +++ b/frontend/src/widgets/NodeList.vue @@ -23,11 +23,14 @@ import { connectNode } from "@/services/apis"; import { message } from "ant-design-vue"; +import { useAppRouters } from "@/hooks/useAppRouters"; defineProps<{ card: LayoutCard; }>(); +const { toPage } = useAppRouters(); + const operationForm = ref({ name: "" }); @@ -72,14 +75,24 @@ const nodeOperations = [ title: t("TXT_CODE_ae533703"), icon: FolderOpenOutlined, click: () => { - console.log(3); + toPage({ + path: "/instances/terminal/files" + }); } }, { title: t("TXT_CODE_524e3036"), icon: CodeOutlined, - click: () => { - console.log(3); + click: (item: ComputedNodeInfo) => { + const daemonId = item.uuid; + const instanceId = "global0001"; + toPage({ + path: "/instances/terminal", + query: { + daemonId, + instanceId + } + }); } }, {