# Generated by Django 4.2.9 on 2024-01-29 08:16

from django.db import migrations, models
import taggit.managers
import utilities.json


class Migration(migrations.Migration):

    dependencies = [
        ('slurpit_netbox', '0004_slurpitmapping'),
    ]

    operations = [
        migrations.RunSQL(
            """
            UPDATE extras_customfield
            SET name = 'slurpit_manufacturer',
                label = 'Manufacturer'
            WHERE name = 'slurpit_manufactor'
            """,
        ),
        migrations.RunSQL(
            """
            UPDATE dcim_device
            SET custom_field_data = custom_field_data - 'slurpit_manufactor' || jsonb_build_object('slurpit_manufacturer', custom_field_data->'slurpit_manufactor')
			WHERE custom_field_data ? 'slurpit_manufactor'
            """,
        ),
    ]
