From 1bc2820c01b47fd13d38b19b1975c9b093abf479 Mon Sep 17 00:00:00 2001 From: odc.xiaohui <xiaohui@Q1> Date: 星期三, 21 六月 2023 11:30:24 +0800 Subject: [PATCH] 修改青羊试卷添加 --- src/store/modules/exam.js | 17 ++++++++++++++--- 1 files changed, 14 insertions(+), 3 deletions(-) diff --git a/src/store/modules/exam.js b/src/store/modules/exam.js index 816c71d..b96a649 100644 --- a/src/store/modules/exam.js +++ b/src/store/modules/exam.js @@ -6,11 +6,22 @@ const getters = { subjectEnumFormat: (state) => (key) => { - for (let item of state.subjects) { - if (item.id === key) { - return item.name + ' ( ' + item.levelName + ' )' + // console.log(state.subjects,key) + let str = '' + for (const j of state.subjects) { + for (let k of key) { + // console.log(j,k) + if (j.id ==k){ + str+= j.name + ' /' + } } } + return str.slice(0,str.length-1) + // for (let item of state.subjects) { + // if (item.id === key) { + // return item.name + ' ( ' + item.levelName + ' )' + // } + // } return null } } -- Gitblit v1.8.0