diff --git a/cypress/integration/nav_tabs.js b/cypress/integration/nav_tabs.js index 26c0014233..34e48c58f5 100644 --- a/cypress/integration/nav_tabs.js +++ b/cypress/integration/nav_tabs.js @@ -22,9 +22,9 @@ describe('Nav tabs properties/attachments', () => { cy.visit(href); }); cy.get("a#tab-properties").should('have.class', 'active'); - cy.get("a#tab-attachments-accessibility").should('not.have.class', 'active'); - cy.get("a#tab-attachments-accessibility").click(); - cy.get("a#tab-attachments-accessibility").should('have.class', 'active'); + cy.get("a#tab-related-objects").should('not.have.class', 'active'); + cy.get("a#tab-related-objects").click(); + cy.get("a#tab-related-objects").should('have.class', 'active'); cy.get("a#tab-properties").should('not.have.class', 'active'); }); }); diff --git a/docs/changelog.rst b/docs/changelog.rst index 87c8183fc6..180d74943e 100644 --- a/docs/changelog.rst +++ b/docs/changelog.rst @@ -5,6 +5,12 @@ CHANGELOG 2.111.0+dev (XXXX-XX-XX) ---------------------------- +**UI/UX** + +- Move the related objects from the properties tab into their own tab, on objects details pages (refs #2967) +- Move Treks' accessibility pictures into the attached files tab (refs #2967) +- Removes the display of an object's structure in its properties tab title + **Documentation** - Update theme color diff --git a/geotrek/authent/templates/authent/authent_propertiestab_fragment.html b/geotrek/authent/templates/authent/authent_propertiestab_fragment.html deleted file mode 100644 index 9bf0c109e6..0000000000 --- a/geotrek/authent/templates/authent/authent_propertiestab_fragment.html +++ /dev/null @@ -1,4 +0,0 @@ -{% load i18n %} -{% if object.structure %} - {{ object.structure }} -{% endif %} \ No newline at end of file diff --git a/geotrek/cirkwi/locale/de/LC_MESSAGES/django.po b/geotrek/cirkwi/locale/de/LC_MESSAGES/django.po index 437d36b743..edaee0eb4f 100644 --- a/geotrek/cirkwi/locale/de/LC_MESSAGES/django.po +++ b/geotrek/cirkwi/locale/de/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-11-20 12:48+0000\n" +"POT-Creation-Date: 2025-01-06 15:41+0000\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -45,10 +45,6 @@ msgstr "" msgid "Cirkwi POI categories" msgstr "" -#, python-brace-format -msgid "Failed to download {url}. HTTP status code {status_code}" -msgstr "" - #, python-brace-format msgid "" "{model} '{val}' did not exist in Geotrek-Admin and was automatically created" diff --git a/geotrek/cirkwi/locale/en/LC_MESSAGES/django.po b/geotrek/cirkwi/locale/en/LC_MESSAGES/django.po index 437d36b743..edaee0eb4f 100644 --- a/geotrek/cirkwi/locale/en/LC_MESSAGES/django.po +++ b/geotrek/cirkwi/locale/en/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-11-20 12:48+0000\n" +"POT-Creation-Date: 2025-01-06 15:41+0000\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -45,10 +45,6 @@ msgstr "" msgid "Cirkwi POI categories" msgstr "" -#, python-brace-format -msgid "Failed to download {url}. HTTP status code {status_code}" -msgstr "" - #, python-brace-format msgid "" "{model} '{val}' did not exist in Geotrek-Admin and was automatically created" diff --git a/geotrek/cirkwi/locale/es/LC_MESSAGES/django.po b/geotrek/cirkwi/locale/es/LC_MESSAGES/django.po index 437d36b743..edaee0eb4f 100644 --- a/geotrek/cirkwi/locale/es/LC_MESSAGES/django.po +++ b/geotrek/cirkwi/locale/es/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-11-20 12:48+0000\n" +"POT-Creation-Date: 2025-01-06 15:41+0000\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -45,10 +45,6 @@ msgstr "" msgid "Cirkwi POI categories" msgstr "" -#, python-brace-format -msgid "Failed to download {url}. HTTP status code {status_code}" -msgstr "" - #, python-brace-format msgid "" "{model} '{val}' did not exist in Geotrek-Admin and was automatically created" diff --git a/geotrek/cirkwi/locale/fr/LC_MESSAGES/django.po b/geotrek/cirkwi/locale/fr/LC_MESSAGES/django.po index 065a22ce90..224ed19959 100644 --- a/geotrek/cirkwi/locale/fr/LC_MESSAGES/django.po +++ b/geotrek/cirkwi/locale/fr/LC_MESSAGES/django.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-11-20 12:30+0000\n" +"POT-Creation-Date: 2025-01-06 15:41+0000\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -44,10 +44,6 @@ msgstr "Catégorie de POI Cirkwi" msgid "Cirkwi POI categories" msgstr "Catégories de POI Cirkwi" -#, python-brace-format -msgid "Failed to download {url}. HTTP status code {status_code}" -msgstr "Téléchargement impossible de {url}. Code d'erreur HTTP {status_code}" - #, python-brace-format msgid "" "{model} '{val}' did not exist in Geotrek-Admin and was automatically created" diff --git a/geotrek/cirkwi/locale/it/LC_MESSAGES/django.po b/geotrek/cirkwi/locale/it/LC_MESSAGES/django.po index 437d36b743..edaee0eb4f 100644 --- a/geotrek/cirkwi/locale/it/LC_MESSAGES/django.po +++ b/geotrek/cirkwi/locale/it/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-11-20 12:48+0000\n" +"POT-Creation-Date: 2025-01-06 15:41+0000\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -45,10 +45,6 @@ msgstr "" msgid "Cirkwi POI categories" msgstr "" -#, python-brace-format -msgid "Failed to download {url}. HTTP status code {status_code}" -msgstr "" - #, python-brace-format msgid "" "{model} '{val}' did not exist in Geotrek-Admin and was automatically created" diff --git a/geotrek/cirkwi/locale/nl/LC_MESSAGES/django.po b/geotrek/cirkwi/locale/nl/LC_MESSAGES/django.po index 437d36b743..edaee0eb4f 100644 --- a/geotrek/cirkwi/locale/nl/LC_MESSAGES/django.po +++ b/geotrek/cirkwi/locale/nl/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-11-20 12:48+0000\n" +"POT-Creation-Date: 2025-01-06 15:41+0000\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -45,10 +45,6 @@ msgstr "" msgid "Cirkwi POI categories" msgstr "" -#, python-brace-format -msgid "Failed to download {url}. HTTP status code {status_code}" -msgstr "" - #, python-brace-format msgid "" "{model} '{val}' did not exist in Geotrek-Admin and was automatically created" diff --git a/geotrek/common/forms.py b/geotrek/common/forms.py index c163145f98..6ed0860623 100644 --- a/geotrek/common/forms.py +++ b/geotrek/common/forms.py @@ -388,7 +388,7 @@ def __init__(self, request, *args, **kwargs): self.helper.form_style = "default" self.helper.label_class = 'col-md-3' self.helper.field_class = 'col-md-9' - self.fields['next'].initial = f"{self._object.get_detail_url()}?tab=attachments-accessibility" + self.fields['next'].initial = f"{self._object.get_detail_url()}?tab=attachments" if not self.instance.pk: form_actions = [ @@ -423,7 +423,7 @@ class Meta: def success_url(self): obj = self._object - return f"{obj.get_detail_url()}?tab=attachments-accessibility" + return f"{obj.get_detail_url()}?tab=attachments" def clean_attachment_accessibility_file(self): uploaded_image = self.cleaned_data.get("attachment_accessibility_file", False) diff --git a/geotrek/common/locale/de/LC_MESSAGES/django.po b/geotrek/common/locale/de/LC_MESSAGES/django.po index 242d48b728..5993469057 100644 --- a/geotrek/common/locale/de/LC_MESSAGES/django.po +++ b/geotrek/common/locale/de/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-08-06 08:26+0000\n" +"POT-Creation-Date: 2025-01-07 14:35+0000\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -695,6 +695,16 @@ msgctxt "West" msgid "W" msgstr "" +msgid "" +"Feature geometry cannot be converted to a single continuous LineString " +"feature" +msgstr "" + +msgid "" +"Geometries from various features cannot be converted to a single continuous " +"LineString feature" +msgstr "" + msgid "Reports" msgstr "" diff --git a/geotrek/common/locale/en/LC_MESSAGES/django.po b/geotrek/common/locale/en/LC_MESSAGES/django.po index 242d48b728..5993469057 100644 --- a/geotrek/common/locale/en/LC_MESSAGES/django.po +++ b/geotrek/common/locale/en/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-08-06 08:26+0000\n" +"POT-Creation-Date: 2025-01-07 14:35+0000\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -695,6 +695,16 @@ msgctxt "West" msgid "W" msgstr "" +msgid "" +"Feature geometry cannot be converted to a single continuous LineString " +"feature" +msgstr "" + +msgid "" +"Geometries from various features cannot be converted to a single continuous " +"LineString feature" +msgstr "" + msgid "Reports" msgstr "" diff --git a/geotrek/common/locale/es/LC_MESSAGES/django.po b/geotrek/common/locale/es/LC_MESSAGES/django.po index cfdf07737a..bbbe3118bb 100644 --- a/geotrek/common/locale/es/LC_MESSAGES/django.po +++ b/geotrek/common/locale/es/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-08-06 08:26+0000\n" +"POT-Creation-Date: 2025-01-07 14:35+0000\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: Olivia Duval \n" "Language-Team: LANGUAGE \n" @@ -695,6 +695,16 @@ msgctxt "West" msgid "W" msgstr "" +msgid "" +"Feature geometry cannot be converted to a single continuous LineString " +"feature" +msgstr "" + +msgid "" +"Geometries from various features cannot be converted to a single continuous " +"LineString feature" +msgstr "" + msgid "Reports" msgstr "" diff --git a/geotrek/common/locale/fr/LC_MESSAGES/django.po b/geotrek/common/locale/fr/LC_MESSAGES/django.po index b3f66c1095..4bbb275daa 100644 --- a/geotrek/common/locale/fr/LC_MESSAGES/django.po +++ b/geotrek/common/locale/fr/LC_MESSAGES/django.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-08-06 08:26+0000\n" +"POT-Creation-Date: 2025-01-07 14:35+0000\n" "PO-Revision-Date: 2020-09-23 07:10+0000\n" "Last-Translator: Emmanuelle Helly \n" "Language-Team: French \n" "Language-Team: LANGUAGE \n" @@ -695,6 +695,16 @@ msgctxt "West" msgid "W" msgstr "" +msgid "" +"Feature geometry cannot be converted to a single continuous LineString " +"feature" +msgstr "" + +msgid "" +"Geometries from various features cannot be converted to a single continuous " +"LineString feature" +msgstr "" + msgid "Reports" msgstr "" diff --git a/geotrek/common/locale/nl/LC_MESSAGES/django.po b/geotrek/common/locale/nl/LC_MESSAGES/django.po index 242d48b728..5993469057 100644 --- a/geotrek/common/locale/nl/LC_MESSAGES/django.po +++ b/geotrek/common/locale/nl/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-08-06 08:26+0000\n" +"POT-Creation-Date: 2025-01-07 14:35+0000\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -695,6 +695,16 @@ msgctxt "West" msgid "W" msgstr "" +msgid "" +"Feature geometry cannot be converted to a single continuous LineString " +"feature" +msgstr "" + +msgid "" +"Geometries from various features cannot be converted to a single continuous " +"LineString feature" +msgstr "" + msgid "Reports" msgstr "" diff --git a/geotrek/common/templates/common/hdviewpoint_detail.html b/geotrek/common/templates/common/hdviewpoint_detail.html index 7f7a02b2ad..bdeebbd334 100644 --- a/geotrek/common/templates/common/hdviewpoint_detail.html +++ b/geotrek/common/templates/common/hdviewpoint_detail.html @@ -42,7 +42,6 @@

{{ object }}

{% block detailspanel %} -

{% trans "Attributes" %}

diff --git a/geotrek/common/tests/test_attachments.py b/geotrek/common/tests/test_attachments.py index db17c15482..7878a8091c 100644 --- a/geotrek/common/tests/test_attachments.py +++ b/geotrek/common/tests/test_attachments.py @@ -230,7 +230,7 @@ def attachmentPostData(self): 'legend': "A legend", 'attachment_accessibility_file': get_dummy_uploaded_image(name='face.png'), 'info_accessibility': 'slope', - 'next': f"{self.object.get_detail_url()}?tab=attachments-accessibility" + 'next': f"{self.object.get_detail_url()}?tab=attachments" } return data @@ -238,7 +238,7 @@ def test_upload_redirects_to_trek_detail_url(self): response = self.client.post(add_url_for_obj(self.object), data=self.attachmentPostData()) self.assertEqual(response.status_code, 302) - self.assertEqual(response['location'], f"{self.object.get_detail_url()}?tab=attachments-accessibility") + self.assertEqual(response['location'], f"{self.object.get_detail_url()}?tab=attachments") self.assertEqual(3, AccessibilityAttachment.objects.count()) self.client.force_login(user=self.user) @@ -278,7 +278,7 @@ def attachmentPostData(self): 'legend': "A legend", 'attachment_accessibility_file': get_dummy_uploaded_image(name='face.png'), 'info_accessibility': 'slope', - 'next': f"{self.object.get_detail_url()}?tab=attachments-accessibility" + 'next': f"{self.object.get_detail_url()}?tab=attachments" } return data @@ -300,7 +300,7 @@ def test_post_update_url(self): data=self.attachmentPostData(), ) self.assertEqual(response.status_code, 302) - self.assertEqual(response['location'], f"{self.object.get_detail_url()}?tab=attachments-accessibility") + self.assertEqual(response['location'], f"{self.object.get_detail_url()}?tab=attachments") self.attachment.refresh_from_db() self.assertEqual(self.attachment.legend, "A legend") self.client.force_login(user=self.user) @@ -318,7 +318,7 @@ def test_get_delete_with_perms_url(self): self.client.force_login(user=self.superuser) response = self.client.get(delete_url_for_obj(self.attachment)) self.assertEqual(response.status_code, 302) - self.assertEqual(response['location'], f"{self.object.get_detail_url()}?tab=attachments-accessibility") + self.assertEqual(response['location'], f"{self.object.get_detail_url()}?tab=attachments") self.assertEqual(1, AccessibilityAttachment.objects.count()) self.client.force_login(user=self.user) @@ -334,7 +334,7 @@ def user_perms(p, obj=None): self.client.force_login(user=self.user) response = self.client.get(delete_url_for_obj(self.attachment)) self.assertEqual(response.status_code, 302) - self.assertEqual(response['location'], f"{self.object.get_detail_url()}?tab=attachments-accessibility") + self.assertEqual(response['location'], f"{self.object.get_detail_url()}?tab=attachments") self.assertEqual(2, AccessibilityAttachment.objects.count()) response = self.client.get(delete_url_for_obj(self.attachment), follow=True) self.assertIn(b'You are not allowed to delete this attachment.', response.content) @@ -446,7 +446,7 @@ def test_attachment_is_larger_max_size(self): 'attachment_accessibility_file': SimpleUploadedFile(file.name, file.read(), content_type='image/png'), 'author': "newauthor", 'info_accessibility': 'slope', - 'next': f"{self.object.get_detail_url()}?tab=attachments-accessibility" + 'next': f"{self.object.get_detail_url()}?tab=attachments" } ) self.assertEqual(response.status_code, 302) @@ -462,7 +462,7 @@ def test_attachment_is_larger_max_size(self): 'attachment_accessibility_file': big_image, 'author': "newauthor", 'info_accessibility': 'slope', - 'next': f"{self.object.get_detail_url()}?tab=attachments-accessibility" + 'next': f"{self.object.get_detail_url()}?tab=attachments" }, follow=True ) @@ -488,7 +488,7 @@ def test_attachment_is_not_wide_enough(self): 'author': "newauthor", 'legend': "A legend", 'info_accessibility': 'slope', - 'next': f"{self.object.get_detail_url()}?tab=attachments-accessibility" + 'next': f"{self.object.get_detail_url()}?tab=attachments" } ) self.assertEqual(response.status_code, 302) @@ -508,7 +508,7 @@ def test_attachment_is_not_wide_enough(self): 'attachment_accessibility_file': SimpleUploadedFile(small_file.name, small_file.read(), content_type='image/png'), 'author': "newauthor", 'info_accessibility': 'slope', - 'next': f"{self.object.get_detail_url()}?tab=attachments-accessibility" + 'next': f"{self.object.get_detail_url()}?tab=attachments" }, follow=True ) @@ -535,7 +535,7 @@ def test_attachment_is_not_tall_enough(self): 'attachment_accessibility_file': SimpleUploadedFile(file.name, file.read(), content_type='image/png'), 'author': "newauthor", 'info_accessibility': 'slope', - 'next': f"{self.object.get_detail_url()}?tab=attachments-accessibility" + 'next': f"{self.object.get_detail_url()}?tab=attachments" } ) self.assertEqual(response.status_code, 302) @@ -555,7 +555,7 @@ def test_attachment_is_not_tall_enough(self): 'author': "newauthor", 'legend': "A legend", 'info_accessibility': 'slope', - 'next': f"{self.object.get_detail_url()}?tab=attachments-accessibility" + 'next': f"{self.object.get_detail_url()}?tab=attachments" }, follow=True ) @@ -577,7 +577,7 @@ def test_attachment_deleted(self): 'author': "newauthor", 'legend': "A legend", 'info_accessibility': 'slope', - 'next': f"{self.object.get_detail_url()}?tab=attachments-accessibility" + 'next': f"{self.object.get_detail_url()}?tab=attachments" } ) self.assertEqual(response.status_code, 302) diff --git a/geotrek/common/views.py b/geotrek/common/views.py index 2f2aab8edd..5548eee3be 100644 --- a/geotrek/common/views.py +++ b/geotrek/common/views.py @@ -482,7 +482,7 @@ def delete_attachment_accessibility(request, attachment_pk): else: error_msg = _('You are not allowed to delete this attachment.') messages.error(request, error_msg) - return HttpResponseRedirect(f"{obj.get_detail_url()}?tab=attachments-accessibility") + return HttpResponseRedirect(f"{obj.get_detail_url()}?tab=attachments") home = last_list diff --git a/geotrek/core/templates/core/path_detail_attributes.html b/geotrek/core/templates/core/path_detail_attributes.html index 6736e81e65..eecf9b27a6 100644 --- a/geotrek/core/templates/core/path_detail_attributes.html +++ b/geotrek/core/templates/core/path_detail_attributes.html @@ -3,7 +3,6 @@ {% block attributes %} -

