Esempio n. 1
0
class Migration(migrations.Migration):

    initial = True

    dependencies = []

    operations = [
        migrations.CreateModel(
            name='Movies',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('plot', models.CharField(max_length=1000)),
                ('genres',
                 djongo.models.fields.ArrayModelField(
                     model_container=catalog.models.Genre)),
                ('runtime', models.PositiveIntegerField()),
                ('cast',
                 djongo.models.fields.ArrayModelField(
                     model_container=catalog.models.Cast)),
                ('poster', models.CharField(max_length=1000, null=True)),
                ('title', models.CharField(max_length=1000)),
                ('fullplot', models.CharField(max_length=1000)),
                ('countries',
                 djongo.models.fields.ArrayModelField(
                     model_container=catalog.models.Country)),
                ('released', models.DateField()),
                ('languages',
                 djongo.models.fields.ArrayModelField(
                     model_container=catalog.models.Language)),
                ('directors',
                 djongo.models.fields.ArrayModelField(
                     model_container=catalog.models.Director)),
                ('writers',
                 djongo.models.fields.ArrayModelField(
                     model_container=catalog.models.Writers)),
                ('year', models.PositiveIntegerField()),
                ('imdb',
                 djongo.models.fields.EmbeddedModelField(
                     model_container=catalog.models.Imdb, null=True)),
                ('tomatoes',
                 djongo.models.fields.EmbeddedModelField(
                     model_container=catalog.models.Tomatoes, null=True)),
                ('Douban',
                 djongo.models.fields.EmbeddedModelField(
                     model_container=catalog.models.DouBan, null=True)),
            ],
        ),
        migrations.CreateModel(
            name='Users',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('name', models.CharField(max_length=128)),
                ('email', models.EmailField(max_length=254, unique=True)),
                ('password', models.CharField(max_length=256)),
            ],
        ),
        migrations.CreateModel(
            name='Ratings',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('date', models.DateField(auto_now_add=True)),
                ('rating',
                 models.IntegerField(
                     choices=[(0, '0'), (1,
                                         '1'), (2,
                                                '2'), (3,
                                                       '3'), (4,
                                                              '4'), (5,
                                                                     '5')])),
                ('movie_id',
                 djongo.models.fields.ArrayReferenceField(
                     on_delete=django.db.models.deletion.CASCADE,
                     to='catalog.Movies')),
                ('user_id',
                 djongo.models.fields.ArrayReferenceField(
                     on_delete=django.db.models.deletion.CASCADE,
                     to='catalog.Users')),
            ],
            options={
                'ordering': ['-date'],
            },
        ),
    ]
