baigl #180
|
@ -869,7 +869,7 @@ const onSubmit = () => {
|
|||
var formd = {
|
||||
id: dialogProps.value.studentObj.id, // this.activeClassWork.id;
|
||||
status: '1',//0 未批阅; 1 已批阅
|
||||
updatedate: getTimeDate,// = year+'-'+month+'-'+day+' '+hh+':'+mm;
|
||||
updatedate: getTimeDate(),// = year+'-'+month+'-'+day+' '+hh+':'+mm;
|
||||
};
|
||||
// 更新作业批改状态
|
||||
updateClassworkdata(formd).then(res => {
|
||||
|
|
|
@ -161,6 +161,8 @@ import { ElMessage } from 'element-plus'
|
|||
import { getCurrentTime, getAfterMinutes } from '@/utils/date'
|
||||
import { processList } from '@/hooks/useProcessList'
|
||||
import ItemDialogScore from '@/views/classTask/container/item-dialog-score.vue'
|
||||
// zdg: 组件导入
|
||||
import quizStats from '@/views/classTask/container/quizStats.vue'
|
||||
|
||||
const { proxy } = getCurrentInstance()
|
||||
const emit = defineEmits(['addSuccess'])
|
||||
|
@ -521,6 +523,41 @@ const escapeHtmlQuotes = (str) => {
|
|||
// })
|
||||
}
|
||||
|
||||
//#region 作业概况
|
||||
// 查看学生-作业概览
|
||||
const workHandle = (type) => {
|
||||
// 关闭右侧批阅ui
|
||||
isopen_dtwk_table.value = false;
|
||||
classWorkAnalysis.view = type
|
||||
const isClose = type != 'quizStats' && !! classWorkActiveData.timerId
|
||||
const isOpen = type == 'quizStats' && !classWorkActiveData.timerId
|
||||
if (isClose) clearInterval(classWorkActiveData.timerId) // 关闭定时器
|
||||
if (isOpen) {
|
||||
// 轮询 更新学生作答数据
|
||||
classWorkActiveData.timerId = setInterval(() => {
|
||||
console.log('zdg: 定时执行')
|
||||
getWorkFeedList()
|
||||
}, 20 * 1000);
|
||||
}
|
||||
}
|
||||
// 获取学生答题回馈数据-更新
|
||||
const getWorkFeedList = async() =>{
|
||||
const workid = classWorkAnalysis.row.id
|
||||
const res = await listClassworkeval({workid, isFinish: 1, pageSize: 1000})
|
||||
const getStudentid = (workdataid) => { // 获取学生id
|
||||
const classworkdata = (classWorkAnalysis.classworkdata||[]).find(o => o.id === workdataid)
|
||||
return classworkdata ? classworkdata.studentid : ''
|
||||
}
|
||||
res.rows.forEach(o => { o.studentid = getStudentid(o.workdataid) })
|
||||
classWorkActiveData.workFeedList = res.rows
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
//#endregion
|
||||
|
||||
|
||||
defineExpose({
|
||||
openDialog
|
||||
})
|
||||
|
|
|
@ -70,13 +70,14 @@
|
|||
</el-row>
|
||||
</template>
|
||||
<script setup>
|
||||
import { ref, defineExpose, onMounted, reactive, computed, watch, nextTick, watchEffect } from 'vue'
|
||||
// 功能说明:习题-概况|作业统计(使用:公屏-习题练习|作业管理-作业布置)
|
||||
// === 引入和参数初始化 ===
|
||||
// import { nextTick } from 'vue'
|
||||
|
||||
// import * as elementPlus from 'element-plus' // ElMessage ElMessageBox
|
||||
let colorArr = [] // 进度颜色值 -- 静态数据
|
||||
const attrs = useAttrs() // props中未定义属性
|
||||
// const attrs = useAttrs() // props中未定义属性
|
||||
const activeTopic = ref(0) // 展开的题
|
||||
let dataList = ref([]) // 左侧数据
|
||||
let studentList = ref([]) // 学生数据
|
||||
|
@ -209,7 +210,7 @@ watchEffect(() => { initData() })
|
|||
// 弹窗容器
|
||||
.c-warp{
|
||||
background: #F2F3F5;
|
||||
height: 100vh;
|
||||
height: 75vh;
|
||||
margin: 0 !important;
|
||||
.left{padding-left: 0 !important;}
|
||||
.right{padding-right: 0 !important;}
|
||||
|
@ -218,7 +219,7 @@ watchEffect(() => { initData() })
|
|||
background: #fff;
|
||||
border: none;
|
||||
overflow-y: auto;
|
||||
height: 100vh;
|
||||
height: 75vh;
|
||||
}
|
||||
.collapse-item{
|
||||
.item-title-o{
|
||||
|
@ -259,7 +260,7 @@ watchEffect(() => { initData() })
|
|||
margin-bottom: 10px;
|
||||
}
|
||||
.respond{
|
||||
height: calc(100vh - 65px);
|
||||
height: calc(70vh - 65px);
|
||||
overflow: auto;
|
||||
.el-space{padding: 5px;}
|
||||
.card-warp{
|
||||
|
|
Loading…
Reference in New Issue