|
@@ -22,7 +22,7 @@
|
|
|
</div>
|
|
|
<div class="finish-detail">
|
|
|
<template v-if="isExercises">
|
|
|
- <div ref="situation" class="exercise">
|
|
|
+ <div v-if="exercise_info.answer_record?.is_finish === 'true'" ref="situation" class="exercise">
|
|
|
<div class="title">测试报告</div>
|
|
|
<div class="color-list">
|
|
|
<div v-for="{ label, color } in questionColorList" :key="label" class="color-item">
|
|
@@ -82,7 +82,25 @@
|
|
|
|
|
|
<div class="footer">
|
|
|
<el-button type="primary" @click="remarkTaskStudentExecuteInfo_Teacher">批改完成</el-button>
|
|
|
- <el-button>重发</el-button>
|
|
|
+ <el-button @click="resendStudentExerciseTask">重发</el-button>
|
|
|
+ <el-button v-if="student_list.length > 1" @click="next">
|
|
|
+ {{ buttonName }} <i :class="buttonIcon"></i>
|
|
|
+ </el-button>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div v-else ref="situation" class="exercise">
|
|
|
+ <div>练习任务</div>
|
|
|
+ <div class="exercise-task">
|
|
|
+ <el-tag color="#fff">
|
|
|
+ <div class="courseware">
|
|
|
+ <svg-icon icon-class="courseware" />
|
|
|
+ <span class="courseware_name nowrap-ellipsis">{{ exercise_info.answer_record?.exercise_name }}</span>
|
|
|
+ </div>
|
|
|
+ </el-tag>
|
|
|
+ <span class="not-submitted">未提交</span>
|
|
|
+ </div>
|
|
|
+ <div class="footer">
|
|
|
+ <el-button @click="resendStudentExerciseTask">重发</el-button>
|
|
|
<el-button v-if="student_list.length > 1" @click="next">
|
|
|
{{ buttonName }} <i :class="buttonIcon"></i>
|
|
|
</el-button>
|
|
@@ -201,7 +219,12 @@ export default {
|
|
|
|
|
|
<script setup>
|
|
|
import { ref, inject, nextTick, computed } from 'vue';
|
|
|
-import { GetTaskInfo, GetTaskStudentExecuteInfo, RemarkTaskStudentExecuteInfo_Teacher } from '@/api/course';
|
|
|
+import {
|
|
|
+ GetTaskInfo,
|
|
|
+ GetTaskStudentExecuteInfo,
|
|
|
+ RemarkTaskStudentExecuteInfo_Teacher,
|
|
|
+ ResendStudentExerciseTask
|
|
|
+} from '@/api/course';
|
|
|
import { useRoute } from 'vue-router/composables';
|
|
|
import { Message } from 'element-ui';
|
|
|
import { useShowFile } from '@/common/show_file/index';
|
|
@@ -334,6 +357,14 @@ function getTaskStudentExecuteInfo(student_id) {
|
|
|
);
|
|
|
}
|
|
|
|
|
|
+function resendStudentExerciseTask() {
|
|
|
+ ResendStudentExerciseTask({ task_id: id, student_id: curStudentId.value }).then(() => {
|
|
|
+ Message.success('重发成功');
|
|
|
+ getTaskStudentExecuteInfo(curStudentId.value);
|
|
|
+ student_list.value.find(({ student_id }) => student_id === curStudentId.value).exercise_info.is_finish = 'false';
|
|
|
+ });
|
|
|
+}
|
|
|
+
|
|
|
let previewGroupId = ref('[]');
|
|
|
let dialogVisible = ref(false);
|
|
|
let curCoursewareId = ref('');
|
|
@@ -550,6 +581,32 @@ $bor-color: #d9d9d9;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ &-task {
|
|
|
+ display: flex;
|
|
|
+ column-gap: 16px;
|
|
|
+ align-items: center;
|
|
|
+
|
|
|
+ :deep .el-tag {
|
|
|
+ .courseware {
|
|
|
+ .svg-icon {
|
|
|
+ margin-right: 12px;
|
|
|
+ font-size: 18px;
|
|
|
+ vertical-align: super;
|
|
|
+ }
|
|
|
+
|
|
|
+ &_name {
|
|
|
+ display: inline-block;
|
|
|
+ max-width: 120px;
|
|
|
+ font-size: 16px;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ .not-submitted {
|
|
|
+ color: #e43e3e;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
.footer {
|
|
|
.el-button {
|
|
|
font-weight: bold;
|