Ver Fonte

异常数据处理逻辑更新

dengshaobo há 3 semanas atrás
pai
commit
28674c8972

+ 9 - 0
src/api/exam.ts

@@ -263,5 +263,14 @@ export const updateExamNumberException= (data:any):Promise<ApiResponse> => {
   })
 }
 
+//扫描学生 获取异常列表数据
+export const getExamAbnormalList= (data:any):Promise<ApiResponse> => {
+  return request({
+    url: '/api/v1/ai_exam_scan/find_abnormal_detail',
+    method: 'get',
+    params: data 
+  })
+}
+
 
 

+ 276 - 2
src/styles/common.scss

@@ -3922,8 +3922,8 @@ body {
             }
 
             .right_table {
-            width: calc(100% - 40px);
-            margin: auto;
+              width: calc(100% - 40px);
+              margin: auto;
             }
         }
 
@@ -4569,4 +4569,278 @@ body {
 
         }
     }
+}
+
+
+// 右侧表格
+.right_table
+{
+  width: calc(100% - 40px);
+  margin: auto;
+
+  .el-table {
+    border-radius: 4px;
+  }
+
+  .el-table .el-table__header {
+    height: 40px;
+  }
+
+  //表格顶部标题栏
+  .el-table tr th.el-table__cell {
+    background-color: #f0f2f5;
+    font-size: 16px;
+    color: #303133;
+    font-weight: 600;
+  }
+
+  .el-table__body tr {
+    cursor: pointer;
+  }
+
+  //行的悬浮样式设置
+  .el-table__body tr:hover>td {
+    // background-color: transparent !important;
+  }
+
+  //行的悬浮样式设置
+  .el-table__body .el-table .selected_row tr:hover>td {
+    background-color: transparent !important;
+  }
+
+  //选中行的背景色和字体颜色
+  .el-table .selected_row {
+    // background-color: #d5e0fe;
+    /* 选中行的背景色 */
+    color: #2e64fa;
+
+  }
+
+  .el-table .cell {
+    padding: 0 !important;
+  }
+
+  .el-table .el-table__cell {
+    height: 40px;
+    padding: 0 !important;
+  }
+
+  .table_row_title {
+    width: 100%;
+    overflow: hidden;
+    /* 隐藏超出容器的内容 */
+    white-space: nowrap;
+    /* 保持文本在一行内 */
+    text-overflow: ellipsis;
+    /* 超出部分显示省略号 */
+    cursor: pointer;
+  }
+
+  .table_row_value {
+    width: 100%;
+    overflow: hidden;
+    /* 隐藏超出容器的内容 */
+    white-space: nowrap;
+    /* 保持文本在一行内 */
+    text-overflow: ellipsis;
+    /* 超出部分显示省略号 */
+    cursor: pointer;
+  }
+
+  .row_scan_status {
+    width: 100%;
+    text-align: center;
+    display: flex;
+    justify-content: center;
+    align-items: center;
+    cursor: pointer;
+    gap: 5px;
+
+    .no_scan_btn {
+      font-weight: 400;
+      font-size: 14px;
+      color: #666666;
+      text-align: center;
+    }
+
+    .yes_scan_btn {
+      width: 54px;
+      height: 24px;
+      border-radius: 4px 4px 4px 4px;
+      border: 1px solid #2bc644;
+      font-weight: 400;
+      font-size: 14px;
+      color: #2bc644;
+      line-height: 24px;
+    }
+
+    //重号
+    .repeat_scan_btn {
+      width: 54px;
+      height: 24px;
+      border-radius: 4px 4px 4px 4px;
+      border: 1px solid #f56c6c;
+      font-weight: 400;
+      font-size: 14px;
+      color: #f56c6c;
+      line-height: 24px;
+    }
+
+    //灰色查看
+    .disable_view_btn {
+      width: auto;
+      height: 24px;
+      border-radius: 4px 4px 4px 4px;
+      // border: 1px solid #2e64fa;
+      font-weight: 400;
+      font-size: 14px;
+      color: #C0C4CC;
+      line-height: 24px;
+    }
+
+    //认领
+    .claim_scan_btn {
+      width: auto;
+      height: 24px;
+      border-radius: 4px 4px 4px 4px;
+      // border: 1px solid #2e64fa;
+      font-weight: 400;
+      font-size: 14px;
+      color: #2e64fa;
+      line-height: 24px;
+    }
+  }
+}
+
+//客观题答案处理表格
+.answer_table {
+  width: calc(100% - 40px);
+  margin: auto;
+
+  .el-table {
+    border-radius: 4px;
+  }
+
+  .el-table .el-table__header {
+    height: 36px;
+  }
+
+  //表格顶部标题栏
+  .el-table tr th.el-table__cell {
+    background-color: #f0f2f5;
+    font-size: 16px;
+    color: #303133;
+    font-weight: 600;
+  }
+
+  .el-table .el-table__cell {
+    height: 42px;
+    padding: 0 !important;
+  }
+
+  .el-input__inner {
+    height: 32px;
+    line-height: 32px;
+
+  }
+
+  .input_error {
+    .el-input__inner {
+      color: red;
+    }
+
+  }
+
+  // .el-table--striped
+  //   .el-table__body
+  //   tr.el-table__row--striped
+  //   td.el-table__cell {
+  //   background-color: transparent;
+  // }
+
+  .table_row_answer_choose {
+    width: 100%;
+    height: 100%;
+    display: flex;
+    justify-content: flex-start;
+    align-items: center;
+    flex-wrap: wrap;
+    padding-top: 10px;
+    padding-bottom: 10px;
+    gap: 12px;
+
+    .answer_item {
+      width: 36px;
+      height: 20px;
+      font-weight: 500;
+      font-size: 12px;
+      color: #666666;
+      background: #ffffff;
+      border-radius: 0px 0px 0px 0px;
+      border: 1px solid #909399;
+      line-height: 18px;
+      text-align: center;
+      cursor: pointer;
+    }
+
+    .choose {
+      border: 1px solid #2e64fa;
+      background: #2e64fa;
+      color: #fff;
+    }
+
+    .input_error {
+      border: 1px solid red;
+      border-radius: 4px;
+    }
+
+    .el-input {
+      height: 32px;
+      line-height: 32px;
+    }
+
+    .el-input__inner {
+      height: 32px;
+      line-height: 32px;
+    }
+
+    .score_count_append {
+      width: 44px;
+      height: 20px;
+      line-height: 20px;
+      color: #C0C4CC;
+    }
+  }
+
+  .answer_cur_row_bg {
+    background-color: rgba(245, 108, 108, 0.2);
+
+    .el-table--border .el-table__cell:first-child .cell {
+      background-color: rgba(245, 108, 108, 0.2);
+    }
+  }
+
+
+
+  //成绩纠错 表格 题目名称样式
+  .table_row_question_name {
+    font-size: 14px;
+    color: #666;
+  }
+
+  //成绩纠错 表格 修改后样式
+  .table_row_question_update {
+    font-size: 14px;
+    color: #F56C6C;
+  }
+
+
+  //选中行的背景色和字体颜色
+  .el-table .selected_row {
+    background-color: #F56C6C20 !important;
+    /* 选中行的背景色 */
+    color: #F56C6C;
+    /* 选中行的文字颜色 */
+
+  }
 }

