Skip to content

Commit

Permalink
Add keywords
Browse files Browse the repository at this point in the history
  • Loading branch information
bruhnild committed Jan 13, 2025
1 parent ffc9b7f commit ac2e90f
Show file tree
Hide file tree
Showing 14 changed files with 470 additions and 142 deletions.
2 changes: 2 additions & 0 deletions docs/advanced-configuration/attachments.rst
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ Attached files are downloaded by default by browser, with the following line, fi
Resizing uploaded pictures
----------------------------

See the default values in `geotrek/settings/base.py <https://github.com/GeotrekCE/Geotrek-admin/blob/master/geotrek/settings/base.py>`_ for the complete list of available parameters.

Paperclip resize attachments on upload
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Expand Down
19 changes: 15 additions & 4 deletions docs/advanced-configuration/edition.rst
Original file line number Diff line number Diff line change
Expand Up @@ -67,11 +67,22 @@ You can also add ``{legend}``: ``"{title}-:-{author}-:-{legend}"``
Thumbnail copyright size
~~~~~~~~~~~~~~~~~~~~~~~~~~

Change the size of thumbnail
Change the size of thumbnail:

Example::
.. md-tab-set::
:name: thumbnail-copyright-tabs

.. md-tab-item:: Default configuration

THUMBNAIL_COPYRIGHT_SIZE = 15
.. code-block:: python
THUMBNAIL_COPYRIGHT_SIZE = 15
.. md-tab-item:: Example

.. code-block:: python
THUMBNAIL_COPYRIGHT_SIZE = 20
Facebook configuration
-----------------------
Expand Down Expand Up @@ -103,7 +114,7 @@ Example::
Override translations
----------------------

Translations are managed by https://weblate.makina-corpus.net/ where you can contribute.
Translations are managed by `Weblate <https://weblate.makina-corpus.net/>`_ where you can contribute.
But you can also override default translation files available in each module
(for example those from trekking module available in ``/opt/geotrek-admin/lib/python3.6/site-packages/geotrek/trekking/locale/fr/LC_MESSAGES/django.po``).

Expand Down
158 changes: 131 additions & 27 deletions docs/advanced-configuration/feedback-report-settings.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
Feedback reports settings
==========================

See the default values in `geotrek/settings/base.py <https://github.com/GeotrekCE/Geotrek-admin/blob/master/geotrek/settings/base.py>`_ for the complete list of available parameters.

Send acknowledge email
------------------------

Expand All @@ -19,12 +21,12 @@ If ``False``, no email will be sent to the sender of any feedback on Geotrek-ran

.. code-block:: python
SEND_REPORT_ACK = False
SEND_REPORT_ACK = True
.. md-tab-item:: Example

.. code-block:: python
SEND_REPORT_ACK = True
SEND_REPORT_ACK = False
.. _suricate-support:

Expand All @@ -42,9 +44,20 @@ This mode sends no report data to Suricate.

To initialize Report forms (Geotrek-admin, Geotrek-rando-V2, Geotrek-rando-V3) load lists for categories, activities, statuses and problem magnitude:

.. code-block:: python
.. md-tab-set::
:name: loaddata-no-suricate-tabs

.. md-tab-item:: With Debian

.. code-block:: bash
geotrek loaddata /opt/geotrek-admin/lib/python*/site-packages/geotrek/feedback/fixtures/basic.json
geotrek loaddata /opt/geotrek-admin/lib/python*/site-packages/geotrek/feedback/fixtures/basic.json
.. md-tab-item:: With Docker

