提交 4a52679b authored 作者: 王鹏飞's avatar 王鹏飞

chore: upgrade to vue2.7

上级 5ba4b5f3
module.exports = { module.exports = {
root: true,
env: { env: {
node: true node: true
}, },
extends: ['plugin:vue/essential', 'standard'], extends: ['eslint:recommended', 'plugin:vue/essential'],
rules: { rules: {
'vue/no-mutating-props': 'off', // 暂时关闭
'vue/comment-directive': 'off', 'vue/comment-directive': 'off',
'vue/multi-word-component-names': 'off', 'vue/multi-word-component-names': 'off',
'space-before-function-paren': 'off' 'vue/no-mutating-props': 'off' // 暂时关闭
} }
} }
{
"compilerOptions": {
"baseUrl": ".",
"paths": {
"@/*": ["src/*"]
}
},
"exclude": ["node_modules", "dist"],
"vueCompilerOptions": {
"target": 2.7
}
}
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -15,28 +15,23 @@ ...@@ -15,28 +15,23 @@
"axios": "^0.26.1", "axios": "^0.26.1",
"blueimp-md5": "^2.19.0", "blueimp-md5": "^2.19.0",
"echarts": "^5.2.2", "echarts": "^5.2.2",
"element-ui": "^2.15.6", "element-ui": "^2.15.12",
"js-base64": "^3.7.2", "js-base64": "^3.7.3",
"lodash": "^4.17.21", "lodash": "^4.17.21",
"query-string": "^7.1.1", "query-string": "^7.1.1",
"vue": "^2.6.14", "vue": "^2.7.14",
"vue-html2pdf": "^1.8.0", "vue-html2pdf": "^1.8.0",
"vue-router": "^3.5.3", "vue-router": "^3.6.5",
"vuex": "^3.6.2" "vuex": "^3.6.2"
}, },
"devDependencies": { "devDependencies": {
"@vitejs/plugin-vue2": "^2.0.1",
"ali-oss": "^6.17.1", "ali-oss": "^6.17.1",
"chalk": "^4.1.2", "chalk": "^4.1.2",
"eslint": "^7.32.0", "eslint": "^8.28.0",
"eslint-config-standard": "^16.0.3", "eslint-plugin-vue": "^9.8.0",
"eslint-plugin-import": "^2.25.3", "sass": "1.56.1",
"eslint-plugin-node": "^11.1.0", "vite": "^3.2.4",
"eslint-plugin-promise": "^5.1.1", "vite-plugin-checker": "^0.5.1"
"eslint-plugin-vue": "^8.5.0",
"sass": "1.49.10",
"vite": "^2.9.0",
"vite-plugin-checker": "^0.4.4",
"vite-plugin-vue2": "^1.9.3",
"vue-template-compiler": "^2.6.14"
} }
} }
...@@ -5,10 +5,7 @@ ...@@ -5,10 +5,7 @@
<aside class="question-list-hd__aside"><slot name="index"></slot></aside> <aside class="question-list-hd__aside"><slot name="index"></slot></aside>
</div> </div>
<div class="question-list-bd"> <div class="question-list-bd">
<h2 class="question-list-title" v-if="conmonTitle" v-html="conmonTitle"> <h2 class="question-list-title" v-if="commonTitle" v-html="commonTitle"></h2>
<!-- <span class="num">{{ page }}.</span> -->
<!-- {{ conmonTitle }} -->
</h2>
<question-list-item <question-list-item
v-for="(item, i) in data.question_list" v-for="(item, i) in data.question_list"
:data="item" :data="item"
...@@ -16,8 +13,7 @@ ...@@ -16,8 +13,7 @@
:page="data.question_list.length > 1 ? i + 1 : page" :page="data.question_list.length > 1 ? i + 1 : page"
:key="item.id" :key="item.id"
v-bind="$attrs" v-bind="$attrs"
v-on="$listeners" v-on="$listeners">
>
<slot v-bind="{ item, data }"></slot> <slot v-bind="{ item, data }"></slot>
</question-list-item> </question-list-item>
</div> </div>
...@@ -39,7 +35,7 @@ export default { ...@@ -39,7 +35,7 @@ export default {
return map[this.data.question_type] || this.data.question_type return map[this.data.question_type] || this.data.question_type
}, },
// 公共题干 // 公共题干
conmonTitle() { commonTitle() {
const [first = {}] = this.data.question_list || [] const [first = {}] = this.data.question_list || []
return first.common_content return first.common_content
} }
......
...@@ -4,14 +4,21 @@ ...@@ -4,14 +4,21 @@
<div class="order-num" v-if="questionParams.card"> <div class="order-num" v-if="questionParams.card">
<template v-for="(item, index) in questionParams.card"> <template v-for="(item, index) in questionParams.card">
<div :key="index" v-if="item"> <div :key="index" v-if="item">
<div class="tit">{{ item.find(tit => { return tit.question_item_title }).question_item_title }}</div> <div class="tit">
{{
item.find(tit => {
return tit.question_item_title
}).question_item_title
}}
</div>
<ul> <ul>
<template v-for="(cItem, cIndex) in item"> <template v-for="(cItem, cIndex) in item">
<li <li
:key="cItem.q_order + '-' + cIndex" :key="cItem.q_order + '-' + cIndex"
@click="goQuestion(cItem.q_order)" @click="goQuestion(cItem.q_order)"
:class="$route.query.id ? isAnalysisClass(cItem) + ' analy' : isClass(cItem)" :class="$route.query.id ? isAnalysisClass(cItem) + ' analy' : isClass(cItem)">
>{{ cItem.q_order }}</li> {{ cItem.q_order }}
</li>
</template> </template>
</ul> </ul>
</div> </div>
...@@ -65,7 +72,7 @@ export default { ...@@ -65,7 +72,7 @@ export default {
return this.questionParams.answerRecord return this.questionParams.answerRecord
}, },
isClass() { isClass() {
return (cItem) => { return cItem => {
const currentAnswer = this.questionParams.answerRecord[cItem.question_item_id] const currentAnswer = this.questionParams.answerRecord[cItem.question_item_id]
return this.questionParams.questionIndex + 1 === cItem.q_order return this.questionParams.questionIndex + 1 === cItem.q_order
? currentAnswer ? currentAnswer
...@@ -101,7 +108,7 @@ export default { ...@@ -101,7 +108,7 @@ export default {
} }
}, },
isAnalysisClass() { isAnalysisClass() {
return (cItem) => { return cItem => {
const findItems = this.questionParams.beforeData.answers[cItem.question_item_id] const findItems = this.questionParams.beforeData.answers[cItem.question_item_id]
const scoreItems = this.questionParams.beforeData.score_items[cItem.question_item_id][cItem.id] const scoreItems = this.questionParams.beforeData.score_items[cItem.question_item_id][cItem.id]
return findItems return findItems
...@@ -123,13 +130,13 @@ export default { ...@@ -123,13 +130,13 @@ export default {
const id = this.questionParams.question const id = this.questionParams.question
this.questionParams.answerRecord[id.question_item_id] this.questionParams.answerRecord[id.question_item_id]
? this.questionParams.answerRecord[id.question_item_id][id.id] ? this.questionParams.answerRecord[id.question_item_id][id.id]
? this.questionParams.answerRecord[id.question_item_id][id.id].sign = stu ? (this.questionParams.answerRecord[id.question_item_id][id.id].sign = stu)
: this.questionParams.answerRecord[id.question_item_id][id.id] = { : (this.questionParams.answerRecord[id.question_item_id][id.id] = {
sign: stu sign: stu
} })
: this.questionParams.answerRecord[id.question_item_id] = { : (this.questionParams.answerRecord[id.question_item_id] = {
[id.id]: { sign: stu } [id.id]: { sign: stu }
} })
this.$forceUpdate() this.$forceUpdate()
}, },
monitoringChanges() { monitoringChanges() {
...@@ -140,36 +147,36 @@ export default { ...@@ -140,36 +147,36 @@ export default {
} }
}, },
watch: { watch: {
changeQuestionIndex(newV, oldV) { changeQuestionIndex() {
this.$forceUpdate() this.$forceUpdate()
} }
} }
} }
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.info{ .info {
display: flex; display: flex;
align-items: center; align-items: center;
height: 100px; height: 100px;
.shape{ .shape {
width: 60px; width: 60px;
height: 60px; height: 60px;
border-radius: 50%; border-radius: 50%;
overflow: hidden; overflow: hidden;
} }
img{ img {
width: 75px; width: 75px;
// transform: scale(1); // transform: scale(1);
display: block; display: block;
} }
.right{ .right {
margin-left: 22px; margin-left: 22px;
.name{ .name {
font-size: 18px; font-size: 18px;
color: #222222; color: #222222;
line-height: 25px; line-height: 25px;
} }
.code{ .code {
font-size: 14px; font-size: 14px;
color: #222222; color: #222222;
line-height: 20px; line-height: 20px;
...@@ -177,54 +184,54 @@ export default { ...@@ -177,54 +184,54 @@ export default {
} }
} }
} }
.order-num{ .order-num {
padding-top: 20px; padding-top: 20px;
padding-bottom: 90px; padding-bottom: 90px;
.tit{ .tit {
font-size: 12px; font-size: 12px;
color: #999999; color: #999999;
line-height: 17px; line-height: 17px;
margin-bottom: 10px; margin-bottom: 10px;
} }
ul{ ul {
display: flex; display: flex;
list-style: none; list-style: none;
padding: 0; padding: 0;
margin: 0; margin: 0;
flex-wrap: wrap; flex-wrap: wrap;
li{ li {
cursor: pointer; cursor: pointer;
position: relative; position: relative;
border-radius: 50px; border-radius: 50px;
width: 24px; width: 24px;
height: 24px; height: 24px;
border: 1px solid #CCCCCC; border: 1px solid #cccccc;
font-size: 14px; font-size: 14px;
color: #666666; color: #666666;
line-height: 24px; line-height: 24px;
margin-right: 20px; margin-right: 20px;
margin-bottom: 10px; margin-bottom: 10px;
text-align: center; text-align: center;
&:nth-child(5n+5){ &:nth-child(5n + 5) {
margin-right: 0; margin-right: 0;
} }
&.analy{ &.analy {
&.stu1{ &.stu1 {
border: 2px solid #0FC118; border: 2px solid #0fc118;
line-height: 22px; line-height: 22px;
background: #fff; background: #fff;
color: #999; color: #999;
} }
&.stu2{ &.stu2 {
border: 2px solid #C01540; border: 2px solid #c01540;
line-height: 22px; line-height: 22px;
background: #fff; background: #fff;
color: #999; color: #999;
} }
&.stu3{ &.stu3 {
color: #fff; color: #fff;
background: #999999; background: #999999;
&::after{ &::after {
content: ''; content: '';
position: absolute; position: absolute;
top: -1px; top: -1px;
...@@ -236,208 +243,208 @@ export default { ...@@ -236,208 +243,208 @@ export default {
} }
} }
} }
&.stu1{ &.stu1 {
background: #999; background: #999;
border: 1px solid #999; border: 1px solid #999;
color: #fff; color: #fff;
} }
&.stu2{ &.stu2 {
width: 22px; width: 22px;
height: 22px; height: 22px;
line-height: 22px; line-height: 22px;
border: 2px solid #0FC118; border: 2px solid #0fc118;
} }
&.stu3{ &.stu3 {
&::after{ &::after {
content: ''; content: '';
position: absolute; position: absolute;
top: -1px; top: -1px;
right: -1px; right: -1px;
width: 4px; width: 4px;
height: 4px; height: 4px;
background: #C01540; background: #c01540;
border-radius: 50%; border-radius: 50%;
} }
} }
} }
} }
} }
.flag-tips{ .flag-tips {
width: 260px; width: 260px;
position: fixed; position: fixed;
bottom: 60px; bottom: 60px;
right:0; right: 0;
display: flex; display: flex;
justify-content: space-around; justify-content: space-around;
padding: 15px 0 10px; padding: 15px 0 10px;
background: #fff; background: #fff;
margin: 0; margin: 0;
list-style: none; list-style: none;
li{ li {
.circle1{ .circle1 {
width: 24px; width: 24px;
height: 24px; height: 24px;
background: #EEEEEE; background: #eeeeee;
border: 1px solid #CCCCCC; border: 1px solid #cccccc;
border-radius: 50%; border-radius: 50%;
} }
.circle1{ .circle1 {
width: 24px; width: 24px;
height: 24px; height: 24px;
border: 1px solid #CCCCCC; border: 1px solid #cccccc;
border-radius: 50%; border-radius: 50%;
} }
.circle2{ .circle2 {
width: 24px; width: 24px;
height: 24px; height: 24px;
border: 1px solid #CCCCCC; border: 1px solid #cccccc;
border-radius: 50%; border-radius: 50%;
} }
.circle3{ .circle3 {
width: 24px; width: 24px;
height: 24px; height: 24px;
border: 2px solid #0FC118; border: 2px solid #0fc118;
border-radius: 50%; border-radius: 50%;
} }
.circle4{ .circle4 {
position: relative; position: relative;
width: 24px; width: 24px;
height: 24px; height: 24px;
border: 1px solid #CCCCCC; border: 1px solid #cccccc;
border-radius: 50%; border-radius: 50%;
&::after{ &::after {
content: ''; content: '';
position: absolute; position: absolute;
top: -1px; top: -1px;
right: -1px; right: -1px;
width: 4px; width: 4px;
height: 4px; height: 4px;
background: #C01540; background: #c01540;
border-radius: 50%; border-radius: 50%;
} }
} }
.txt{ .txt {
margin-top: 5px; margin-top: 5px;
font-size: 12px; font-size: 12px;
color: #CCCCCC; color: #cccccc;
line-height: 17px; line-height: 17px;
} }
} }
} }
.flag-tips{ .flag-tips {
width: 260px; width: 260px;
position: fixed; position: fixed;
bottom: 60px; bottom: 60px;
right:0; right: 0;
display: flex; display: flex;
justify-content: space-around; justify-content: space-around;
padding: 15px 0 10px; padding: 15px 0 10px;
background: #fff; background: #fff;
margin: 0; margin: 0;
list-style: none; list-style: none;
li{ li {
.circle1{ .circle1 {
width: 24px; width: 24px;
height: 24px; height: 24px;
background: #999; background: #999;
border: 1px solid #999; border: 1px solid #999;
border-radius: 50%; border-radius: 50%;
} }
.circle2{ .circle2 {
width: 24px; width: 24px;
height: 24px; height: 24px;
border: 1px solid #CCCCCC; border: 1px solid #cccccc;
border-radius: 50%; border-radius: 50%;
} }
.circle3{ .circle3 {
width: 24px; width: 24px;
height: 24px; height: 24px;
border: 2px solid #0FC118; border: 2px solid #0fc118;
background: rgba(15, 193, 24, 0.1); background: rgba(15, 193, 24, 0.1);
border-radius: 50%; border-radius: 50%;
} }
.circle4{ .circle4 {
position: relative; position: relative;
width: 24px; width: 24px;
height: 24px; height: 24px;
border: 1px solid #CCCCCC; border: 1px solid #cccccc;
border-radius: 50%; border-radius: 50%;
&::after{ &::after {
content: ''; content: '';
position: absolute; position: absolute;
top: -1px; top: -1px;
right: -1px; right: -1px;
width: 4px; width: 4px;
height: 4px; height: 4px;
background: #C01540; background: #c01540;
border-radius: 50%; border-radius: 50%;
} }
} }
.txt{ .txt {
margin-top: 5px; margin-top: 5px;
font-size: 12px; font-size: 12px;
color: #CCCCCC; color: #cccccc;
line-height: 17px; line-height: 17px;
} }
} }
} }
.tips-box{ .tips-box {
width: 260px; width: 260px;
position: fixed; position: fixed;
bottom: 60px; bottom: 60px;
right:0; right: 0;
display: flex; display: flex;
justify-content: space-around; justify-content: space-around;
padding: 15px 0 10px; padding: 15px 0 10px;
background: #fff; background: #fff;
margin: 0; margin: 0;
list-style: none; list-style: none;
li{ li {
&:nth-child(2){ &:nth-child(2) {
// margin: 0 50px; // margin: 0 50px;
} }
.circle1{ .circle1 {
width: 24px; width: 24px;
height: 24px; height: 24px;
background: #fff; background: #fff;
border: 2px solid #0FC118; border: 2px solid #0fc118;
border-radius: 50%; border-radius: 50%;
box-sizing: border-box; box-sizing: border-box;
} }
.circle2{ .circle2 {
width: 24px; width: 24px;
height: 24px; height: 24px;
border: 2px solid #C01540; border: 2px solid #c01540;
border-radius: 50%; border-radius: 50%;
box-sizing: border-box; box-sizing: border-box;
} }
.circle3{ .circle3 {
width: 24px; width: 24px;
height: 24px; height: 24px;
background: #999999; background: #999999;
border-radius: 50%; border-radius: 50%;
} }
.circle4{ .circle4 {
position: relative; position: relative;
width: 24px; width: 24px;
height: 24px; height: 24px;
border: 1px solid #CCCCCC; border: 1px solid #cccccc;
border-radius: 50%; border-radius: 50%;
&::after{ &::after {
content: ''; content: '';
position: absolute; position: absolute;
top: -1px; top: -1px;
right: -1px; right: -1px;
width: 4px; width: 4px;
height: 4px; height: 4px;
background: #C01540; background: #c01540;
border-radius: 50%; border-radius: 50%;
} }
} }
.txt{ .txt {
margin-top: 5px; margin-top: 5px;
font-size: 12px; font-size: 12px;
color: #CCCCCC; color: #cccccc;
line-height: 17px; line-height: 17px;
} }
} }
......
...@@ -19,7 +19,7 @@ export default function (blobInfo, succFun, failFun) { ...@@ -19,7 +19,7 @@ export default function (blobInfo, succFun, failFun) {
failFun('上传失败') failFun('上传失败')
}) })
}) })
.catch(response => { .catch(() => {
failFun('获取Signature失败') failFun('获取Signature失败')
}) })
} }
...@@ -56,14 +56,14 @@ export default { ...@@ -56,14 +56,14 @@ export default {
.catch(this.$refs.countdown.stop) .catch(this.$refs.countdown.stop)
}, },
checkCode() { checkCode() {
api.checkCode(this.ruleForm).then(response => { api.checkCode(this.ruleForm).then(() => {
this.updateUser() this.updateUser()
}) })
}, },
updateUser() { updateUser() {
api api
.updateUser({ mobile: this.ruleForm.account }) .updateUser({ mobile: this.ruleForm.account })
.then(response => { .then(() => {
this.$message({ type: 'success', message: '手机号码修改成功' }) this.$message({ type: 'success', message: '手机号码修改成功' })
this.$store.dispatch('getUser') this.$store.dispatch('getUser')
this.$emit('success') this.$emit('success')
......
...@@ -98,7 +98,7 @@ export default { ...@@ -98,7 +98,7 @@ export default {
}, },
// 发送邮箱验证码 // 发送邮箱验证码
sendEmailCode(account) { sendEmailCode(account) {
api.sendCode({ account }).then(response => { api.sendCode({ account }).then(() => {
this.$message({ message: '验证码发送成功,请前往邮箱获取验证码', type: 'success' }) this.$message({ message: '验证码发送成功,请前往邮箱获取验证码', type: 'success' })
}) })
}, },
...@@ -108,7 +108,7 @@ export default { ...@@ -108,7 +108,7 @@ export default {
}, },
// 校验验证码 // 校验验证码
checkCode() { checkCode() {
api.checkCode(this.ruleForm).then(response => { api.checkCode(this.ruleForm).then(() => {
this.$emit('success') this.$emit('success')
}) })
} }
......
...@@ -61,7 +61,7 @@ export default { ...@@ -61,7 +61,7 @@ export default {
this.submitLoading = true this.submitLoading = true
api api
.updatePassword(this.ruleForm) .updatePassword(this.ruleForm)
.then(response => { .then(() => {
this.$message({ message: '密码修改成功', type: 'success' }) this.$message({ message: '密码修改成功', type: 'success' })
// 重置表单 // 重置表单
this.$refs.ruleForm.resetFields() this.$refs.ruleForm.resetFields()
......
...@@ -9,8 +9,7 @@ ...@@ -9,8 +9,7 @@
:video="chatperResources.video" :video="chatperResources.video"
@timeupdate="onTimeupdate" @timeupdate="onTimeupdate"
@ready="onReady" @ready="onReady"
ref="videoPlayer" ref="videoPlayer"></video-player>
></video-player>
</div> </div>
<div class="player-column" v-if="pptVisible"> <div class="player-column" v-if="pptVisible">
<!-- ppt --> <!-- ppt -->
...@@ -19,8 +18,7 @@ ...@@ -19,8 +18,7 @@
:ppts="chatperResources.ppts" :ppts="chatperResources.ppts"
@close="onPPTClose" @close="onPPTClose"
@fullscreen="onPPTFullscreen" @fullscreen="onPPTFullscreen"
@videoSyncTime="onVideoSyncTime" @videoSyncTime="onVideoSyncTime"></ppt-player>
></ppt-player>
</div> </div>
</div> </div>
<div class="player-footer"> <div class="player-footer">
...@@ -221,7 +219,7 @@ export default { ...@@ -221,7 +219,7 @@ export default {
}) })
}, },
// 更新章节视频进度 // 更新章节视频进度
updateChapterVideoProgress(time, durations) { updateChapterVideoProgress() {
// 登录用户信息 // 登录用户信息
const user = this.$store.state.user const user = this.$store.state.user
const params = { const params = {
......
...@@ -14,13 +14,14 @@ ...@@ -14,13 +14,14 @@
</template> </template>
</div> </div>
<div class="ppt-player-controls__pages"> <div class="ppt-player-controls__pages">
<span class="is-active">{{currentIndex + 1}}</span> <span class="is-active">{{ currentIndex + 1 }}</span>
/ /
<span>{{ppts.length}}</span> <span>{{ ppts.length }}</span
>
</div> </div>
<div class="ppt-player-controls__tools"> <div class="ppt-player-controls__tools">
<el-tooltip content="PPT同步视频播放"> <el-tooltip content="PPT同步视频播放">
<i :class="['el-icon-self-xuexiao', (isSync ? 'active' : '')]" @click="onToggleSync"></i> <i :class="['el-icon-self-xuexiao', isSync ? 'active' : '']" @click="onToggleSync"></i>
</el-tooltip> </el-tooltip>
<el-tooltip content="放大PPT"> <el-tooltip content="放大PPT">
<i class="el-icon-self-quanping" @click="fullscreen"></i> <i class="el-icon-self-quanping" @click="fullscreen"></i>
...@@ -62,9 +63,7 @@ export default { ...@@ -62,9 +63,7 @@ export default {
}, },
computed: { computed: {
pptUrl() { pptUrl() {
return this.ppts[this.currentIndex] return this.ppts[this.currentIndex] ? this.ppts[this.currentIndex].ppt_url : ''
? this.ppts[this.currentIndex].ppt_url
: ''
} }
}, },
methods: { methods: {
...@@ -78,14 +77,14 @@ export default { ...@@ -78,14 +77,14 @@ export default {
this.currentIndex = this.getIndex(this.currentIndex - 1) this.currentIndex = this.getIndex(this.currentIndex - 1)
this.isSync = false this.isSync = false
}, },
next(e) { next() {
this.currentIndex = this.getIndex(this.currentIndex + 1) this.currentIndex = this.getIndex(this.currentIndex + 1)
this.isSync = false this.isSync = false
}, },
onToggleSync(e) { onToggleSync() {
this.isSync = !this.isSync this.isSync = !this.isSync
}, },
setVideoTime(e) { setVideoTime() {
this.isSync = true this.isSync = true
this.$emit('videoSyncTime', this.ppts[this.currentIndex].ppt_point) this.$emit('videoSyncTime', this.ppts[this.currentIndex].ppt_point)
}, },
......
...@@ -37,16 +37,16 @@ export default { ...@@ -37,16 +37,16 @@ export default {
controlBarVisibility: 'always', controlBarVisibility: 'always',
useHlsPluginForSafari: true useHlsPluginForSafari: true
}, },
function(player) { function (player) {
player.on('ready', function() { player.on('ready', function () {
// 跳过片头 // 跳过片头
_this.isSkip && player.seek(6) _this.isSkip && player.seek(6)
_this.$emit('ready', player) _this.$emit('ready', player)
}) })
player.on('timeupdate', function(event) { player.on('timeupdate', function () {
_this.$emit('timeupdate', player.getCurrentTime()) _this.$emit('timeupdate', player.getCurrentTime())
}) })
player.on('error', function(event) { player.on('error', function (event) {
console.log(event) console.log(event)
}) })
} }
......
...@@ -11,8 +11,7 @@ ...@@ -11,8 +11,7 @@
@submit="submitExam" @submit="submitExam"
@back="handleBack" @back="handleBack"
ref="exam" ref="exam"
v-if="Object.keys(data).length" v-if="Object.keys(data).length"></exam-card>
></exam-card>
</div> </div>
</template> </template>
<script> <script>
...@@ -113,7 +112,7 @@ export default { ...@@ -113,7 +112,7 @@ export default {
answers: JSON.stringify(answer), answers: JSON.stringify(answer),
duration: duration duration: duration
} }
api.setCache(param).then(response => { api.setCache(param).then(() => {
if (isCache) { if (isCache) {
clearInterval(this.cacheAnswerTime) clearInterval(this.cacheAnswerTime)
this.$router.replace({ path: '/exam/exam/result', query: { exam_id: this.examId } }) this.$router.replace({ path: '/exam/exam/result', query: { exam_id: this.examId } })
......
...@@ -249,8 +249,7 @@ export default { ...@@ -249,8 +249,7 @@ export default {
} }
}, },
watch: { watch: {
dialogVisible: function (newVal, oldVal) { dialogVisible() {
console.log(this.dialogVisible)
let numTime = 20 let numTime = 20
if (this.dialogVisible && !this.isRead) { if (this.dialogVisible && !this.isRead) {
clearInterval(this.noticeTimes) clearInterval(this.noticeTimes)
......
import fs from 'fs' import fs from 'fs'
import path from 'path' import path from 'path'
import { defineConfig } from 'vite' import { defineConfig } from 'vite'
import { createVuePlugin } from 'vite-plugin-vue2' import vue from '@vitejs/plugin-vue2'
import checker from 'vite-plugin-checker' import checker from 'vite-plugin-checker'
export default defineConfig(({ mode }) => { export default defineConfig(({ mode }) => {
return { return {
base: mode === 'prod' ? 'https://webapp-pub.ezijing.com/website/prod/fd-learn/' : '/', base: mode === 'prod' ? 'https://webapp-pub.ezijing.com/website/prod/fd-learn/' : '/',
plugins: [ plugins: [vue(), checker({ eslint: { lintCommand: 'eslint "./src/**/*.{vue,js,jsx,ts,tsx}"' } })],
checker({
eslint: { lintCommand: 'eslint "./src/**/*.{vue,js,jsx,ts,tsx}"' }
}),
createVuePlugin()
],
server: { server: {
open: true, open: true,
host: 'dev.ezijing.com', host: 'dev.ezijing.com',
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论