diff --git a/src/agenda_culturel/models.py b/src/agenda_culturel/models.py index 5af3ee3..9f1534a 100644 --- a/src/agenda_culturel/models.py +++ b/src/agenda_culturel/models.py @@ -332,7 +332,7 @@ class Place(models.Model): return self.name + ", " + self.city def get_absolute_url(self): - return reverse("view_place", kwargs={"pk": self.pk}) + return reverse("view_place_fullname", kwargs={"pk": self.pk, "extra": slugify(self.name)}) def nb_events(self): return Event.objects.filter(exact_location=self).count() diff --git a/src/agenda_culturel/templates/agenda_culturel/event-location-inc.html b/src/agenda_culturel/templates/agenda_culturel/event-location-inc.html index 7f51fab..a237b1f 100644 --- a/src/agenda_culturel/templates/agenda_culturel/event-location-inc.html +++ b/src/agenda_culturel/templates/agenda_culturel/event-location-inc.html @@ -3,7 +3,7 @@ {% if nolink %} {{ event.exact_location.name }}, {{ event.exact_location.city }} {% else %} - {{ event.exact_location.name }}, {{ event.exact_location.city }} + {{ event.exact_location.name }}, {{ event.exact_location.city }} {% endif %} {% else %} {% if perms.agenda_culturel.change_event and perms.agenda_culturel.change_place %} diff --git a/src/agenda_culturel/templates/agenda_culturel/place_detail.html b/src/agenda_culturel/templates/agenda_culturel/place_detail.html index e53095f..0a93c29 100644 --- a/src/agenda_culturel/templates/agenda_culturel/place_detail.html +++ b/src/agenda_culturel/templates/agenda_culturel/place_detail.html @@ -69,7 +69,7 @@ {% cache cache_timeout place_list user.is_authenticated object page_obj.number past %}