{% trans "Attributes" %}

{{ object|verbose:"title" }}
diff --git a/geotrek/core/templates/core/trail_detail.html b/geotrek/core/templates/core/trail_detail.html index 4892505243..11d1fc3827 100644 --- a/geotrek/core/templates/core/trail_detail.html +++ b/geotrek/core/templates/core/trail_detail.html @@ -8,4 +8,4 @@
{% trans "GPX" %} {% trans "KML" %} -{% endblock download %} \ No newline at end of file +{% endblock download %} diff --git a/geotrek/core/templates/core/trail_detail_attributes.html b/geotrek/core/templates/core/trail_detail_attributes.html index 2b05d58d28..c5e9037ede 100644 --- a/geotrek/core/templates/core/trail_detail_attributes.html +++ b/geotrek/core/templates/core/trail_detail_attributes.html @@ -3,7 +3,6 @@ {% block attributes %} -

{% trans "Attributes" %}

{{ object|verbose:"name" }}
diff --git a/geotrek/diving/templates/diving/dive_detail_attributes.html b/geotrek/diving/templates/diving/dive_detail_attributes.html index b9b3218f4d..cd61aff019 100644 --- a/geotrek/diving/templates/diving/dive_detail_attributes.html +++ b/geotrek/diving/templates/diving/dive_detail_attributes.html @@ -2,7 +2,6 @@ {% load i18n mapentity_tags %} {% block attributes %} -