.. code-block:: python
docker compose run --rm web ./manage.py loaddata /opt/geotrek-admin/lib/python*/site-packages/geotrek/feedback/fixtures/basic.json
2 - Suricate Standard
~~~~~~~~~~~~~~~~~~~~~~~~~~
Expand Down Expand Up @@ -187,28 +200,73 @@ You can find the same detailled explanation on the workflow in `this article in
You can use the following command to test your connection settings:

.. code-block:: python
.. md-tab-set::
:name: sync-suricate-connectiontest-tabs

geotrek sync_suricate -v 2 --connection-test
.. md-tab-item:: With Debian

.. code-block:: bash
geotrek sync_suricate -v 2 --connection-test
.. md-tab-item:: With Docker

.. code-block:: python
docker compose run --rm web ./manage.py sync_suricate -v 2 --connection-test
Load lists for activities and/or report statuses from Suricate:

.. code-block:: python
.. md-tab-set::
:name: sync-suricate-status-tabs

.. md-tab-item:: With Debian

.. code-block:: bash
geotrek sync_suricate --activities --statuses -v 2
geotrek sync_suricate --activities --statuses -v 2
.. md-tab-item:: With Docker

.. code-block:: python
docker compose run --rm web ./manage.py sync_suricate --activities --statuses -v 2
Load alerts from Suricate (located in your bounding box) :

.. code-block:: python
.. md-tab-set::
:name: sync-suricate-alerts-tabs

.. md-tab-item:: With Debian

.. code-block:: bash
geotrek sync_suricate -v 2 --no-notification
.. md-tab-item:: With Docker

geotrek sync_suricate -v 2 --no-notification
.. code-block:: python
docker compose run --rm web ./manage.py sync_suricate -v 2 --no-notification
- Then load extra required statuses for Reports and Interventions:

.. code-block:: python
.. md-tab-set::
:name: sync-suricate-reports-tabs

geotrek loaddata /opt/geotrek-admin/lib/python*/site-packages/geotrek/feedback/fixtures/management_workflow.json
geotrek loaddata /opt/geotrek-admin/lib/python*/site-packages/geotrek/maintenance/fixtures/basic.json
.. md-tab-item:: With Debian

.. code-block:: bash
geotrek loaddata /opt/geotrek-admin/lib/python*/site-packages/geotrek/feedback/fixtures/management_workflow.json
geotrek loaddata /opt/geotrek-admin/lib/python*/site-packages/geotrek/maintenance/fixtures/basic.json
.. md-tab-item:: With Docker

.. code-block:: python
docker compose run --rm web ./manage.py loaddata /opt/geotrek-admin/lib/python*/site-packages/geotrek/feedback/fixtures/management_workflow.json
docker compose run --rm web ./manage.py loaddata /opt/geotrek-admin/lib/python*/site-packages/geotrek/maintenance/fixtures/basic.json
- Go to the configuration site and :

Expand All @@ -223,11 +281,24 @@ Load alerts from Suricate (located in your bounding box) :

Make sure to run these three commands daily to maintain synchronization and update reports (thanks to `cron` for instance) :

.. code-block:: python
.. md-tab-set::
:name: sync-suricate-sync-tabs

.. md-tab-item:: With Debian

.. code-block:: bash
geotrek retry_failed_requests_and_mails
geotrek check_timers
geotrek sync_suricate
geotrek retry_failed_requests_and_mails
geotrek check_timers
geotrek sync_suricate
.. md-tab-item:: With Docker

.. code-block:: python
docker compose run --rm web ./manage.py retry_failed_requests_and_mails
docker compose run --rm web ./manage.py check_timers
docker compose run --rm web ./manage.py sync_suricate
Display reports with status defined colors
--------------------------------------------
Expand All @@ -244,12 +315,12 @@ Go to the Configuration site and select colors to display for each status (`/adm

.. code-block:: python
ENABLE_REPORT_COLORS_PER_STATUS = False
ENABLE_REPORT_COLORS_PER_STATUS = True
.. md-tab-item:: Example

.. code-block:: python
ENABLE_REPORT_COLORS_PER_STATUS = True
ENABLE_REPORT_COLORS_PER_STATUS = False
Use timers to receive alerts for your reports
-------------------------------------------------
Expand All @@ -268,9 +339,21 @@ Use timers to receive alerts for your reports

- Make sure to run this commands daily to send email alerts and clear obsolete timers (thanks to `cron` for instance) :

.. code-block:: python

geotrek check_timers
.. md-tab-set::
:name: sync-checktimers-tabs

