diff --git a/gas/gas/core/views.py b/gas/gas/core/views.py index 3700eeb..4adcfbe 100644 --- a/gas/gas/core/views.py +++ b/gas/gas/core/views.py @@ -34,6 +34,7 @@ class GASLoginView(LoginView): class GASPasswordChangeView(GASMixin, PasswordChangeView): template_name = 'gas/base_form.html' success_url = reverse_lazy('gas:index') + continue_url = reverse_lazy('gas:change_password') title = _('Change your password') success_message = _('Password changed.') diff --git a/gas/gas/users/views.py b/gas/gas/users/views.py index ffda20e..5c0a126 100644 --- a/gas/gas/users/views.py +++ b/gas/gas/users/views.py @@ -75,6 +75,9 @@ class ChangePasswordUser(BaseMixin, gviews.GASMixin, FormView): def get_title(self): return _('Change {username} user password').format(username=self.user.username) + def get_continue_url(self): + return reverse('gas:user_change_password', args=(self.kwargs['pk'],)) + def get_form_kwargs(self): kwargs = super().get_form_kwargs() kwargs['user'] = self.user