{% trans "Attributes" %}

{{ trail|verbose:"structure" }}
diff --git a/geotrek/feedback/locale/de/LC_MESSAGES/django.po b/geotrek/feedback/locale/de/LC_MESSAGES/django.po index a65044cb84..f5d7486e88 100644 --- a/geotrek/feedback/locale/de/LC_MESSAGES/django.po +++ b/geotrek/feedback/locale/de/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-06-04 15:20+0000\n" +"POT-Creation-Date: 2025-01-06 15:19+0000\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -266,6 +266,12 @@ msgid "" "Some data could not be forwarded to Suricate yet - Please come back later" msgstr "" +msgid "Intervention" +msgstr "" + +msgid "Add a new intervention" +msgstr "" + msgid "Attributes" msgstr "" @@ -296,12 +302,6 @@ msgstr "" msgid "No" msgstr "" -msgid "Intervention" -msgstr "" - -msgid "Add a new intervention" -msgstr "" - msgid "Map" msgstr "" diff --git a/geotrek/feedback/locale/en/LC_MESSAGES/django.po b/geotrek/feedback/locale/en/LC_MESSAGES/django.po index a65044cb84..f5d7486e88 100644 --- a/geotrek/feedback/locale/en/LC_MESSAGES/django.po +++ b/geotrek/feedback/locale/en/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-06-04 15:20+0000\n" +"POT-Creation-Date: 2025-01-06 15:19+0000\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -266,6 +266,12 @@ msgid "" "Some data could not be forwarded to Suricate yet - Please come back later" msgstr "" +msgid "Intervention" +msgstr "" + +msgid "Add a new intervention" +msgstr "" + msgid "Attributes" msgstr "" @@ -296,12 +302,6 @@ msgstr "" msgid "No" msgstr "" -msgid "Intervention" -msgstr "" - -msgid "Add a new intervention" -msgstr "" - msgid "Map" msgstr "" diff --git a/geotrek/feedback/locale/es/LC_MESSAGES/django.po b/geotrek/feedback/locale/es/LC_MESSAGES/django.po index a65044cb84..f5d7486e88 100644 --- a/geotrek/feedback/locale/es/LC_MESSAGES/django.po +++ b/geotrek/feedback/locale/es/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-06-04 15:20+0000\n" +"POT-Creation-Date: 2025-01-06 15:19+0000\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -266,6 +266,12 @@ msgid "" "Some data could not be forwarded to Suricate yet - Please come back later" msgstr "" +msgid "Intervention" +msgstr "" + +msgid "Add a new intervention" +msgstr "" + msgid "Attributes" msgstr "" @@ -296,12 +302,6 @@ msgstr "" msgid "No" msgstr "" -msgid "Intervention" -msgstr "" - -msgid "Add a new intervention" -msgstr "" - msgid "Map" msgstr "" diff --git a/geotrek/feedback/locale/fr/LC_MESSAGES/django.po b/geotrek/feedback/locale/fr/LC_MESSAGES/django.po index 815161a0ff..0d1940c847 100644 --- a/geotrek/feedback/locale/fr/LC_MESSAGES/django.po +++ b/geotrek/feedback/locale/fr/LC_MESSAGES/django.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-06-04 15:20+0000\n" +"POT-Creation-Date: 2025-01-06 15:19+0000\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -136,7 +136,7 @@ msgid "to" msgstr "à" msgid "Follow-up message generated by Geotrek" -msgstr "" +msgstr "Message de suivi généré par Geotrek" msgid "New report to process" msgstr "Nouveau Signalement à traiter" @@ -148,19 +148,19 @@ msgid "Tag" msgstr "Clé" msgid "Label" -msgstr "" +msgstr "Label" msgid "Paths" -msgstr "" +msgstr "Tronçons" msgid "Treks" msgstr "Itinéraires" msgid "POIs" -msgstr "" +msgstr "POIs" msgid "Services" -msgstr "" +msgstr "Services" msgid "Interventions" msgstr "Interventions" @@ -178,7 +178,7 @@ msgid "Identifiant" msgstr "Identifiant" msgid "Color" -msgstr "" +msgstr "Couleur" msgid "Display in legend" msgstr "Afficher dans la légende" @@ -199,7 +199,7 @@ msgstr "" "comptes à rebours. La valeur 0 désactive les alertes" msgid "Suricate label" -msgstr "" +msgstr "Label Suricate" msgid "Problem magnitudes" msgstr "Amplitudes des problèmes" @@ -278,11 +278,17 @@ msgstr "" "Des informations n'ont pas encore pu être transmises à Suricate - Merci de " "vérifier plus tard" +msgid "Intervention" +msgstr "Intervention" + +msgid "Add a new intervention" +msgstr "Ajouter une nouvelle intervention" + msgid "Attributes" msgstr "Informations" msgid "None" -msgstr "" +msgstr "Aucun(e)" msgid "Districts" msgstr "Secteurs" @@ -303,19 +309,13 @@ msgid "Date" msgstr "Date" msgid "Yes" -msgstr "" +msgstr "Oui" msgid "No" -msgstr "" - -msgid "Intervention" -msgstr "Intervention" - -msgid "Add a new intervention" -msgstr "Ajouter une nouvelle intervention" +msgstr "Non" msgid "Map" -msgstr "" +msgstr "Carte" #, python-format msgid "%(email)s has sent a feedback." diff --git a/geotrek/feedback/locale/it/LC_MESSAGES/django.po b/geotrek/feedback/locale/it/LC_MESSAGES/django.po index a65044cb84..f5d7486e88 100644 --- a/geotrek/feedback/locale/it/LC_MESSAGES/django.po +++ b/geotrek/feedback/locale/it/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-06-04 15:20+0000\n" +"POT-Creation-Date: 2025-01-06 15:19+0000\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -266,6 +266,12 @@ msgid "" "Some data could not be forwarded to Suricate yet - Please come back later" msgstr "" +msgid "Intervention" +msgstr "" + +msgid "Add a new intervention" +msgstr "" + msgid "Attributes" msgstr "" @@ -296,12 +302,6 @@ msgstr "" msgid "No" msgstr "" -msgid "Intervention" -msgstr "" - -msgid "Add a new intervention" -msgstr "" - msgid "Map" msgstr "" diff --git a/geotrek/feedback/locale/nl/LC_MESSAGES/django.po b/geotrek/feedback/locale/nl/LC_MESSAGES/django.po index a65044cb84..f5d7486e88 100644 --- a/geotrek/feedback/locale/nl/LC_MESSAGES/django.po +++ b/geotrek/feedback/locale/nl/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-06-04 15:20+0000\n" +"POT-Creation-Date: 2025-01-06 15:19+0000\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -266,6 +266,12 @@ msgid "" "Some data could not be forwarded to Suricate yet - Please come back later" msgstr "" +msgid "Intervention" +msgstr "" + +msgid "Add a new intervention" +msgstr "" + msgid "Attributes" msgstr "" @@ -296,12 +302,6 @@ msgstr "" msgid "No" msgstr "" -msgid "Intervention" -msgstr "" - -msgid "Add a new intervention" -msgstr "" - msgid "Map" msgstr "" diff --git a/geotrek/feedback/templates/feedback/report_detail.html b/geotrek/feedback/templates/feedback/report_detail.html index c2f9e9391c..0596f704b1 100644 --- a/geotrek/feedback/templates/feedback/report_detail.html +++ b/geotrek/feedback/templates/feedback/report_detail.html @@ -1,5 +1,5 @@ {% extends "common/common_detail.html" %} -{% load feedback_tags i18n %} +{% load feedback_tags i18n mapentity_tags %} {% block detailspanel %} @@ -19,3 +19,38 @@ {{ block.super }} {% endblock detailspanel %} + +{% block related_objects_tab_content %} + {% suricate_workflow_enabled as suricate_workflow_enabled %} +
{{ object|verbose:"structure" }}
+ + + {% endif %} + +
+ {% if perms.maintenance.add_intervention %} +

