fix:添加活动;
This commit is contained in:
parent
5b1d921378
commit
9e021edc67
|
@ -67,8 +67,6 @@
|
||||||
|
|
||||||
<div class="page-number">幻灯片 {{slideIndex + 1}} / {{slides.length}}</div>
|
<div class="page-number">幻灯片 {{slideIndex + 1}} / {{slides.length}}</div>
|
||||||
|
|
||||||
<!-- 引入活动的列表页面 -->
|
|
||||||
<Active ref="activeRef" v-show="false"/>
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
@ -88,7 +86,6 @@ import ThumbnailSlide from '../../../views/components/ThumbnailSlide/index.vue'
|
||||||
import LayoutPool from './LayoutPool.vue'
|
import LayoutPool from './LayoutPool.vue'
|
||||||
import Popover from '../../../components/Popover.vue'
|
import Popover from '../../../components/Popover.vue'
|
||||||
import Draggable from 'vuedraggable'
|
import Draggable from 'vuedraggable'
|
||||||
import Active from '../Toolbar/ElementStylePanel/Active/index.vue'
|
|
||||||
|
|
||||||
const mainStore = useMainStore()
|
const mainStore = useMainStore()
|
||||||
const slidesStore = useSlidesStore()
|
const slidesStore = useSlidesStore()
|
||||||
|
@ -127,7 +124,6 @@ const {
|
||||||
updateSectionTitle,
|
updateSectionTitle,
|
||||||
} = useSectionHandler()
|
} = useSectionHandler()
|
||||||
|
|
||||||
const activeRef = ref()
|
|
||||||
|
|
||||||
// 页面被切换时
|
// 页面被切换时
|
||||||
const thumbnailsRef = ref<InstanceType<typeof Draggable>>()
|
const thumbnailsRef = ref<InstanceType<typeof Draggable>>()
|
||||||
|
@ -151,8 +147,6 @@ watch(() => slideIndex.value, () => {
|
||||||
|
|
||||||
// 切换页面
|
// 切换页面
|
||||||
const changeSlideIndex = (index: number) => {
|
const changeSlideIndex = (index: number) => {
|
||||||
console.log(workItem.value[index],'hasSection');
|
|
||||||
activeRef.value.clickPPTList(workItem.value[index])
|
|
||||||
|
|
||||||
mainStore.setActiveElementIdList([])
|
mainStore.setActiveElementIdList([])
|
||||||
|
|
||||||
|
|
|
@ -43,7 +43,6 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
{{workList.length}}
|
|
||||||
</div>
|
</div>
|
||||||
<!-- // 推送作业 -->
|
<!-- // 推送作业 -->
|
||||||
<el-dialog v-model="dialogVisible" append-to-body :show-close="false" width="80%" height="500">
|
<el-dialog v-model="dialogVisible" append-to-body :show-close="false" width="80%" height="500">
|
||||||
|
@ -71,45 +70,95 @@
|
||||||
</el-table>
|
</el-table>
|
||||||
<template #footer>
|
<template #footer>
|
||||||
<el-button @click="activeVisible = false">取 消</el-button>
|
<el-button @click="activeVisible = false">取 消</el-button>
|
||||||
<el-button type="primary" @click="save">确 定</el-button>
|
<el-button type="primary" @click="savePPtData">确 定</el-button>
|
||||||
</template>
|
</template>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script setup>
|
<script setup lang="ts">
|
||||||
import { ref, reactive, onMounted, onBeforeMount, defineExpose,nextTick } from 'vue'
|
import { ref, reactive, onMounted, nextTick, watch } from 'vue'
|
||||||
import Divider from '../../../../../components/Divider.vue'
|
import Divider from '../../../../../components/Divider.vue'
|
||||||
import { listEntpcoursefile } from '@/api/education/entpcoursefile'
|
import { listEntpcoursefile } from '@/api/education/entpcoursefile'
|
||||||
import { homeworklist } from '@/api/teaching/classwork'
|
import { homeworklist } from '@/api/teaching/classwork'
|
||||||
import { processList } from "@/hooks/useProcessList";
|
import { processList } from "@/hooks/useProcessList";
|
||||||
import { listEntpcoursework } from "@/api/classTask/index";
|
import { listEntpcoursework } from "@/api/classTask/index";
|
||||||
import { ElMessageBox } from 'element-plus'
|
import { ElMessageBox,ElMessage } from 'element-plus'
|
||||||
import NewClassTsakAssign from '@/views/classTask/newClassTaskAssign/index.vue'
|
import NewClassTsakAssign from '@/views/classTask/newClassTaskAssign/index.vue'
|
||||||
import { sessionStore } from '@/utils/store'
|
import { sessionStore } from '@/utils/store'
|
||||||
import { useGetHomework } from '@/hooks/useGetHomework'
|
import { useGetHomework } from '@/hooks/useGetHomework'
|
||||||
import { updateSlide } from '@/AixPPTist/src/api/index'
|
import { PPTApi } from '../../../../../api/index'
|
||||||
const currentCourse = reactive({
|
import { storeToRefs } from 'pinia'
|
||||||
|
import {useSlidesStore} from '../../../../../store'
|
||||||
|
const slidesStore = useSlidesStore()
|
||||||
|
const { slides, slideIndex, currentSlide, workItem } = storeToRefs(slidesStore)
|
||||||
|
|
||||||
|
interface CourseNode {
|
||||||
|
rootid: number;
|
||||||
|
parentNode: { id: number };
|
||||||
|
id: number;
|
||||||
|
itemtitle: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
interface CurrentCourse {
|
||||||
|
textbookId: number;
|
||||||
|
levelFirstId: number;
|
||||||
|
levelSecondId: number;
|
||||||
|
coursetitle: string;
|
||||||
|
node: CourseNode;
|
||||||
|
id: number;
|
||||||
|
worktype: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
interface Params {
|
||||||
|
parentid: number;
|
||||||
|
pageSize: number;
|
||||||
|
orderby: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
interface WorkType {
|
||||||
|
label: string;
|
||||||
|
value: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
interface WorkItem {
|
||||||
|
status: string;
|
||||||
|
activityContent?: string;
|
||||||
|
worktype: string;
|
||||||
|
quizlist?: { id: number }[];
|
||||||
|
workcodes: string;
|
||||||
|
base64?: string;
|
||||||
|
prevData?: any;
|
||||||
|
id: number;
|
||||||
|
evaltitle?: string; // 添加 evaltitle 属性
|
||||||
|
}
|
||||||
|
|
||||||
|
const currentCourse = reactive<CurrentCourse>({
|
||||||
textbookId: 0,
|
textbookId: 0,
|
||||||
levelFirstId: 0,
|
levelFirstId: 0,
|
||||||
levelSecondId: 0,
|
levelSecondId: 0,
|
||||||
coursetitle: '',
|
coursetitle: '',
|
||||||
node:{},
|
node: {} as CourseNode,
|
||||||
id: 1,
|
id: 1,
|
||||||
worktype: '',
|
worktype: '',
|
||||||
})
|
})
|
||||||
const dataList = ref([])
|
|
||||||
const dialogVisible = ref(false)
|
const dataList = ref<WorkItem[]>([])
|
||||||
const tasklist_loading = ref(false)
|
const dialogVisible = ref<boolean>(false)
|
||||||
|
const tasklist_loading = ref<boolean>(false)
|
||||||
|
|
||||||
// 活动列表
|
// 活动列表
|
||||||
const taskList = ref([])
|
const taskList = ref<WorkItem[]>([])
|
||||||
|
|
||||||
// 活动引用的弹窗
|
// 活动引用的弹窗
|
||||||
const activeVisible = ref(false)
|
const activeVisible = ref<boolean>(false)
|
||||||
const params = reactive({
|
|
||||||
|
const params = reactive<Params>({
|
||||||
parentid: 14766,
|
parentid: 14766,
|
||||||
pageSize: 500,
|
pageSize: 500,
|
||||||
orderby: 'fileidx'
|
orderby: 'fileidx'
|
||||||
})
|
})
|
||||||
const type = ref([
|
|
||||||
|
const type = ref<WorkType[]>([
|
||||||
{
|
{
|
||||||
label: '习题训练',
|
label: '习题训练',
|
||||||
value: 'danger'
|
value: 'danger'
|
||||||
|
@ -123,131 +172,144 @@ const type = ref([
|
||||||
value: 'primary'
|
value: 'primary'
|
||||||
},
|
},
|
||||||
])
|
])
|
||||||
|
|
||||||
|
const objItem = ref<any>({})
|
||||||
// 作业列表
|
// 作业列表
|
||||||
const workList = ref([])
|
const workList = ref<WorkItem[]>([])
|
||||||
|
|
||||||
// 获取所选择的作业列表
|
// 获取所选择的作业列表
|
||||||
const selectedWorkList = ref([])
|
const selectedWorkList = ref<WorkItem[]>([])
|
||||||
// 获取当前的活动ppt页面
|
|
||||||
const currentPPT = ref({})
|
|
||||||
const selectable=(row, index)=>{
|
const paramData = ref<{ id: number, activityContent: string }>({} as { id: number, activityContent: string })
|
||||||
return row.status == '10';
|
|
||||||
|
const selectable = (row: WorkItem, index: number): boolean => {
|
||||||
|
return row.status === '10';
|
||||||
};
|
};
|
||||||
const clickPPTList = (item) => {
|
|
||||||
console.log(item,'点击了')
|
|
||||||
console.log(item.id,'item');
|
const formatClassWorkFile = async (postData: WorkItem[]): Promise<void> => {
|
||||||
return
|
|
||||||
workList.value = []
|
|
||||||
let datacontent = item.datacontent;
|
|
||||||
let pptJson = "";
|
|
||||||
if(typeof datacontent === 'string') pptJson = JSON.parse(datacontent)
|
|
||||||
if(pptJson&&pptJson.activityContent) {
|
|
||||||
homeworklist({ids:pptJson.activityContent, pageSize: 100}).then( async res => {
|
|
||||||
// await formatClassWorkFile(res.rows)
|
|
||||||
await nextTick();
|
|
||||||
workList.value = [...res.rows]
|
|
||||||
console.log(workList.value,'workList.value');
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
const formatClassWorkFile = async (postData) => {
|
|
||||||
return new Promise(async (resolve, reject) => {
|
|
||||||
for (let i = 0; i < postData.length; i++) {
|
for (let i = 0; i < postData.length; i++) {
|
||||||
let item = postData[i];
|
let item = postData[i];
|
||||||
console.log("当前处理的元素:", item); // 新增这行,查看元素结构
|
|
||||||
switch (item.worktype) {
|
switch (item.worktype) {
|
||||||
case '框架梳理': {
|
case '框架梳理': {
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case '习题训练': {
|
case '习题训练': {
|
||||||
let workIds = item.quizlist.map(items => items.id).join(',');
|
console.log(item,'item');
|
||||||
let ress = await listEntpcoursework({ ids: workIds });
|
// let workIds = item.quizlist!.map(items => items.id).join(',');
|
||||||
processList(ress.rows);
|
// let ress = await listEntpcoursework({ ids: workIds });
|
||||||
|
// const arr = ress.rows.map((item:{id:number}) => {
|
||||||
|
// return item.id
|
||||||
|
// })
|
||||||
|
|
||||||
|
// processList(ress.rows);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case '课堂展示': {
|
case '课堂展示': {
|
||||||
item.base64 = JSON.parse(item.workcodes).base64;
|
// item.base64 = JSON.parse(item.workcodes).base64;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case '常规作业': {
|
case '常规作业': {
|
||||||
item.prevData = JSON.parse(item.workcodes);
|
// item.prevData = JSON.parse(item.workcodes);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// console.log(workList.value, 'workList.value');
|
const arr = paramData.value.activityContent.split(',')
|
||||||
|
arr.push(item.id.toString())
|
||||||
|
await PPTApi.updateSlide(paramData.value)
|
||||||
|
addWorkList(item)
|
||||||
}
|
}
|
||||||
await nextTick();
|
await nextTick();
|
||||||
resolve();
|
}
|
||||||
});
|
// 添加的活动回显到页面上面去
|
||||||
|
const addWorkList = (item: WorkItem) => {
|
||||||
|
workList.value.push(item)
|
||||||
}
|
}
|
||||||
// 删除作业
|
// 删除作业
|
||||||
const handleRemoveDemoActivityClassWork = (item) => {
|
const handleRemoveDemoActivityClassWork = (item: WorkItem) => {
|
||||||
ElMessageBox.confirm('是否确认删除?')
|
ElMessageBox.confirm('是否确认删除?')
|
||||||
.then(function () {
|
.then(() => {
|
||||||
workList.value.splice(workList.value.indexOf(item), 1);
|
workList.value.splice(workList.value.indexOf(item), 1);
|
||||||
})
|
})
|
||||||
.catch(() => { });
|
.catch(() => { });
|
||||||
}
|
}
|
||||||
|
|
||||||
// 获取tag的样式
|
// 获取tag的样式
|
||||||
const getTagType = (worktype) => {
|
const getTagType = (worktype: string): string => {
|
||||||
return type.value.find(item => item.label == worktype).value
|
return type.value.find(item => item.label === worktype)!.value
|
||||||
}
|
}
|
||||||
|
|
||||||
// 获取活动引用的列表数据
|
// 获取活动引用的列表数据
|
||||||
const initHomeWork = async () => {
|
const initHomeWork = async () => {
|
||||||
tasklist_loading.value = true;
|
tasklist_loading.value = true;
|
||||||
const { res, chapterId } = await useGetHomework(sessionStore.get('subject.curNode'));
|
const { res, chapterId } = await useGetHomework(sessionStore.get('subject.curNode'));
|
||||||
console.log(res,'res');
|
|
||||||
|
|
||||||
taskList.value = res;
|
taskList.value = res;
|
||||||
tasklist_loading.value = false;
|
tasklist_loading.value = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
// 多选活动引用
|
// 多选活动引用
|
||||||
const handleSelectionChange = (val) => {
|
const handleSelectionChange = (val: WorkItem[]) => {
|
||||||
console.log(val,'多选')
|
|
||||||
selectedWorkList.value = [...val]
|
selectedWorkList.value = [...val]
|
||||||
}
|
}
|
||||||
|
|
||||||
// 打开添加作业活动
|
// 打开添加作业活动
|
||||||
const showDialog = (item) => {
|
const showDialog = (item: string) => {
|
||||||
currentCourse.worktype = item
|
currentCourse.worktype = item
|
||||||
dialogVisible.value = true
|
dialogVisible.value = true
|
||||||
}
|
}
|
||||||
|
|
||||||
const openList = () => {
|
const openList = () => {
|
||||||
activeVisible.value = true
|
activeVisible.value = true
|
||||||
initHomeWork()
|
initHomeWork()
|
||||||
}
|
}
|
||||||
|
|
||||||
// 添加活动引用列表作业
|
// 添加活动引用列表作业
|
||||||
const save = async () => {
|
const savePPtData = async () => {
|
||||||
console.log('添加了')
|
if (selectedWorkList.value.length === 0) {
|
||||||
if(!currentPPT.classWorkList){
|
ElMessage.warning('请选择活动')
|
||||||
currentPPT.classWorkList = [];
|
return
|
||||||
}
|
}
|
||||||
const arr = selectedWorkList.value.map(item => item.id)
|
const arr = selectedWorkList.value.map(item => item.id)
|
||||||
const classworkList = arr.join(',')
|
// 应该是新加而不是覆盖
|
||||||
// await formatClassWorkFile(selectedWorkList.value)
|
paramData.value.activityContent = arr.join(',')
|
||||||
updateSlide({activityContent:classworkList})
|
await PPTApi.updateSlide(paramData.value)
|
||||||
activeVisible.value = false
|
activeVisible.value = false
|
||||||
}
|
}
|
||||||
|
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
// console.log(sessionStore.get('subject.curBook'),'curBook');
|
const curNode = sessionStore.get('subject.curNode') as CourseNode
|
||||||
// console.log(sessionStore.get('subject.subjectTree'),'subjectTree');
|
|
||||||
// console.log(sessionStore.get('subject.bookList'),'bookList');
|
|
||||||
console.log(sessionStore.get('subject.curNode'),'curNode');
|
|
||||||
const curNode = sessionStore.get('subject.curNode')
|
|
||||||
currentCourse.textbookId = curNode.rootid
|
currentCourse.textbookId = curNode.rootid
|
||||||
currentCourse.levelFirstId = curNode.parentNode.id
|
currentCourse.levelFirstId = curNode.parentNode.id
|
||||||
currentCourse.levelSecondId = curNode.id
|
currentCourse.levelSecondId = curNode.id
|
||||||
currentCourse.coursetitle = curNode.itemtitle,
|
currentCourse.coursetitle = curNode.itemtitle
|
||||||
currentCourse.node = curNode
|
currentCourse.node = curNode
|
||||||
listEntpcoursefile(params).then((res) => {
|
listEntpcoursefile(params).then((res: { rows: WorkItem[] }) => {
|
||||||
dataList.value = [...res.rows]
|
dataList.value = [...res.rows]
|
||||||
})
|
})
|
||||||
|
objItem.value = workItem.value[slideIndex.value]
|
||||||
|
getCurrentPPtData()
|
||||||
})
|
})
|
||||||
|
watch(() => slideIndex.value, () => {
|
||||||
|
getCurrentPPtData()
|
||||||
|
})
|
||||||
|
// 获取当前ppt页的数据
|
||||||
|
const getCurrentPPtData = async () => {
|
||||||
|
workList.value = []
|
||||||
|
objItem.value = workItem.value[slideIndex.value]
|
||||||
|
paramData.value.id = objItem.value.id
|
||||||
|
if (objItem.value?.activityContent) {
|
||||||
|
paramData.value.activityContent = objItem.value?.activityContent
|
||||||
|
const res = await homeworklist({ ids: objItem.value?.activityContent, pageSize: 100 })
|
||||||
|
await formatClassWorkFile(res.rows)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// 接收习题训练的值
|
// 接收习题训练的值
|
||||||
const getData = async (data) => {
|
const getData = async (data: WorkItem) => {
|
||||||
console.log(data, 'data')
|
console.log(data, 'data')
|
||||||
await formatClassWorkFile([data])
|
await formatClassWorkFile([data])
|
||||||
}
|
}
|
||||||
defineExpose({
|
|
||||||
clickPPTList
|
|
||||||
})
|
|
||||||
</script>
|
</script>
|
||||||
<style scoped lang="scss">
|
<style scoped lang="scss">
|
||||||
.buttonDiv{
|
.buttonDiv{
|
||||||
|
|
|
@ -461,11 +461,8 @@ const handleClassWorkFormQuizRemove = (index) =>{
|
||||||
await nextTick(); // 确保DOM更新完成
|
await nextTick(); // 确保DOM更新完成
|
||||||
proxy.$refs["classWorkFormRef"].validate(async valid => {
|
proxy.$refs["classWorkFormRef"].validate(async valid => {
|
||||||
if (valid) {
|
if (valid) {
|
||||||
if(!isShow.value){
|
|
||||||
//
|
|
||||||
// const { chapterId } = await useGetHomework(courseObj.node)
|
// const { chapterId } = await useGetHomework(courseObj.node)
|
||||||
// this.entpcourseid = chapterId
|
// this.entpcourseid = chapterId
|
||||||
debugger
|
|
||||||
const cform = {
|
const cform = {
|
||||||
id: 0,
|
id: 0,
|
||||||
workdate: classWorkForm.workdate, // //作业类型?web端这里貌似没有这个时间
|
workdate: classWorkForm.workdate, // //作业类型?web端这里貌似没有这个时间
|
||||||
|
@ -509,7 +506,7 @@ const handleClassWorkFormQuizRemove = (index) =>{
|
||||||
cform.workcodes = JSON.stringify({json: canvasJson, base64: canvasBase64});
|
cform.workcodes = JSON.stringify({json: canvasJson, base64: canvasBase64});
|
||||||
cform.entpcourseworklist = JSON.stringify([{'id':-1, 'score': '10'}]);
|
cform.entpcourseworklist = JSON.stringify([{'id':-1, 'score': '10'}]);
|
||||||
try {
|
try {
|
||||||
addClassworkReturnId(cform).then(() => {
|
addClassworkReturnId(cform).then((res) => {
|
||||||
ElMessage({ type: 'success', message: '作业设计成功!'});
|
ElMessage({ type: 'success', message: '作业设计成功!'});
|
||||||
// 重置提交表单
|
// 重置提交表单
|
||||||
classWorkForm.worktype = "课堂展示";
|
classWorkForm.worktype = "课堂展示";
|
||||||
|
@ -521,7 +518,8 @@ const handleClassWorkFormQuizRemove = (index) =>{
|
||||||
// 情况选择的资源缓存
|
// 情况选择的资源缓存
|
||||||
classWorkForm.chooseWorkLists = []; // 框架梳理list
|
classWorkForm.chooseWorkLists = []; // 框架梳理list
|
||||||
classWorkForm.whiteboardObj = ''; // ? // 清空白板
|
classWorkForm.whiteboardObj = ''; // ? // 清空白板
|
||||||
|
classWorkForm.id = res
|
||||||
|
emits('getData',classWorkForm)
|
||||||
boardLoading.value = false
|
boardLoading.value = false
|
||||||
})
|
})
|
||||||
} finally {
|
} finally {
|
||||||
|
@ -533,7 +531,7 @@ const handleClassWorkFormQuizRemove = (index) =>{
|
||||||
cform.workcodes = JSON.stringify(classWorkForm.fileHomeworkList);
|
cform.workcodes = JSON.stringify(classWorkForm.fileHomeworkList);
|
||||||
cform.entpcourseworklist = JSON.stringify([{'id':-2, 'score': '10'}]);
|
cform.entpcourseworklist = JSON.stringify([{'id':-2, 'score': '10'}]);
|
||||||
try {
|
try {
|
||||||
addClassworkReturnId(cform).then(() => {
|
addClassworkReturnId(cform).then((res) => {
|
||||||
ElMessage({ type: 'success', message: '作业设计成功!'});
|
ElMessage({ type: 'success', message: '作业设计成功!'});
|
||||||
// 重置提交表单
|
// 重置提交表单
|
||||||
classWorkForm.worktype = "常规作业";
|
classWorkForm.worktype = "常规作业";
|
||||||
|
@ -545,7 +543,8 @@ const handleClassWorkFormQuizRemove = (index) =>{
|
||||||
classWorkForm.chooseWorkLists = []; // 框架梳理list
|
classWorkForm.chooseWorkLists = []; // 框架梳理list
|
||||||
classWorkForm.whiteboardObj = ''; // ? // 清空白板
|
classWorkForm.whiteboardObj = ''; // ? // 清空白板
|
||||||
classWorkForm.fileHomeworkList = []; // 常规作业list
|
classWorkForm.fileHomeworkList = []; // 常规作业list
|
||||||
|
classWorkForm.id = res
|
||||||
|
emits('getData',classWorkForm)
|
||||||
fileLoading.value = false
|
fileLoading.value = false
|
||||||
})
|
})
|
||||||
} finally {
|
} finally {
|
||||||
|
@ -576,7 +575,7 @@ const handleClassWorkFormQuizRemove = (index) =>{
|
||||||
console.log(cform,'提交的数据');
|
console.log(cform,'提交的数据');
|
||||||
if(cform.entpcourseworklist == '') return ElMessage({ type: 'warning', message: '请先添加作业资源!'});
|
if(cform.entpcourseworklist == '') return ElMessage({ type: 'warning', message: '请先添加作业资源!'});
|
||||||
|
|
||||||
addClassworkReturnId(cform).then(workres => {
|
addClassworkReturnId(cform).then(res => {
|
||||||
ElMessage({ type: 'success', message: '作业设计成功!'});
|
ElMessage({ type: 'success', message: '作业设计成功!'});
|
||||||
// 重置提交表单
|
// 重置提交表单
|
||||||
classWorkForm.worktype = "习题训练";
|
classWorkForm.worktype = "习题训练";
|
||||||
|
@ -587,6 +586,8 @@ const handleClassWorkFormQuizRemove = (index) =>{
|
||||||
// 情况选择的资源缓存
|
// 情况选择的资源缓存
|
||||||
classWorkForm.chooseWorkLists = [];
|
classWorkForm.chooseWorkLists = [];
|
||||||
classWorkForm.whiteboardObj = ''; // ? // 清空白板
|
classWorkForm.whiteboardObj = ''; // ? // 清空白板
|
||||||
|
classWorkForm.id = res
|
||||||
|
emits('getData',classWorkForm)
|
||||||
// refresh the list
|
// refresh the list
|
||||||
//这里分离了,所以不需要更新表单数据了
|
//这里分离了,所以不需要更新表单数据了
|
||||||
// this.getClassWorkAllList();
|
// this.getClassWorkAllList();
|
||||||
|
@ -606,10 +607,7 @@ const handleClassWorkFormQuizRemove = (index) =>{
|
||||||
// // 首页进入的,跳转到作业布置页面
|
// // 首页进入的,跳转到作业布置页面
|
||||||
// router.push({ path: '/classTaskAssign' });
|
// router.push({ path: '/classTaskAssign' });
|
||||||
// }
|
// }
|
||||||
}else{
|
|
||||||
console.log(11111);
|
|
||||||
emits('getData',classWorkForm)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue