mirror of
https://github.com/xinnan-tech/xiaozhi-esp32-server.git
synced 2026-07-24 16:13:54 +08:00
feature:实现角色配置
This commit is contained in:
@@ -18,7 +18,8 @@ export default {
|
||||
// this.login(loginForm, callback)
|
||||
// })
|
||||
}).send()
|
||||
}, // 获取验证码
|
||||
},
|
||||
// 获取验证码
|
||||
getCaptcha(uuid, callback) {
|
||||
|
||||
RequestService.sendRequest()
|
||||
@@ -98,4 +99,24 @@ export default {
|
||||
// })
|
||||
}).send()
|
||||
},
|
||||
// 修改用户密码
|
||||
changePassword(oldPassword, newPassword, successCallback, errorCallback) {
|
||||
RequestService.sendRequest()
|
||||
.url(`${getServiceUrl()}/user/change-password`) // 修改URL
|
||||
.method('PUT') // 修改方法为PUT
|
||||
.data({
|
||||
old_password: oldPassword, // 修改参数名
|
||||
new_password: newPassword // 修改参数名
|
||||
})
|
||||
.success((res) => {
|
||||
RequestService.clearRequestTime();
|
||||
successCallback(res);
|
||||
})
|
||||
.fail((error) => {
|
||||
// RequestService.reAjaxFun(() => {
|
||||
// this.changePassword(oldPassword, newPassword, successCallback, errorCallback);
|
||||
// });
|
||||
})
|
||||
.send();
|
||||
},
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user