Esempio n. 1
0
    def change_password(self, account):
        if 'password' in request.params:
            password = request.params['password']

            dh = DirectoryHelper(
                directoryCN, directoryPassword, directoryDomain)
            dh.change_password(account, password)

            session['flash'] = "Password changed successfully"
            session.save()
            return redirect(url(
                    controller='users', action='edit', account=account))

        session['flash'] = "Error changing password"
        session.save()
        return redirect(url(
                controller='users', action='edit', account=account))