个人中心文版通账号可复制功能实现
This commit is contained in:
@@ -95,6 +95,12 @@
|
||||
导出助记词
|
||||
<uni-icons class="forward" type="forward" color="#999" />
|
||||
</view>
|
||||
<view class="btns-box-item" @click="onWbt">
|
||||
<image class="icon" src="@/static/user/userIcon_02.png" mode="widthFix" />
|
||||
文版通账号
|
||||
<uni-icons class="forward" type="forward" color="#999" />
|
||||
</view>
|
||||
|
||||
<view class="btns-box-item" @click="resetPassword">
|
||||
<image class="icon" src="@/static/user/userIcon_13.png" mode="widthFix" />
|
||||
{{hasPassword ? '修改' : '设置'}}支付密码
|
||||
@@ -152,7 +158,7 @@
|
||||
<view>The total force ecological</view>
|
||||
</view>
|
||||
<!-- 助记词弹出框 -->
|
||||
<u-modal :show="wordsShow" :zoom="false" confirmText="复制" @confirm="copyWord" confirmColor="#34CE98">
|
||||
<u-modal :show="wordsShow" :zoom="false" confirmText="复制" @confirm="copyWord('zjc')" confirmColor="#34CE98">
|
||||
<slot default>
|
||||
<view class="wordsCont">
|
||||
<view class="wordsCont-title">导出助记词</view>
|
||||
@@ -163,6 +169,18 @@
|
||||
</view>
|
||||
</slot>
|
||||
</u-modal>
|
||||
<!-- 查看文版通账号 -->
|
||||
<u-modal :show="wbtShow" :zoom="false" confirmText="复制" @confirm="copyWord('wbt')" confirmColor="#34CE98">
|
||||
<slot default>
|
||||
<view class="wordsCont">
|
||||
<view class="wordsCont-title">文版通账号</view>
|
||||
<view class="wordsCont-tips">请务必抄下文版通账号并存在安全的地方,若文版通账号丢失,重装或换设备登录时将无法查看历史消息!若文版通账号被他人获取,将可能获取你的信息!</view>
|
||||
<view class="wordsCont-text">账号:{{wbtAccount}}</view>
|
||||
<image class="wordsCont-close" @click="wordsShow = false;wbtShow= false;" src="@/static/icon/userCloes.png"
|
||||
mode="widthFix"></image>
|
||||
</view>
|
||||
</slot>
|
||||
</u-modal>
|
||||
<!-- 输入支付密码 -->
|
||||
<u-modal :show="showIv" title="请输入钱包支付密码" :showCancelButton="true" confirmColor="#34CE98" negativeTop="160"
|
||||
@confirm="validationIv" @cancel="()=>{ this.showIv = false, this.iv = '' }">
|
||||
@@ -224,6 +242,8 @@
|
||||
// 数据看板权限
|
||||
canSeeData: false,
|
||||
messages:0,
|
||||
wbtAccount:'',
|
||||
wbtShow:false,
|
||||
};
|
||||
},
|
||||
onShow() {
|
||||
@@ -231,14 +251,29 @@
|
||||
this.getInfo();
|
||||
},
|
||||
methods: {
|
||||
zzz(){
|
||||
console.log('....');
|
||||
onWbt(){
|
||||
console.log(this.wbtAccount);
|
||||
if(this.wbtAccount === ''){
|
||||
uni.showModal({
|
||||
title:'温馨提示',
|
||||
content:'当前账号没有绑定文版通账号,是否现在就去绑定',
|
||||
confirmText:'立即绑定',
|
||||
cancelText:'先不绑定',
|
||||
success:(res) => {
|
||||
if(res.confirm){
|
||||
this.$Router.push({name:'WbtBind'})
|
||||
}
|
||||
}
|
||||
})
|
||||
}else{
|
||||
console.log('....')
|
||||
this.wbtShow = true;
|
||||
}
|
||||
},
|
||||
// 用户信息
|
||||
getInfo() {
|
||||
if (this.$store.state.token === '') return;
|
||||
info().then(res => {
|
||||
console.log(res)
|
||||
uni.setNavigationBarTitle({
|
||||
title: res.nickname
|
||||
});
|
||||
@@ -257,6 +292,7 @@
|
||||
this.serial = res.serial;
|
||||
this.hasPassword = res.has_transfer_password;
|
||||
this.messages = Number(res.messages);
|
||||
this.wbtAccount = res.wbt_account;
|
||||
})
|
||||
.catch(err => {
|
||||
uni.showToast({
|
||||
@@ -322,7 +358,6 @@
|
||||
},
|
||||
// 按钮导航
|
||||
onBtn(name, params) {
|
||||
console.log('name',name);
|
||||
this.$Router.push({
|
||||
name,
|
||||
params
|
||||
@@ -371,13 +406,14 @@
|
||||
}
|
||||
},
|
||||
// 复制助记词
|
||||
copyWord() {
|
||||
copyWord(type) {
|
||||
uni.setClipboardData({
|
||||
data: this.mnemonic,
|
||||
data: type === 'zjc'?this.mnemonic:this.wbtAccount,
|
||||
success: () => {
|
||||
this.wordsShow = false
|
||||
this.wbtShow = false
|
||||
uni.showToast({
|
||||
title: '助记词已复制',
|
||||
title: type === 'zjc' ? '助记词已复制' : '文版通账号已复制',
|
||||
icon: 'none',
|
||||
mask: true
|
||||
})
|
||||
|
||||
3054
unpackage/dist/dev/app-plus/app-service.js
vendored
3054
unpackage/dist/dev/app-plus/app-service.js
vendored
File diff suppressed because one or more lines are too long
2039
unpackage/dist/dev/app-plus/app-view.js
vendored
2039
unpackage/dist/dev/app-plus/app-view.js
vendored
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user