You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

127 lines
2.1 KiB

3 years ago
<template>
<view class="notbegun">
3 years ago
<view class="tuichu" @click="tuichu" v-if="lastOne">退出登录</view>
3 years ago
<view class="content">
<view class="img">
<image src="../../static/qidai.png" mode=""></image>
</view>
<view class="test">
<text>考试结束
</text>
</view>
</view>
</view>
</template>
<script>
3 years ago
import {
dradis
} from "../../api/api.js"
3 years ago
export default {
data() {
return {
3 years ago
examinerId: "",
timer1:null,
lastOne:false
3 years ago
}
},
methods: {
tuichu() {
uni.navigateTo({
url: '../login/login'
3 years ago
});
clearInterval(this.timer1)
3 years ago
}
3 years ago
},
onLoad() {
// 考官id
this.examinerId = uni.getStorageSync("examinerId");
dradis({
examinerId: this.examinerId
}).then((res) => {
this.lastOne=res.data.state;
if (res.data.state) {
return
} else {
this.timer1=setInterval(()=>{
dradis({
examinerId: this.examinerId
}).then((res)=>{
this.lastOne=res.data.state;
if(res.data.begin){
uni.navigateTo({
url:"../Test1/Test1"
})
clearInterval(this.timer1)
}
})
},5000)
}
})
3 years ago
}
}
</script>
<style lang="scss">
.tuichu {
position: fixed;
width: 120rpx;
height: 38rpx;
border-radius: 24rpx 24rpx 24rpx 24rpx;
border: 2rpx solid #27C5FF;
box-sizing: border-box;
color: #27C5FF;
display: flex;
align-items: center;
justify-content: center;
margin-right: 20rpx;
right: 40rpx;
top: 30rpx;
}
page {
// background-color: #F5F7FA;
}
.notbegun {
width: 100%;
height: 100vh;
.content {
width: 100%;
height: 100%;
background: #FFFFFF;
box-shadow: 3rpx 0rpx 14rpx 1rpx rgba(0, 0, 0, 0.05);
// border-radius: 19rpx;
margin: 0rpx auto;
margin-top: 20rpx;
display: flex;
justify-content: center;
align-items: center;
flex-direction: column;
.img {
image {
width: 260rpx;
height: 260rpx;
}
}
.test {
font-size: 24rpx;
font-weight: 400;
color: #333333;
margin-top: 20rpx;
}
}
}
</style>