security_center.vue
3.0 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
<template>
<view style="background-color: #f5f5f5; height: 100vh;">
<view class="title_bg" :style="'padding-top:' + (common.statusBarH + 10)+ 'px; '">
<image style="width: 40rpx; height: 40rpx;" src='../../static/common/icon_back.png' @click="onBack()">
</image>
<text style="color: white; font-size: 36rpx; font-weight: 700; margin-left: 15rpx;">安全中心</text>
<image style="width: 40rpx; height: 40rpx;">
</image>
</view>
<view :style="'height: ' + titleHeight + 'px'"></view>
<view class="data-item" @click="goToShare()">
<text>身份证</text>
<view style="display: flex; justify-content: center; align-items: center;">
<text :class="userInfo.IdCard ? 'text2' : 'text1'">{{userInfo.Mobile ? "已绑定" : "绑定身份证,账号更安全"}}</text>
<image style="width: 28rpx; height: 28rpx; margin-left: 15rpx;" src="../../static/arrow_right.png">
</image>
</view>
</view>
<view class="data-item" @click="goToShare()">
<text>手机</text>
<view style="display: flex; justify-content: center; align-items: center;">
<text :class="userInfo.Mobile ? 'text2' : 'text1'">{{userInfo.Mobile ? "已绑定" : "绑定手机"}}</text>
<image style="width: 28rpx; height: 28rpx; margin-left: 15rpx;" src="../../static/arrow_right.png">
</image>
</view>
</view>
<view class="data-item" @click="goToShare()">
<text>修改密码</text>
<view style="display: flex; justify-content: center; align-items: center;">
<text class="text1">修改登录密码</text>
<image style="width: 28rpx; height: 28rpx; margin-left: 15rpx;" src="../../static/arrow_right.png">
</image>
</view>
</view>
</view>
</template>
<script>
import common from '@/utils/common.js'
import loginHelper from "../../utils/loginHelper.js"
export default {
data() {
return {
titleHeight: 80,
common,
userInfo: {}
}
},
onReady() {
var this_ = this
uni.createSelectorQuery()
.in(this)
.select('.title_bg')
.boundingClientRect((rect) => {
if (rect) {
this_.titleHeight = rect.height
console.log("rect.height:" + rect.height)
}
})
.exec();
this.userInfo = loginHelper.getUserInfo()
},
onShow() {
},
methods: {
}
}
</script>
<style>
.title_bg {
background: linear-gradient(90deg, #FF6F38 0%, #FFA04B 100%);
display: flex;
justify-content: space-between;
align-items: center;
padding-left: 24rpx;
padding-right: 24rpx;
padding-bottom: 20rpx;
position: fixed;
top: 0;
left: 0;
right: 0;
z-index: 999;
}
.data-item {
display: flex;
justify-content: space-between;
align-items: center;
height: 110rpx;
background-color: white;
margin-top: 3rpx;
margin-bottom: 3rpx;
padding-left: 30rpx;
padding-right: 30rpx;
}
.text1 {
font-size: 30rpx;
color: #B0B0B0;
}
.text2 {
font-size: 30rpx;
color: #666666;
}
</style>