Esempio n. 2
0
class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('auth', '0009_alter_user_last_name_max_length'),
    ]

    operations = [
        migrations.CreateModel(
            name='User',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('password', models.CharField(max_length=128, verbose_name='password')),
                ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')),
                ('is_superuser', models.BooleanField(default=False, help_text='Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')),
                ('is_staff', models.BooleanField(default=False, help_text='Designates whether the user can log into this admin site.', verbose_name='staff status')),
                ('is_active', models.BooleanField(default=True, help_text='Designates whether this user should be treated as active. Unselect this instead of deleting accounts.', verbose_name='active')),
                ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')),
                ('email', models.EmailField(max_length=254, unique=True, verbose_name='email address')),
                ('bool_is_author', models.BooleanField(default=False, help_text='Designates whether user is an author', verbose_name='Author')),
                ('bool_is_editor', models.BooleanField(default=False, help_text='Designates whether user is an editor', verbose_name='Editor')),
                ('bool_is_executive_editor', models.BooleanField(default=False, help_text='Designates whether user is an executive editor', verbose_name='Executive editor')),
                ('first_name', models.CharField(max_length=30, verbose_name='first name')),
                ('last_name', models.CharField(max_length=30, verbose_name='last name')),
                ('bio', models.TextField(blank=True)),
                ('profile_pic', models.ImageField(blank=True, default='default_profile_pic.jpg', upload_to='')),
            ],
            options={
                'verbose_name': 'user',
                'verbose_name_plural': 'users',
                'abstract': False,
            },
            managers=[
                ('objects', catalog.models.UserManager()),
            ],
        ),
        migrations.CreateModel(
            name='Article',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('title', models.CharField(max_length=100)),
                ('text', models.TextField(default='Start typing here...')),
                ('thumb', models.ImageField(blank=True, default='default.png', upload_to='')),
                ('pub_date', models.DateTimeField(auto_now_add=True)),
                ('layout', models.CharField(choices=[('LO1', 'Normal'), ('LO2', 'Two columns'), ('LO3', 'Picture in middle')], default='LO1', max_length=3)),
                ('is_published', models.BooleanField(default=False, help_text='Publish article')),
                ('is_reviewed', models.BooleanField(default=False, help_text='Review article')),
                ('last_edited', models.DateTimeField(auto_now=True)),
                ('assigned_proof_read', models.ManyToManyField(blank=True, limit_choices_to={'bool_is_editor': True}, related_name='proof_read', to=settings.AUTH_USER_MODEL)),
                ('author', models.ManyToManyField(blank=True, limit_choices_to={'bool_is_author': True}, related_name='author', to=settings.AUTH_USER_MODEL)),
            ],
            options={
                'ordering': ['-pub_date'],
            },
        ),
        migrations.CreateModel(
            name='ColorScheme',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('color', models.CharField(max_length=100)),
            ],
        ),
        migrations.CreateModel(
            name='Comment',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=100)),
                ('email', models.EmailField(max_length=254)),
                ('body', models.TextField()),
                ('created', models.DateTimeField(auto_now_add=True)),
                ('updated', models.DateTimeField(auto_now=True)),
                ('active', models.BooleanField(default=True)),
                ('post', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='comments', to='catalog.Article')),
            ],
            options={
                'ordering': ('created',),
            },
        ),
        migrations.CreateModel(
            name='Layout',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('layout', models.CharField(choices=[('layout_one_column.html', 'One column'), ('layout_articles_side_by_side.html', 'Two columns'), ('layout_big_article.html', 'Big two columns')], default='layout_one_column.html', max_length=33)),
            ],
        ),
        migrations.CreateModel(
            name='RateComment',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=100)),
                ('email', models.EmailField(max_length=254)),
                ('body', models.TextField()),
                ('created', models.DateTimeField(auto_now_add=True)),
                ('updated', models.DateTimeField(auto_now=True)),
                ('active', models.BooleanField(default=True)),
                ('rating', models.IntegerField(default=1, validators=[django.core.validators.MaxValueValidator(10), django.core.validators.MinValueValidator(1)], verbose_name='Rating 1-10')),
                ('post', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='ratecomments', to='catalog.Article')),
            ],
            options={
                'ordering': ('created',),
            },
        ),
        migrations.CreateModel(
            name='Request',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('body', models.TextField()),
                ('user', models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='Tag',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=20, unique=True)),
            ],
        ),
        migrations.AddField(
            model_name='article',
            name='tag',
            field=models.ManyToManyField(blank=True, related_name='article_tag', to='catalog.Tag'),
        ),
        migrations.AddField(
            model_name='user',
            name='favorites',
            field=models.ManyToManyField(blank=True, related_name='favorites', to='catalog.Article'),
        ),
        migrations.AddField(
            model_name='user',
            name='groups',
            field=models.ManyToManyField(blank=True, help_text='The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups'),
        ),
        migrations.AddField(
            model_name='user',
            name='subscribe_author',
            field=models.ManyToManyField(blank=True, to=settings.AUTH_USER_MODEL),
        ),
        migrations.AddField(
            model_name='user',
            name='subscribe_tag',
            field=models.ManyToManyField(blank=True, related_name='subscribe_tag', to='catalog.Tag'),
        ),
        migrations.AddField(
            model_name='user',
            name='user_permissions',
            field=models.ManyToManyField(blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions'),
        ),
    ]