.. md-tab-item:: With Debian

.. code-block:: bash
geotrek check_timers
.. md-tab-item:: With Docker

.. code-block:: python
docker compose run --rm web ./manage.py check_timers
Anonymize feedback reports
---------------------------
Expand All @@ -279,16 +362,37 @@ To be compliant to GDPR, you cannot keep personnal data infinitely,
and should notice your users on how many time you keep their email.

A Django command is available to anonymize reports, by default older
than 365 days.
than 365 days:

.. code-block:: bash
.. md-tab-set::
:name: erase-emails-tabs

geotrek erase_emails
.. md-tab-item:: With Debian

Or if you want to erase emails for reports older than 90 days
.. code-block:: bash
geotrek erase_emails
.. code-block:: bash
.. md-tab-item:: With Docker

geotrek erase_emails --days 90
.. code-block:: python
docker compose run --rm web ./manage.py erase_emails
Or if you want to erase emails for reports older than 90 days:

.. md-tab-set::
:name: erase-emails-older-tabs

.. md-tab-item:: With Debian

.. code-block:: bash
geotrek erase_emails --days 90
.. md-tab-item:: With Docker

.. code-block:: python
docker compose run --rm web ./manage.py erase_emails --days 90
43 changes: 28 additions & 15 deletions docs/advanced-configuration/interface.rst
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,25 @@ For each module, use the following syntax to configure columns to export as CSV
COLUMNS_LISTS['<module>_export'] = ['list', 'of', 'columns']
Another setting exists to enable a more detailed export of jobs costs in the interventions module. When enabling this settings, interventions list exports will contain a new column for each job's total cost.
.. md-tab-set::
:name: enable-job-costs-detailed-export-tabs

.. md-tab-item:: Default configuration

.. code-block:: python
ENABLE_JOBS_COSTS_DETAILED_EXPORT = False
.. md-tab-item:: Example

.. code-block:: python
ENABLE_JOBS_COSTS_DETAILED_EXPORT = True
Enable jobs cost detailed export
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Enable a more detailed export
Enable a more detailed export :

.. md-tab-set::
:name: enable-job-costs-detailed-export-tabs
Expand All @@ -41,6 +54,8 @@ Enable jobs cost detailed export
ENABLE_JOBS_COSTS_DETAILED_EXPORT = True
When enabling this setting, interventions list exports will contain a new column for each job's total cost.

Custom columns available
~~~~~~~~~~~~~~~~~~~~~~~~~

Expand Down Expand Up @@ -1128,11 +1143,11 @@ Configure form fields in creation views
Hidden form fields
~~~~~~~~~~~~~~~~~~~~

For each module, use the following syntax to configure fields to hide in the creation form.
For each module, use the following syntax to configure fields to hide in the creation form.

Example::
Example::

HIDDEN_FORM_FIELDS['<module>'] = ['list', 'of', 'fields']
HIDDEN_FORM_FIELDS['<module>'] = ['list', 'of', 'fields']


Hideable form fields
Expand Down Expand Up @@ -1449,20 +1464,18 @@ and ``error_on_review`` if you want this fields to be required before sending to
Completeness level
~~~~~~~~~~~~~~~~~~~

Configure completeness level

Example::
Example of completeness level configuration::

COMPLETENESS_LEVEL = 'warning'
COMPLETENESS_LEVEL = 'warning'

Completeness fields
~~~~~~~~~~~~~~~~~~~~~

For each module, configure fields to be needed or required on review or publication
For each module, you can configure fields to be needed or required on review or publication.

Example::
Example::

COMPLETENESS_FIELDS = {
'trek': ['practice', 'departure', 'duration', 'difficulty', 'description_teaser'],
'dive': ['practice', 'difficulty', 'description_teaser'],
}
COMPLETENESS_FIELDS = {
'trek': ['practice', 'departure', 'duration', 'difficulty', 'description_teaser'],
'dive': ['practice', 'difficulty', 'description_teaser'],
}
Loading

0 comments on commit ac2e90f

Please sign in to comment.