| | |
| | | export const ENABLE_OPTIONS = [ |
| | | { id: '1', fullName: '启用' }, |
| | | { id: '0', fullName: '停用' }, |
| | | ]; |
| | | |
| | | /** tmsCourseCategory */ |
| | | export const CATEGORY_OPTIONS = [ |
| | | { id: 'gmp', fullName: 'GMP' }, |
| | | { id: 'sop', fullName: 'SOP' }, |
| | | { id: 'safety', fullName: '安全' }, |
| | | { id: 'skill', fullName: '技能' }, |
| | | { id: 'other', fullName: '其他' }, |
| | | ]; |
| | | |
| | | /** 与培训方式配置编码对齐 */ |
| | | export const TRAIN_MODE_OPTIONS = [ |
| | | { id: 'onsite', fullName: '集中授课' }, |
| | | { id: 'practice', fullName: '操作授课' }, |
| | | { id: 'online', fullName: '在线学习' }, |
| | | ]; |
| | | |
| | | /** 与考核方式配置编码对齐 */ |
| | | export const EVAL_MODE_OPTIONS = [ |
| | | { id: 'quiz', fullName: '提问' }, |
| | | { id: 'practice', fullName: '现场操作' }, |
| | | { id: 'exam', fullName: '在线考试' }, |
| | | { id: 'none', fullName: '无需考核' }, |
| | | ]; |
| | | |
| | | export function labelOfEnabled(v?: string) { |
| | | return ENABLE_OPTIONS.find((x) => x.id === v)?.fullName || v || '-'; |
| | | } |
| | | |
| | | export function labelOfCategory(v?: string) { |
| | | return CATEGORY_OPTIONS.find((x) => x.id === v)?.fullName || v || '-'; |
| | | } |
| | | |
| | | export function labelOfTrainMode(v?: string) { |
| | | return TRAIN_MODE_OPTIONS.find((x) => x.id === v)?.fullName || v || '-'; |
| | | } |
| | | |
| | | export function labelOfEvalMode(v?: string) { |
| | | return EVAL_MODE_OPTIONS.find((x) => x.id === v)?.fullName || v || '-'; |
| | | } |
| | | |
| | | /** 在线考试时关联试卷建议必填 */ |
| | | export function evalModeNeedPaper(evalMode?: string) { |
| | | return evalMode === 'exam'; |