Esempio n. 3
0
class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('auth', '0009_alter_user_last_name_max_length'),
    ]

    operations = [
        migrations.CreateModel(
            name='User',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('password',
                 models.CharField(max_length=128, verbose_name='password')),
                ('last_login',
                 models.DateTimeField(blank=True,
                                      null=True,
                                      verbose_name='last login')),
                ('is_superuser',
                 models.BooleanField(
                     default=False,
                     help_text=
                     'Designates that this user has all permissions without explicitly assigning them.',
                     verbose_name='superuser status')),
                ('username', models.CharField(max_length=100, unique=True)),
                ('email', models.EmailField(max_length=254, unique=True)),
                ('idnum', models.IntegerField(null=True, unique=True)),
                ('firstname', models.CharField(max_length=100)),
                ('lastname', models.CharField(max_length=100)),
                ('timestamp', models.DateTimeField(auto_now_add=True)),
                ('is_manager', models.BooleanField(null=True)),
                ('is_administrator', models.BooleanField(null=True)),
                ('groups',
                 models.ManyToManyField(
                     blank=True,
                     help_text=
                     'The groups this user belongs to. A user will get all permissions granted to each of their groups.',
                     related_name='user_set',
                     related_query_name='user',
                     to='auth.Group',
                     verbose_name='groups')),
                ('user_permissions',
                 models.ManyToManyField(
                     blank=True,
                     help_text='Specific permissions for this user.',
                     related_name='user_set',
                     related_query_name='user',
                     to='auth.Permission',
                     verbose_name='user permissions')),
            ],
            options={
                'verbose_name': 'user',
                'verbose_name_plural': 'users',
            },
            managers=[
                ('objects', catalog.models.UserManager()),
            ],
        ),
        migrations.CreateModel(
            name='Book',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('title', models.CharField(max_length=200)),
                ('author', models.TextField(max_length=200)),
                ('publisher', models.CharField(max_length=200)),
                ('publication_year', models.IntegerField()),
                ('isbn',
                 models.CharField(
                     help_text=
                     '13 Character <a href="https://www.isbn-international.org/content/what-isbn">ISBN number</a>',
                     max_length=13,
                     verbose_name='ISBN')),
                ('reserved', models.BooleanField(default=False)),
            ],
        ),
        migrations.CreateModel(
            name='Review',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('content', models.TextField()),
            ],
        ),
    ]
