Skip to content

Database governance built for humans and agents — controlling changes and access across every major database.

refactor(frontend): simplify TaskView navigation and display (#18614)

boojackc9c6e5564831
diff --git a/frontend/src/components/RolloutV1/components/TaskView.vue b/frontend/src/components/RolloutV1/components/TaskView.vue
index e06c68e655..6b5da8fb12 100644
--- a/frontend/src/components/RolloutV1/components/TaskView.vue
+++ b/frontend/src/components/RolloutV1/components/TaskView.vue
@@ -1,34 +1,19 @@
<template>
<div v-if="task" class="w-full h-full flex flex-col gap-y-4 p-4">
- <p v-if="selectedStage">
- <RouterLink
- :to="{
- name: PROJECT_V1_ROUTE_ROLLOUT_DETAIL_STAGE_DETAIL,
- params: {
- projectId: extractProjectResourceName(plan.name),
- rolloutId: rolloutId,
- stageId: stageId,
- },
- }"
- class="textinfolabel hover:underline"
- >
- &larr; {{ $t("rollout.stage.back-to-stage", { stage: selectedStageTitle }) }}
- </RouterLink>
- </p>
<!-- Task Basic Info -->
<div class="w-full flex flex-col gap-y-3">
<div
class="flex flex-col sm:flex-row sm:items-center sm:justify-between gap-3"
>
<div class="flex flex-row items-center gap-x-3 flex-wrap">
- <TaskStatus :size="'large'" :status="task.status" />
+ <NTag round>
+ {{ selectedStageTitle }}
+ </NTag>
+ <TaskStatus :status="task.status" />
<div class="flex flex-row items-center text-xl min-w-0">
<DatabaseDisplay :database="database.name" :size="'large'" />
</div>
<div class="flex flex-row gap-x-2 flex-wrap">
- <NTag round>
- {{ semanticTaskType(task.type) }}
- </NTag>
<NTooltip v-if="schemaVersion">
<template #trigger>
<NTag round>{{ schemaVersion }}</NTag>
@@ -150,7 +135,6 @@ import { CalendarClockIcon, LinkIcon } from "lucide-vue-next";
import { NButton, NTag, NTooltip } from "naive-ui";
import { computed, watchEffect } from "vue";
import { RouterLink } from "vue-router";
-import { semanticTaskType } from "@/components/IssueV1";
import TaskRunDetail from "@/components/IssueV1/components/TaskRunSection/TaskRunDetail.vue";
import { MonacoEditor } from "@/components/MonacoEditor";
import DatabaseDisplay from "@/components/Plan/components/common/DatabaseDisplay.vue";
@@ -159,10 +143,7 @@ import {
usePlanContextWithRollout,
} from "@/components/Plan/logic";
import TaskStatus from "@/components/Rollout/kits/TaskStatus.vue";
-import {
- PROJECT_V1_ROUTE_PLAN_DETAIL_SPEC_DETAIL,
- PROJECT_V1_ROUTE_ROLLOUT_DETAIL_STAGE_DETAIL,
-} from "@/router/dashboard/projectV1";
+import { PROJECT_V1_ROUTE_PLAN_DETAIL_SPEC_DETAIL } from "@/router/dashboard/projectV1";
import {
taskRunNamePrefix,
useCurrentProjectV1,
diff --git a/frontend/src/locales/en-US.json b/frontend/src/locales/en-US.json
index 4a940ab98d..4527342108 100644
--- a/frontend/src/locales/en-US.json
+++ b/frontend/src/locales/en-US.json
@@ -1259,8 +1259,7 @@
"stage": {
"self": "Stage | Stages",
"run-stage": "Run Tasks",
- "confirm-create": "Confirm to create tasks for this stage?",
- "back-to-stage": "Back to Stage {stage}"
+ "confirm-create": "Confirm to create tasks for this stage?"
},
"task": {
"selected-count": "{count} task selected | {count} tasks selected",
diff --git a/frontend/src/locales/es-ES.json b/frontend/src/locales/es-ES.json
index 72ceac9b89..d6737d3fb0 100644
--- a/frontend/src/locales/es-ES.json
+++ b/frontend/src/locales/es-ES.json
@@ -1259,8 +1259,7 @@
"stage": {
"self": "Escenario | Escenarios",
"run-stage": "Ejecutar tareas",
- "confirm-create": "¿Está seguro de que desea crear tareas para esta etapa?",
- "back-to-stage": "Volver a la etapa {stage}"
+ "confirm-create": "¿Está seguro de que desea crear tareas para esta etapa?"
},
"task": {
"selected-count": "{count} tarea seleccionada | {count} tareas seleccionadas",
diff --git a/frontend/src/locales/ja-JP.json b/frontend/src/locales/ja-JP.json
index c8b953067e..ec4e6fa06b 100644
--- a/frontend/src/locales/ja-JP.json
+++ b/frontend/src/locales/ja-JP.json
@@ -1259,8 +1259,7 @@
"stage": {
"self": "ステージ | ステージ",
"run-stage": "タスクを実行",
- "confirm-create": "このステージのタスクを作成してもよろしいですか?",
- "back-to-stage": "ステージに戻る {stage}"
+ "confirm-create": "このステージのタスクを作成してもよろしいですか?"
},
"task": {
"selected-count": "{count} 個のタスクが選択されました | {count} 個のタスクが選択されました",
diff --git a/frontend/src/locales/vi-VN.json b/frontend/src/locales/vi-VN.json
index 2b90a8586b..6bb9e59d6c 100644
--- a/frontend/src/locales/vi-VN.json
+++ b/frontend/src/locales/vi-VN.json
@@ -1259,8 +1259,7 @@
"stage": {
"self": "Giai đoạn | Các giai đoạn",
"run-stage": "Chạy tác vụ",
- "confirm-create": "Bạn có chắc chắn muốn tạo tác vụ cho giai đoạn này không?",
- "back-to-stage": "Trở lại sân khấu {stage}"
+ "confirm-create": "Bạn có chắc chắn muốn tạo tác vụ cho giai đoạn này không?"
},
"task": {
"selected-count": "{count} nhiệm vụ đã chọn | {count} nhiệm vụ đã chọn",
diff --git a/frontend/src/locales/zh-CN.json b/frontend/src/locales/zh-CN.json
index ab05604fea..778cc4dcb2 100644
--- a/frontend/src/locales/zh-CN.json
+++ b/frontend/src/locales/zh-CN.json
@@ -1259,8 +1259,7 @@
"stage": {
"self": "阶段 | 阶段",
"run-stage": "运行任务",
- "confirm-create": "确定要为此阶段创建任务吗?",
- "back-to-stage": "返回阶段 {stage}"
+ "confirm-create": "确定要为此阶段创建任务吗?"
},
"task": {
"selected-count": "已选择 {count} 个任务",