This commit is contained in:
zdg 2024-09-29 15:14:13 +08:00
commit 0973128e0e
3 changed files with 22 additions and 12 deletions

View File

@ -153,7 +153,7 @@ function handleCommand(command) {
function logout() {
const hasClass = sessionStore.has('activeClass.id')
if (hasClass || toolState.isToolWin) return ElMessage.warning('当前正在上课,请先结束上课')
if (hasClass || toolState.isToolWin) return ElMessage.warning('当前正在上课,请先结束上课')
ElMessageBox.confirm('确认退出系统吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',

View File

@ -377,6 +377,7 @@ const closeDialog = () => {
getStudentClassWorkDataPolling()
}
const openDialogTime = ref(null);//
/**
* 开启新批改弹窗
* @param item 作业对象
@ -386,12 +387,15 @@ const onClickItem = (item) => {
clearInterval(pollingST.value)
// itemDialogRef.value.openDialog(item)
//
// 1item2 3item
// localStorage.setItem('teachClassWorkItem', JSON.stringify(item))
sessionStore.set('teachClassWorkItem', item)
toolState.isTaskWin=true //
if(openDialogTime.value) return;
clearTimeout(openDialogTime.value)
openDialogTime.value = setTimeout(() => {
openDialogTime.value = null;
toolState.isTaskWin=true; //
sessionStore.set('teachClassWorkItem', item); // item
//
createWindow('open-taskwin',{url:'/teachClassTask'})
}, 1000)
}

View File

@ -67,14 +67,20 @@ const getHomework = async () => {
loading.value = false
}
}
const openDialogTime = ref(null);//
//
const onClickItem = (item) => {
console.log('开启弹窗')
// itemDialogRef.value.openDialog(item)
if(openDialogTime.value) return;
clearTimeout(openDialogTime.value)
openDialogTime.value = setTimeout(() => {
openDialogTime.value = null;
toolState.isTaskWin=true; //
sessionStore.set('teachClassWorkItem', item); // item
//
sessionStore.set('teachClassWorkItem', item)
toolState.isTaskWin=true //
createWindow('open-taskwin',{url:'/teachClassTask'})
}, 1000)
}
const tagType = (time) => {