{% trans "Intervention" %}

+ {% with columns="name,status,stake,total_cost,begin_date,end_date" %} + {% valuetable report.interventions.all columns=columns %} + {% endwith %} + {% if not suricate_workflow_enabled %} +

+

+ + {% trans "Add a new intervention" %} +

+ {% elif suricate_workflow_enabled and report.interventions.all|length == 0 %} + {% if report.status.identifier == 'late_intervention' or report.status.identifier == 'waiting' %} +

+

+ + {% trans "Add a new intervention" %} +

+ {% endif %} + {% endif %} +
+
+{% endblock %} \ No newline at end of file diff --git a/geotrek/feedback/templates/feedback/report_detail_attributes.html b/geotrek/feedback/templates/feedback/report_detail_attributes.html index 7f46fa455f..b5cc2a68ea 100644 --- a/geotrek/feedback/templates/feedback/report_detail_attributes.html +++ b/geotrek/feedback/templates/feedback/report_detail_attributes.html @@ -5,7 +5,6 @@ {% block attributes %} {% suricate_workflow_enabled as suricate_workflow_enabled %} {% workflow_manager as workflow_manager %} -

{% trans "Attributes" %}

{% if not suricate_workflow_enabled or request.user.pk == workflow_manager or request.user.is_superuser%} @@ -125,35 +124,5 @@