Esempio n. 4
0
class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('auth', '0011_update_proxy_permissions'),
    ]

    operations = [
        migrations.CreateModel(
            name='CustomUser',
            fields=[
                ('password',
                 models.CharField(max_length=128, verbose_name='password')),
                ('last_login',
                 models.DateTimeField(blank=True,
                                      null=True,
                                      verbose_name='last login')),
                ('is_superuser',
                 models.BooleanField(
                     default=False,
                     help_text=
                     'Designates that this user has all permissions without explicitly assigning them.',
                     verbose_name='superuser status')),
                ('id',
                 models.UUIDField(default=uuid.uuid4,
                                  editable=False,
                                  primary_key=True,
                                  serialize=False)),
                ('email',
                 models.EmailField(max_length=255,
                                   unique=True,
                                   verbose_name='Email')),
                ('is_staff',
                 models.BooleanField(default=False, verbose_name='Is staff')),
                ('is_active',
                 models.BooleanField(default=True, verbose_name='Is active')),
                ('joined_at',
                 models.DateTimeField(default=django.utils.timezone.now,
                                      verbose_name='Joined at')),
            ],
            options={
                'verbose_name': 'User',
                'verbose_name_plural': 'Users',
            },
        ),
        migrations.CreateModel(
            name='Brewing',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('temperature',
                 models.PositiveSmallIntegerField(
                     blank=True,
                     default=0,
                     null=True,
                     validators=[
                         django.core.validators.MaxValueValidator(100)
                     ])),
                ('weight',
                 models.FloatField(
                     blank=True,
                     default=0,
                     null=True,
                     validators=[django.core.validators.MinValueValidator(0)
                                 ])),
                ('initial',
                 models.DurationField(blank=True,
                                      default=datetime.timedelta(0),
                                      null=True)),
                ('increments',
                 models.DurationField(blank=True,
                                      default=datetime.timedelta(0),
                                      null=True)),
            ],
        ),
        migrations.CreateModel(
            name='Category',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('name',
                 models.CharField(choices=[('WHITE', 'WHITE'),
                                           ('YELLOW', 'YELLOW'),
                                           ('GREEN', 'GREEN'),
                                           ('OOLONG', 'OOLONG'),
                                           ('BLACK', 'BLACK'),
                                           ('FERMENTED', 'FERMENTED'),
                                           ('HERBAL', 'HERBAL'),
                                           ('SCENTED', 'SCENTED'),
                                           ('OTHER', 'OTHER')],
                                  max_length=20)),
                ('description', models.TextField(blank=True)),
                ('description_source',
                 models.CharField(blank=True, max_length=100)),
                ('gongfu_brewing',
                 models.ForeignKey(
                     blank=True,
                     null=True,
                     on_delete=django.db.models.deletion.SET_NULL,
                     related_name='+',
                     to='catalog.Brewing')),
                ('western_brewing',
                 models.ForeignKey(
                     blank=True,
                     null=True,
                     on_delete=django.db.models.deletion.SET_NULL,
                     related_name='+',
                     to='catalog.Brewing')),
            ],
        ),
        migrations.CreateModel(
            name='Origin',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('is_public', models.BooleanField(default=False)),
                ('country', models.CharField(max_length=30)),
                ('region', models.CharField(blank=True, max_length=50)),
                ('locality', models.CharField(blank=True, max_length=50)),
                ('latitude', models.FloatField(blank=True, null=True)),
                ('longitude', models.FloatField(blank=True, null=True)),
                ('user',
                 models.ForeignKey(on_delete=django.db.models.deletion.CASCADE,
                                   to=settings.AUTH_USER_MODEL)),
            ],
            options={
                'ordering': ['country', 'region', 'locality'],
            },
        ),
        migrations.CreateModel(
            name='Subcategory',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('is_public', models.BooleanField(default=False)),
                ('name', models.CharField(max_length=50)),
                ('translated_name', models.CharField(blank=True,
                                                     max_length=50)),
                ('description', models.TextField(blank=True)),
                ('description_source',
                 models.CharField(blank=True, max_length=100)),
                ('category',
                 models.ForeignKey(blank=True,
                                   null=True,
                                   on_delete=django.db.models.deletion.CASCADE,
                                   to='catalog.Category')),
                ('gongfu_brewing',
                 models.ForeignKey(
                     blank=True,
                     null=True,
                     on_delete=django.db.models.deletion.SET_NULL,
                     related_name='+',
                     to='catalog.Brewing')),
                ('origin',
                 models.ForeignKey(
                     blank=True,
                     null=True,
                     on_delete=django.db.models.deletion.SET_NULL,
                     to='catalog.Origin')),
                ('user',
                 models.ForeignKey(on_delete=django.db.models.deletion.CASCADE,
                                   to=settings.AUTH_USER_MODEL)),
                ('western_brewing',
                 models.ForeignKey(
                     blank=True,
                     null=True,
                     on_delete=django.db.models.deletion.SET_NULL,
                     related_name='+',
                     to='catalog.Brewing')),
            ],
        ),
        migrations.CreateModel(
            name='Vendor',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('is_public', models.BooleanField(default=False)),
                ('name', models.CharField(max_length=50)),
                ('website', models.CharField(blank=True, max_length=50)),
                ('popularity',
                 models.PositiveSmallIntegerField(
                     blank=True,
                     default=5,
                     null=True,
                     validators=[django.core.validators.MaxValueValidator(10)
                                 ])),
                ('origin',
                 models.ForeignKey(
                     blank=True,
                     null=True,
                     on_delete=django.db.models.deletion.SET_NULL,
                     to='catalog.Origin')),
                ('user',
                 models.ForeignKey(on_delete=django.db.models.deletion.CASCADE,
                                   to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='VendorTrademark',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('name', models.CharField(max_length=50)),
                ('vendor',
                 models.ForeignKey(on_delete=django.db.models.deletion.CASCADE,
                                   to='catalog.Vendor')),
            ],
        ),
        migrations.CreateModel(
            name='Tea',
            fields=[
                ('id',
                 models.UUIDField(default=uuid.uuid4,
                                  editable=False,
                                  primary_key=True,
                                  serialize=False)),
                ('is_archived', models.BooleanField(default=False)),
                ('name', models.CharField(max_length=50)),
                ('image',
                 models.ImageField(blank=True,
                                   null=True,
                                   upload_to=catalog.models.get_upload_path)),
                ('year',
                 models.SmallIntegerField(
                     blank=True,
                     null=True,
                     validators=[
                         django.core.validators.MinValueValidator(1900),
                         django.core.validators.MaxValueValidator(2100)
                     ])),
                ('gongfu_preferred', models.BooleanField(default=True)),
                ('created_on', models.DateTimeField(auto_now_add=True)),
                ('last_consumed_on', models.DateTimeField(auto_now=True)),
                ('price',
                 models.FloatField(
                     blank=True,
                     default=0,
                     null=True,
                     validators=[django.core.validators.MinValueValidator(0)
                                 ])),
                ('weight_left',
                 models.FloatField(
                     blank=True,
                     default=0,
                     null=True,
                     validators=[django.core.validators.MinValueValidator(0)
                                 ])),
                ('weight_consumed',
                 models.FloatField(
                     blank=True,
                     default=0,
                     null=True,
                     validators=[django.core.validators.MinValueValidator(0)
                                 ])),
                ('rating',
                 models.SmallIntegerField(
                     blank=True,
                     default=0,
                     null=True,
                     validators=[
                         django.core.validators.MinValueValidator(0),
                         django.core.validators.MaxValueValidator(10)
                     ])),
                ('notes',
                 models.TextField(blank=True, max_length=10000, null=True)),
                ('category',
                 models.ForeignKey(blank=True,
                                   null=True,
                                   on_delete=django.db.models.deletion.CASCADE,
                                   to='catalog.Category')),
                ('gongfu_brewing',
                 models.ForeignKey(
                     blank=True,
                     null=True,
                     on_delete=django.db.models.deletion.SET_NULL,
                     related_name='+',
                     to='catalog.Brewing')),
                ('origin',
                 models.ForeignKey(
                     blank=True,
                     null=True,
                     on_delete=django.db.models.deletion.SET_NULL,
                     to='catalog.Origin')),
                ('subcategory',
                 models.ForeignKey(
                     blank=True,
                     null=True,
                     on_delete=django.db.models.deletion.SET_NULL,
                     to='catalog.Subcategory')),
                ('user',
                 models.ForeignKey(on_delete=django.db.models.deletion.CASCADE,
                                   to=settings.AUTH_USER_MODEL)),
                ('vendor',
                 models.ForeignKey(
                     blank=True,
                     null=True,
                     on_delete=django.db.models.deletion.SET_NULL,
                     to='catalog.Vendor')),
                ('western_brewing',
                 models.ForeignKey(
                     blank=True,
                     null=True,
                     on_delete=django.db.models.deletion.SET_NULL,
                     related_name='+',
                     to='catalog.Brewing')),
            ],
        ),
        migrations.CreateModel(
            name='SubcategoryName',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('name', models.CharField(max_length=50)),
                ('subcategory',
                 models.ForeignKey(on_delete=django.db.models.deletion.CASCADE,
                                   to='catalog.Subcategory')),
            ],
        ),
        migrations.CreateModel(
            name='CategoryName',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('name', models.CharField(max_length=50)),
                ('category',
                 models.ForeignKey(on_delete=django.db.models.deletion.CASCADE,
                                   to='catalog.Category')),
            ],
        ),
        migrations.AddConstraint(
            model_name='brewing',
            constraint=models.UniqueConstraint(fields=('temperature', 'weight',
                                                       'initial',
                                                       'increments'),
                                               name='unique_brewing'),
        ),
        migrations.AddField(
            model_name='customuser',
            name='groups',
            field=models.ManyToManyField(
                blank=True,
                help_text=
                'The groups this user belongs to. A user will get all permissions granted to each of their groups.',
                related_name='user_set',
                related_query_name='user',
                to='auth.Group',
                verbose_name='groups'),
        ),
        migrations.AddField(
            model_name='customuser',
            name='user_permissions',
            field=models.ManyToManyField(
                blank=True,
                help_text='Specific permissions for this user.',
                related_name='user_set',
                related_query_name='user',
                to='auth.Permission',
                verbose_name='user permissions'),
        ),
        migrations.AddConstraint(
            model_name='origin',
            constraint=models.UniqueConstraint(fields=('user', 'country',
                                                       'region', 'locality'),
                                               name='unique_origin'),
        ),
        migrations.AddConstraint(
            model_name='origin',
            constraint=models.UniqueConstraint(
                condition=models.Q(locality=None),
                fields=('user', 'country', 'region'),
                name='unique_region_origin'),
        ),
        migrations.AddConstraint(
            model_name='origin',
            constraint=models.UniqueConstraint(condition=models.Q(region=None),
                                               fields=('user', 'country',
                                                       'locality'),
                                               name='unique_locality_origin'),
        ),
    ]
