|
|
@@ -26,6 +26,7 @@ import { ref, computed, onMounted, watch } from 'vue'
|
|
|
import { useRoute, useRouter } from 'vue-router'
|
|
|
import { useExamStore } from '@/store/exam'
|
|
|
import { useAnalysisStore } from '@/store/analysis'
|
|
|
+import { queryQuestionGroupByAiId } from '@/api/analysis'
|
|
|
|
|
|
const examStore = useExamStore()
|
|
|
const analysisStore = useAnalysisStore()
|
|
|
@@ -56,7 +57,11 @@ const examStateStr = computed(() => {
|
|
|
const examType=computed(() => {
|
|
|
return examStore.currentExam?.examType // 默认为选择题
|
|
|
})
|
|
|
-
|
|
|
+// 考试步骤
|
|
|
+const stepFlow = computed(() => {
|
|
|
+ return examStore.currentExam?.stepFlow
|
|
|
+})
|
|
|
+const isShowGroupAnalysis = computed(() => analysisStore?.isShowGroupAnalysis || false);
|
|
|
|
|
|
// 5. 动态菜单列表
|
|
|
const menuList = computed(() => {
|
|
|
@@ -65,11 +70,15 @@ const menuList = computed(() => {
|
|
|
if(examType.value==1)
|
|
|
{
|
|
|
//选择题判分
|
|
|
- list = [
|
|
|
- { name: '试题结构', number: '1', path: 'question', desc: '建立考试试题结构、设置标答、分组等信息', status: 0 },
|
|
|
- { name: '扫描学生', number: '2', path: 'scanList', desc: '扫描学生,处理扫描异常学生等', status: 0 },
|
|
|
- { name: '成绩查询', number: '3', path: 'analysis/score', desc: '设置每个主观题下的划分区信息及位置', status: 0 ,
|
|
|
- menu:[
|
|
|
+ if(stepFlow.value < 2){
|
|
|
+ list = [
|
|
|
+ { name: '试题结构', number: '1', path: 'question', desc: '建立考试试题结构、设置标答、分组等信息', status: 0 },
|
|
|
+ { name: '扫描学生', number: '2', path: 'scanList', desc: '扫描学生,处理扫描异常学生等', status: 0 },
|
|
|
+ ];
|
|
|
+ }else{
|
|
|
+ let analysisMenu = []
|
|
|
+ if(isShowGroupAnalysis.value){
|
|
|
+ analysisMenu = [
|
|
|
{ name: '成绩单',number: '4', path: 'score' },
|
|
|
{ name: '错题分析',number: '5', path: 'errorAnalysis' },
|
|
|
{ name: '选项明细',number: '6', path: 'optionDetail' },
|
|
|
@@ -79,10 +88,27 @@ const menuList = computed(() => {
|
|
|
{ name: '分组分析',number: '10', path: 'groupAnalysis' },
|
|
|
{ name: '选项分析',number: '11', path: 'optionAnalysis' },
|
|
|
{ name: '命题分析',number: '12', path: 'propositionAnalysis' },
|
|
|
- ]
|
|
|
- },
|
|
|
- ];
|
|
|
-
|
|
|
+ ];
|
|
|
+ }else{
|
|
|
+ analysisMenu = [
|
|
|
+ { name: '成绩单',number: '4', path: 'score' },
|
|
|
+ { name: '错题分析',number: '5', path: 'errorAnalysis' },
|
|
|
+ { name: '选项明细',number: '6', path: 'optionDetail' },
|
|
|
+ { name: '水平分布',number: '7', path: 'levelDistribution' },
|
|
|
+ { name: '班级对比',number: '8', path: 'classComparison' },
|
|
|
+ { name: '小题分析',number: '9', path: 'questionAnalysis' },
|
|
|
+ { name: '选项分析',number: '11', path: 'optionAnalysis' },
|
|
|
+ { name: '命题分析',number: '12', path: 'propositionAnalysis' },
|
|
|
+ ];
|
|
|
+ }
|
|
|
+ list = [
|
|
|
+ { name: '试题结构', number: '1', path: 'question', desc: '建立考试试题结构、设置标答、分组等信息', status: 0 },
|
|
|
+ { name: '扫描学生', number: '2', path: 'scanList', desc: '扫描学生,处理扫描异常学生等', status: 0 },
|
|
|
+ { name: '成绩查询', number: '3', path: 'analysis/score', desc: '设置每个主观题下的划分区信息及位置', status: 0 ,
|
|
|
+ menu:analysisMenu
|
|
|
+ },
|
|
|
+ ];
|
|
|
+ }
|
|
|
}
|
|
|
else if(examType.value==2)
|
|
|
{
|
|
|
@@ -212,8 +238,12 @@ onMounted(() => {
|
|
|
stepOnIndex.value = 0
|
|
|
|
|
|
}
|
|
|
-
|
|
|
-
|
|
|
+ const res = queryQuestionGroupByAiId(examSubjectId.value)
|
|
|
+ if (res.code === 200) {
|
|
|
+ analysisStore.setIsShowGroupAnalysis(true);
|
|
|
+ }else{
|
|
|
+ analysisStore.setIsShowGroupAnalysis(false);
|
|
|
+ }
|
|
|
})
|
|
|
|
|
|
</script>
|