fix
This commit is contained in:
parent
1d9b70aa18
commit
e0f561c8b8
|
@ -144,6 +144,7 @@ function resetPassword() {
|
||||||
.then(data => {
|
.then(data => {
|
||||||
if (data.code == 200 ) {
|
if (data.code == 200 ) {
|
||||||
alert(data.msg);
|
alert(data.msg);
|
||||||
|
window.location.href = {{.HomePage}};
|
||||||
} else {
|
} else {
|
||||||
alert(data.msg);
|
alert(data.msg);
|
||||||
}
|
}
|
||||||
|
|
|
@ -50,9 +50,11 @@ func (l *UserResetPasswordHtmlLogic) UserResetPasswordHtml(req *types.RequestUse
|
||||||
func (l *UserResetPasswordHtmlLogic) AfterLogic(w http.ResponseWriter, r *http.Request, resp *basic.Response) {
|
func (l *UserResetPasswordHtmlLogic) AfterLogic(w http.ResponseWriter, r *http.Request, resp *basic.Response) {
|
||||||
|
|
||||||
err := tpls.ExecuteTemplate(w, "reset_confirm.tpl", map[string]string{
|
err := tpls.ExecuteTemplate(w, "reset_confirm.tpl", map[string]string{
|
||||||
|
"HomePage": "http://www.fusen.3718.cn",
|
||||||
"ResetToken": l.ResetToken,
|
"ResetToken": l.ResetToken,
|
||||||
"ResetPasswordLink": l.svcCtx.Config.MainAddress + "/api/auth/reset/password",
|
"ResetPasswordLink": l.svcCtx.Config.MainAddress + "/api/auth/reset/password",
|
||||||
})
|
})
|
||||||
|
|
||||||
if err != nil {
|
if err != nil {
|
||||||
httpx.OkJsonCtx(l.ctx, w, resp.SetStatusWithMessage(basic.CodeTemplateErr, err.Error()))
|
httpx.OkJsonCtx(l.ctx, w, resp.SetStatusWithMessage(basic.CodeTemplateErr, err.Error()))
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user