diff --git a/main/manager-web/src/apis/httpRequest.js b/main/manager-web/src/apis/httpRequest.js index 98f47bf7..4d8093d3 100755 --- a/main/manager-web/src/apis/httpRequest.js +++ b/main/manager-web/src/apis/httpRequest.js @@ -105,11 +105,12 @@ function httpHandlerError(info, callBack) { /** 请求成功,退出该函数 可以根据项目需求来判断是否请求成功。这里判断的是status为200的时候是成功 */ let networkError = false if (info.status === 200) { - if (info.data.code === 'success' || info.data.code === 0 || info.data.code === undefined) { return networkError }else if (info.data.code === 401) { - goToPage(Constant.PAGE.LOGIN, true) + console.log('触发 401,清除 Token 并跳转登录页'); + store.commit('clearAuth'); + window.location.href = '/login'; return true } else { showDanger(info.data.msg) diff --git a/main/manager-web/src/apis/module/user.js b/main/manager-web/src/apis/module/user.js index 1fb3503d..5ce20941 100755 --- a/main/manager-web/src/apis/module/user.js +++ b/main/manager-web/src/apis/module/user.js @@ -138,8 +138,8 @@ export default { .url(`${getServiceUrl()}/api/v1/user/change-password`) .method('PUT') .data({ - old_password: oldPassword, - new_password: newPassword, + password: oldPassword, + newPassword: newPassword, }) .success((res) => { RequestService.clearRequestTime(); diff --git a/main/manager-web/src/assets/header/roboot.png b/main/manager-web/src/assets/header/robot.png similarity index 100% rename from main/manager-web/src/assets/header/roboot.png rename to main/manager-web/src/assets/header/robot.png diff --git a/main/manager-web/src/components/ChangePasswordDialog.vue b/main/manager-web/src/components/ChangePasswordDialog.vue index 19c20fd6..ffefdb41 100644 --- a/main/manager-web/src/components/ChangePasswordDialog.vue +++ b/main/manager-web/src/components/ChangePasswordDialog.vue @@ -1,57 +1,63 @@