fix(webserver): correct job name of web crawler

This commit is contained in:
Meng Zhang 2024-06-27 23:02:44 +08:00
parent 25ac779b40
commit 5df50bbde0
2 changed files with 7 additions and 5 deletions

View File

@ -350,10 +350,12 @@ impl Query {
// FIXME(meng): This is a temporary solution to expose the list of jobs, we should consider switching to a enum based approach.
async fn jobs() -> Result<Vec<String>> {
Ok(vec!["scheduler_git", "scheduler_github_gitlab", "web"]
.into_iter()
.map(Into::into)
.collect())
Ok(
vec!["scheduler_git", "scheduler_github_gitlab", "web_crawler"]
.into_iter()
.map(Into::into)
.collect(),
)
}
async fn daily_stats_in_past_year(

View File

@ -5,7 +5,7 @@ import { JobRun } from '@/lib/gql/generates/graphql'
const JOB_DISPLAY_NAME_MAPPINGS = {
scheduler_git: 'Git',
scheduler_github_gitlab: 'Github / Gitlab',
web: 'Web'
web_crawler: 'Web'
}
export function getJobDisplayName(name: string): string {