{% trans "Attributes" %}

{% endif %} {% include "mapentity/trackinfo_fragment.html" %}
- - - - - {% endif %} - -
- {% if perms.maintenance.add_intervention %} -

{% trans "Intervention" %}

- {% with columns="name,status,stake,total_cost,begin_date,end_date" %} - {% valuetable report.interventions.all columns=columns %} - {% endwith %} - {% if not suricate_workflow_enabled %} -

-

- - {% trans "Add a new intervention" %} -

- {% elif suricate_workflow_enabled and report.interventions.all|length == 0 %} - {% if report.status.identifier == 'late_intervention' or report.status.identifier == 'waiting' %} -

-

- - {% trans "Add a new intervention" %} -

- {% endif %} - {% endif %} -
{% endblock attributes %} diff --git a/geotrek/infrastructure/templates/infrastructure/infrastructure_detail_attributes.html b/geotrek/infrastructure/templates/infrastructure/infrastructure_detail_attributes.html index 7fd4c13287..c9269d0a02 100644 --- a/geotrek/infrastructure/templates/infrastructure/infrastructure_detail_attributes.html +++ b/geotrek/infrastructure/templates/infrastructure/infrastructure_detail_attributes.html @@ -3,7 +3,6 @@ {% block attributes %} -

{% trans "Attributes" %}

