From bf69a355fe5758e979ce1f7c52c5db6201296030 Mon Sep 17 00:00:00 2001 From: yuetsh <517252939@qq.com> Date: Mon, 25 May 2026 23:55:16 -0600 Subject: [PATCH] update --- src/admin/problem/list.vue | 21 +++++++++++++++++++++ src/utils/types.ts | 3 +++ 2 files changed, 24 insertions(+) diff --git a/src/admin/problem/list.vue b/src/admin/problem/list.vue index ac42a3f..63b50d1 100644 --- a/src/admin/problem/list.vue +++ b/src/admin/problem/list.vue @@ -79,6 +79,27 @@ const columns: DataTableColumn[] = [ row.tags.map((t) => h(NTag, { key: t, size: "small" }, () => t)), ), }, + { + title: "AST", + key: "has_ast_rules", + width: 60, + render: (row) => + row.has_ast_rules ? h(NTag, { type: "info", size: "small" }, () => "AST") : null, + }, + { + title: "绘图", + key: "allow_flowchart", + width: 60, + render: (row) => + row.allow_flowchart ? h(NTag, { type: "success", size: "small" }, () => "绘图") : null, + }, + { + title: "流程", + key: "show_flowchart", + width: 60, + render: (row) => + row.show_flowchart ? h(NTag, { type: "warning", size: "small" }, () => "流程图") : null, + }, { title: "出题人", key: "username", width: 120 }, { title: "创建时间", diff --git a/src/utils/types.ts b/src/utils/types.ts index 672c339..1e44904 100644 --- a/src/utils/types.ts +++ b/src/utils/types.ts @@ -186,6 +186,9 @@ export interface AdminProblemFiltered { create_time: string difficulty: "Low" | "Mid" | "High" tags: string[] + has_ast_rules: boolean + allow_flowchart: boolean + show_flowchart: boolean } // 题单相关类型