Beispiel #1
0
 def get(self, request, *args, **kwargs):
     provider = get_broker()
     if fail_direct(request, organization=provider):
         return super(ProviderRedirectView, self).get(
             request, *args, **kwargs)
     kwargs.update({self.slug_url_kwarg: provider})
     return RedirectView.get(self, request, *args, **kwargs)
Beispiel #2
0
def is_direct(request, organization=None):
    if organization is None:
        organization = get_broker()
    return not fail_direct(request, organization=organization)