diff options
Diffstat (limited to 'ishtar_common')
-rw-r--r-- | ishtar_common/fixtures/initial_geo-fr.json | 17 | ||||
-rw-r--r-- | ishtar_common/management/commands/migrate_to_geo_v4.py | 5 |
2 files changed, 7 insertions, 15 deletions
diff --git a/ishtar_common/fixtures/initial_geo-fr.json b/ishtar_common/fixtures/initial_geo-fr.json index 514d9a9bf..a7563cb85 100644 --- a/ishtar_common/fixtures/initial_geo-fr.json +++ b/ishtar_common/fixtures/initial_geo-fr.json @@ -525,8 +525,8 @@ { "model": "ishtar_common.geoorigintype", "fields": { - "label": "Digitalisation de carte ancienne", - "txt_idx": "digitalisation-de-carte-ancienne", + "label": "Vectorisation de carte ancienne", + "txt_idx": "vectorisation-de-carte-ancienne", "comment": "", "available": true, "parent": null, @@ -646,19 +646,8 @@ { "model": "ishtar_common.geodatatype", "fields": { - "label": "Centre du mobilier d'origine", - "txt_idx": "basefind-center", - "comment": "", - "available": true, - "parent": null, - "order": 10 - } -}, -{ - "model": "ishtar_common.geodatatype", - "fields": { "label": "Point mobilier", - "txt_idx": "point-mobilier", + "txt_idx": "basefind-center", "comment": "", "available": true, "parent": null, diff --git a/ishtar_common/management/commands/migrate_to_geo_v4.py b/ishtar_common/management/commands/migrate_to_geo_v4.py index 11e4f7b76..77fcd2727 100644 --- a/ishtar_common/management/commands/migrate_to_geo_v4.py +++ b/ishtar_common/management/commands/migrate_to_geo_v4.py @@ -368,9 +368,12 @@ def migrate(log=True, process_number=1): txt_idx=f"{model_slug}-outline", defaults={"label": f"Contour {model_full_name}"}, ) + lbl = f"Centre {model_full_name}" + if model == BaseFind: + lbl = "Point mobilier" data_type_center, __ = models_common.GeoDataType.objects.get_or_create( txt_idx=f"{model_slug}-center", - defaults={"label": f"Centre {model_full_name}"}, + defaults={"label": lbl}, ) q = model.objects.exclude(main_geodata__isnull=False) launch_job(q.all(), model_name, process_number, _process_main) |