+ 0 - 0
src/views/analysis/选择题判分成绩分析.txt


+ 106 - 9
src/views/exam/abnormal/abnormal.vue

@@ -551,7 +551,7 @@ import { onMounted, ref, computed, nextTick, watch } from 'vue';
 import { ElMessage } from 'element-plus'
 
 // 引入可能需要的 API (请根据实际路径调整)
-// import { getAbnormalList, updateAbnormalStatus, deletePaper } from '@/api/exam'
+import { getExamAbnormalList, updateAbnormalStatus, deletePaper } from '@/api/exam'
 
 // 引入子组件 (确保路径正确)
 // import PositionCanvas from './components/PositionCanvas.vue' // 假设路径
@@ -562,6 +562,24 @@ import { ElMessage } from 'element-plus'
 const examStore = useExamStore()
 const router = useRouter()
 
+// ==================== 考试通用数据(可追加)====================
+// 考试科目 ID
+const examSubjectId = computed(() => {
+  return examStore.currentExam?.id
+})//计算属性
+
+const schoolId = computed(() => {
+  return 0;
+})//学校id
+
+//考试科目code
+const examSubjectCode=computed(() => {
+    return examStore.currentExam?.examSubjectCode
+})
+
+
+
+
 // ==================== 状态定义 ====================
 
 // 异常类型: 2-定位异常 3-考号异常 4-客观题异常 5-选做题异常 6-划分异常(空白卷) 7-缺页异常
