diff options
author | Étienne Loks <etienne.loks@iggdrasil.net> | 2017-10-26 18:29:00 +0200 |
---|---|---|
committer | Étienne Loks <etienne.loks@iggdrasil.net> | 2017-10-26 18:29:00 +0200 |
commit | 5fb235649207a15f54c69f3ac9c2f0659fc2436d (patch) | |
tree | 0b6a033a9446f485bf825d54d26518adc2e206e4 | |
parent | 088239b8fbe0bd68edd66123549b064189fe5678 (diff) | |
download | Ishtar-5fb235649207a15f54c69f3ac9c2f0659fc2436d.tar.bz2 Ishtar-5fb235649207a15f54c69f3ac9c2f0659fc2436d.zip |
Towns: remove "canton" add limits - change meta for data
7 files changed, 262 insertions, 2 deletions
diff --git a/archaeological_context_records/migrations/0013_auto_20171026_1827.py b/archaeological_context_records/migrations/0013_auto_20171026_1827.py new file mode 100644 index 000000000..7f7c0062e --- /dev/null +++ b/archaeological_context_records/migrations/0013_auto_20171026_1827.py @@ -0,0 +1,34 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.11 on 2017-10-26 18:27 +from __future__ import unicode_literals + +import django.contrib.postgres.fields.jsonb +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('archaeological_context_records', '0012_auto_20171017_1840'), + ] + + operations = [ + migrations.AlterModelOptions( + name='recordrelations', + options={'permissions': [('view_recordrelation', 'Can view all Context record relations')], 'verbose_name': 'Record relation', 'verbose_name_plural': 'Record relations'}, + ), + migrations.AlterModelOptions( + name='recordrelationview', + options={'managed': False, 'permissions': [('view_recordrelation', 'Can view all record relations - view')]}, + ), + migrations.AlterField( + model_name='contextrecord', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + migrations.AlterField( + model_name='historicalcontextrecord', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + ] diff --git a/archaeological_files/migrations/0011_auto_20171026_1827.py b/archaeological_files/migrations/0011_auto_20171026_1827.py new file mode 100644 index 000000000..93cbaf62c --- /dev/null +++ b/archaeological_files/migrations/0011_auto_20171026_1827.py @@ -0,0 +1,26 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.11 on 2017-10-26 18:27 +from __future__ import unicode_literals + +import django.contrib.postgres.fields.jsonb +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('archaeological_files', '0010_auto_20171017_1840'), + ] + + operations = [ + migrations.AlterField( + model_name='file', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + migrations.AlterField( + model_name='historicalfile', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + ] diff --git a/archaeological_finds/migrations/0013_auto_20171026_1828.py b/archaeological_finds/migrations/0013_auto_20171026_1828.py new file mode 100644 index 000000000..e11bdc60b --- /dev/null +++ b/archaeological_finds/migrations/0013_auto_20171026_1828.py @@ -0,0 +1,61 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.11 on 2017-10-26 18:28 +from __future__ import unicode_literals + +import django.contrib.postgres.fields.jsonb +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('archaeological_finds', '0012_auto_20171017_1840'), + ] + + operations = [ + migrations.AlterField( + model_name='basefind', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + migrations.AlterField( + model_name='find', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + migrations.AlterField( + model_name='historicalbasefind', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + migrations.AlterField( + model_name='historicalfind', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + migrations.AlterField( + model_name='historicaltreatment', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + migrations.AlterField( + model_name='historicaltreatmentfile', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + migrations.AlterField( + model_name='property', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + migrations.AlterField( + model_name='treatment', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + migrations.AlterField( + model_name='treatmentfile', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + ] diff --git a/archaeological_operations/migrations/0012_auto_20171026_1827.py b/archaeological_operations/migrations/0012_auto_20171026_1827.py new file mode 100644 index 000000000..3b34f8c4f --- /dev/null +++ b/archaeological_operations/migrations/0012_auto_20171026_1827.py @@ -0,0 +1,55 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.11 on 2017-10-26 18:27 +from __future__ import unicode_literals + +import django.contrib.postgres.fields.jsonb +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('archaeological_operations', '0011_auto_20171017_1840'), + ] + + operations = [ + migrations.AlterModelOptions( + name='recordrelations', + options={'ordering': ('left_record', 'relation_type'), 'permissions': [('view_operationrelation', 'Can view all Operation relations')], 'verbose_name': 'Operation record relation', 'verbose_name_plural': 'Operation record relations'}, + ), + migrations.AlterField( + model_name='administrativeact', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + migrations.AlterField( + model_name='archaeologicalsite', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + migrations.AlterField( + model_name='historicaladministrativeact', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + migrations.AlterField( + model_name='historicaloperation', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + migrations.AlterField( + model_name='operation', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + migrations.AlterField( + model_name='parcel', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + migrations.AlterField( + model_name='parcelowner', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + ] diff --git a/archaeological_warehouse/migrations/0011_auto_20171026_1828.py b/archaeological_warehouse/migrations/0011_auto_20171026_1828.py new file mode 100644 index 000000000..0f1363816 --- /dev/null +++ b/archaeological_warehouse/migrations/0011_auto_20171026_1828.py @@ -0,0 +1,31 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.11 on 2017-10-26 18:28 +from __future__ import unicode_literals + +import django.contrib.postgres.fields.jsonb +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('archaeological_warehouse', '0010_auto_20171017_1840'), + ] + + operations = [ + migrations.AlterField( + model_name='collection', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + migrations.AlterField( + model_name='container', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + migrations.AlterField( + model_name='warehouse', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + ] diff --git a/ishtar_common/migrations/0019_auto_20171026_1827.py b/ishtar_common/migrations/0019_auto_20171026_1827.py new file mode 100644 index 000000000..854304837 --- /dev/null +++ b/ishtar_common/migrations/0019_auto_20171026_1827.py @@ -0,0 +1,54 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.11 on 2017-10-26 18:27 +from __future__ import unicode_literals + +import django.contrib.gis.db.models.fields +import django.contrib.postgres.fields.jsonb +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('ishtar_common', '0018_auto_20171017_1840'), + ] + + operations = [ + migrations.AlterModelOptions( + name='jsondatafield', + options={'ordering': ['order', 'name'], 'verbose_name': 'Json data - Field', 'verbose_name_plural': 'Json data - Fields'}, + ), + migrations.AlterModelOptions( + name='jsondatasection', + options={'ordering': ['order', 'name'], 'verbose_name': 'Json data - Menu', 'verbose_name_plural': 'Json data - Menus'}, + ), + migrations.RemoveField( + model_name='town', + name='canton', + ), + migrations.AddField( + model_name='town', + name='limit', + field=django.contrib.gis.db.models.fields.MultiPolygonField(blank=True, null=True, srid=4326, verbose_name='Limit'), + ), + migrations.AlterField( + model_name='historicalorganization', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + migrations.AlterField( + model_name='historicalperson', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + migrations.AlterField( + model_name='organization', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + migrations.AlterField( + model_name='person', + name='data', + field=django.contrib.postgres.fields.jsonb.JSONField(blank=True, db_index=True, default={}), + ), + ] diff --git a/ishtar_common/models.py b/ishtar_common/models.py index c3ba4fdd0..a06568d99 100644 --- a/ishtar_common/models.py +++ b/ishtar_common/models.py @@ -2659,12 +2659,11 @@ class Town(Imported, models.Model): surface = models.IntegerField(_(u"Surface (m2)"), blank=True, null=True) center = models.PointField(_(u"Localisation"), srid=settings.SRID, blank=True, null=True) + limit = models.MultiPolygonField(_(u"Limit"), blank=True, null=True) if settings.COUNTRY == 'fr': numero_insee = models.CharField(u"Numéro INSEE", max_length=6) departement = models.ForeignKey( Department, verbose_name=u"Département", null=True, blank=True) - canton = models.ForeignKey(Canton, verbose_name=u"Canton", null=True, - blank=True) year = models.IntegerField( _("Year of creation"), null=True, blank=True, help_text=_(u"Filling this field is relevant to distinguish old towns " |