# Generated by Django 4.1.5 on 2023-03-14 11:19 from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('spec', '0030_auto_20211105_1029'), ] operations = [ migrations.AddField( model_name='xmlschema', name='is_json', field=models.BooleanField(default=False), ), migrations.AlterField( model_name='datatype', name='union_types', field=models.ManyToManyField(blank=True, help_text='If this data type is a union of multiple other types, list them here.', related_name='+', to='spec.datatype'), ), migrations.CreateModel( name='JSONObject', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('name', models.CharField(max_length=80)), ('slug', models.CharField(max_length=80)), ('object_type', models.SmallIntegerField(choices=[(1, 'Dictionary'), (2, 'Array'), (3, 'String'), (4, 'Number'), (5, 'Boolean'), (6, 'Literal string')])), ('schema', models.ForeignKey(default=1, on_delete=django.db.models.deletion.CASCADE, to='spec.xmlschema')), ], options={ 'verbose_name': 'JSON object', 'verbose_name_plural': 'JSON objects', 'db_table': 'json_objects', 'unique_together': {('schema', 'slug')}, }, ), migrations.CreateModel( name='ExampleDocumentObject', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('example', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='spec.exampledocument')), ('json_object', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, to='spec.jsonobject')), ], options={ 'db_table': 'example_objects', }, ), migrations.CreateModel( name='JSONObjectRelationship', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('child_key', models.CharField(max_length=80)), ('is_required', models.BooleanField(default=False)), ('child', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='child_rel', to='spec.jsonobject')), ('parent', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='parent_rel', to='spec.jsonobject')), ], options={ 'verbose_name': 'JSON object relationship', 'verbose_name_plural': 'JSON object relationships', 'db_table': 'json_object_relationships', 'unique_together': {('parent', 'child_key')}, }, ), ]