# Copyright © Michal Čihař <michal@weblate.org>
#
# SPDX-License-Identifier: GPL-3.0-or-later

# Generated by Django 4.2.3 on 2023-08-04 10:42

from django.db import migrations

from weblate.utils.fields import migrate_json_field


def billing_jsonfield(apps, schema_editor):
    migrate_json_field(
        apps.get_model("billing", "Billing"),
        schema_editor.connection.alias,
        "payment",
    )
    migrate_json_field(
        apps.get_model("billing", "Invoice"),
        schema_editor.connection.alias,
        "payment",
    )


class Migration(migrations.Migration):
    dependencies = [
        ("billing", "0007_billing_payment_new"),
    ]

    operations = [migrations.RunPython(billing_jsonfield, elidable=True)]
