|
@@ -7,7 +7,8 @@ import {
|
|
|
Transition,
|
|
|
computed,
|
|
|
nextTick,
|
|
|
- watch
|
|
|
+ watch,
|
|
|
+ toRef
|
|
|
} from 'vue';
|
|
|
import styles from './index.module.less';
|
|
|
import 'plyr/dist/plyr.css';
|
|
@@ -67,13 +68,16 @@ import rightIconMetronome from './image/right_icon5.png';
|
|
|
import rightIconTuner from './image/right_icon6.png';
|
|
|
import rightIconTimer from './image/right_icon7.png';
|
|
|
import rightIconCall from './image/right_icon10.png';
|
|
|
-import rightIconPackUp from './image/right_icon8.png';
|
|
|
+import rightIconPackUp from './image/right_icon11.png';
|
|
|
+import leftIconPackUp from './image/right_icon8.png';
|
|
|
import rightIconMusic from './image/right_icon9.png';
|
|
|
import bottomIconSwitch from './image/bottom_icon1.png';
|
|
|
import bottomIconResource from './image/bottom_icon2.png';
|
|
|
import bottomIconPre from './image/bottom_icon3.png';
|
|
|
import bottomIconNext from './image/bottom_icon4.png';
|
|
|
+import rightIconTool from './image/right_icon12.png';
|
|
|
import rightHideIcon from './image/right_hide_icon.png';
|
|
|
+import leftHideIcon from './image/left_hide_icon.png';
|
|
|
import SelectResources from '../prepare-lessons/model/select-resources';
|
|
|
import { getStudentAfterWork, getStudentList } from '../studentList/api';
|
|
|
import TheNoticeBar from '/src/components/TheNoticeBar';
|
|
@@ -90,6 +94,8 @@ import ResourceMain from '../prepare-lessons/components/resource-main';
|
|
|
import { useResizeObserver } from '@vueuse/core';
|
|
|
import { storage } from '/src/utils/storage';
|
|
|
import { ACCESS_TOKEN_ADMIN } from '/src/store/mutation-types';
|
|
|
+import useDrag from '@/hooks/useDrag';
|
|
|
+import Dragbom from '@/hooks/useDrag/dragbom';
|
|
|
|
|
|
export type ToolType = 'init' | 'pen' | 'whiteboard' | 'call';
|
|
|
export type ToolItem = {
|
|
@@ -193,6 +199,7 @@ export default defineComponent({
|
|
|
selectClassStatus: false, // 选择课件
|
|
|
homeworkStatus: true, // 布置作业完成时
|
|
|
removeVisiable: false,
|
|
|
+ nextEndShow: false,
|
|
|
removeTitle: '',
|
|
|
removeContent: '',
|
|
|
removeCourseStatus: false, // 是否布置作业
|
|
@@ -351,7 +358,16 @@ export default defineComponent({
|
|
|
getDetail();
|
|
|
getLessonCoursewareDetail();
|
|
|
if (data.type === 'preview') {
|
|
|
- rightList.splice(6, 1);
|
|
|
+ // 预览隐藏点名和布置作业
|
|
|
+ const hideListIds = [2, 10];
|
|
|
+ let index = rightList.length - 1;
|
|
|
+ while (index >= 0) {
|
|
|
+ if (hideListIds.includes(rightList[index].id)) {
|
|
|
+ console.log(index);
|
|
|
+ rightList.splice(index, 1);
|
|
|
+ }
|
|
|
+ index--;
|
|
|
+ }
|
|
|
}
|
|
|
rollCallStudentList();
|
|
|
});
|
|
@@ -399,7 +415,6 @@ export default defineComponent({
|
|
|
}, 200);
|
|
|
}
|
|
|
);
|
|
|
-
|
|
|
const formatParentId = (id: any, list: any, ids = [] as any) => {
|
|
|
for (const item of list) {
|
|
|
if (item.knowledgeList && item.knowledgeList.length > 0) {
|
|
@@ -814,74 +829,76 @@ export default defineComponent({
|
|
|
handleSwipeChange(popupData.activeIndex + 1);
|
|
|
return;
|
|
|
}
|
|
|
+ data.nextEndShow = true;
|
|
|
+ }
|
|
|
+ };
|
|
|
+ // 当前课件结束之后选择下一个课件
|
|
|
+ function handleNextEnd() {
|
|
|
+ // 获取当前是哪个章节
|
|
|
+ let detailIndex = popupData.chapterDetails.findIndex(
|
|
|
+ (item: any) => item.id == data.lessonCoursewareDetailId
|
|
|
+ );
|
|
|
+ const detailItem =
|
|
|
+ popupData.chapterDetails[detailIndex]?.knowledgeList || [];
|
|
|
+ let lessonIndex = detailItem.findIndex(
|
|
|
+ (item: any) => item.id == data.detailId
|
|
|
+ );
|
|
|
|
|
|
- // 获取当前是哪个章节
|
|
|
- let detailIndex = popupData.chapterDetails.findIndex(
|
|
|
- (item: any) => item.id == data.lessonCoursewareDetailId
|
|
|
- );
|
|
|
- const detailItem =
|
|
|
- popupData.chapterDetails[detailIndex]?.knowledgeList || [];
|
|
|
- let lessonIndex = detailItem.findIndex(
|
|
|
- (item: any) => item.id == data.detailId
|
|
|
- );
|
|
|
-
|
|
|
- let lessonStatus = false; // 当前章节下面是否有内容
|
|
|
- let lessonCoursewareDetailId = '';
|
|
|
- let coursewareDetailKnowledgeId = '';
|
|
|
- while (lessonIndex < detailItem.length - 1) {
|
|
|
- lessonIndex++;
|
|
|
- if (lessonIndex >= 0) {
|
|
|
- if (detailItem[lessonIndex].coursewareNum > 0) {
|
|
|
- lessonStatus = true;
|
|
|
- lessonCoursewareDetailId =
|
|
|
- detailItem[lessonIndex].lessonCoursewareDetailId;
|
|
|
- coursewareDetailKnowledgeId = detailItem[lessonIndex].id;
|
|
|
- }
|
|
|
- }
|
|
|
- if (lessonStatus) {
|
|
|
- break;
|
|
|
+ let lessonStatus = false; // 当前章节下面是否有内容
|
|
|
+ let lessonCoursewareDetailId = '';
|
|
|
+ let coursewareDetailKnowledgeId = '';
|
|
|
+ while (lessonIndex < detailItem.length - 1) {
|
|
|
+ lessonIndex++;
|
|
|
+ if (lessonIndex >= 0) {
|
|
|
+ if (detailItem[lessonIndex].coursewareNum > 0) {
|
|
|
+ lessonStatus = true;
|
|
|
+ lessonCoursewareDetailId =
|
|
|
+ detailItem[lessonIndex].lessonCoursewareDetailId;
|
|
|
+ coursewareDetailKnowledgeId = detailItem[lessonIndex].id;
|
|
|
}
|
|
|
}
|
|
|
- // 判断当前章节下面课程是否有内容,否则往下一个章节走
|
|
|
if (lessonStatus) {
|
|
|
- popupData.courseId = coursewareDetailKnowledgeId;
|
|
|
- data.selectClassStatus = true;
|
|
|
- return;
|
|
|
+ break;
|
|
|
}
|
|
|
+ }
|
|
|
+ // 判断当前章节下面课程是否有内容,否则往下一个章节走
|
|
|
+ if (lessonStatus) {
|
|
|
+ popupData.courseId = coursewareDetailKnowledgeId;
|
|
|
+ data.selectClassStatus = true;
|
|
|
+ return;
|
|
|
+ }
|
|
|
|
|
|
- let nextLessonStatus = false;
|
|
|
- while (detailIndex <= popupData.chapterDetails.length - 1) {
|
|
|
- detailIndex++;
|
|
|
- const tempDetail =
|
|
|
- popupData.chapterDetails[detailIndex]?.knowledgeList || [];
|
|
|
- let tempLessonLength = 0;
|
|
|
- while (tempLessonLength <= tempDetail.length - 1) {
|
|
|
- if (tempDetail[tempLessonLength].coursewareNum > 0) {
|
|
|
- nextLessonStatus = true;
|
|
|
- lessonCoursewareDetailId =
|
|
|
- tempDetail[tempLessonLength].lessonCoursewareDetailId;
|
|
|
- coursewareDetailKnowledgeId = tempDetail[tempLessonLength].id;
|
|
|
- }
|
|
|
- tempLessonLength++;
|
|
|
- if (nextLessonStatus) {
|
|
|
- break;
|
|
|
- }
|
|
|
+ let nextLessonStatus = false;
|
|
|
+ while (detailIndex <= popupData.chapterDetails.length - 1) {
|
|
|
+ detailIndex++;
|
|
|
+ const tempDetail =
|
|
|
+ popupData.chapterDetails[detailIndex]?.knowledgeList || [];
|
|
|
+ let tempLessonLength = 0;
|
|
|
+ while (tempLessonLength <= tempDetail.length - 1) {
|
|
|
+ if (tempDetail[tempLessonLength].coursewareNum > 0) {
|
|
|
+ nextLessonStatus = true;
|
|
|
+ lessonCoursewareDetailId =
|
|
|
+ tempDetail[tempLessonLength].lessonCoursewareDetailId;
|
|
|
+ coursewareDetailKnowledgeId = tempDetail[tempLessonLength].id;
|
|
|
}
|
|
|
-
|
|
|
+ tempLessonLength++;
|
|
|
if (nextLessonStatus) {
|
|
|
break;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- // 判断当前章节下面课程是否有内容,否则往上一个章节走
|
|
|
if (nextLessonStatus) {
|
|
|
- popupData.courseId = coursewareDetailKnowledgeId;
|
|
|
- data.selectClassStatus = true;
|
|
|
- return;
|
|
|
+ break;
|
|
|
}
|
|
|
}
|
|
|
- };
|
|
|
|
|
|
+ // 判断当前章节下面课程是否有内容,否则往上一个章节走
|
|
|
+ if (nextLessonStatus) {
|
|
|
+ popupData.courseId = coursewareDetailKnowledgeId;
|
|
|
+ data.selectClassStatus = true;
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ }
|
|
|
/** 弹窗关闭 */
|
|
|
const handleClosePopup = () => {
|
|
|
const item = data.itemList[popupData.activeIndex];
|
|
@@ -894,11 +911,11 @@ export default defineComponent({
|
|
|
}
|
|
|
};
|
|
|
document.body.addEventListener('keyup', (e: KeyboardEvent) => {
|
|
|
- if (e.code === 'ArrowLeft') {
|
|
|
+ if (e.code === 'ArrowUp') {
|
|
|
// if (popupData.activeIndex === 0) return;
|
|
|
setModalOpen();
|
|
|
handlePreAndNext('up');
|
|
|
- } else if (e.code === 'ArrowRight') {
|
|
|
+ } else if (e.code === 'ArrowDown') {
|
|
|
// if (popupData.activeIndex === data.itemList.length - 1) return;
|
|
|
setModalOpen();
|
|
|
handlePreAndNext('down');
|
|
@@ -1166,36 +1183,30 @@ export default defineComponent({
|
|
|
// 右侧菜单栏
|
|
|
const rightList = reactive([
|
|
|
{
|
|
|
- name: '曲目资源',
|
|
|
- name2: '曲目资源',
|
|
|
- icon: rightIconMusic,
|
|
|
- id: 9
|
|
|
+ name: '上一张',
|
|
|
+ icon: bottomIconPre,
|
|
|
+ id: 11
|
|
|
},
|
|
|
{
|
|
|
- name: '批注',
|
|
|
- icon: rightIconPostil,
|
|
|
- id: 3
|
|
|
+ name: '下一张',
|
|
|
+ icon: bottomIconNext,
|
|
|
+ id: 12
|
|
|
},
|
|
|
{
|
|
|
- name: '白板',
|
|
|
- icon: rightIconWhiteboard,
|
|
|
- id: 4
|
|
|
+ name: '切换章节',
|
|
|
+ icon: bottomIconSwitch,
|
|
|
+ id: 13
|
|
|
},
|
|
|
{
|
|
|
- name: '节拍器',
|
|
|
- icon: rightIconMetronome,
|
|
|
- id: 5
|
|
|
+ name: '资源列表',
|
|
|
+ icon: bottomIconResource,
|
|
|
+ id: 14
|
|
|
},
|
|
|
{
|
|
|
- name: '计时器',
|
|
|
- icon: rightIconTimer,
|
|
|
- id: 7
|
|
|
+ name: '曲目资源',
|
|
|
+ icon: rightIconMusic,
|
|
|
+ id: 9
|
|
|
},
|
|
|
- // {
|
|
|
- // name: '调音器',
|
|
|
- // icon: rightIconTuner,
|
|
|
- // id: 6
|
|
|
- // },
|
|
|
{
|
|
|
name: '点名',
|
|
|
icon: rightIconCall,
|
|
@@ -1207,6 +1218,11 @@ export default defineComponent({
|
|
|
id: 2
|
|
|
},
|
|
|
{
|
|
|
+ name: '工具箱',
|
|
|
+ icon: rightIconTool,
|
|
|
+ id: 15
|
|
|
+ },
|
|
|
+ {
|
|
|
name: '结束课程',
|
|
|
name2: '结束预览',
|
|
|
icon: rightIconEnd,
|
|
@@ -1214,40 +1230,55 @@ export default defineComponent({
|
|
|
},
|
|
|
{
|
|
|
name: '收起',
|
|
|
- icon: rightIconPackUp,
|
|
|
+ icon: leftIconPackUp,
|
|
|
id: 8
|
|
|
}
|
|
|
]);
|
|
|
-
|
|
|
- // 底部菜单栏
|
|
|
- const bottomList = reactive([
|
|
|
+ const tooltipList = [
|
|
|
{
|
|
|
- name: '切换章节',
|
|
|
- icon: bottomIconSwitch,
|
|
|
- id: 1
|
|
|
+ name: '节拍器',
|
|
|
+ icon: rightIconMetronome,
|
|
|
+ id: 5
|
|
|
},
|
|
|
{
|
|
|
- name: '资源列表',
|
|
|
- icon: bottomIconResource,
|
|
|
- id: 2
|
|
|
+ name: '计时器',
|
|
|
+ icon: rightIconTimer,
|
|
|
+ id: 7
|
|
|
},
|
|
|
{
|
|
|
- name: '上一张',
|
|
|
- icon: bottomIconPre,
|
|
|
+ name: '批注',
|
|
|
+ icon: rightIconPostil,
|
|
|
id: 3
|
|
|
},
|
|
|
{
|
|
|
- name: '下一张',
|
|
|
- icon: bottomIconNext,
|
|
|
+ name: '白板',
|
|
|
+ icon: rightIconWhiteboard,
|
|
|
id: 4
|
|
|
}
|
|
|
- ]);
|
|
|
+ // {
|
|
|
+ // name: '调音器',
|
|
|
+ // icon: rightIconTuner,
|
|
|
+ // id: 6
|
|
|
+ // }
|
|
|
+ ];
|
|
|
// 默认收起菜单
|
|
|
- const rightColumnShow = ref(false);
|
|
|
-
|
|
|
+ const columnShow = ref(true);
|
|
|
+ // 菜单位置
|
|
|
+ const columnPos = ref<'left' | 'right'>('left');
|
|
|
+ watch(columnPos, () => {
|
|
|
+ for (let i = 0; i < data.itemList.length; i++) {
|
|
|
+ const activeItem = data.itemList[i];
|
|
|
+ if (['RHYTHM', 'MUSIC'].includes(activeItem.type)) {
|
|
|
+ activeItem.iframeRef?.contentWindow?.postMessage(
|
|
|
+ { api: 'imagePos', data: columnPos.value },
|
|
|
+ '*'
|
|
|
+ );
|
|
|
+ }
|
|
|
+ }
|
|
|
+ });
|
|
|
// 右边栏操作
|
|
|
const operateRightBtn = async (id: number) => {
|
|
|
- if (id !== 8) {
|
|
|
+ if (![8, 11, 12, 13, 14].includes(id)) {
|
|
|
handleStop(false);
|
|
|
}
|
|
|
|
|
@@ -1328,7 +1359,7 @@ export default defineComponent({
|
|
|
startShowModal('setTimeIcon');
|
|
|
break;
|
|
|
case 8:
|
|
|
- rightColumnShow.value = false;
|
|
|
+ columnShow.value = false;
|
|
|
break;
|
|
|
case 9:
|
|
|
// 选择曲目时需要暂停所有播放
|
|
@@ -1347,6 +1378,23 @@ export default defineComponent({
|
|
|
return;
|
|
|
}
|
|
|
break;
|
|
|
+ case 11:
|
|
|
+ if (!isUpArrow.value) return;
|
|
|
+ handlePreAndNext('up');
|
|
|
+ break;
|
|
|
+ case 12:
|
|
|
+ if (!isDownArrow.value) return;
|
|
|
+ handlePreAndNext('down');
|
|
|
+ break;
|
|
|
+ case 13:
|
|
|
+ popupData.chapterOpen = true;
|
|
|
+ break;
|
|
|
+ case 14:
|
|
|
+ popupData.open = true;
|
|
|
+ nextTick(() => {
|
|
|
+ scrollResourceSection();
|
|
|
+ });
|
|
|
+ break;
|
|
|
default:
|
|
|
break;
|
|
|
}
|
|
@@ -1378,31 +1426,6 @@ export default defineComponent({
|
|
|
}
|
|
|
};
|
|
|
|
|
|
- // 底部悬浮按钮操作
|
|
|
- const operateBottomBtn = (id: number) => {
|
|
|
- switch (id) {
|
|
|
- case 1:
|
|
|
- popupData.chapterOpen = true;
|
|
|
- break;
|
|
|
- case 2:
|
|
|
- popupData.open = true;
|
|
|
- nextTick(() => {
|
|
|
- scrollResourceSection();
|
|
|
- });
|
|
|
- break;
|
|
|
- case 3:
|
|
|
- if (!isUpArrow.value) return;
|
|
|
- handlePreAndNext('up');
|
|
|
- break;
|
|
|
- case 4:
|
|
|
- if (!isDownArrow.value) return;
|
|
|
- handlePreAndNext('down');
|
|
|
- break;
|
|
|
- default:
|
|
|
- break;
|
|
|
- }
|
|
|
- };
|
|
|
-
|
|
|
// 滚动到某个元素的位置
|
|
|
const scrollResourceSection = () => {
|
|
|
const drawerCardItemRefs =
|
|
@@ -1426,6 +1449,112 @@ export default defineComponent({
|
|
|
}
|
|
|
};
|
|
|
|
|
|
+ /* 弹窗加拖动 */
|
|
|
+ // 选择课件弹窗
|
|
|
+ const selCourBoxClass = 'selCourBoxClass_drag';
|
|
|
+ const selCourDragData = useDrag(
|
|
|
+ [`${selCourBoxClass}>.n-card-header`, `${selCourBoxClass} .bom_drag`],
|
|
|
+ selCourBoxClass,
|
|
|
+ toRef(data, 'selectClassStatus'),
|
|
|
+ users.info.id
|
|
|
+ );
|
|
|
+ // 选择资源弹窗
|
|
|
+ const selResourBoxClass = 'selResourBoxClass_drag';
|
|
|
+ const selResourDragData = useDrag(
|
|
|
+ [
|
|
|
+ `${selResourBoxClass} .select-resource>.n-tabs>.n-tabs-nav--top.n-tabs-nav`,
|
|
|
+ `${selResourBoxClass} .bom_drag`
|
|
|
+ ],
|
|
|
+ selResourBoxClass,
|
|
|
+ toRef(data, 'selectResourceStatus'),
|
|
|
+ users.info.id
|
|
|
+ );
|
|
|
+ // 结束预览 结束课程确认弹窗
|
|
|
+ const removeResourBoxClass = 'removeResourBoxClass_drag';
|
|
|
+ const removeResourDragData = useDrag(
|
|
|
+ [
|
|
|
+ `${removeResourBoxClass}>.n-card-header`,
|
|
|
+ `${removeResourBoxClass} .bom_drag`
|
|
|
+ ],
|
|
|
+ removeResourBoxClass,
|
|
|
+ toRef(data, 'removeVisiable'),
|
|
|
+ users.info.id
|
|
|
+ );
|
|
|
+ // 章节next弹窗
|
|
|
+ const nextEndBoxClass = 'nextEndBoxClass_drag';
|
|
|
+ const nextEndBoxDragData = useDrag(
|
|
|
+ [`${nextEndBoxClass}>.n-card-header`, `${nextEndBoxClass} .bom_drag`],
|
|
|
+ nextEndBoxClass,
|
|
|
+ toRef(data, 'nextEndShow'),
|
|
|
+ users.info.id
|
|
|
+ );
|
|
|
+ // 章节切换弹窗
|
|
|
+ const chapterConBoxClass = 'chapterConBoxClass_drag';
|
|
|
+ const chapterConBoxDragData = useDrag(
|
|
|
+ [
|
|
|
+ `${chapterConBoxClass}>.n-card-header`,
|
|
|
+ `${chapterConBoxClass} .bom_drag`
|
|
|
+ ],
|
|
|
+ chapterConBoxClass,
|
|
|
+ toRef(popupData, 'chapterOpen'),
|
|
|
+ users.info.id
|
|
|
+ );
|
|
|
+ // 资源列表弹窗
|
|
|
+ const resourcesConBoxClass = 'resourcesConBoxClass_drag';
|
|
|
+ const resourcesConDragData = useDrag(
|
|
|
+ [
|
|
|
+ `${resourcesConBoxClass}>.n-card-header`,
|
|
|
+ `${resourcesConBoxClass} .bom_drag`
|
|
|
+ ],
|
|
|
+ resourcesConBoxClass,
|
|
|
+ toRef(popupData, 'open'),
|
|
|
+ users.info.id
|
|
|
+ );
|
|
|
+ // 计时器
|
|
|
+ const timerMeterConBoxClass = 'timerMeterConBoxClass_drag';
|
|
|
+ const timerMeterConDragData = useDrag(
|
|
|
+ [
|
|
|
+ `${timerMeterConBoxClass}>.n-card-header`,
|
|
|
+ `${timerMeterConBoxClass} .bom_drag`
|
|
|
+ ],
|
|
|
+ timerMeterConBoxClass,
|
|
|
+ showModalTime,
|
|
|
+ users.info.id
|
|
|
+ );
|
|
|
+ // 节拍器
|
|
|
+ const metronomeConBoxClass = 'metronomeConBoxClass_drag';
|
|
|
+ const metronomeConBoxDragData = useDrag(
|
|
|
+ [
|
|
|
+ `${metronomeConBoxClass}>.n-card-header`,
|
|
|
+ `${metronomeConBoxClass} .bom_drag`
|
|
|
+ ],
|
|
|
+ metronomeConBoxClass,
|
|
|
+ showModalBeat,
|
|
|
+ users.info.id
|
|
|
+ );
|
|
|
+ // 布置作业弹窗
|
|
|
+ const modelTrainStatusConBoxClass = 'modelTrainStatusConBoxClass_drag';
|
|
|
+ const modelTrainStatusConBoxDragData = useDrag(
|
|
|
+ [
|
|
|
+ `${modelTrainStatusConBoxClass}>.n-card-header`,
|
|
|
+ `${modelTrainStatusConBoxClass} .bom_drag`
|
|
|
+ ],
|
|
|
+ modelTrainStatusConBoxClass,
|
|
|
+ toRef(data, 'modelTrainStatus'),
|
|
|
+ users.info.id
|
|
|
+ );
|
|
|
+ // 布置作业课后作业
|
|
|
+ const modelTrainHomeWordConBoxClass =
|
|
|
+ 'modelTrainHomeWordConBoxClassBoxClass_drag';
|
|
|
+ const modelTrainHomeWordConBoxDragData = useDrag(
|
|
|
+ [
|
|
|
+ `${modelTrainHomeWordConBoxClass}>.n-card-header`,
|
|
|
+ `${modelTrainHomeWordConBoxClass} .bom_drag`
|
|
|
+ ],
|
|
|
+ modelTrainHomeWordConBoxClass,
|
|
|
+ toRef(data, 'modelAttendStatus'),
|
|
|
+ users.info.id
|
|
|
+ );
|
|
|
return () => (
|
|
|
<div id="playContent" class={[styles.playContent, 'wrap']}>
|
|
|
<div
|
|
@@ -1457,6 +1586,7 @@ export default defineComponent({
|
|
|
}
|
|
|
class={styles.itemDiv}>
|
|
|
<VideoPlay
|
|
|
+ imagePos={columnPos.value}
|
|
|
ref={(el: any) => (data.videoItemRef = el)}
|
|
|
item={activeVideoItem.value}
|
|
|
showModel={activeData.model}
|
|
@@ -1586,6 +1716,7 @@ export default defineComponent({
|
|
|
<img src={m.content} />
|
|
|
) : m.type === 'SONG' ? (
|
|
|
<AudioPay
|
|
|
+ imagePos={columnPos.value}
|
|
|
item={m}
|
|
|
activeStatus={popupData.activeIndex === mIndex}
|
|
|
ref={(v: any) => (data.audioRefs[mIndex] = v)}
|
|
@@ -1629,6 +1760,7 @@ export default defineComponent({
|
|
|
<RhythmModal
|
|
|
item={m}
|
|
|
activeStatus={popupData.activeIndex === mIndex}
|
|
|
+ imagePos={columnPos.value}
|
|
|
onSetIframe={(el: any) => {
|
|
|
m.iframeRef = el;
|
|
|
}}
|
|
@@ -1690,74 +1822,133 @@ export default defineComponent({
|
|
|
<div
|
|
|
class={[
|
|
|
styles.rightColumn,
|
|
|
- !rightColumnShow.value ? styles.rightColumnHide : '',
|
|
|
- studyData.type !== 'init' &&
|
|
|
- (studyData.penShow || studyData.whiteboardShow)
|
|
|
- ? styles.rightColumnZ
|
|
|
- : ''
|
|
|
+ columnShow.value && columnPos.value === 'right'
|
|
|
+ ? ''
|
|
|
+ : styles.rightColumnHide
|
|
|
]}>
|
|
|
- {rightList.map((item: any, index: number) => (
|
|
|
- <div
|
|
|
- class={[
|
|
|
- styles.rightItem,
|
|
|
- (item.id === 2 && data.preStudentNum <= 0) ||
|
|
|
- (item.id === 10 && studyData.callStudentList.length <= 0)
|
|
|
- ? styles.itemDisabled
|
|
|
- : '',
|
|
|
- item.id === 10 && !data.classId ? styles.itemHide : ''
|
|
|
- ]}
|
|
|
- onClick={() => operateRightBtn(item.id)}>
|
|
|
- <NTooltip showArrow={false} placement="left">
|
|
|
- {{
|
|
|
- trigger: () => <img src={item.icon} />,
|
|
|
- default: (
|
|
|
- <>
|
|
|
- {index === rightList.length - 2 && data.type === 'preview'
|
|
|
- ? item.name2
|
|
|
- : item.name}
|
|
|
- </>
|
|
|
- )
|
|
|
- }}
|
|
|
- </NTooltip>
|
|
|
+ {rightList.map((item: any) => (
|
|
|
+ <div class={styles.columnItemBox}>
|
|
|
+ <div
|
|
|
+ class={[
|
|
|
+ styles.columnItem,
|
|
|
+ (item.id === 2 && data.preStudentNum <= 0) ||
|
|
|
+ (item.id === 10 && studyData.callStudentList.length <= 0) ||
|
|
|
+ (item.id === 11 && !isUpArrow.value) ||
|
|
|
+ (item.id === 12 && !isDownArrow.value)
|
|
|
+ ? styles.itemDisabled
|
|
|
+ : ''
|
|
|
+ ]}
|
|
|
+ onClick={() => operateRightBtn(item.id)}>
|
|
|
+ <NTooltip
|
|
|
+ showArrow={false}
|
|
|
+ placement="left"
|
|
|
+ class={[
|
|
|
+ item.id === 15
|
|
|
+ ? 'columnItemTooltip rightColumnItemTooltip'
|
|
|
+ : ''
|
|
|
+ ]}>
|
|
|
+ {{
|
|
|
+ trigger: () => (
|
|
|
+ <img src={item.id === 8 ? rightIconPackUp : item.icon} />
|
|
|
+ ),
|
|
|
+ default: () =>
|
|
|
+ item.id === 15 ? (
|
|
|
+ <div class="tools">
|
|
|
+ {tooltipList.map(i => (
|
|
|
+ <div onClick={() => operateRightBtn(i.id)}>
|
|
|
+ <img src={i.icon} />
|
|
|
+ <div class="tit">{i.name}</div>
|
|
|
+ </div>
|
|
|
+ ))}
|
|
|
+ </div>
|
|
|
+ ) : item.id === 1 && data.type === 'preview' ? (
|
|
|
+ item.name2
|
|
|
+ ) : (
|
|
|
+ item.name
|
|
|
+ )
|
|
|
+ }}
|
|
|
+ </NTooltip>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
))}
|
|
|
</div>
|
|
|
- {!rightColumnShow.value && (
|
|
|
- <img
|
|
|
- class={[
|
|
|
- styles.rightHideIcon,
|
|
|
- !rightColumnShow.value ? styles.rightIconShow : ''
|
|
|
- ]}
|
|
|
- src={rightHideIcon}
|
|
|
- onClick={() => (rightColumnShow.value = true)}
|
|
|
- />
|
|
|
- )}
|
|
|
- {/* 右下角悬浮按钮 */}
|
|
|
- <div class={styles.bottomColumn}>
|
|
|
- {bottomList.map((item: any, index: number) => (
|
|
|
- <div
|
|
|
- class={[
|
|
|
- styles.bottomItem,
|
|
|
- (item.id === 3 && !isUpArrow.value) ||
|
|
|
- (item.id === 4 && !isDownArrow.value)
|
|
|
- ? styles.itemDisabled
|
|
|
- : ''
|
|
|
- ]}
|
|
|
- onClick={() => operateBottomBtn(item.id)}>
|
|
|
- <NTooltip showArrow={false} placement="top">
|
|
|
- {{
|
|
|
- trigger: () => <img src={item.icon} />,
|
|
|
- default: <>{item.name}</>
|
|
|
- }}
|
|
|
- </NTooltip>
|
|
|
- {/* <img src={item.icon} />
|
|
|
- <div class={styles.bottomTips}>{item.name}</div> */}
|
|
|
+ <img
|
|
|
+ class={[
|
|
|
+ styles.rightHideIcon,
|
|
|
+ !(columnShow.value && columnPos.value === 'right')
|
|
|
+ ? styles.rightIconShow
|
|
|
+ : ''
|
|
|
+ ]}
|
|
|
+ src={rightHideIcon}
|
|
|
+ onClick={() => {
|
|
|
+ columnPos.value = 'right';
|
|
|
+ columnShow.value = true;
|
|
|
+ }}
|
|
|
+ />
|
|
|
+ {/* 左边操作栏 */}
|
|
|
+ <div
|
|
|
+ class={[
|
|
|
+ styles.leftColumn,
|
|
|
+ columnShow.value && columnPos.value === 'left'
|
|
|
+ ? ''
|
|
|
+ : styles.leftColumnHide
|
|
|
+ ]}>
|
|
|
+ {rightList.map((item: any) => (
|
|
|
+ <div class={styles.columnItemBox}>
|
|
|
+ <div
|
|
|
+ class={[
|
|
|
+ styles.columnItem,
|
|
|
+ (item.id === 2 && data.preStudentNum <= 0) ||
|
|
|
+ (item.id === 10 && studyData.callStudentList.length <= 0) ||
|
|
|
+ (item.id === 11 && !isUpArrow.value) ||
|
|
|
+ (item.id === 12 && !isDownArrow.value)
|
|
|
+ ? styles.itemDisabled
|
|
|
+ : ''
|
|
|
+ ]}
|
|
|
+ onClick={() => operateRightBtn(item.id)}>
|
|
|
+ <NTooltip
|
|
|
+ showArrow={false}
|
|
|
+ placement="right"
|
|
|
+ class={[item.id === 15 ? 'columnItemTooltip' : '']}>
|
|
|
+ {{
|
|
|
+ trigger: () => <img src={item.icon} />,
|
|
|
+ default: () =>
|
|
|
+ item.id === 15 ? (
|
|
|
+ <div class="tools">
|
|
|
+ {tooltipList.map(i => (
|
|
|
+ <div onClick={() => operateRightBtn(i.id)}>
|
|
|
+ <img src={i.icon} />
|
|
|
+ <div class="tit">{i.name}</div>
|
|
|
+ </div>
|
|
|
+ ))}
|
|
|
+ </div>
|
|
|
+ ) : item.id === 1 && data.type === 'preview' ? (
|
|
|
+ item.name2
|
|
|
+ ) : (
|
|
|
+ item.name
|
|
|
+ )
|
|
|
+ }}
|
|
|
+ </NTooltip>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
))}
|
|
|
</div>
|
|
|
+ <img
|
|
|
+ class={[
|
|
|
+ styles.leftHideIcon,
|
|
|
+ !(columnShow.value && columnPos.value === 'left')
|
|
|
+ ? styles.leftIconShow
|
|
|
+ : ''
|
|
|
+ ]}
|
|
|
+ src={leftHideIcon}
|
|
|
+ onClick={() => {
|
|
|
+ columnPos.value = 'left';
|
|
|
+ columnShow.value = true;
|
|
|
+ }}
|
|
|
+ />
|
|
|
|
|
|
{/* 显示列表 */}
|
|
|
- <NDrawer
|
|
|
+ {/* <NDrawer
|
|
|
v-model:show={popupData.open}
|
|
|
class={[styles.drawerContainer, styles.drawerContainerSource]}
|
|
|
onAfterLeave={handleClosePopup}
|
|
@@ -1783,10 +1974,32 @@ export default defineComponent({
|
|
|
)
|
|
|
}}
|
|
|
</NDrawerContent>
|
|
|
- </NDrawer>
|
|
|
-
|
|
|
- {/* 显示列表 */}
|
|
|
- <NDrawer
|
|
|
+ </NDrawer> */}
|
|
|
+ <NModal
|
|
|
+ transformOrigin="center"
|
|
|
+ v-model:show={popupData.open}
|
|
|
+ preset="card"
|
|
|
+ class={[
|
|
|
+ 'modalTitle background',
|
|
|
+ styles.drawerContainer,
|
|
|
+ resourcesConBoxClass
|
|
|
+ ]}
|
|
|
+ style={resourcesConDragData.styleDrag.value}
|
|
|
+ title={activeName.value || '资源列表'}>
|
|
|
+ <SourceList
|
|
|
+ teacherChapterName={data.teacherChapterName}
|
|
|
+ knowledgePointList={data.knowledgePointList}
|
|
|
+ courseActiveIndex={popupData.courseActiveIndex}
|
|
|
+ activeItem={data.itemList[popupData.activeIndex]}
|
|
|
+ onConfirm={(item: any) => {
|
|
|
+ popupData.open = false;
|
|
|
+ toggleMaterial(item.id);
|
|
|
+ }}
|
|
|
+ />
|
|
|
+ <Dragbom></Dragbom>
|
|
|
+ </NModal>
|
|
|
+ {/* 章节切换 */}
|
|
|
+ {/* <NDrawer
|
|
|
v-model:show={popupData.chapterOpen}
|
|
|
class={styles.drawerContainer}
|
|
|
onAfterLeave={handleClosePopup}
|
|
@@ -1806,11 +2019,34 @@ export default defineComponent({
|
|
|
}}
|
|
|
/>
|
|
|
</NDrawerContent>
|
|
|
- </NDrawer>
|
|
|
-
|
|
|
+ </NDrawer> */}
|
|
|
+ <NModal
|
|
|
+ transformOrigin="center"
|
|
|
+ v-model:show={popupData.chapterOpen}
|
|
|
+ preset="card"
|
|
|
+ class={[
|
|
|
+ 'modalTitle background',
|
|
|
+ styles.drawerContainer,
|
|
|
+ chapterConBoxClass
|
|
|
+ ]}
|
|
|
+ style={chapterConBoxDragData.styleDrag.value}
|
|
|
+ title={'切换章节'}>
|
|
|
+ <Chapter
|
|
|
+ treeList={popupData.chapterDetails}
|
|
|
+ itemActive={data.detailId as any}
|
|
|
+ onHandleSelect={async (val: any) => {
|
|
|
+ // itemActive: child.id,
|
|
|
+ // itemName: child.name
|
|
|
+ popupData.courseId = val.itemActive;
|
|
|
+ data.selectClassStatus = true;
|
|
|
+ }}
|
|
|
+ />
|
|
|
+ <Dragbom></Dragbom>
|
|
|
+ </NModal>
|
|
|
{/* 批注 */}
|
|
|
{studyData.penShow && (
|
|
|
<Pen
|
|
|
+ isDrag={true}
|
|
|
show={studyData.type === 'pen'}
|
|
|
type={studyData.type}
|
|
|
close={() => closeStudyTool()}
|
|
@@ -1819,6 +2055,7 @@ export default defineComponent({
|
|
|
|
|
|
{studyData.whiteboardShow && (
|
|
|
<Pen
|
|
|
+ isDrag={true}
|
|
|
show={studyData.type === 'whiteboard'}
|
|
|
type={studyData.type}
|
|
|
close={() => closeStudyTool()}
|
|
@@ -1827,6 +2064,8 @@ export default defineComponent({
|
|
|
|
|
|
{studyData.callShow && (
|
|
|
<Pen
|
|
|
+ isDrag={true}
|
|
|
+ imagePos={columnPos.value}
|
|
|
callStudents={studyData.callStudentList}
|
|
|
show={studyData.type === 'call'}
|
|
|
type={studyData.type}
|
|
@@ -1842,8 +2081,10 @@ export default defineComponent({
|
|
|
class={[
|
|
|
'modalTitle background',
|
|
|
// styles.attendClassModal,
|
|
|
- styles.selectClassModal
|
|
|
+ styles.selectClassModal,
|
|
|
+ selCourBoxClass
|
|
|
]}
|
|
|
+ style={selCourDragData.styleDrag.value}
|
|
|
title={'选择课件'}>
|
|
|
<SelectClass
|
|
|
classId={data.classId}
|
|
@@ -1874,6 +2115,7 @@ export default defineComponent({
|
|
|
popupData.chapterLoading = false;
|
|
|
}}
|
|
|
/>
|
|
|
+ <Dragbom></Dragbom>
|
|
|
</NModal>
|
|
|
|
|
|
{/* 布置作业 */}
|
|
@@ -1882,7 +2124,12 @@ export default defineComponent({
|
|
|
v-model:show={data.modelAttendStatus}
|
|
|
preset="card"
|
|
|
title={'课后作业'}
|
|
|
- class={['modalTitle', styles.removeVisiable]}>
|
|
|
+ style={modelTrainHomeWordConBoxDragData.styleDrag.value}
|
|
|
+ class={[
|
|
|
+ 'modalTitle',
|
|
|
+ styles.removeVisiable,
|
|
|
+ modelTrainHomeWordConBoxClass
|
|
|
+ ]}>
|
|
|
<div class={styles.studentRemove}>
|
|
|
<p>{data.modalAttendMessage}</p>
|
|
|
<NSpace class={styles.btnGroupModal} justify="center">
|
|
@@ -1909,6 +2156,7 @@ export default defineComponent({
|
|
|
</NButton>
|
|
|
</NSpace>
|
|
|
</div>
|
|
|
+ <Dragbom class={styles.dragbom}></Dragbom>
|
|
|
</NModal>
|
|
|
|
|
|
{/* 训练设置 */}
|
|
@@ -1930,11 +2178,17 @@ export default defineComponent({
|
|
|
<NModal
|
|
|
v-model:show={data.modelTrainStatus}
|
|
|
preset="card"
|
|
|
- class={['modalTitle background', styles.workVisiable]}
|
|
|
+ class={[
|
|
|
+ 'modalTitle background',
|
|
|
+ styles.workVisiable,
|
|
|
+ modelTrainStatusConBoxClass
|
|
|
+ ]}
|
|
|
+ style={modelTrainStatusConBoxDragData.styleDrag.value}
|
|
|
title={'布置作业'}>
|
|
|
<div id="model-homework-height" class={styles.workContainer}>
|
|
|
<div class={styles.workTrain}>
|
|
|
<Train
|
|
|
+ from={'class'}
|
|
|
cardType="homeworkRecord"
|
|
|
lessonPreTraining={{
|
|
|
title: data.lessonPreTrainingId
|
|
@@ -1952,18 +2206,22 @@ export default defineComponent({
|
|
|
/>
|
|
|
</div>
|
|
|
<div class={styles.resourceMain}>
|
|
|
- <ResourceMain cardType="homerowk-record" />
|
|
|
+ <ResourceMain from={'class'} cardType="homerowk-record" />
|
|
|
</div>
|
|
|
</div>
|
|
|
+ <Dragbom class={styles.dragbom}></Dragbom>
|
|
|
</NModal>
|
|
|
|
|
|
<NModal
|
|
|
transformOrigin="center"
|
|
|
- class={['modalTitle background']}
|
|
|
+ class={['modalTitle background', metronomeConBoxClass]}
|
|
|
title={'节拍器'}
|
|
|
preset="card"
|
|
|
v-model:show={showModalBeat.value}
|
|
|
- style={{ width: '687px' }}>
|
|
|
+ style={{
|
|
|
+ width: '687px',
|
|
|
+ ...metronomeConBoxDragData.styleDrag.value
|
|
|
+ }}>
|
|
|
<div class={styles.modeWrap}>
|
|
|
<iframe
|
|
|
src={`${vaildUrl()}/metronome/?id=${new Date().getTime()}`}
|
|
@@ -1974,6 +2232,7 @@ export default defineComponent({
|
|
|
iframeDislableKeyboard(val.target);
|
|
|
}}
|
|
|
height={'650px'}></iframe>
|
|
|
+ <Dragbom class={styles.dragbom}></Dragbom>
|
|
|
</div>
|
|
|
</NModal>
|
|
|
|
|
@@ -1991,27 +2250,34 @@ export default defineComponent({
|
|
|
<NModal
|
|
|
transformOrigin="center"
|
|
|
v-model:show={showModalTime.value}
|
|
|
- class={['modalTitle background']}
|
|
|
+ class={['modalTitle background', timerMeterConBoxClass]}
|
|
|
title={'计时器'}
|
|
|
preset="card"
|
|
|
- style={{ width: px2vw(772) }}>
|
|
|
+ style={{
|
|
|
+ width: px2vw(772),
|
|
|
+ ...timerMeterConDragData.styleDrag.value
|
|
|
+ }}>
|
|
|
<div>
|
|
|
<TimerMeter></TimerMeter>
|
|
|
+ <Dragbom class={styles.dragbom}></Dragbom>
|
|
|
</div>
|
|
|
</NModal>
|
|
|
|
|
|
<NModal
|
|
|
v-model:show={data.selectResourceStatus}
|
|
|
- class={['modalTitle', styles.selectMusicModal]}
|
|
|
+ class={['modalTitle', styles.selectMusicModal, selResourBoxClass]}
|
|
|
+ style={selResourDragData.styleDrag.value}
|
|
|
preset="card"
|
|
|
title={'选择资源'}>
|
|
|
<SelectResources from="class" />
|
|
|
+ <Dragbom></Dragbom>
|
|
|
</NModal>
|
|
|
<NModal
|
|
|
transformOrigin="center"
|
|
|
v-model:show={data.removeVisiable}
|
|
|
preset="card"
|
|
|
- class={['modalTitle', styles.removeVisiable]}
|
|
|
+ class={['modalTitle', styles.removeVisiable, removeResourBoxClass]}
|
|
|
+ style={removeResourDragData.styleDrag.value}
|
|
|
title={data.removeTitle}>
|
|
|
<div class={styles.studentRemove}>
|
|
|
<p>{data.removeContent}</p>
|
|
@@ -2078,6 +2344,39 @@ export default defineComponent({
|
|
|
{data.removeCourseStatus ? '布置作业' : '确定'}
|
|
|
</NButton>
|
|
|
</NSpace>
|
|
|
+ <Dragbom></Dragbom>
|
|
|
+ </div>
|
|
|
+ </NModal>
|
|
|
+ <NModal
|
|
|
+ style={nextEndBoxDragData.styleDrag.value}
|
|
|
+ z-index={3000}
|
|
|
+ transformOrigin="center"
|
|
|
+ v-model:show={data.nextEndShow}
|
|
|
+ preset="card"
|
|
|
+ title={'提示'}
|
|
|
+ class={['modalTitle', styles.removeVisiable, nextEndBoxClass]}>
|
|
|
+ <div class={styles.studentRemove}>
|
|
|
+ <p>当前课件已结束,是否进入下一章节</p>
|
|
|
+ <NSpace class={styles.btnGroupModal} justify="center">
|
|
|
+ <NButton
|
|
|
+ type="default"
|
|
|
+ round
|
|
|
+ onClick={() => {
|
|
|
+ data.nextEndShow = false;
|
|
|
+ }}>
|
|
|
+ 取消
|
|
|
+ </NButton>
|
|
|
+ <NButton
|
|
|
+ type="primary"
|
|
|
+ round
|
|
|
+ onClick={() => {
|
|
|
+ data.nextEndShow = false;
|
|
|
+ handleNextEnd();
|
|
|
+ }}>
|
|
|
+ 确认
|
|
|
+ </NButton>
|
|
|
+ </NSpace>
|
|
|
+ <Dragbom></Dragbom>
|
|
|
</div>
|
|
|
</NModal>
|
|
|
</div>
|