Skip to content

Commit

Permalink
Add fixture rules of sensitive area
Browse files Browse the repository at this point in the history
  • Loading branch information
amandine-sahl committed Sep 11, 2023
1 parent a9f8969 commit 985d7b3
Show file tree
Hide file tree
Showing 41 changed files with 4,434 additions and 4 deletions.
1 change: 1 addition & 0 deletions debian/postinst
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@ if [ "$MANAGE_DB" = "true" ] && [ -z "$2" ]; then
geotrek loaddata -v0 cirkwi || true
geotrek loaddata -v0 basic || true
geotrek loaddata -v0 licenses || true
geotrek loaddata -v0 rules || true
for dir in `ls -d /opt/geotrek-admin/lib/python3*/site-packages/geotrek/*/fixtures/upload`; do
cd $dir > /dev/null
cp -r * /opt/geotrek-admin/var/media/upload/
Expand Down
1 change: 1 addition & 0 deletions docker/load_data.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ cd /opt/geotrek-admin
./manage.py loaddata cirkwi
./manage.py loaddata basic
./manage.py loaddata licenses
./manage.py loaddata rules

# copy media files for fixtures
for dir in `find geotrek/ -type d -name upload`; do pushd `dirname $$dir` > /dev/null && cp -R $dir/* /opt/geotrek-admin/var/media/upload/ && popd > /dev/null; done
6 changes: 5 additions & 1 deletion docs/changelog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ CHANGELOG
2.100.1+dev (XXXX-XX-XX)
------------------------

**New features**

- Add rules fixture on sensitive area (#3470)

**Improvements**

- Remove 'review' field on ServiceType (#1669)
Expand All @@ -31,7 +35,7 @@ CHANGELOG

**Documentation**

- Replace broken link
- Replace broken link

**Improvements**

Expand Down
12 changes: 9 additions & 3 deletions docs/install/advanced-configuration.rst
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ Geotrek reports can work together with Suricate API, using one of 3 modes. Proce

**1** - No Suricate (default)

This mode sends no report data to Suricate.
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:

Expand Down Expand Up @@ -191,7 +191,7 @@ To make these lists available for your Geotrek-rando, run ``sync_rando`` (see :r
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
- Go to the Admin Site and
- Go to the Admin Site and
- if you want to include the moderation steps (`SKIP_MANAGER_MODERATION = False`), select a user as Workflow Manager (`/admin/feedback/workflowmanager/`). Their role is to assign reports to other users.
- select a district as Workflow District (`/admin/feedback/workflowdistrict/`). This zone defines the area of reponsibility for reports. Reports relocated outside of the district will be excluded from workflow.
- create predefined emails (`/admin/feedback/predefinedemail/`) to notify Suricate Sentinels and Administrators. You can use `##intervention_date##` and `##supervisor##` in the messages' body to automatically replace with the report's linked Intervention date and author. The Extended Username field will be dsiplayed (see User Profile under `/admin/auth/user/`).
Expand All @@ -212,7 +212,7 @@ Display reports with status defined colors
.. code-block :: python
ENABLE_REPORT_COLORS_PER_STATUS = True
Go to the Admin Site and select colors to display for each status (`/admin/feedback/reportstatus/`).


Expand Down Expand Up @@ -319,6 +319,12 @@ You can insert licenses of attachments with this command :

sudo geotrek loaddata /opt/geotrek-admin/lib/python*/site-packages/geotrek/common/fixtures/licenses.json

You can insert rules of sensitive area with this command :

::

sudo geotrek loaddata /opt/geotrek-admin/lib/python*/site-packages/geotrek/sensitivity/fixtures/rules.json


Outdoor
-------
Expand Down
Loading

0 comments on commit 985d7b3

Please sign in to comment.