Commit 3d1032bd by zhanghaozhe

忘记密码

parent 4c0c60a9
...@@ -98,8 +98,9 @@ const formikConfig = { ...@@ -98,8 +98,9 @@ const formikConfig = {
function forgotPasswordReset(values, props) { function forgotPasswordReset(values, props) {
let key = sessionStorage.getItem('r_type') === 'email' ? 'email' : 'tel' let key = sessionStorage.getItem('r_type') === 'email' ? 'email' : 'tel'
http.post(`${API['passport-api']}/account/up_pass_by_${key === 'email' ? 'email' : 'phone'}`, { let requestKey = key === 'email' ? 'email' : 'phone'
[key]: sessionStorage.getItem(key), http.post(`${API['passport-api']}/account/up_pass_by_${requestKey}`, {
[requestKey]: sessionStorage.getItem(key),
password: encrypt(values.password) password: encrypt(values.password)
}) })
.then(res => { .then(res => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment