# Generated by Django 3.0.3 on 2020-02-22 04:39

import collections
from django.db import migrations, models
import django.db.models.deletion
import jsonfield.fields
import tests.models


class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('contenttypes', '0002_remove_content_type_name'),
    ]

    operations = [
        migrations.CreateModel(
            name='CallableDefaultModel',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('json', jsonfield.fields.JSONField(default=tests.models.default)),
            ],
        ),
        migrations.CreateModel(
            name='GenericForeignKeyObj',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=255, null=True, verbose_name='Foreign Obj')),
            ],
        ),
        migrations.CreateModel(
            name='JSONCharModel',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('json', jsonfield.fields.JSONCharField(max_length=100)),
                ('default_json', jsonfield.fields.JSONCharField(default={'check': 34}, max_length=100)),
            ],
        ),
        migrations.CreateModel(
            name='JSONModel',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('json', jsonfield.fields.JSONField()),
                ('default_json', jsonfield.fields.JSONField(default={'check': 12})),
                ('complex_default_json', jsonfield.fields.JSONField(default=[{'checkcheck': 1212}])),
                ('empty_default', jsonfield.fields.JSONField(blank=True, default={})),
            ],
        ),
        migrations.CreateModel(
            name='JSONModelCustomEncoders',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('json', jsonfield.fields.JSONField(dump_kwargs={'cls': tests.models.ComplexEncoder, 'indent': 4}, load_kwargs={'object_hook': tests.models.as_complex})),
            ],
        ),
        migrations.CreateModel(
            name='JSONNotRequiredModel',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('json', jsonfield.fields.JSONField(blank=True, null=True)),
            ],
        ),
        migrations.CreateModel(
            name='JSONRequiredModel',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('json', jsonfield.fields.JSONField()),
            ],
        ),
        migrations.CreateModel(
            name='MTIParentModel',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('parent_data', jsonfield.fields.JSONField()),
            ],
        ),
        migrations.CreateModel(
            name='OrderedJSONModel',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('json', jsonfield.fields.JSONField(load_kwargs={'object_pairs_hook': collections.OrderedDict})),
            ],
        ),
        migrations.CreateModel(
            name='MTIChildModel',
            fields=[
                ('mtiparentmodel_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='tests.MTIParentModel')),
                ('child_data', jsonfield.fields.JSONField()),
            ],
            bases=('tests.mtiparentmodel',),
        ),
        migrations.CreateModel(
            name='RemoteJSONModel',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('foreign', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='tests.JSONModel')),
            ],
        ),
        migrations.CreateModel(
            name='JSONModelWithForeignKey',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('json', jsonfield.fields.JSONField(null=True)),
                ('object_id', models.PositiveIntegerField(blank=True, db_index=True, null=True)),
                ('content_type', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='contenttypes.ContentType')),
            ],
        ),
    ]
