This commit is contained in:
Henry Oswald 2015-02-24 22:07:43 +00:00
commit 40b30b957a
2 changed files with 84 additions and 76 deletions

View file

@ -112,6 +112,11 @@ module.exports = (app)->
res.locals.formatPrice = SubscriptionFormatters.formatPrice
next()
app.use (req, res, next)->
res.locals.externalAuthenticationSystemUsed = ->
Settings.ldap?
next()
app.use (req, res, next)->
if req.session.user?
res.locals.user =

View file

@ -19,6 +19,7 @@ block content
h3 #{translate("update_account_info")}
form(async-form="settings", name="settingsForm", method="POST", action="/user/settings", novalidate)
input(type="hidden", name="_csrf", value=csrfToken)
if !externalAuthenticationSystemUsed()
.form-group
label(for='email') #{translate("email")}
input.form-control(
@ -51,7 +52,7 @@ block content
type='submit',
ng-disabled="settingsForm.$invalid"
) #{translate("update")}
if !externalAuthenticationSystemUsed()
.col-md-5.col-md-offset-1
h3 #{translate("change_password")}
form(async-form="changepassword", name="changePasswordForm", action="/user/password/update", method="POST", novalidate)
@ -100,6 +101,8 @@ block content
hr
if !externalAuthenticationSystemUsed()
p.small
| #{translate("newsletter_info_and_unsubscribe")}
a(