|
|
@@ -33,6 +33,7 @@ import { mapGetters } from 'vuex'
|
|
|
import TuiListCell from '@/components/plugin/list-cell'
|
|
|
const form = require('@/utils/formValidation.js')
|
|
|
// api
|
|
|
+import { getSelfInfo } from '@/utils/auth'
|
|
|
import { updatePassword, updateConfirmPassword } from '@/api/login'
|
|
|
export default {
|
|
|
name: 'password-setting',
|
|
|
@@ -69,15 +70,15 @@ export default {
|
|
|
computed: {
|
|
|
...mapGetters({ selfInfo: 'getSelfInfo' }),
|
|
|
isOldPass() {
|
|
|
- let status = this.tabIndex == 1 ? this.selfInfo.password : this.selfInfo.confirmPassword
|
|
|
+ let status = this.selfInfo ? this.tabIndex == 1 ? this.selfInfo.password : this.selfInfo.confirmPassword : false
|
|
|
return !!status
|
|
|
}
|
|
|
},
|
|
|
onLoad() {
|
|
|
- // getSelfInfo().then(res => {
|
|
|
+ getSelfInfo().then(res => {
|
|
|
// console.log(res)
|
|
|
// // if (res.) {}
|
|
|
- // })
|
|
|
+ })
|
|
|
},
|
|
|
methods: {
|
|
|
changeTab(index) {
|