class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('auth', '0009_alter_user_last_name_max_length'),
    ]

    operations = [
        migrations.CreateModel(
            name='User',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('password',
                 models.CharField(max_length=128, verbose_name='password')),
                ('last_login',
                 models.DateTimeField(blank=True,
                                      null=True,
                                      verbose_name='last login')),
                ('is_superuser',
                 models.BooleanField(
                     default=False,
                     help_text=
                     'Designates that this user has all permissions without explicitly assigning them.',
                     verbose_name='superuser status')),
                ('first_name',
                 models.CharField(blank=True,
                                  max_length=30,
                                  verbose_name='first name')),
                ('last_name',
                 models.CharField(blank=True,
                                  max_length=150,
                                  verbose_name='last name')),
                ('is_staff',
                 models.BooleanField(
                     default=False,
                     help_text=
                     'Designates whether the user can log into this admin site.',
                     verbose_name='staff status')),
                ('is_active',
                 models.BooleanField(
                     default=True,
                     help_text=
                     'Designates whether this user should be treated as active. Unselect this instead of deleting accounts.',
                     verbose_name='active')),
                ('date_joined',
                 models.DateTimeField(default=django.utils.timezone.now,
                                      verbose_name='date joined')),
                ('email',
                 models.EmailField(max_length=254,
                                   unique=True,
                                   verbose_name='email address')),
                ('groups',
                 models.ManyToManyField(
                     blank=True,
                     help_text=
                     'The groups this user belongs to. A user will get all permissions granted to each of their groups.',
                     related_name='user_set',
                     related_query_name='user',
                     to='auth.Group',
                     verbose_name='groups')),
                ('user_permissions',
                 models.ManyToManyField(
                     blank=True,
                     help_text='Specific permissions for this user.',
                     related_name='user_set',
                     related_query_name='user',
                     to='auth.Permission',
                     verbose_name='user permissions')),
            ],
            options={
                'verbose_name': 'user',
                'verbose_name_plural': 'users',
                'abstract': False,
            },
            managers=[
                ('objects', catalog.models.UserManager()),
            ],
        ),
        migrations.CreateModel(
            name='service_project',
            fields=[
                ('project_ID',
                 models.IntegerField(primary_key=True, serialize=False)),
                ('project_title',
                 models.CharField(help_text='Enter field documentation',
                                  max_length=15)),
                ('project_duration',
                 models.CharField(help_text='Enter field documentation',
                                  max_length=15)),
                ('project_location',
                 models.CharField(help_text='Enter field documentation',
                                  max_length=15)),
                ('project_leader',
                 models.CharField(help_text='Enter field documentation',
                                  max_length=15)),
                ('project_date',
                 models.CharField(help_text='Enter field documentation',
                                  max_length=15)),
                ('members_needed', models.IntegerField(default=4)),
                ('wait_list', models.IntegerField(default=2)),
            ],
            options={
                'db_table': 'catalog_service_project',
            },
        ),
        migrations.CreateModel(
            name='work_order',
            fields=[
                ('work_order_id',
                 models.IntegerField(primary_key=True, serialize=False)),
            ],
        ),
    ]