Exemplo n.º 1
0
 def _lookup(self, nbhd_mount, *remainder):
     n_url_prefix = '/%s/' % nbhd_mount
     n = self._lookup_neighborhood(n_url_prefix)
     if n and not n.url_prefix.startswith('//'):
         return NeighborhoodController(n), remainder
     else:
         raise exc.HTTPNotFound
Exemplo n.º 2
0
 def bind_controller(self, controller):
     from allura.controllers.project import NeighborhoodController
     controller_attr = self.url_prefix[1:-1]
     setattr(controller, controller_attr, NeighborhoodController(self))