Skip to content

Commit

Permalink
Merge pull request #85 from neogeo-technologies/develop
Browse files Browse the repository at this point in the history
v1.2.0
  • Loading branch information
sebastiendarocha authored Dec 21, 2020
2 parents fac291b + 9940309 commit 9ff7c51
Show file tree
Hide file tree
Showing 46 changed files with 2,995 additions and 223 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -95,3 +95,6 @@ config/settings.py
config/wsgi.py
config/__init__.py
/docker/nginx/conf.d/geocontrib.conf

# MacOS
.DS_Store
22 changes: 22 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,28 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).

## Unreleased

## [1.2.0] - 2020-12-17

### Changed
- Redmine 9704: Allow the management of feature links in Django admin
- Redmine 8551: Can import features files with extention "geojson" in addition to "json"
- Redmine 9330: A feature type can be duplicated
- Redmine 9329: Can turn a project into a project template and instatiate a project from a project model
- Django admin improvements
- Projects list ordered by title
- FeatureType list ordered by project, title
- FeatureType list grouped by project
- Users list ordered by username, last_name, first_name
- FeatureType geom editable on create (read-only on update)
- CustomField list ordered by feature_type, label
- Project creator required (fixing 500 on edit)

### Fixed
- Docker, prevent creating files not readable by nginx
- Redmine 9706: The modification of the basemap form are recorded
- Redmine 9654: Creating a basemap without title doesn't crash
- Redmine 9623: A connected user doesn't see achived features if he is not allowed

## [1.1.3] - 2020-11-13

### Changed
Expand Down
4 changes: 2 additions & 2 deletions api/serializers.py
Original file line number Diff line number Diff line change
Expand Up @@ -248,7 +248,7 @@ def get_feature_type_url(self, obj):
kwargs={
'slug': obj.project.slug,
'feature_type_slug': obj.feature_type.slug
})
})


class FeatureLinkSerializer(serializers.ModelSerializer):
Expand All @@ -261,7 +261,7 @@ def get_feature_to(self, obj):
res = {}
if obj.feature_to:
try:
feature = Feature.objects.get(feature_id=obj.feature_to)
feature = obj.feature_to
res = {
'feature_id': str(feature.feature_id),
'title': str(feature.title),
Expand Down
16 changes: 15 additions & 1 deletion config_sample/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -222,4 +222,18 @@
# Active geocoder
SELECTED_GEOCODER = {
'PROVIDER': config('SELECTED_GEOCODER_PROVIDER', default='addok')
}
}

# Project duplication settings
PROJECT_COPY_RELATED = {
'AUTHORIZATION': True,
'BASE_MAP': True,
'FEATURE': True,
'FEATURE_TYPE': True,
'THUMBNAIL': True,
}

DATA_UPLOAD_MAX_NUMBER_FIELDS = config('DATA_UPLOAD_MAX_NUMBER_FIELDS', default=10000)

# 9745 & 9645 don't create temp files with 0o000
FILE_UPLOAD_PERMISSIONS = 0o644
18 changes: 11 additions & 7 deletions docker/geocontrib/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -158,13 +158,13 @@
}

# E-mail and notification parameters
# EMAIL_BACKEND = config('EMAIL_BACKEND', default="django.core.mail.backends.console.EmailBackend")
# EMAIL_HOST = config('EMAIL_HOST')
# EMAIL_HOST_USER = config('EMAIL_HOST_USER')
# EMAIL_HOST_PASSWORD = config('EMAIL_HOST_PASSWORD')
# EMAIL_PORT = config('EMAIL_PORT', cast=int)
# EMAIL_USE_TLS = config('EMAIL_USE_TLS', cast=bool)
# DEFAULT_FROM_EMAIL = config('DEFAULT_FROM_EMAIL')
EMAIL_BACKEND = config('EMAIL_BACKEND', default="django.core.mail.backends.console.EmailBackend")
EMAIL_HOST = config('EMAIL_HOST')
EMAIL_HOST_USER = config('EMAIL_HOST_USER')
EMAIL_HOST_PASSWORD = config('EMAIL_HOST_PASSWORD')
EMAIL_PORT = config('EMAIL_PORT', cast=int)
EMAIL_USE_TLS = config('EMAIL_USE_TLS', cast=bool)
DEFAULT_FROM_EMAIL = config('DEFAULT_FROM_EMAIL')

# Notification frequency (allowed values: 'never', 'instantly', 'daily', 'weekly')
DEFAULT_SENDING_FREQUENCY = config('DEFAULT_SENDING_FREQUENCY', default='never')
Expand Down Expand Up @@ -212,3 +212,7 @@
}

DATA_UPLOAD_MAX_NUMBER_FIELDS = config('DATA_UPLOAD_MAX_NUMBER_FIELDS', default=10000)

# 9745 & 9645 don't create temp files with 0o000
FILE_UPLOAD_PERMISSIONS = 0o644

4 changes: 4 additions & 0 deletions geocontrib/admin/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
from geocontrib.admin.feature import *
from geocontrib.admin.flat_page import *
from geocontrib.admin.project import *
from geocontrib.admin.user import *
Loading

0 comments on commit 9ff7c51

Please sign in to comment.