@@ -611,7 +629,7 @@ const searchContent = ref('')
 const searchStudetList = ref<any[]>([])
 
 // 表格高度与Key
-const tableHeightRight = ref(200)
+const tableHeightRight = ref(200)//定位表格高度
 const losePagetableHeight = ref(200)
 const searchTableHeight = ref(200)
 const objectTableHeight = ref(200)
@@ -655,6 +673,7 @@ const AbnormalChanage = (type: number) => {
     abnormalType.value = type
     // TODO: 加载对应类型的异常列表数据
     console.log('切换异常类型:', type)
+    GetAbnormalList();
 }
 
 // 2. 刷新异常列表
@@ -892,6 +911,83 @@ const SubjectiveCheck = () => {
     }, 1000)
 }
 
+//定位异常数据处理
+const  PositionAbnormal= () => { 
+    console.log("定位异常数据处理");
+
+}
+
+//初始化重置数据
+const ResetData = () => { 
+    // rotationAngle.value = 0;
+    currentPaperIndex.value=0;
+}
+
+// ==================== API 请求 ==========
+
+//通用获取异常列表数据
+const GetAbnormalList = async () => {
+    const params={
+        examSubjectId: examSubjectId.value,//考试id
+        schoolId:schoolId.value,
+    };
+    const res = await getExamAbnormalList(params);
+    console.log("打印异常数据",res);
+    if(res.code == 200)
+    {
+        let examInfoCount={
+            unScanned:res.data.unScanned,//未扫描
+            examMissNum:res.data.examMissNum,//缺考
+            scannedNum:res.data.scannedNum,//已上传
+            abnormalNum:res.data.abnormalNum,//异常
+            examTotal:res.data.totalNum,//总数
+        };
+        examStore.setExamInfoCount(examInfoCount);//设置扫描数据信息
+        //异常数据处理
+        if(res.data.abnormalGroupVO)
+        {
+            
+            //定位异常处理
+            if(res.data.abnormalGroupVO.dwAbnormal)
+            {
+                positionData.value.pendingList = res.data.abnormalGroupVO.dwAbnormal || [];
+            }
+
+            //考号异常处理
+            if(res.data.abnormalGroupVO.cardNumberAbnormal)
+            {
+                numberData.value.pendingList = res.data.abnormalGroupVO.cardNumberAbnormal || [];
+            }
+
+            //客观题异常处理
+            if(res.data.abnormalGroupVO.objectiveAbnormal)
+            {
+                objectData.value.pendingList = res.data.abnormalGroupVO.objectiveAbnormal || [];
+                objectData.value.processedList = res.data.abnormalGroupVO.dealObjectiveAbnormal || [];
+            }
+
+            abnormalObj.value={
+                locationErrorNum: positionData.value.pendingList.length, // 定位异常数量
+                examNumberErrorNum: numberData.value.pendingList.length, // 考号异常数量
+                losePageErrorNum: losePageData.value.pendingList.length, // 缺页异常数量
+                objectErrorNum: objectData.value.pendingList.length, // 客观题异常数量
+                choiceErrorNum: choiceData.value.pendingList.length, // 选做题异常数量
+                subjectiveErrorNum: subjectiveData.value.pendingList.length, // 划分异常数量
+            };//异常数据
+        }
+
+
+
+
+    }
+    else
+    {
+
+    }
+
+}
+       
+
 // ==================== 生命周期 ====================
 
 onMounted(() => {
@@ -902,17 +998,18 @@ onMounted(() => {
         // LoadAbnormalStats()
         // LoadAbnormalList(abnormalType.value)
     }
-    
+    GetAbnormalList();
     // 监听窗口变化调整高度
-    window.addEventListener('resize', CalculateHeight)
-    CalculateHeight()
+    window.addEventListener('resize', CalculateTableHeight)
+    CalculateTableHeight()
 })
 
-const CalculateHeight = () => {
+//计算表格高度
+const CalculateTableHeight = () => {
     nextTick(() => {
-        const h = window.innerHeight - 150
-        tableHeightRight.value = h > 200 ? h : 200
-        losePagetableHeight.value = h > 200 ? h : 200
+
+        tableHeightRight.value = window.innerHeight - 220;
+       
         // 其他高度同理
     })
 }