diff --git a/fiches/templates/fiches/base.html b/fiches/templates/fiches/base.html index fbb4a95..7bd92ba 100644 --- a/fiches/templates/fiches/base.html +++ b/fiches/templates/fiches/base.html @@ -6,6 +6,7 @@ + {% if no_crawlers %}{% endif %} {% block title_onglet %}{% trans "Annuaire des élèves de l'ENS" %}{% endblock %} diff --git a/fiches/views.py b/fiches/views.py index 3e321a5..5ce621c 100644 --- a/fiches/views.py +++ b/fiches/views.py @@ -30,6 +30,7 @@ from fiches.models import Address, Mail, Phone, Profile, Social class FicheView(DetailView): model = Profile template_name = "fiches/fiche.html" + extra_context = {"no_crawlers": True} def get_object(self): return get_object_or_404(Profile, user__username=self.kwargs.get("user")) @@ -40,6 +41,7 @@ class EditView(UpdateView): template_name = "fiches/fiches_modif.html" model = Profile form_class = ProfileForm + extra_context = {"no_crawlers": True} def get(self, request, *args, **kwargs): self.object = self.get_object() @@ -141,6 +143,7 @@ class HomeView(FormView): class BirthdayView(ListView): model = Profile template_name = "fiches/birthday.html" + extra_context = {"no_crawlers": True} def get_context_data(self, **kwargs): context = super().get_context_data(**kwargs)