Merge pull request 'zouyf_dev' (#341) from zouyf_dev into main

Reviewed-on: #341
This commit is contained in:
zouyf 2024-10-19 17:20:42 +08:00
commit 4e7b9f0a82
5 changed files with 20 additions and 14 deletions

View File

@ -34,6 +34,7 @@ export const editListItem = (row, courseObj) => {
chooseWorkLists: [],// 设计中的框架梳理list
fileHomeworkList: [],// 设计中的常规作业list
whiteboardObj: '',// 设计中的课堂展示对象
question: '', // 设计中的[课堂展示]的问题
};
console.log('编辑的行', row);
@ -99,7 +100,7 @@ export const editListItem = (row, courseObj) => {
console.log('row.课堂展示', row.workcodes);
const workcodes = JSON.parse(row.workcodes);
classtaskObj.whiteboardObj = JSON.stringify(workcodes.json);
//
classtaskObj.question = row.worktag;
// console.log('课堂展示', classtaskObj);
return resolve(classtaskObj);
}

View File

@ -33,7 +33,7 @@
v-if="classWorkAnalysis.row.worktype == '习题训练'"
:type="classWorkAnalysis.view == 'quizStats' ? 'success' : ''"
@click="workHandle('quizStats')"
>逐题分析</el-button
>逐题讲评</el-button
>
<el-button
v-if="classWorkAnalysis.row.worktype == '习题训练'"
@ -141,7 +141,7 @@
</div>
</div>
<!-- 逐题分析 -->
<!-- 逐题讲评 -->
<div v-else-if="classWorkAnalysis.view == 'quizStats'">
<quiz-stats :active-data="classWorkActiveData" />
</div>
@ -193,7 +193,7 @@ const tableRadio = reactive({
const loading_dt_table = ref(false)
const isopen_dtwk_table = ref(false)
// zdg:
// zdg:
const classWorkActiveData = reactive({
quizlist: [], //
studentList: [], // -
@ -536,7 +536,7 @@ const escapeHtmlQuotes = (str) => {
return result;
}
//#region
//#region
// -
const workHandle = (type) => {
// ui
@ -643,12 +643,12 @@ const closeDialog = () => {
watch(classWorkAnalysis, (newVal, oldVal) => {
if(newVal.view != 'quizStats'){
console.log('关闭zdg: 定时执行')
clearInterval(classWorkActiveData.timerId) //
clearInterval(classWorkActiveData.timerId) //
}
})
onUnmounted(() => {
clearInterval(classWorkActiveData.timerId) //
clearInterval(classWorkActiveData.timerId) //
})
defineExpose({

View File

@ -21,7 +21,7 @@
<div v-if="classWorkForm.worktype == '课堂展示'" style="height: 100%; display: flex; flex-direction: column;">
<div style="flex: 0 0 auto;">
<el-form-item label="问题">
<el-input v-model="classWorkForm.title" type="text" placeholder="请输入问题" />
<el-input v-model="classWorkForm.question" type="text" placeholder="请输入问题" />
</el-form-item>
</div>
<div v-loading="boardLoading" class="board-wrap" style="height: 100%; flex: 1; overflow: hidden;">
@ -349,6 +349,7 @@ let classWorkForm = reactive({
chooseWorkLists: props.propsformobj.chooseWorkLists?cloneDeep(props.propsformobj.chooseWorkLists):[], // list
fileHomeworkList: props.propsformobj.fileHomeworkList?cloneDeep(props.propsformobj.fileHomeworkList):[], //
whiteboardObj: props.propsformobj.whiteboardObj?cloneDeep(props.propsformobj.whiteboardObj):'', // -
question: props.propsformobj.question?cloneDeep(props.propsformobj.question):'', // -
}); //
// ---------------------------------------------------
// const listWorkType = ref(['', '', '', '']); //
@ -638,6 +639,7 @@ const handleClassWorkSave = async () => {
let canvasJson = proxy.$refs.boardref.getCanvasJson()
let canvasBase64 = await proxy.$refs.boardref.getCanvasBase64()
//
cform.worktag = classWorkForm.question;
cform.title = classWorkForm.title;
cform.workcodes = JSON.stringify({json: canvasJson, base64: canvasBase64});
cform.entpcourseworklist = JSON.stringify([{'id':-1, 'score': '10'}]);
@ -648,6 +650,7 @@ const handleClassWorkSave = async () => {
classWorkForm.worktype = "课堂展示";
classWorkForm.uniquekey = props.propsformobj.uniquekey, //
classWorkForm.title = "";
classWorkForm.question = "";
classWorkForm.quizlist = [], //
//
@ -839,6 +842,7 @@ const editWork = async (cform) =>{
let canvasJson = proxy.$refs.boardref.getCanvasJson()
let canvasBase64 = await proxy.$refs.boardref.getCanvasBase64()
cform.workcodes = JSON.stringify({json: canvasJson, base64: canvasBase64});
cform.worktag = classWorkForm.question;
}
else if (classWorkForm.worktype=='常规作业') {
// 1. (, )

View File

@ -69,6 +69,7 @@ const classWorkForm = reactive({
chooseWorkLists: classtaskObj? JSON.parse(classtaskObj).chooseWorkLists : [],// list
fileHomeworkList: classtaskObj? JSON.parse(classtaskObj).fileHomeworkList : [],// list
whiteboardObj: classtaskObj? JSON.parse(classtaskObj).whiteboardObj : '',//
question: classtaskObj? JSON.parse(classtaskObj).question : '',//
})

View File

@ -23,7 +23,7 @@
v-if="classWorkAnalysis.row.worktype == '习题训练'"
:type="classWorkAnalysis.view == 'quizStats' ? 'success' : ''"
@click="workHandle('quizStats')"
>逐题分析</el-button
>逐题讲评</el-button
>
<el-button
v-if="classWorkAnalysis.row.worktype == '习题训练'"
@ -131,7 +131,7 @@
</div>
</div>
<!-- 逐题分析 -->
<!-- 逐题讲评 -->
<div v-else-if="classWorkAnalysis.view == 'quizStats'" style="width: 100%;">
<quiz-stats :active-data="classWorkActiveData" style="width: 100%;height: 100%;"/>
</div>
@ -180,7 +180,7 @@ const tableRadio = reactive({
const loading_dt_table = ref(false)
const isopen_dtwk_table = ref(false)
// zdg:
// zdg:
const classWorkActiveData = reactive({
quizlist: [], //
studentList: [], // -
@ -528,7 +528,7 @@ const escapeHtmlQuotes = (str) => {
return result;
}
//#region
//#region
// -
const workHandle = (type) => {
// ui
@ -646,12 +646,12 @@ onMounted(() => {
watch(classWorkAnalysis, (newVal, oldVal) => {
if(newVal.view != 'quizStats'){
console.log('关闭zdg: 定时执行')
clearInterval(classWorkActiveData.timerId) //
clearInterval(classWorkActiveData.timerId) //
}
})
onUnmounted(() => {
clearInterval(classWorkActiveData.timerId) //
clearInterval(classWorkActiveData.timerId) //
})
// defineExpose({