diff --git a/django_project/api/management/commands/generate_shapefile_countries.py b/django_project/api/management/commands/generate_shapefile_countries.py index c809b15e..1cd5df96 100644 --- a/django_project/api/management/commands/generate_shapefile_countries.py +++ b/django_project/api/management/commands/generate_shapefile_countries.py @@ -80,7 +80,7 @@ def country_data_into_shapefile(country=None): query=queryset.filter(osm_type=LocalityOSMView.NODE), fields=fields, dir_shapefile=dir_shapefile, - shp_filename='{}-node'.format(shp_filename), + shp_filename=u'{}-node'.format(shp_filename), TYPE=shapefile.POINT) # generate the way shapefile @@ -88,7 +88,7 @@ def country_data_into_shapefile(country=None): query=queryset.filter(osm_type=LocalityOSMView.WAY), fields=fields, dir_shapefile=dir_shapefile, - shp_filename='{}-way'.format(shp_filename), + shp_filename=u'{}-way'.format(shp_filename), TYPE=shapefile.POLYGON) # zip this output diff --git a/django_project/api/urls.py b/django_project/api/urls.py index 6e609a37..fc8f5b0d 100644 --- a/django_project/api/urls.py +++ b/django_project/api/urls.py @@ -34,9 +34,9 @@ ) facilities_api = patterns( '', - url(r'^shapefile/(?P\w+)/detail', + url(r'^shapefile/(?P.+)/detail', GetShapefileDetail.as_view()), - url(r'^shapefile/(?P\w+)/download', + url(r'^shapefile/(?P.+)/download', GetShapefileDownload.as_view()), url(r'^cluster', GetCluster.as_view()),