|
@@ -14,15 +14,19 @@
|
|
|
<img src="../../assets/icon/newIcon/return.svg" alt="" />
|
|
<img src="../../assets/icon/newIcon/return.svg" alt="" />
|
|
|
</div>
|
|
</div>
|
|
|
<div v-if="tcid" class="class-info-group">
|
|
<div v-if="tcid" class="class-info-group">
|
|
|
- <span class="class-label">班级</span>
|
|
|
|
|
|
|
+ <span class="class-label">{{ lang.ssClass }}</span>
|
|
|
<span class="class-value">{{ className }}</span>
|
|
<span class="class-value">{{ className }}</span>
|
|
|
</div>
|
|
</div>
|
|
|
<div v-if="tcid" class="class-info-group">
|
|
<div v-if="tcid" class="class-info-group">
|
|
|
- <span class="class-label" v-if="inviteCode">识别码</span>
|
|
|
|
|
|
|
+ <span class="class-label" v-if="inviteCode">{{ lang.ssInviteCode }}</span>
|
|
|
<span class="class-value" v-if="inviteCode">{{ inviteCode }}</span>
|
|
<span class="class-value" v-if="inviteCode">{{ inviteCode }}</span>
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|
|
|
<div class="pec_h_center">
|
|
<div class="pec_h_center">
|
|
|
|
|
+ <div class="pec_h_r_btn_refresh" :class="{ 'recording': recordedForm.status == 1 }" @click="toggleRecording" v-show="(jArray.includes(oid) || jArray.includes(org)) && courseDetail.userid == userid && tcid">
|
|
|
|
|
+ <svg t="1772588344140" viewBox="0 0 1024 1024" p-id="1693" width="200" height="200"><path d="M512 1024a512.568889 512.568889 0 0 1-512-512 512.625778 512.625778 0 0 1 512-512 512.568889 512.568889 0 0 1 512 512 512.568889 512.568889 0 0 1-512 512zM512 73.329778c-241.948444 0-438.670222 196.835556-438.670222 438.670222S270.051556 950.670222 512 950.670222s438.670222-196.835556 438.670222-438.670222S753.948444 73.329778 512 73.329778z m0 686.592a245.191111 245.191111 0 1 1 0-490.382222 245.191111 245.191111 0 0 1 0 490.382222z" p-id="1694"></path></svg>
|
|
|
|
|
+ <span>{{ recordedForm.status == 1 ? lang.ssStopRecording2 : lang.ssRecord }}</span>
|
|
|
|
|
+ </div>
|
|
|
<el-tooltip effect="dark" :content="courseDetail.title" placement="bottom">
|
|
<el-tooltip effect="dark" :content="courseDetail.title" placement="bottom">
|
|
|
<div class="pec_h_l_title">
|
|
<div class="pec_h_l_title">
|
|
|
<span>{{ courseDetail.title }}</span>
|
|
<span>{{ courseDetail.title }}</span>
|
|
@@ -38,12 +42,12 @@
|
|
|
inactive-color="#d8d8d8"
|
|
inactive-color="#d8d8d8"
|
|
|
@change="onFreeBrowseChange"
|
|
@change="onFreeBrowseChange"
|
|
|
></el-switch>
|
|
></el-switch>
|
|
|
- <span class="switch-label" :class="{ active: freeBrowse }">{{ freeBrowse ? '自由浏览' : '跟随模式' }}</span>
|
|
|
|
|
|
|
+ <span class="switch-label" :class="{ active: freeBrowse }">{{ freeBrowse ? lang.ssFreeBrowse : lang.ssFollowMode }}</span>
|
|
|
</div>
|
|
</div>
|
|
|
<div class="free-browse-switch" v-if="tType == 2">
|
|
<div class="free-browse-switch" v-if="tType == 2">
|
|
|
- <span class="switch-label" :class="{ active: freeBrowse }">{{ freeBrowse ? '自由浏览' : '跟随模式' }}</span>
|
|
|
|
|
|
|
+ <span class="switch-label" :class="{ active: freeBrowse }">{{ freeBrowse ? lang.ssFreeBrowse : lang.ssFollowMode }}</span>
|
|
|
</div>
|
|
</div>
|
|
|
- <el-tooltip effect="dark" content="刷新" placement="bottom">
|
|
|
|
|
|
|
+ <el-tooltip effect="dark" :content="lang.ssRefresh" placement="bottom">
|
|
|
<div class="refresh_icon" @click="refreshCourse">
|
|
<div class="refresh_icon" @click="refreshCourse">
|
|
|
<img src="../../assets/icon/course/refresh-2.svg" />
|
|
<img src="../../assets/icon/course/refresh-2.svg" />
|
|
|
</div>
|
|
</div>
|
|
@@ -53,12 +57,9 @@
|
|
|
<div class="pec_h_r_btnArea">
|
|
<div class="pec_h_r_btnArea">
|
|
|
<!-- openObserveDialog -->
|
|
<!-- openObserveDialog -->
|
|
|
<!-- toggleRecording -->
|
|
<!-- toggleRecording -->
|
|
|
- <div class="pec_h_r_btn_refresh" :class="{ 'recording': recordedForm.status == 1 }" @click="toggleRecording" v-show="(jArray.includes(oid) || jArray.includes(org)) && courseDetail.userid == userid && tcid">
|
|
|
|
|
- <span>{{ recordedForm.status == 1 ? '结束录音' : '开始录音' }}</span>
|
|
|
|
|
- </div>
|
|
|
|
|
<div class="pec_h_r_btn_afterClass" @click="afterClass" v-if="courseDetail.userid == userid">
|
|
<div class="pec_h_r_btn_afterClass" @click="afterClass" v-if="courseDetail.userid == userid">
|
|
|
<img src="../../assets/icon/newIcon/afterClass.svg" alt="" />
|
|
<img src="../../assets/icon/newIcon/afterClass.svg" alt="" />
|
|
|
- <span>下课</span>
|
|
|
|
|
|
|
+ <span>{{ lang.ssEndClass }}</span>
|
|
|
</div>
|
|
</div>
|
|
|
<div class="name_box" v-if="tType == 2">
|
|
<div class="name_box" v-if="tType == 2">
|
|
|
{{ userJson.username }}
|
|
{{ userJson.username }}
|
|
@@ -168,10 +169,26 @@ export default {
|
|
|
const now = new Date();
|
|
const now = new Date();
|
|
|
const duration = (now - new Date(this.recordingStartTime)) / 1000;
|
|
const duration = (now - new Date(this.recordingStartTime)) / 1000;
|
|
|
if (duration < 5) {
|
|
if (duration < 5) {
|
|
|
- this.$message.warning('录音时间至少需要5秒');
|
|
|
|
|
|
|
+ this.$message.warning(this.lang.ssRecordingTimeAtLeast5Seconds);
|
|
|
return;
|
|
return;
|
|
|
}
|
|
}
|
|
|
- this.onFinishRecordWithMicrosoft();
|
|
|
|
|
|
|
+ this.$confirm(this.lang.ssStopRecordingNotice, this.lang.ssStopRecordingConfirm, {
|
|
|
|
|
+ confirmButtonText: this.lang.ssConfirm,
|
|
|
|
|
+ cancelButtonText: this.lang.ssCancel,
|
|
|
|
|
+ confirmButtonClass:"pptEasyClassConfirmButtonText",
|
|
|
|
|
+ cancelButtonClass:"pptEasyClassCancelButtonText"
|
|
|
|
|
+ }).then(() => {
|
|
|
|
|
+ console.log("确定")
|
|
|
|
|
+ // this.$message({
|
|
|
|
|
+ // dangerouslyUseHTMLString: true,
|
|
|
|
|
+ // customClass:"pptEasyClassMessage",
|
|
|
|
|
+ // message: '已停止录制 <p style="color:#3AB855;text-decoration: underline;cursor: pointer;float:right;margin-left:10px" target="_blank">查看结果</p>'
|
|
|
|
|
+ // });
|
|
|
|
|
+ this.onFinishRecordWithMicrosoft();
|
|
|
|
|
+ }).catch(() => {
|
|
|
|
|
+ console.log("取消")
|
|
|
|
|
+ });
|
|
|
|
|
+
|
|
|
} else {
|
|
} else {
|
|
|
const now = new Date();
|
|
const now = new Date();
|
|
|
const duration = (now - new Date(this.recordingEndTime)) / 1000;
|
|
const duration = (now - new Date(this.recordingEndTime)) / 1000;
|
|
@@ -258,7 +275,12 @@ export default {
|
|
|
this.recordedForm.status = 0;
|
|
this.recordedForm.status = 0;
|
|
|
this.controlsStatus = 2;
|
|
this.controlsStatus = 2;
|
|
|
this.showGetTextLoading = false;
|
|
this.showGetTextLoading = false;
|
|
|
- this.$message.success("已结束录音");
|
|
|
|
|
|
|
+ // this.$message.success("已结束录音");
|
|
|
|
|
+ this.$message({
|
|
|
|
|
+ dangerouslyUseHTMLString: true,
|
|
|
|
|
+ customClass:"pptEasyClassMessage",
|
|
|
|
|
+ message: `${this.lang.ssStoppedRecording} <p style="color:#3AB855;text-decoration: underline;cursor: pointer;float:right;margin-left:10px" target="_blank">${this.lang.ssViewRecordingResult}</p>`
|
|
|
|
|
+ });
|
|
|
console.log("结束录音👇");
|
|
console.log("结束录音👇");
|
|
|
console.log("结束录音", e);
|
|
console.log("结束录音", e);
|
|
|
this.recordedForm.audioBlob.push(e.preaudio);
|
|
this.recordedForm.audioBlob.push(e.preaudio);
|
|
@@ -385,7 +407,7 @@ export default {
|
|
|
})
|
|
})
|
|
|
.catch(err => {
|
|
.catch(err => {
|
|
|
console.log(err);
|
|
console.log(err);
|
|
|
- this.$message.error("获取课程数据失败");
|
|
|
|
|
|
|
+ this.$message.error(this.lang.ssGetCourseDataFail);
|
|
|
this.pageLoading = false;
|
|
this.pageLoading = false;
|
|
|
});
|
|
});
|
|
|
},
|
|
},
|
|
@@ -465,9 +487,9 @@ export default {
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
afterClass() {
|
|
afterClass() {
|
|
|
- this.$confirm('此操作将使当前课程内所有学生退出登录,是否继续?', '提示', {
|
|
|
|
|
- confirmButtonText: '确定',
|
|
|
|
|
- cancelButtonText: '取消',
|
|
|
|
|
|
|
+ this.$confirm(this.lang.ssEndClassConfirm, this.lang.ssPrompt, {
|
|
|
|
|
+ confirmButtonText: this.lang.ssConfirm,
|
|
|
|
|
+ cancelButtonText: this.lang.ssCancel,
|
|
|
type: 'warning'
|
|
type: 'warning'
|
|
|
}).then(() => {
|
|
}).then(() => {
|
|
|
this.$refs.ppt.contentWindow.PPTistStudent.forceLogout();
|
|
this.$refs.ppt.contentWindow.PPTistStudent.forceLogout();
|
|
@@ -489,6 +511,7 @@ export default {
|
|
|
}, 600000);
|
|
}, 600000);
|
|
|
},
|
|
},
|
|
|
setoTime(time) {
|
|
setoTime(time) {
|
|
|
|
|
+ this.doSyncClassData();
|
|
|
let params = [
|
|
let params = [
|
|
|
{
|
|
{
|
|
|
uid: this.userid,
|
|
uid: this.userid,
|
|
@@ -513,26 +536,29 @@ export default {
|
|
|
this.jArray = Array;
|
|
this.jArray = Array;
|
|
|
})
|
|
})
|
|
|
},
|
|
},
|
|
|
|
|
+ doSyncClassData(){
|
|
|
|
|
+ if (this.courseDetail.userid == this.userid && this.org == '16ace517-b5c7-4168-a9bb-a9e0035df840') {
|
|
|
|
|
+ let endTime = new Date().toLocaleString("zh-CN", {
|
|
|
|
|
+ hour12: false,
|
|
|
|
|
+ timeZone: "Asia/Shanghai"
|
|
|
|
|
+ }).replace(/\//g, "-")
|
|
|
|
|
+ let courseTime = Math.floor((new Date(endTime) - new Date(this.startTime)) / (1000 * 60))
|
|
|
|
|
+ this.syncClassData({
|
|
|
|
|
+ courseId: this.id,
|
|
|
|
|
+ title: this.courseDetail.title,
|
|
|
|
|
+ courseGrade: this.tcid2 ? this.tcid2 : '',
|
|
|
|
|
+ courseTime: courseTime,
|
|
|
|
|
+ startTime: this.startTime,
|
|
|
|
|
+ endTime: endTime,
|
|
|
|
|
+ })
|
|
|
|
|
+ console.log('同步数据')
|
|
|
|
|
+ }
|
|
|
|
|
+ },
|
|
|
},
|
|
},
|
|
|
destroyed() {
|
|
destroyed() {
|
|
|
clearInterval(this.opertimer);
|
|
clearInterval(this.opertimer);
|
|
|
this.opertimer = null;
|
|
this.opertimer = null;
|
|
|
- if (this.courseDetail.userid == this.userid && this.org == '16ace517-b5c7-4168-a9bb-a9e0035df840') {
|
|
|
|
|
- let endTime = new Date().toLocaleString("zh-CN", {
|
|
|
|
|
- hour12: false,
|
|
|
|
|
- timeZone: "Asia/Shanghai"
|
|
|
|
|
- }).replace(/\//g, "-")
|
|
|
|
|
- let courseTime = Math.floor((new Date(endTime) - new Date(this.startTime)) / (1000 * 60))
|
|
|
|
|
- this.syncClassData({
|
|
|
|
|
- courseId: this.id,
|
|
|
|
|
- title: this.courseDetail.title,
|
|
|
|
|
- courseGrade: this.tcid2 ? this.tcid2 : '',
|
|
|
|
|
- courseTime: courseTime,
|
|
|
|
|
- startTime: this.startTime,
|
|
|
|
|
- endTime: endTime,
|
|
|
|
|
- })
|
|
|
|
|
- console.log('同步数据')
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ this.doSyncClassData();
|
|
|
},
|
|
},
|
|
|
async mounted() {
|
|
async mounted() {
|
|
|
this.setoTime("1");
|
|
this.setoTime("1");
|
|
@@ -554,6 +580,9 @@ export default {
|
|
|
});
|
|
});
|
|
|
this.userJson = res.data[0][0]
|
|
this.userJson = res.data[0][0]
|
|
|
}
|
|
}
|
|
|
|
|
+ setTimeout(() => {
|
|
|
|
|
+ this.doSyncClassData();
|
|
|
|
|
+ }, 1000);
|
|
|
}
|
|
}
|
|
|
};
|
|
};
|
|
|
</script>
|
|
</script>
|
|
@@ -659,15 +688,35 @@ export default {
|
|
|
margin-right: 5px;
|
|
margin-right: 5px;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
-.pec_h_r_btnArea>.pec_h_r_btn_refresh {
|
|
|
|
|
|
|
+.pec_h_center>.pec_h_r_btn_refresh {
|
|
|
color: #fff;
|
|
color: #fff;
|
|
|
- background-color: #0061ff;
|
|
|
|
|
- border-color: #0061ff;
|
|
|
|
|
|
|
+ /* background-color: #0061ff;
|
|
|
|
|
+ border-color: #0061ff; */
|
|
|
|
|
+ padding: 9px 10px;
|
|
|
|
|
+ margin-right: 15px;
|
|
|
|
|
+ border-radius: 26px;
|
|
|
|
|
+ display: flex;
|
|
|
|
|
+ align-items: center;
|
|
|
|
|
+ justify-content: center;
|
|
|
|
|
+ gap: 5px;
|
|
|
|
|
+ background: #FFF7F5;
|
|
|
|
|
+ color: #000000;
|
|
|
|
|
+ font-weight: 400;
|
|
|
|
|
+ cursor: pointer;
|
|
|
|
|
+ fill: #666666;
|
|
|
|
|
+}
|
|
|
|
|
+
|
|
|
|
|
+.pec_h_center>.pec_h_r_btn_refresh>svg{
|
|
|
|
|
+
|
|
|
|
|
+ width: 1rem;
|
|
|
|
|
+ height: 1rem;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
-.pec_h_r_btnArea>.pec_h_r_btn_refresh.recording {
|
|
|
|
|
- background-color: #F53F3F;
|
|
|
|
|
- border-color: #F53F3F;
|
|
|
|
|
|
|
+.pec_h_center>.pec_h_r_btn_refresh.recording {
|
|
|
|
|
+ /* background-color: #F53F3F;
|
|
|
|
|
+ border-color: #F53F3F; */
|
|
|
|
|
+ background: #FFF7E8;
|
|
|
|
|
+ fill: #FF9300;
|
|
|
animation: pulse 1.5s infinite;
|
|
animation: pulse 1.5s infinite;
|
|
|
}
|
|
}
|
|
|
|
|
|