mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-student.git
synced 2025-12-10 19:36:48 +08:00
作业考试开始结束按钮状态
This commit is contained in:
@@ -23,10 +23,10 @@
|
||||
<div class="time" style="margin-top: 26px">
|
||||
<img style="width: 15px; height: 17px" src="../../assets/image/time.png" />
|
||||
<div style="margin-left: 8px">
|
||||
{{ data.planDto?.beginTime + "至" + data.planDto?.endTime }}
|
||||
{{ dayjs(data.planDto?.beginTime).format('YYYY-MM-DD HH:MM') + " 至 " + dayjs(data.planDto?.endTime).format('YYYY-MM-DD HH:MM') }}
|
||||
</div>
|
||||
</div>
|
||||
<div class="time" style="margin-top: 23px">
|
||||
<div v-if="data.planDto.address" class="time" style="margin-top: 23px">
|
||||
<img style="width: 16px; height: 18px" src="../../assets/image/position.png" />
|
||||
<div style="margin-left: 8px">{{ data.planDto?.address }}</div>
|
||||
</div>
|
||||
@@ -38,14 +38,12 @@
|
||||
background: data.signFlag ? '#999' : 'rgb(57, 146, 249)',
|
||||
}" @click="signClick">{{ data.signFlag ? "已签到" : "签到" }}
|
||||
</botton>
|
||||
<botton style="background: #999" class="btn" @click="toSurvery" v-if="data.planDto?.evalFlag == 0">
|
||||
<botton style="background: #999" class="btn" @click="toSurvery" v-if="data.planDto?.evalFlag == 0 ">
|
||||
评估
|
||||
</botton>
|
||||
<botton :style="{
|
||||
background: `${new Date(data.planDto.beginTime).getTime() > new Date().getTime() ? '#999' : data.isSurvery ? '#999' : 'rgb(57, 146, 249)'}`,
|
||||
}" class="btn" @click="toSurvery" v-if="data.planDto?.evalFlag && data.planDto?.evalFlag == 1">{{
|
||||
data.isSurvery ? "已评估" : "评估"
|
||||
}}
|
||||
}" class="btn" @click="toSurvery" v-else>{{data.isSurvery ? "已评估" : "评估"}}
|
||||
</botton>
|
||||
</div>
|
||||
</div>
|
||||
@@ -66,17 +64,11 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="detailB">
|
||||
<el-tabs v-model="activeName" @tab-click="handleClick">
|
||||
<el-tabs v-model="activeName" @tab-click="handleClick" >
|
||||
<el-tab-pane label="课程附件" name="first">
|
||||
<div v-if="data.planDto?.attach === '[]'" style="
|
||||
font-size: 14px;
|
||||
font-weight: 400;
|
||||
line-height: 24px;
|
||||
cursor: pointer;
|
||||
margin-left: 40px;
|
||||
margin-top: 20px;
|
||||
">
|
||||
<div v-if="data.planDto?.attach === '[]'" style="font-size: 14px;font-weight: 400; line-height: 24px; cursor: pointer;margin-left: 40px; margin-top: 20px;">
|
||||
此课程无附件
|
||||
</div>
|
||||
<div v-else>
|
||||
@@ -106,16 +98,7 @@
|
||||
</div>
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="课程作业" name="second">
|
||||
<div v-if="data.planDto?.attach === '[]'" style="
|
||||
font-size: 14px;
|
||||
font-weight: 400;
|
||||
line-height: 24px;
|
||||
cursor: pointer;
|
||||
margin-left: 40px;
|
||||
margin-top: 20px;
|
||||
">
|
||||
此课程无作业
|
||||
</div>
|
||||
|
||||
<div class="work" v-if="data.workDto?.workName">
|
||||
<div>
|
||||
<div class="question">{{ data.workDto?.workName }}</div>
|
||||
@@ -125,27 +108,19 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div v-if="isEndSubMitWork()" class="submit" style="background: #999">
|
||||
已结束
|
||||
</div>
|
||||
<div v-if="dayjs(data.value.workDto.submitEndTime).isBefore(dayjs())" @click="toWork" class="submit" style="background: #999">已结束</div>
|
||||
<div v-if="dayjs().isBefore(dayjs(data.value.workDto.submitStartTime))" @click="toWork" class="submit" style="background: #999">未开始</div>
|
||||
<div
|
||||
:style="{ background: new Date(data.planDto.beginTime).getTime() > new Date().getTime() ? '#999' : '' }"
|
||||
v-else class="submit" @click="toWork" v-if="data.workDto?.workId">
|
||||
:style="{ background: new Date(data.planDto.beginTime).getTime() > new Date().getTime() ? '#999' : '' }" class="submit" @click="toWork" v-else>
|
||||
交作业
|
||||
</div>
|
||||
</div>
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="课程考试" name="third">
|
||||
<div v-if="data.planDto?.attach === '[]'" style="
|
||||
font-size: 14px;
|
||||
font-weight: 400;
|
||||
line-height: 24px;
|
||||
cursor: pointer;
|
||||
margin-left: 40px;
|
||||
margin-top: 20px;
|
||||
">
|
||||
此课程无考试
|
||||
<div v-else style=" font-size: 14px; font-weight: 400; line-height: 24px; cursor: pointer;margin-left: 40px;margin-top: 20px; ">
|
||||
此课程无作业
|
||||
</div>
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="课程考试" name="third" :disabed=dayjs().isBefore(dayjs(data.planDto.beginTime)) >
|
||||
|
||||
<div class="work" v-if="data.examinationDto?.examinationTestName">
|
||||
<div>
|
||||
<div class="question">
|
||||
@@ -158,12 +133,17 @@
|
||||
<div class="tag3" style="margin-left: 11px">考试</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
<div v-if="dayjs(data.value.workDto.examinationEndTime).isBefore(dayjs())" class="submit" style="background: #999" @click="toExamItem(data.examinationDto)">已结束</div>
|
||||
<div v-if="dayjs().isBefore(dayjs(data.value.workDto.examinationStartTime))" class="submit" style="background: #999">未开始</div>
|
||||
<div v-else
|
||||
:style="{ background: new Date(data.planDto.beginTime).getTime() > new Date().getTime() ? '#999' : '' }"
|
||||
class="submit" @click="toExamItem(data.examinationDto)">
|
||||
去考试
|
||||
</div>
|
||||
</div>
|
||||
<div v-else style=" font-size: 14px; font-weight: 400;line-height: 24px;cursor: pointer; margin-left: 40px; margin-top: 20px; ">
|
||||
此课程无考试
|
||||
</div>
|
||||
</el-tab-pane>
|
||||
</el-tabs>
|
||||
</div>
|
||||
@@ -177,7 +157,7 @@
|
||||
<!-- todo #面授课接口 讲师缺少img和介绍-->
|
||||
<div class="teacheritem">
|
||||
<img class="peopleimg" :src="teacherInfo.avatar" />
|
||||
<div style="margin-left: 17px; width: 190px">
|
||||
<div class="nameSpan">
|
||||
<div class="teacherName" style="margin-right: 5px">
|
||||
{{ data.planDto?.teacher }}
|
||||
</div>
|
||||
@@ -204,6 +184,7 @@ import {
|
||||
import { useRoute, useRouter } from "vue-router";
|
||||
import { useUserInfo } from "@/api/utils";
|
||||
import { ElMessage, messageConfig } from "element-plus";
|
||||
import dayjs from "dayjs";
|
||||
const router = useRouter();
|
||||
const returnclick = () => {
|
||||
router.back();
|
||||
@@ -225,13 +206,13 @@ const state = reactive({
|
||||
});
|
||||
const { activeName, enclosure, isAllowSign } = toRefs(state);
|
||||
const handleClick = (tab, event) => {
|
||||
console.log(tab, event);
|
||||
console.log("附件",tab, event);
|
||||
};
|
||||
const download = (url) => {
|
||||
window.open(url);
|
||||
};
|
||||
const downloads = (url) => {
|
||||
ElMessage.info("未到开始时间,请耐心等待!");
|
||||
ElMessage.warning("未到开始时间,请耐心等待!");
|
||||
};
|
||||
let timer = null;
|
||||
//判断能否签到
|
||||
@@ -291,22 +272,22 @@ const signClick = () => {
|
||||
// state.isAllowSign,
|
||||
// !state.isAllowSign
|
||||
// );
|
||||
if (data.value.planDto.beginTime) {
|
||||
let date1 = new Date(data.value.planDto.beginTime).getTime()
|
||||
let date2 = new Date().getTime()
|
||||
if (date1 > date2) {
|
||||
ElMessage.info("未到开始时间,请耐心等待!");
|
||||
return;
|
||||
}
|
||||
}
|
||||
//if (data.value.planDto.beginTime) {
|
||||
// let date1 = new Date(data.value.planDto.beginTime).getTime()
|
||||
// let date2 = new Date().getTime()
|
||||
// if (date1 > date2) {
|
||||
// ElMessage.info("未到开始时间,请耐心等待!");
|
||||
// return;
|
||||
// }
|
||||
//}
|
||||
if (!state.isAllowSign) {
|
||||
// console.log("data.signFlag", data.value.signFlag, isAllowSign);
|
||||
ElMessage.info("未在签到范围内");
|
||||
ElMessage.warning("未在允许签到时间范围内");
|
||||
return;
|
||||
}
|
||||
2;
|
||||
|
||||
data.value.signFlag = 1;
|
||||
ElMessage.info("签到成功");
|
||||
ElMessage.warning("签到成功");
|
||||
|
||||
if (taskId) {
|
||||
request(TASK_OFFCOURSE_SIGN, { courseId: courseId, taskId, type });
|
||||
@@ -319,16 +300,12 @@ function toSurvery() {
|
||||
if (data.value.isSurvery) {
|
||||
// return;
|
||||
}
|
||||
if (data.value.planDto.beginTime) {
|
||||
let date1 = new Date(data.value.planDto.beginTime).getTime()
|
||||
let date2 = new Date().getTime()
|
||||
if (date1 > date2) {
|
||||
ElMessage.info("未到开始时间,请耐心等待!");
|
||||
return;
|
||||
}
|
||||
if (data.value.planDto.beginTime && dayjs().isBefore(data.value.planDto.beginTime)) {
|
||||
ElMessage.warning("课程未开始,请耐心等待!");
|
||||
return;
|
||||
}
|
||||
if (data.value.planDto.evalFlag == 0) {
|
||||
ElMessage.info("此课程无评估");
|
||||
ElMessage.warning("此课程无评估");
|
||||
return;
|
||||
}
|
||||
router.push({
|
||||
@@ -345,25 +322,14 @@ function toSurvery() {
|
||||
});
|
||||
}
|
||||
|
||||
function isEndSubMitWork() {
|
||||
if (data.value.workDto.submitEndTime) {
|
||||
let date1 = new Date(data.value.workDto.submitEndTime).getTime();
|
||||
let date2 = new Date().getTime();
|
||||
console.log(date1, date2, date1 > date2, data.value.workDto.submitEndTime)
|
||||
if (date1 < date2) {
|
||||
return true;
|
||||
}
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
function toWork() {
|
||||
if (data.value.planDto.beginTime) {
|
||||
let date1 = new Date(data.value.planDto.beginTime).getTime()
|
||||
let date2 = new Date().getTime()
|
||||
if (date1 > date2) {
|
||||
ElMessage.info("未到开始时间,请耐心等待!");
|
||||
ElMessage.warning("未到开始时间,请耐心等待!");
|
||||
return;
|
||||
}
|
||||
}
|
||||
@@ -387,7 +353,7 @@ function toExamItem(obj) {
|
||||
let date1 = new Date(data.value.planDto.beginTime).getTime()
|
||||
let date2 = new Date().getTime()
|
||||
if (date1 > date2) {
|
||||
ElMessage.info("未到开始时间,请耐心等待!");
|
||||
ElMessage.warning("未到开始时间,请耐心等待!");
|
||||
return;
|
||||
}
|
||||
}
|
||||
@@ -524,7 +490,11 @@ onUnmounted(() => {
|
||||
background: #ffffff;
|
||||
border-radius: 8px;
|
||||
margin-top: 20px;
|
||||
|
||||
.wenxintishi{
|
||||
display: flex;
|
||||
justify-content: stretch;
|
||||
padding: 72px;
|
||||
}
|
||||
.el-tabs__item {
|
||||
height: 69px;
|
||||
padding: 25px 7px 0px 52px;
|
||||
@@ -634,9 +604,11 @@ onUnmounted(() => {
|
||||
margin-left: 48px;
|
||||
margin-right: 48px;
|
||||
// min-height: 115px;
|
||||
margin-top: 20px;
|
||||
padding: 25px 0px;
|
||||
display: flex;
|
||||
position: relative;
|
||||
|
||||
// align-items: center;
|
||||
}
|
||||
|
||||
@@ -646,12 +618,41 @@ onUnmounted(() => {
|
||||
border-radius: 30px;
|
||||
}
|
||||
|
||||
.teacheritem .teacherName {
|
||||
font-size: 14px;
|
||||
font-weight: bold;
|
||||
color: #394145;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
.teacheritem {
|
||||
.nameSpan{
|
||||
width: 190px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
|
||||
.teacherName {
|
||||
font-size: 14px;
|
||||
font-weight: bold;
|
||||
color: #394145;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
.teacheritem {
|
||||
.nameSpan{
|
||||
width: 190px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
|
||||
.teacherName {
|
||||
font-size: 14px;
|
||||
font-weight: bold;
|
||||
color: #394145;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
.teacheritem .introduce {
|
||||
@@ -679,6 +680,8 @@ onUnmounted(() => {
|
||||
cursor: pointer;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -46,7 +46,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div v-if="!dayjs(data?.submitEndTime).isSameOrBefore(dayjs())" >
|
||||
<div v-if="dayjs().isBefore(dayjs(data?.submitEndTime)) && dayjs(data?.submitStartTime).isBefore(dayjs())" >
|
||||
<UploadImg v-model:value="fileList" ref="uploadRef">
|
||||
<button class="shangchuan" style="cursor: pointer">
|
||||
上传
|
||||
@@ -107,12 +107,17 @@
|
||||
<div class="text">作业内容</div>
|
||||
<div class="box"></div>
|
||||
</div>
|
||||
|
||||
<div class="join">
|
||||
<el-input :disabled ="dayjs(data?.submitEndTime).isSameOrBefore(dayjs())" v-model="sbValue.content" :autosize="{ minRows: 12.5, maxRows: 12.5 }" resize="none"
|
||||
<div v-if="dayjs().isBefore(dayjs(data?.submitEndTime)) && dayjs(data?.submitStartTime).isBefore(dayjs())" >
|
||||
<el-input v-model="sbValue.content" :autosize="{ minRows: 12.5, maxRows: 12.5 }" resize="none"
|
||||
type="textarea" />
|
||||
</div>
|
||||
<div v-if="!dayjs(data?.submitEndTime).isSameOrBefore(dayjs())" >
|
||||
<div v-else class="join">
|
||||
<el-input disabled v-model="sbValue.content" :autosize="{ minRows: 12.5, maxRows: 12.5 }" resize="none"
|
||||
type="textarea" />
|
||||
</div>
|
||||
|
||||
|
||||
<div v-if="dayjs().isBefore(dayjs(data?.submitEndTime)) && dayjs(data?.submitStartTime).isBefore(dayjs())" >
|
||||
<div style="display: flex; justify-content: center">
|
||||
<button class="tijiao" @click="handleClick">{{ submitList && submitList.length > 0 ? "再次" : ""
|
||||
}}提交</button>
|
||||
@@ -149,9 +154,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="content3">
|
||||
<div>
|
||||
|
||||
<span style="margin-left: 10px">
|
||||
<div><span style="margin-left: 10px">
|
||||
<el-link target="_blank" type="primary" :href="value.workUploadAddress?.split(',')[0] || ''">{{
|
||||
value.workUploadAddress?.split(',')[0].split('/').at(-1) ||
|
||||
''
|
||||
@@ -172,33 +175,12 @@
|
||||
</div>
|
||||
<div class="timebox clearfix">
|
||||
<div class="innertime">
|
||||
{{
|
||||
data?.submitStartTime
|
||||
}} 至 {{
|
||||
data?.submitEndTime
|
||||
}}
|
||||
{{data?.submitStartTime}} 至 {{data?.submitEndTime}}
|
||||
</div>
|
||||
<div class="endtime clearfix">
|
||||
|
||||
|
||||
|
||||
<div v-if="dayjs(data?.submitEndTime).isSameOrBefore(dayjs())" class="endtimetext">
|
||||
改任务已结束
|
||||
</div>
|
||||
|
||||
|
||||
<div v-else class="endtimetext">
|
||||
距离结束还有
|
||||
<span class="te">{{
|
||||
parseInt(
|
||||
dayjs(data?.submitEndTime).diff(dayjs(), "minute") / 60
|
||||
)
|
||||
}}</span> 小时 <span class="te">{{
|
||||
dayjs(data?.submitEndTime).diff(dayjs(), "minute") % 60
|
||||
}}</span> 分钟
|
||||
</div>
|
||||
|
||||
|
||||
<div v-if="dayjs(data?.submitEndTime).isBefore(dayjs())" class="endtimetext">改任务已结束</div>
|
||||
<div v-else class="endtimetext">距离结束还有 <span class="te">{{parseInt(dayjs(data?.submitEndTime).diff(dayjs(), "minute") / 60)}}</span> 小时
|
||||
<span class="te">{{dayjs(data?.submitEndTime).diff(dayjs(), "minute") % 60}}</span> 分钟</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="righttitle">
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
<div class="time" style="margin-top: 26px">
|
||||
<img style="width: 15px; height: 17px" src="../../assets/image/time.png" />
|
||||
<div style="margin-left: 8px">
|
||||
{{ data?.liveStartTime + "至" + data?.liveEndTime }}
|
||||
{{ data?.liveStartTime + " 至 " + data?.liveEndTime }}
|
||||
</div>
|
||||
</div>
|
||||
<!-- todo #直播详情 没有位置字段-->
|
||||
@@ -53,15 +53,13 @@
|
||||
background: `${new Date(data.liveStartTime).getTime() > new Date().getTime() ? '#999' : data.signFlag ? '#999' : 'rgb(57, 146, 249)'}`,
|
||||
}" @click="signClick">{{ data.signFlag ? "已签到" : "签到" }}
|
||||
</botton>
|
||||
<botton style="background: #999" class="btn" @click="commitClick" v-if="data.isEvaluate == 0">
|
||||
<botton style="background: #999" class="btn" @click="commitClick" v-if="data.isEvaluate == 0 ">
|
||||
评估
|
||||
</botton>
|
||||
|
||||
<botton :style="{
|
||||
background: `${new Date(data.liveStartTime).getTime() > new Date().getTime() ? '#999' : data.isSurvery ? '#999' : 'rgb(57, 146, 249)'}`,
|
||||
}" class="btn" @click="commitClick" v-if="data.isEvaluate && data.isEvaluate == 1">{{ data.isSurvery ? "已评估"
|
||||
: "评估"
|
||||
}}
|
||||
}" class="btn" @click="commitClick" v-if="data.isEvaluate && data.isEvaluate == 1">{{ data.isSurvery ? "已评估": "评估"}}
|
||||
</botton>
|
||||
</div>
|
||||
</div>
|
||||
@@ -138,7 +136,7 @@
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { computed, reactive, toRefs } from "vue";
|
||||
import { computed, reactive, toRefs,onUnmounted } from "vue";
|
||||
import img from "@/assets/image/uploadimg.png";
|
||||
import { request, useRequest } from "@/api/request";
|
||||
import { TASK_BROADCAST_DETAIL, TASK_BROADCAST_SIGN } from "@/api/api";
|
||||
@@ -146,6 +144,7 @@ import { useRoute } from "vue-router/dist/vue-router";
|
||||
import { useRouter } from "vue-router";
|
||||
import { useUserInfo } from "@/api/utils";
|
||||
import { ElMessage } from "element-plus";
|
||||
import dayjs from "dayjs";
|
||||
|
||||
const {
|
||||
query: { courseId: liveId, id: taskId, type, pName, sName },
|
||||
@@ -175,27 +174,70 @@ const state = reactive({
|
||||
});
|
||||
const { activeName, teacher } = toRefs(state);
|
||||
const signClick = () => {
|
||||
if (data.value.liveStartTime) {
|
||||
let date1 = new Date(data.value.liveStartTime).getTime()
|
||||
let date2 = new Date().getTime()
|
||||
if (date1 > date2) {
|
||||
ElMessage.info("未到开始时间,请耐心等待!");
|
||||
return;
|
||||
}
|
||||
if (!state.isAllowSign) {
|
||||
// console.log("data.signFlag", data.value.signFlag, isAllowSign);
|
||||
ElMessage.warning("未在允许签到时间范围内");
|
||||
return;
|
||||
}
|
||||
if (data.value.signFlag) {
|
||||
return;
|
||||
}
|
||||
data.value.signFlag = 1;
|
||||
ElMessage.info("签到成功");
|
||||
ElMessage.warning("签到成功");
|
||||
request(TASK_BROADCAST_SIGN, { courseId: liveId, taskId, type });
|
||||
};
|
||||
let timer = null;
|
||||
//判断能否签到
|
||||
function isSignClick() {
|
||||
timer = setInterval(() => {
|
||||
let beginTime = new Date(data.value.liveStartTime).getTime();
|
||||
let endTime = !data.value.afterSignIn
|
||||
? new Date(data.value.liveEndTime).getTime()
|
||||
: new Date(data.value.liveStartTime).getTime();
|
||||
let nowTime = new Date().getTime();
|
||||
if (data.value.beforeSignIn && data.value.afterSignIn) {
|
||||
//有开始前有开始后
|
||||
beginTime = beginTime - data.value.beforeSignIn * 60 * 1000;
|
||||
endTime = endTime + data.value.afterSignIn * 60 * 1000;
|
||||
console.log("1111");
|
||||
} else if (
|
||||
data.value.beforeSignIn &&
|
||||
!data.value.afterSignIn
|
||||
) {
|
||||
//只有开始前无开始后
|
||||
beginTime = beginTime - data.value.beforeSignIn * 60 * 1000;
|
||||
console.log("11112222");
|
||||
} else if (
|
||||
!data.value.beforeSignIn &&
|
||||
data.value.afterSignIn
|
||||
) {
|
||||
//无开始前有开始后
|
||||
endTime = endTime + data.value.afterSignIn * 60 * 1000;
|
||||
console.log("1111333");
|
||||
}
|
||||
if (nowTime < endTime && nowTime > beginTime) {
|
||||
state.isAllowSign = true;
|
||||
} else {
|
||||
state.isAllowSign = false;
|
||||
}
|
||||
// console.log(
|
||||
// "isAllowSign",
|
||||
// state.isAllowSign,
|
||||
// nowTime,
|
||||
// endTime,
|
||||
// beginTime,
|
||||
// nowTime < endTime,
|
||||
// nowTime > beginTime
|
||||
// );
|
||||
}, 1000);
|
||||
}
|
||||
isSignClick();
|
||||
const commitClick = () => {
|
||||
if (data.value.liveStartTime) {
|
||||
let date1 = new Date(data.value.liveStartTime).getTime()
|
||||
let date2 = new Date().getTime()
|
||||
if (date1 > date2) {
|
||||
ElMessage.info("未到开始时间,请耐心等待!");
|
||||
ElMessage.warning("未到时间,请耐心等待!");
|
||||
return;
|
||||
}
|
||||
}
|
||||
@@ -203,7 +245,7 @@ const commitClick = () => {
|
||||
// return;
|
||||
}
|
||||
if (data.value.isEvaluate == 0) {
|
||||
ElMessage.info("此直播无评估");
|
||||
ElMessage.warning("此直播无评估");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -235,12 +277,17 @@ function showClick() {
|
||||
let date1 = new Date(data.value.liveStartTime).getTime()
|
||||
let date2 = new Date().getTime()
|
||||
if (date1 > date2) {
|
||||
ElMessage.info("未到开始时间,请耐心等待!");
|
||||
ElMessage.warning("未到开始时间,请耐心等待!");
|
||||
return;
|
||||
}
|
||||
}
|
||||
window.open(data.value.liveLink);
|
||||
}
|
||||
onUnmounted(() => {
|
||||
if (timer) {
|
||||
clearInterval(timer);
|
||||
}
|
||||
});
|
||||
</script>
|
||||
|
||||
<!-- Add "scoped" attribute to limit CSS to this component only -->
|
||||
|
||||
@@ -160,7 +160,7 @@ const signClick = (tab, event) => {
|
||||
return;
|
||||
}
|
||||
data.value.signFlag = true;
|
||||
ElMessage.info("签到成功");
|
||||
ElMessage.warning("签到成功");
|
||||
request(TASK_ACTIVITY_SIGN, {
|
||||
courseId: activityId,
|
||||
taskId,
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
<!-- 面包屑导航 -->
|
||||
<div class="pdname">
|
||||
{{ userInfo.bandDesc }}
|
||||
<el-popover v-if="!data.remark" ref="popover" popper-class="jianjie" placement="right" trigger="hover" :width="300" :content="data.remark">
|
||||
<el-popover v-if="data.remark" ref="popover" popper-class="jianjie" placement="right" trigger="hover" :width="300" :content="data.remark">
|
||||
<template #reference><span style="font-size: 16px;font-weight: 600;">简介></span></template>
|
||||
</el-popover>
|
||||
</div>
|
||||
@@ -45,10 +45,13 @@
|
||||
(e) => !whiteTypes(e.type)
|
||||
)" :key="index">
|
||||
<div style="width: 70%">
|
||||
|
||||
<div v-if="value.name.length>50" class="coursename" :title="value.name">
|
||||
<el-popover ref="popover" placement="right" trigger="hover" :width="300" :content="value.name">
|
||||
<template #reference><div class="coursename" :title="value.name">{{ value.name }}</div></template>
|
||||
<template #reference>{{ value.name }}</template>
|
||||
</el-popover>
|
||||
</div>
|
||||
|
||||
<div v-else class="coursename" :title="value.name"></div>
|
||||
<div class="coursetag">
|
||||
<div v-if="value.flag" class="tag1" style="margin-right: 11px; margin-top: 16px">
|
||||
必修
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
|
||||
<div class="pdname">
|
||||
{{ userInfo.bandDesc }}
|
||||
<el-popover v-if="!data.remark" ref="popover" popper-class="jianjie" placement="right" trigger="hover" :width="300" :content="data.remark">
|
||||
<el-popover v-if="data.remark" ref="popover" popper-class="jianjie" placement="right" trigger="hover" :width="300" :content="data.remark">
|
||||
<template #reference><span style="font-size: 16px;font-weight: 600;">简介></span></template>
|
||||
</el-popover>
|
||||
</div>
|
||||
@@ -46,9 +46,15 @@
|
||||
:key="index"
|
||||
>
|
||||
<div style="width: 70%">
|
||||
<div v-if="value.name.length >50" class="coursename" :title="value.name">
|
||||
<el-popover ref="popover" placement="right" trigger="hover" :width="300" :content="value.name">
|
||||
<template #reference><div class="coursename" :title="value.name">{{ value.name }}</div></template>
|
||||
</el-popover>
|
||||
<template #reference>{{ value.name }}</template>
|
||||
</el-popover>
|
||||
</div>
|
||||
|
||||
<div v-else class="coursename" :title="value.name">
|
||||
{{ value.name }}
|
||||
</div>
|
||||
<div class="coursetag">
|
||||
<div
|
||||
class="tag1"
|
||||
|
||||
Reference in New Issue
Block a user