diff --git a/geotrek/outdoor/templates/outdoor/course_detail_attributes.html b/geotrek/outdoor/templates/outdoor/course_detail_attributes.html index 092f126711..2fda024c8f 100644 --- a/geotrek/outdoor/templates/outdoor/course_detail_attributes.html +++ b/geotrek/outdoor/templates/outdoor/course_detail_attributes.html @@ -2,9 +2,8 @@ {% load i18n geotrek_tags mapentity_tags outdoor_tags %} {% block attributes %}

{% trans "Tree view" %}

- {% include "outdoor/recursive_courses_tree.html" with sites_at_level=course.all_hierarchy_roots original_course=object %} + {% include "outdoor/recursive_courses_tree.html" with sites_at_level=course.all_hierarchy_roots original_course=object %} -

{% trans "Attributes" %}

{{ object|verbose:"structure" }}
diff --git a/geotrek/outdoor/templates/outdoor/site_detail_attributes.html b/geotrek/outdoor/templates/outdoor/site_detail_attributes.html index 809bdecb0e..4132111c88 100644 --- a/geotrek/outdoor/templates/outdoor/site_detail_attributes.html +++ b/geotrek/outdoor/templates/outdoor/site_detail_attributes.html @@ -5,7 +5,6 @@

{% trans "Tree view" %}

