<template>
|
<view class="user_index">
|
<view class="user_index_info">
|
<text class="info_title">{{userData.examName}}</text>
|
<view class="user_info_user">
|
<view style="margin-bottom: 10px;">答题人</view>
|
<u-icon
|
name="account-fill"
|
color="#1976FF"
|
size="22px"
|
:label="realName"
|
labelSize="22px"
|
labelColor="#1976FF">
|
</u-icon>
|
</view>
|
<view class="user_info_button">
|
<u-button type="primary" color="#1976FF" text="开始答题" @click="startCheck()"></u-button>
|
</view>
|
</view>
|
</view>
|
</template>
|
|
<script>
|
export default {
|
data() {
|
return {
|
userData: {},
|
realName: ''
|
}
|
},
|
onLoad(option) {
|
const data = JSON.parse(option.data);
|
this.userData = data;
|
this.realName = uni.getStorageSync('realName');
|
console.log(data,'=====');
|
},
|
methods: {
|
// 开始答题
|
startCheck() {
|
uni.navigateTo({
|
url: './topic?examId=' + this.userData.examId
|
})
|
}
|
}
|
}
|
</script>
|
|
<style scoped lang="scss">
|
.user_index {
|
height: 100vh;
|
padding: 10px 10px 0;
|
background: #DBDDDF;
|
height: calc(100vh - 10px);
|
|
.user_index_info {
|
display: flex;
|
flex-direction: column;
|
align-items: center;
|
padding: 30px 15px;
|
background: #FFFFFF;
|
border-radius: 8px;
|
|
.info_title {
|
font-size: 20px;
|
}
|
}
|
|
.user_info_user {
|
margin: 40px 0 50px;
|
color: #9E9E9E;
|
font-size: 14px;
|
|
&>view {
|
text-align: center;
|
}
|
}
|
|
.user_info_button {
|
width: 100%;
|
}
|
}
|
</style>
|