<filename>exportplan/migrations/0032_update_ui_progress.py
# Generated by Django 2.2.13 on 2021-04-01 11:41

from django.db import migrations


class Migration(migrations.Migration):

    def migrate_data(apps, schema_editor):
        exportplans = apps.get_model("exportplan", "CompanyExportPlan")
        for exportplan in exportplans.objects.all():
            if exportplan.ui_progress.get('adaptation-for-your-target-market'):
                del exportplan.ui_progress['adaptation-for-your-target-market']
                exportplan.save()

    dependencies = [
        ('exportplan', '0031_auto_20210308_2141'),
    ]

    operations = [
        migrations.RunPython(migrate_data)
    ]
