diff --git a/passbook/providers/saml/models.py b/passbook/providers/saml/models.py index 609b5fe6d..0ff80982a 100644 --- a/passbook/providers/saml/models.py +++ b/passbook/providers/saml/models.py @@ -50,7 +50,7 @@ class SAMLProvider(Provider): """Get link to download XML metadata for admin interface""" try: # pylint: disable=no-member - return reverse('passbook_saml_idp:saml-metadata', + return reverse('passbook_providers_saml:saml-metadata', kwargs={'application': self.application.slug}) except Provider.application.RelatedObjectDoesNotExist: return None diff --git a/passbook/providers/saml/templates/saml/idp/settings.html b/passbook/providers/saml/templates/saml/idp/settings.html index 3e09645f5..336df4e9d 100644 --- a/passbook/providers/saml/templates/saml/idp/settings.html +++ b/passbook/providers/saml/templates/saml/idp/settings.html @@ -39,7 +39,7 @@
diff --git a/passbook/providers/saml/views.py b/passbook/providers/saml/views.py index 0d76601a0..a7dc0bb44 100644 --- a/passbook/providers/saml/views.py +++ b/passbook/providers/saml/views.py @@ -92,7 +92,7 @@ class LoginBeginView(AccessRequiredView): return HttpResponseBadRequest('the SAML request payload is missing') request.session['RelayState'] = source.get('RelayState', '') - return redirect(reverse('passbook_saml_idp:saml-login-process', kwargs={ + return redirect(reverse('passbook_providers_saml:saml-login-process', kwargs={ 'application': application })) @@ -204,10 +204,10 @@ class DescriptorDownloadView(AccessRequiredView): def get(self, request, application): """Replies with the XML Metadata IDSSODescriptor.""" entity_id = self.provider.issuer - slo_url = request.build_absolute_uri(reverse('passbook_saml_idp:saml-logout', kwargs={ + slo_url = request.build_absolute_uri(reverse('passbook_providers_saml:saml-logout', kwargs={ 'application': application })) - sso_url = request.build_absolute_uri(reverse('passbook_saml_idp:saml-login', kwargs={ + sso_url = request.build_absolute_uri(reverse('passbook_providers_saml:saml-login', kwargs={ 'application': application })) pubkey = strip_pem_header(self.provider.signing_cert.replace('\r', '')).replace('\n', '') diff --git a/passbook/sources/oauth/templates/oauth_client/user.html b/passbook/sources/oauth/templates/oauth_client/user.html index 689a11888..c0f0ef4c7 100644 --- a/passbook/sources/oauth/templates/oauth_client/user.html +++ b/passbook/sources/oauth/templates/oauth_client/user.html @@ -6,12 +6,12 @@{% trans 'Connected.' %}
- + {% trans 'Disconnect' %} {% else %}Not connected.
- + {% trans 'Connect' %} {% endif %} diff --git a/passbook/sources/oauth/views/core.py b/passbook/sources/oauth/views/core.py index da47a96de..e10ff67bf 100644 --- a/passbook/sources/oauth/views/core.py +++ b/passbook/sources/oauth/views/core.py @@ -47,7 +47,7 @@ class OAuthRedirect(OAuthClientMixin, RedirectView): def get_callback_url(self, source): "Return the callback url for this source." - return reverse('passbook_oauth_client:oauth-client-callback', + return reverse('passbook_sources_oauth:oauth-client-callback', kwargs={'source_slug': source.slug}) def get_redirect_url(self, **kwargs): @@ -195,7 +195,7 @@ class OAuthCallback(OAuthClientMixin, View): messages.success(self.request, _("Successfully linked %(source)s!" % { 'source': self.source.name })) - return redirect(reverse('passbook_oauth_client:oauth-client-user', kwargs={ + return redirect(reverse('passbook_sources_oauth:oauth-client-user', kwargs={ 'source_slug': self.source.slug })) # User was not authenticated, new user has been created @@ -225,7 +225,7 @@ class DisconnectView(LoginRequiredMixin, View): # User confirmed deletion self.aas.delete() messages.success(request, _('Connection successfully deleted')) - return redirect(reverse('passbook_oauth_client:oauth-client-user', kwargs={ + return redirect(reverse('passbook_sources_oauth:oauth-client-user', kwargs={ 'source_slug': self.source.slug })) return self.get(request, source_slug) @@ -234,7 +234,7 @@ class DisconnectView(LoginRequiredMixin, View): """Show delete form""" return render(request, 'generic/delete.html', { 'object': self.source, - 'delete_url': reverse('passbook_oauth_client:oauth-client-disconnect', kwargs={ + 'delete_url': reverse('passbook_sources_oauth:oauth-client-disconnect', kwargs={ 'source_slug': self.source.slug, }) })