| | |
| | | </div> |
| | | </template> |
| | | <script> |
| | | import {mapMutations} from 'vuex' |
| | | import bus from '../common/bus'; |
| | | export default { |
| | | data() { |
| | |
| | | }, |
| | | |
| | | methods:{ |
| | | ...mapMutations([ |
| | | 'CLEAR_ROLELIST' |
| | | ]), |
| | | // 用户名下拉菜单选择事件 |
| | | handleCommand(command) { |
| | | if(command == 'loginout'){ |
| | |
| | | sessionStorage.userRoleNames = '' |
| | | sessionStorage.userGuid = '' |
| | | sessionStorage.userName = '' |
| | | this.CLEAR_ROLELIST(); //清空本地权限缓存 |
| | | this.$router.push('/login'); |
| | | // this.$confirm("是否退出登录?", "提示", { |
| | | // confirmButtonText: "确定", |
| | |
| | | }, |
| | | url:this.$systemconfig.basePath + '/user/updatePassword ' |
| | | }).then(res => { |
| | | if(res.data.success){ |
| | | if(res.data.code==0){ |
| | | this.form.oldPassword = '' |
| | | this.form.newPassword = '' |
| | | this.form.surePassword = '' |
| | | this.errTishi = '' |
| | | this.$message({message: res.data.message, type: 'success'}); |
| | | this.$message({message:'修改成功', type: 'success'}); |
| | | this.dialogFormVisible = false |
| | | }else{ |
| | | this.$message({message: res.data.message, type: 'false'}); |
| | | this.$message({message: '修改失败', type: 'false'}); |
| | | } |
| | | }) |
| | | } |