diff --git a/src/views/Home.vue b/src/views/Home.vue
index 5c1aa99..1f3b916 100644
--- a/src/views/Home.vue
+++ b/src/views/Home.vue
@@ -49,7 +49,7 @@
{{ menu2.displayName
- }}
+ }}
本地设置
调试工具
- 客户端参数
+ 客户端参数
-
+
@@ -217,7 +217,7 @@ export default {
this.password = this.changepassword;
// console.log(this.password);
// console.log(this.$store.state.changepassword, "ssssssssssss");
- this.user = window.sessionStorage.getItem("user");
+ this.user = window.sessionStorage.getItem("user");
this.LocalConfigInit = deepCopy(this.LocalConfig)
let LocalConfig = window.localStorage.getItem("LocalConfig") || null
@@ -227,7 +227,7 @@ export default {
console.log('window.localStorage.getItem("LocalConfig")', error)
}
},
-
+
mounted() {
//获取当前用户的菜单权限
this.getUserAllPriv();
@@ -309,25 +309,28 @@ export default {
determine() {
this.$refs.ruleForm.validate((valid) => {
if (valid) {
- if (this.form.oldPassWord != this.password) {
- this.$message.warning("旧密码输入错误");
+ if (!this.form.oldPassWord) {
+ this.$message.warning("请输入旧密码");
} else if (this.confirmpassword != this.form.newPassWord) {
this.$message.warning("二次输入的密码不一致");
} else {
- postapi("/api/identity/users/updatepassword", this.form).then(
- (res) => {
- console.log("修改成功");
- this.dialogVisible = false;
- }
- );
+ postapi("/api/identity/users/updatepassword", this.form)
+ .then(res => {
+ if (res.code > -1) {
+ console.log("修改成功");
+ this.dialogVisible = false;
+ }
+ });
}
}
});
},
//修改密码
editpassword() {
- this.dialogVisible = true;
- console.log(this.password);
+ this.form.oldPassWord = ""
+ this.confirmpassword = ""
+ this.form.newPassWord = ""
+ this.dialogVisible = true;
},
//退出登录
logout() {