{% site_as_list site.get_root as root_as_list %} {% include "outdoor/recursive_sites_tree.html" with sites_at_level=root_as_list original_site=object %} -

{% trans "Attributes" %}

{{ object|verbose:"structure" }}
@@ -114,7 +113,7 @@

{% trans "Attributes" %}

{{ object|verbose:"structure" }} {% for label in object.labels.all %} {% if label.published %} - + {% endif %} {{ label.name }}
{% endfor %} diff --git a/geotrek/sensitivity/templates/sensitivity/sensitivearea_detail_attributes.html b/geotrek/sensitivity/templates/sensitivity/sensitivearea_detail_attributes.html index bbaaa39ab0..426e9a47a6 100644 --- a/geotrek/sensitivity/templates/sensitivity/sensitivearea_detail_attributes.html +++ b/geotrek/sensitivity/templates/sensitivity/sensitivearea_detail_attributes.html @@ -10,7 +10,6 @@ padding: 2px; } -

{% trans "Attributes" %}

diff --git a/geotrek/tourism/templates/tourism/touristiccontent_detail_attributes.html b/geotrek/tourism/templates/tourism/touristiccontent_detail_attributes.html index 48b510e9de..deaf0a42e7 100644 --- a/geotrek/tourism/templates/tourism/touristiccontent_detail_attributes.html +++ b/geotrek/tourism/templates/tourism/touristiccontent_detail_attributes.html @@ -2,7 +2,6 @@ {% load i18n mapentity_tags %} {% block attributes %} -

{% trans "Attributes" %}

{{ sensitivearea|verbose:"structure" }}
diff --git a/geotrek/tourism/templates/tourism/touristicevent_detail_attributes.html b/geotrek/tourism/templates/tourism/touristicevent_detail_attributes.html index abbbbb8985..9ac7920c8d 100644 --- a/geotrek/tourism/templates/tourism/touristicevent_detail_attributes.html +++ b/geotrek/tourism/templates/tourism/touristicevent_detail_attributes.html @@ -2,7 +2,6 @@ {% load i18n mapentity_tags %} {% block attributes %} -

{% trans "Attributes" %}

