|
@@ -62,6 +62,7 @@
|
|
<script>
|
|
<script>
|
|
import Clipboard from 'clipboard'
|
|
import Clipboard from 'clipboard'
|
|
import { Toast } from 'vant'
|
|
import { Toast } from 'vant'
|
|
|
|
+ import { getUserInfo } from './api'
|
|
|
|
|
|
export default {
|
|
export default {
|
|
name: 'mine',
|
|
name: 'mine',
|
|
@@ -72,6 +73,7 @@
|
|
}
|
|
}
|
|
},
|
|
},
|
|
mounted () {
|
|
mounted () {
|
|
|
|
+ this.funInit()
|
|
this.clipboardJs = new Clipboard('.btn-copy')
|
|
this.clipboardJs = new Clipboard('.btn-copy')
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
@@ -88,6 +90,15 @@
|
|
}
|
|
}
|
|
this.clipboardJs.text = () => inviteCode
|
|
this.clipboardJs.text = () => inviteCode
|
|
Toast('复制成功')
|
|
Toast('复制成功')
|
|
|
|
+ },
|
|
|
|
+ funInit () {
|
|
|
|
+ getUserInfo().then(res => {
|
|
|
|
+ if (res.status) {} else {
|
|
|
|
+ Toast(res.msg)
|
|
|
|
+ }
|
|
|
|
+ }).catch(err => {
|
|
|
|
+ Toast(err)
|
|
|
|
+ })
|
|
}
|
|
}
|
|
},
|
|
},
|
|
beforeDestroy () {
|
|
beforeDestroy () {
|