1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
| import type { GradeStatus } from './types';
|
| export const GRADE_STATUS_OPTIONS: { id: GradeStatus; fullName: string; color?: string }[] = [
| { id: 'auto', fullName: '无需阅卷', color: '#8c8c8c' },
| { id: 'pending', fullName: '待批改', color: '#fa8c16' },
| { id: 'graded', fullName: '已批改', color: '#52c41a' },
| ];
|
| export function labelOfGradeStatus(v?: string) {
| return GRADE_STATUS_OPTIONS.find((x) => x.id === v)?.fullName ?? v ?? '-';
| }
|
| export function colorOfGradeStatus(v?: string) {
| return GRADE_STATUS_OPTIONS.find((x) => x.id === v)?.color;
| }
|
|