{{ object|verbose:"structure" }}
diff --git a/geotrek/trekking/locale/de/LC_MESSAGES/django.po b/geotrek/trekking/locale/de/LC_MESSAGES/django.po index ed5d526102..bd964fb551 100644 --- a/geotrek/trekking/locale/de/LC_MESSAGES/django.po +++ b/geotrek/trekking/locale/de/LC_MESSAGES/django.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: \n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-11-08 16:23+0000\n" +"POT-Creation-Date: 2025-01-06 15:41+0000\n" "PO-Revision-Date: 2015-10-21 11:16+0200\n" "Last-Translator: \n" "Language-Team: \n" @@ -484,16 +484,6 @@ msgstr "" msgid "APIDAE Trek #%(eid_val)s at line %(line)s" msgstr "" -msgid "" -"Feature geometry cannot be converted to a single continuous LineString " -"feature" -msgstr "" - -msgid "" -"Geometries from various features cannot be converted to a single continuous " -"LineString feature" -msgstr "" - msgid "Trek geometry is None" msgstr "" @@ -559,9 +549,6 @@ msgstr "" msgid "Print booklet" msgstr "" -msgid "Photos accessibility" -msgstr "" - msgid "Itinerancy" msgstr "Roaming" diff --git a/geotrek/trekking/locale/en/LC_MESSAGES/django.po b/geotrek/trekking/locale/en/LC_MESSAGES/django.po index 65b7dbe881..f4eeb7af72 100644 --- a/geotrek/trekking/locale/en/LC_MESSAGES/django.po +++ b/geotrek/trekking/locale/en/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-11-08 16:23+0000\n" +"POT-Creation-Date: 2025-01-06 15:41+0000\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -469,16 +469,6 @@ msgstr "" msgid "APIDAE Trek #%(eid_val)s at line %(line)s" msgstr "" -msgid "" -"Feature geometry cannot be converted to a single continuous LineString " -"feature" -msgstr "" - -msgid "" -"Geometries from various features cannot be converted to a single continuous " -"LineString feature" -msgstr "" - msgid "Trek geometry is None" msgstr "" @@ -542,9 +532,6 @@ msgstr "" msgid "Print booklet" msgstr "" -msgid "Photos accessibility" -msgstr "" - msgid "Itinerancy" msgstr "" diff --git a/geotrek/trekking/locale/es/LC_MESSAGES/django.po b/geotrek/trekking/locale/es/LC_MESSAGES/django.po index 5f1ddf2b0d..cda5340c44 100644 --- a/geotrek/trekking/locale/es/LC_MESSAGES/django.po +++ b/geotrek/trekking/locale/es/LC_MESSAGES/django.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: \n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-11-08 16:23+0000\n" +"POT-Creation-Date: 2025-01-06 15:41+0000\n" "PO-Revision-Date: 2015-10-21 11:16+0200\n" "Last-Translator: jean-etienne.castagnede@makina-corpus.com\n" "Language-Team: \n" @@ -469,16 +469,6 @@ msgstr "" msgid "APIDAE Trek #%(eid_val)s at line %(line)s" msgstr "" -msgid "" -"Feature geometry cannot be converted to a single continuous LineString " -"feature" -msgstr "" - -msgid "" -"Geometries from various features cannot be converted to a single continuous " -"LineString feature" -msgstr "" - msgid "Trek geometry is None" msgstr "" @@ -542,9 +532,6 @@ msgstr "" msgid "Print booklet" msgstr "" -msgid "Photos accessibility" -msgstr "" - msgid "Itinerancy" msgstr "" diff --git a/geotrek/trekking/locale/fr/LC_MESSAGES/django.po b/geotrek/trekking/locale/fr/LC_MESSAGES/django.po index d96b44ad64..dac6d0f958 100644 --- a/geotrek/trekking/locale/fr/LC_MESSAGES/django.po +++ b/geotrek/trekking/locale/fr/LC_MESSAGES/django.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: \n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-11-08 16:23+0000\n" +"POT-Creation-Date: 2025-01-06 15:41+0000\n" "PO-Revision-Date: 2020-09-22 15:57+0000\n" "Last-Translator: Emmanuelle Helly \n" "Language-Team: French {% trans "Attributes" %}
{{ object|verbose:"structure" }}
diff --git a/geotrek/trekking/templates/trekking/service_detail_attributes.html b/geotrek/trekking/templates/trekking/service_detail_attributes.html index fb0a448f12..a02e9fa7aa 100644 --- a/geotrek/trekking/templates/trekking/service_detail_attributes.html +++ b/geotrek/trekking/templates/trekking/service_detail_attributes.html @@ -2,7 +2,6 @@ {% load i18n mapentity_tags %} {% block attributes %} -

{% trans "Attributes" %}

diff --git a/geotrek/trekking/templates/trekking/trek_detail.html b/geotrek/trekking/templates/trekking/trek_detail.html index f61389344e..42af1762d2 100644 --- a/geotrek/trekking/templates/trekking/trek_detail.html +++ b/geotrek/trekking/templates/trekking/trek_detail.html @@ -12,19 +12,8 @@ {% trans "Print booklet" %} {% endblock download %} -{% block after_attachments_extra_tab_nav %} - {% is_photos_accessibilities_enabled as enabled %} - {% if enabled %} - - {% endif %} -{% endblock %} - - {% block attachments_extra_tab_nav %} - {% with attachments_count=object.attachments.count|add:object.view_points.count %} + {% with attachments_count=object.attachments.count|add:object.attachments_accessibility.count|add:object.view_points.count %}
@@ -38,7 +37,7 @@

{% trans "Attributes" %}

{{ trek|verbose:"structure" }} {% for label in trek.labels.all %} {% if label.published %} - + {% endif %} {{ label.name }}
{% endfor %} @@ -260,5 +259,6 @@

{% trans "Attributes" %}

+ {{ block.super }} {% endblock attributes %} diff --git a/requirements.txt b/requirements.txt index 9402b9db39..4a328c49d4 100644 --- a/requirements.txt +++ b/requirements.txt @@ -236,7 +236,8 @@ lxml==4.9.3 # via # mapentity # svglib -mapentity==8.10.0 +#mapentity==8.10.0 +mapentity @ git+https://github.com/makinacorpus/django-mapentity.git@move_related_objects_to_new_tab # via geotrek (setup.py) markdown==3.7 # via geotrek (setup.py) diff --git a/setup.py b/setup.py index b34032010c..42ebdc8f1a 100644 --- a/setup.py +++ b/setup.py @@ -32,7 +32,7 @@ def run(self): install_requires=[ 'Django==4.2.*', 'backports-zoneinfo;python_version<"3.10"', # not directly needed but required to make it worked with 3.10 - 'mapentity', + 'mapentity@git+https://github.com/makinacorpus/django-mapentity.git@move_related_objects_to_new_tab#egg=mapentity', 'chardet', 'cairosvg', 'cairocffi',