Ver código fonte

fix: 修改工作流打开

jiaxing.liao 5 dias atrás
pai
commit
107442b17e
1 arquivos alterados com 4 adições e 4 exclusões
  1. 4 4
      apps/web/src/views/Dashboard.vue

+ 4 - 4
apps/web/src/views/Dashboard.vue

@@ -150,7 +150,7 @@
 							<el-card>
 								<div style="display: flex; justify-content: space-between; align-items: center">
 									<div>
-										<div style="font-weight: 700" class="cursor-pointer" @click="toEditor">
+										<div style="font-weight: 700" class="cursor-pointer" @click="toEditor(item.id)">
 											{{ item.title }}
 										</div>
 										<div style="color: #999; font-size: 12px">上次更新时间: {{ item.created }}</div>
@@ -162,7 +162,7 @@
 											<span class="el-dropdown-link cursor-pointer" @click.stop>•••</span>
 											<template #dropdown>
 												<el-dropdown-menu>
-													<el-dropdown-item @click="toEditor">打开</el-dropdown-item>
+													<el-dropdown-item @click="toEditor(item.id)">打开</el-dropdown-item>
 													<el-dropdown-item>分享</el-dropdown-item>
 													<el-dropdown-item>复制</el-dropdown-item>
 													<el-dropdown-item>移动</el-dropdown-item>
@@ -813,8 +813,8 @@ const filteredVariables = computed(() => {
 	return result
 })
 
-const toEditor = () => {
-	$router.push('/workflow/1')
+const toEditor = (id: string) => {
+	$router.push(`/workflow/${id}`)
 }
 </script>