Disable changing password for LDAP users

This commit is contained in:
cuigh
2017-11-09 19:46:53 +08:00
parent 415d92fede
commit 32d66e3de6
4 changed files with 14 additions and 4 deletions

View File

@@ -45,7 +45,12 @@ func profileModifyInfo(ctx web.Context) error {
}
func profilePassword(ctx web.Context) error {
m := newModel(ctx)
user, err := biz.User.GetByID(ctx.User().ID())
if err != nil {
return err
}
m := newModel(ctx).Set("User", user)
return ctx.Render("profile/password", m)
}