From 0d5d72678548ba21734dbb970aaa97a386cf325d Mon Sep 17 00:00:00 2001 From: Shuchang Zheng Date: Thu, 6 Feb 2025 03:54:11 +0800 Subject: [PATCH] Use the workflow run api updates to show workflow titles (#1732) --- skyvern-frontend/src/api/types.ts | 2 ++ skyvern-frontend/src/routes/history/RunHistory.tsx | 9 ++------- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/skyvern-frontend/src/api/types.ts b/skyvern-frontend/src/api/types.ts index de57bffa..a5be681a 100644 --- a/skyvern-frontend/src/api/types.ts +++ b/skyvern-frontend/src/api/types.ts @@ -225,6 +225,7 @@ export type WorkflowRunApiResponse = { created_at: string; modified_at: string; failure_reason: string | null; + workflow_title: string | null; }; export type WorkflowRunStatusApiResponse = { @@ -244,6 +245,7 @@ export type WorkflowRunStatusApiResponse = { total_steps: number | null; total_cost: number | null; observer_task: ObserverTask | null; + workflow_title: string | null; }; export type TaskGenerationApiResponse = { diff --git a/skyvern-frontend/src/routes/history/RunHistory.tsx b/skyvern-frontend/src/routes/history/RunHistory.tsx index 56dae575..4484f92c 100644 --- a/skyvern-frontend/src/routes/history/RunHistory.tsx +++ b/skyvern-frontend/src/routes/history/RunHistory.tsx @@ -22,8 +22,7 @@ import { useRunsQuery } from "@/hooks/useRunsQuery"; import { basicLocalTimeFormat, basicTimeFormat } from "@/util/timeFormat"; import { cn } from "@/util/utils"; import { useState } from "react"; -import { useSearchParams, useNavigate } from "react-router-dom"; -import { WorkflowTitle } from "../workflows/WorkflowTitle"; +import { useNavigate, useSearchParams } from "react-router-dom"; function isTask(run: Task | WorkflowRunApiResponse): run is Task { return "task_id" in run; @@ -120,11 +119,7 @@ function RunHistory() { }} > {run.workflow_run_id} - - - + {run.workflow_title ?? ""}