Example #1
0
class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='Arching_Tag',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=50)),
            ],
        ),
        migrations.CreateModel(
            name='Quote',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('words', models.CharField(max_length=250)),
                ('author', models.CharField(max_length=100)),
            ],
        ),
        migrations.CreateModel(
            name='Tag_Type',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=50)),
            ],
        ),
        migrations.CreateModel(
            name='Tag',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=50)),
                ('tag_type', models.ManyToManyField(to='core.Tag_Type')),
            ],
        ),
        migrations.CreateModel(
            name='Organization',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=200)),
                ('street', models.CharField(max_length=300)),
                ('city', models.CharField(max_length=100)),
                ('zipcode', models.CharField(max_length=5)),
                ('description', models.CharField(max_length=1000)),
                ('website', models.URLField(max_length=500)),
                ('phone_number', models.CharField(max_length=12)),
                ('email', models.EmailField(max_length=254)),
                ('org_image', models.ImageField(blank=True, null=True, upload_to=core.models.get_image_path)),
                ('contact_phone_number', models.CharField(max_length=12)),
                ('contact_email', models.EmailField(max_length=254)),
                ('contact_image', models.ImageField(blank=True, null=True, upload_to=core.models.get_image_path)),
                ('overall_tags', models.ManyToManyField(to='core.Arching_Tag')),
                ('tags', models.ManyToManyField(to='core.Tag')),
            ],
        ),
    ]
Example #2
0
class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('auth', '0007_alter_validators_add_error_messages'),
    ]

    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')),
                ('email', models.EmailField(max_length=254, unique=True, verbose_name='Email')),
                ('first_name', models.CharField(blank=True, max_length=30, null=True, verbose_name='Имя')),
                ('last_name', models.CharField(blank=True, max_length=60, null=True, verbose_name='Фамилия')),
                ('avatar', models.ImageField(blank=True, null=True, upload_to='avatar', verbose_name='Аватар')),
                ('is_staff', models.BooleanField(default=False, verbose_name='Персонал?')),
                ('is_active', models.BooleanField(default=False, verbose_name='Активен?')),
                ('date_joined', models.DateTimeField(auto_now_add=True, verbose_name='Дата регистрации')),
                ('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_plural': 'пользователи',
                'verbose_name': 'Пользователь',
            },
            managers=[
                ('objects', core.models.UserManager()),
            ],
        ),
    ]
Example #3
0
class Migration(migrations.Migration):

    initial = True

    dependencies = []

    operations = [
        migrations.CreateModel(
            name='Candidate',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('name', models.CharField(max_length=50)),
                ('phone_number', models.CharField(blank=True, max_length=13)),
                ('email', models.EmailField(max_length=150)),
                ('proof',
                 models.FileField(upload_to=core.models.user_directory_path)),
                ('org',
                 models.CharField(choices=[('SELF', 'Self'),
                                           ('GROUP', 'Group'),
                                           ('CORPORATE', 'Corporate'),
                                           ('OTHERS', 'Others')],
                                  default='SELF',
                                  max_length=20)),
                ('ticket', models.IntegerField(default=1)),
                ('token', models.IntegerField()),
                ('created_at', models.DateTimeField(auto_now_add=True)),
            ],
        ),
    ]
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')),
                ('email', models.EmailField(max_length=255, unique=True, verbose_name='Email Address')),
                ('first_name', models.CharField(max_length=255)),
                ('last_name', models.CharField(max_length=255)),
                ('is_active', models.BooleanField(default=True)),
                ('is_staff', models.BooleanField(default=False)),
                ('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={
                'abstract': False,
            },
            managers=[
                ('objects', core.models.UserManager()),
            ],
        ),
    ]
class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('auth', '0015_auto_20200804_1432'),
    ]

    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')),
                ('email', models.EmailField(max_length=254, unique=True, verbose_name='email address')),
                ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')),
                ('last_name', models.CharField(blank=True, max_length=30, verbose_name='last name')),
                ('date_joined', models.DateTimeField(auto_now_add=True, verbose_name='date joined')),
                ('is_active', models.BooleanField(default=True, verbose_name='active')),
                ('avatar', models.ImageField(blank=True, null=True, upload_to='avatars/')),
                ('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', core.models.UserManager()),
            ],
        ),
    ]
Example #6
0
class Migration(migrations.Migration):

    dependencies = [
        ('core', '0002_auto_20170302_2045'),
    ]

    operations = [
        migrations.CreateModel(
            name='RegistrationToken',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('modified', models.DateTimeField(auto_now=True)),
                ('created', models.DateTimeField(auto_now_add=True)),
                ('email', models.EmailField(max_length=254, unique=True)),
                ('token',
                 models.CharField(
                     default=core.models.RegistrationToken.generate_token,
                     max_length=64)),
            ],
            options={
                'abstract': False,
            },
        ),
    ]
Example #7
0
class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='RootCrt',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('key', models.FileField(upload_to=core.models.directory_path_root_key)),
                ('crt', models.FileField(upload_to=core.models.directory_path_root_crt)),
                ('country', models.CharField(max_length=2)),
                ('state', models.CharField(max_length=32)),
                ('location', models.CharField(max_length=128)),
                ('organization', models.CharField(max_length=256)),
                ('organizational_unit_name', models.CharField(blank=True, max_length=256, null=True)),
                ('email', models.EmailField(blank=True, max_length=128, null=True)),
            ],
        ),
        migrations.CreateModel(
            name='SiteCrt',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('key', models.FileField(upload_to=core.models.directory_path_key)),
                ('crt', models.FileField(upload_to=core.models.directory_path_crt)),
                ('cn', models.CharField(max_length=256, unique=True)),
                ('date_start', models.DateTimeField(auto_now_add=True)),
                ('date_end', models.DateTimeField()),
            ],
        ),
    ]
Example #8
0
class Migration(migrations.Migration):

    initial = True

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

    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')),
                ('email', models.EmailField(max_length=50, unique=True)),
                ('displayName', models.CharField(max_length=20, unique=True)),
                ('avatar', models.ImageField(blank=True, null=True, upload_to=core.models.upload_path)),
                ('about', models.CharField(blank=True, max_length=255)),
                ('is_active', models.BooleanField(default=True)),
                ('is_staff', models.BooleanField(default=False)),
                ('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={
                'abstract': False,
            },
        ),
        migrations.CreateModel(
            name='Post',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('content', models.CharField(max_length=140)),
                ('postFrom', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='postFrom', to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='Message',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('message', models.CharField(max_length=140)),
                ('receiver', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='receiver', to=settings.AUTH_USER_MODEL)),
                ('sender', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='sender', to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='FriendRequest',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('approved', models.BooleanField(default=False)),
                ('askFrom', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='askFrom', to=settings.AUTH_USER_MODEL)),
                ('askTo', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='askTo', to=settings.AUTH_USER_MODEL)),
            ],
            options={
                'unique_together': {('askFrom', 'askTo')},
            },
        ),
    ]
class Migration(migrations.Migration):

    initial = True

    dependencies = []

    operations = [
        migrations.CreateModel(
            name='Users',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('first_name', models.CharField(max_length=100)),
                ('last_name', models.CharField(max_length=100)),
                ('middle_name', models.CharField(max_length=100)),
                ('phone_number', models.CharField(max_length=15)),
                ('address', models.CharField(max_length=100)),
                ('state', models.CharField(max_length=2)),
                ('zip_code', models.CharField(max_length=12)),
                ('city', models.CharField(max_length=100)),
                ('email', models.EmailField(max_length=254)),
                ('admin', models.BooleanField(default=False)),
            ],
        ),
        migrations.CreateModel(
            name='Quotes',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('date_submitted',
                 models.DateTimeField(default=datetime.datetime(2020,
                                                                12,
                                                                17,
                                                                21,
                                                                39,
                                                                47,
                                                                203418,
                                                                tzinfo=utc),
                                      editable=False)),
                ('start_date_requested',
                 models.DateTimeField(validators=[core.models.validate_time])),
                ('end_date_requested',
                 models.DateTimeField(validators=[core.models.validate_time])),
                ('quoted_price', models.CharField(max_length=50)),
                ('final_cost', models.CharField(max_length=50)),
                ('completed', models.BooleanField(default=False)),
                ('accepted', models.BooleanField(default=False)),
                ('user',
                 models.ForeignKey(on_delete=django.db.models.deletion.CASCADE,
                                   to='core.users')),
            ],
        ),
    ]
Example #10
0
class Migration(migrations.Migration):

    initial = True

    dependencies = []

    operations = [
        migrations.CreateModel(
            name='Landlord',
            fields=[
                ('id',
                 models.CharField(
                     default=core.models.get_hash_id,
                     editable=False,
                     max_length=16,
                     primary_key=True,
                     serialize=False,
                     validators=[core.validators.validate_hash_id])),
                ('first_name', models.CharField(blank=True, max_length=30)),
                ('last_name', models.CharField(blank=True, max_length=30)),
                ('email', models.EmailField(max_length=254, unique=True)),
            ],
            options={
                'abstract': False,
            },
        ),
        migrations.CreateModel(
            name='Tenant',
            fields=[
                ('id',
                 models.CharField(
                     default=core.models.get_hash_id,
                     editable=False,
                     max_length=16,
                     primary_key=True,
                     serialize=False,
                     validators=[core.validators.validate_hash_id])),
                ('first_name', models.CharField(blank=True, max_length=30)),
                ('last_name', models.CharField(blank=True, max_length=30)),
                ('email', models.EmailField(max_length=254, unique=True)),
            ],
            options={
                'abstract': False,
            },
        ),
    ]
class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('auth', '0012_alter_user_first_name_max_length'),
    ]

    operations = [
        migrations.CreateModel(
            name='User',
            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)),
                ('name', models.CharField(max_length=255)),
                ('is_active', models.BooleanField(default=True)),
                ('is_staff', models.BooleanField(default=False)),
                ('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={
                'abstract': False,
            },
        ),
        migrations.CreateModel(
            name='Ingredient',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=255)),
                ('user', models.ForeignKey(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=255)),
                ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='Recipe',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('title', models.CharField(max_length=255)),
                ('time_minutes', models.IntegerField()),
                ('price', models.DecimalField(decimal_places=2, max_digits=5)),
                ('link', models.CharField(blank=True, max_length=255)),
                ('image', models.ImageField(null=True, upload_to=core.models.recipe_image_file_path)),
                ('ingredients', models.ManyToManyField(to='core.Ingredient')),
                ('tags', models.ManyToManyField(to='core.Tag')),
                ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
        ),
    ]
Example #12
0
class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='Group',
            fields=[
                ('id', models.BigIntegerField(primary_key=True, serialize=False)),
                ('name', models.CharField(max_length=50)),
                ('slug', models.SlugField(unique=True, validators=[core.models.slug_validator])),
                ('description', models.CharField(max_length=200)),
            ],
            options={
                'db_table': 'groups',
            },
        ),
        migrations.CreateModel(
            name='User',
            fields=[
                ('id', models.BigIntegerField(primary_key=True, serialize=False)),
                ('username', models.SlugField(max_length=30, unique=True, validators=[core.models.slug_validator])),
                ('email', models.EmailField(max_length=200, unique=True)),
                ('password', models.CharField(max_length=128)),
                ('last_login', models.IntegerField(default=None, null=True)),
                ('created', models.IntegerField(default=time.time)),
                ('name', models.CharField(max_length=50)),
                ('image', models.ImageField(default='', upload_to=core.models.create_filename)),
                ('password_reset_token', models.CharField(default='', max_length=128)),
                ('password_reset_token_expiry', models.IntegerField(default=0)),
            ],
            options={
                'db_table': 'users',
                'ordering': ['created'],
            },
        ),
        migrations.CreateModel(
            name='UserGroupLink',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('permission', models.IntegerField(choices=[[1, 'invited'], [2, 'member'], [3, 'admin']], default=1)),
                ('group', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='core.group')),
                ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='core.user')),
            ],
            options={
                'db_table': 'user_group_links',
            },
        ),
        migrations.AddField(
            model_name='group',
            name='users',
            field=models.ManyToManyField(related_name='groups', through='core.UserGroupLink', to='core.User'),
        ),
    ]
Example #13
0
class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='Profile',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=100, verbose_name='Nombre')),
                ('last_name', models.CharField(max_length=200, verbose_name='Apellidos')),
                ('image', models.ImageField(upload_to=core.models.custom_profile_upload_to, verbose_name='Imagen')),
                ('profession', models.CharField(blank=True, max_length=100, verbose_name='Profesión')),
                ('email', models.EmailField(blank=True, max_length=254, null=True, verbose_name='Email')),
                ('address', models.CharField(blank=True, max_length=200, null=True, verbose_name='Dirección')),
                ('mobile', models.CharField(blank=True, max_length=15, null=True, verbose_name='Celular')),
                ('city', models.CharField(blank=True, max_length=50, null=True, verbose_name='Ciudad')),
                ('biography', models.TextField(verbose_name='Biografía')),
                ('created', models.DateTimeField(auto_now_add=True, verbose_name='Fecha de creación')),
                ('updated', models.DateTimeField(auto_now=True, verbose_name='Fecha de edición')),
                ('isPublished', models.BooleanField(default=False, unique=True, verbose_name='Publicar')),
            ],
            options={
                'verbose_name': 'Perfil',
                'verbose_name_plural': 'Perfiles',
                'ordering': ['-created'],
            },
        ),
        migrations.CreateModel(
            name='Skill',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('skill_name', models.CharField(max_length=100, verbose_name='Habilidad')),
                ('image', models.ImageField(upload_to=core.models.custom_skill_upload_to, verbose_name='Logo')),
                ('color', colorfield.fields.ColorField(default='#2c98f0', max_length=18, verbose_name='Color del logo')),
                ('created', models.DateTimeField(auto_now_add=True, verbose_name='Fecha de creación')),
                ('updated', models.DateTimeField(auto_now=True, verbose_name='Fecha de edición')),
            ],
            options={
                'verbose_name': 'Habilidad',
                'verbose_name_plural': 'Habilidades',
                'ordering': ['-created'],
            },
        ),
        migrations.AddField(
            model_name='profile',
            name='skills',
            field=models.ManyToManyField(related_name='get_profiles', to='core.Skill', verbose_name='Habilidades'),
        ),
    ]
Example #14
0
class Migration(migrations.Migration):

    initial = True

    dependencies = []

    operations = [
        migrations.CreateModel(
            name='HintNotification',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('notified', models.BooleanField(default=False)),
                ('index_in_contract', models.PositiveIntegerField()),
            ],
        ),
        migrations.CreateModel(
            name='RequestForFind',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('identifier', models.CharField(max_length=130)),
                ('first_name', models.CharField(max_length=130)),
                ('last_name', models.CharField(max_length=130)),
                ('photo',
                 models.ImageField(upload_to=core.models.images_upload_to)),
                ('description', models.TextField(max_length=1024)),
                ('creator_address', models.CharField(max_length=300)),
                ('creator_email', models.EmailField(max_length=254)),
                ('contract_deployed_address',
                 models.CharField(max_length=300)),
                ('finished', models.BooleanField(default=False)),
            ],
            options={
                'verbose_name_plural': 'Requests for finds',
                'verbose_name': 'Request for find',
                'ordering': ['-id'],
            },
        ),
        migrations.AddField(
            model_name='hintnotification',
            name='find_request',
            field=models.ForeignKey(
                on_delete=django.db.models.deletion.PROTECT,
                to='core.RequestForFind'),
        ),
    ]
Example #15
0
class Migration(migrations.Migration):

    initial = True

    dependencies = []

    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')),
                ('username',
                 core.models.LowerCaseCharField(
                     db_index=True,
                     max_length=50,
                     unique=True,
                     validators=[
                         django.core.validators.RegexValidator(
                             b'^[0-9a-zA-Z]*$',
                             b'Only alphanumeric characters are allowed.'),
                         django.core.validators.RegexValidator(
                             b'^(.){5,}$',
                             b'A minimum of 5 characters are required.'),
                         django.core.validators.RegexValidator(
                             b'^[a-zA-Z]', b'Must start with a letter.')
                     ])),
                ('email', models.EmailField(max_length=254, unique=True)),
                ('date_joined', models.DateTimeField(auto_now_add=True)),
                ('first_name',
                 models.CharField(blank=True, default=b'', max_length=300)),
                ('last_name',
                 models.CharField(blank=True, default=b'', max_length=300)),
                ('ip_address', models.GenericIPAddressField(null=True)),
                ('is_staff', models.BooleanField(default=False)),
            ],
            options={
                'abstract': False,
            },
            managers=[
                ('objects', django.contrib.auth.models.UserManager()),
            ],
        ),
    ]
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')),
                ('is_valid', models.BooleanField(default=False, verbose_name='is valid')),
                ('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', core.models.UserManager()),
            ],
        ),
        migrations.CreateModel(
            name='ResetPassword',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('created_at', models.DateTimeField(auto_now_add=True, verbose_name='created at')),
                ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='+', to=settings.AUTH_USER_MODEL, verbose_name='user')),
            ],
        ),
        migrations.CreateModel(
            name='ValidationCode',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('code', models.UUIDField(default=uuid.uuid4, editable=False, verbose_name='validation code')),
                ('user', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, related_name='validation_code', to=settings.AUTH_USER_MODEL, verbose_name='user')),
            ],
        ),
    ]
Example #17
0
class Migration(migrations.Migration):

    initial = True

    dependencies = []

    operations = [
        migrations.CreateModel(
            name='LeanUser',
            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')),
                ('created',
                 models.DateTimeField(auto_now_add=True,
                                      verbose_name='Created')),
                ('modified',
                 models.DateTimeField(auto_now=True, verbose_name='Modified')),
                ('email', models.EmailField(max_length=80, unique=True)),
                ('profile_picture',
                 models.ImageField(blank=True,
                                   default='default/avatar-default.jpg',
                                   max_length=255,
                                   null=True,
                                   upload_to=core.models.photo_upload_to)),
                ('is_active', models.BooleanField(default=True)),
                ('is_admin', models.BooleanField(default=False)),
                ('first_name',
                 models.CharField(blank=True, max_length=80, null=True)),
                ('last_name',
                 models.CharField(blank=True, max_length=80, null=True)),
                ('phone_number', models.CharField(max_length=20, unique=True)),
                ('address',
                 models.CharField(blank=True,
                                  default='',
                                  max_length=300,
                                  null=True)),
            ],
            options={
                'verbose_name_plural': 'Lean Users',
                'db_table': 'users',
            },
        ),
    ]
Example #18
0
class Migration(migrations.Migration):

    initial = True

    dependencies = []

    operations = [
        migrations.CreateModel(
            name='MyUser',
            fields=[
                ('password',
                 models.CharField(max_length=128, verbose_name='password')),
                ('last_login',
                 models.DateTimeField(blank=True,
                                      null=True,
                                      verbose_name='last login')),
                ('id', models.BigAutoField(primary_key=True, serialize=False)),
                ('created', models.DateTimeField(auto_now_add=True)),
                ('modified', models.DateTimeField(auto_now_add=True)),
                ('pub_id',
                 core.models.AutoPubIDField(blank=True,
                                            editable=False,
                                            max_length=20,
                                            unique=True,
                                            verbose_name='public id')),
                ('email',
                 models.EmailField(max_length=50,
                                   unique=True,
                                   verbose_name='email address')),
                ('phone', models.CharField(max_length=64,
                                           verbose_name='phone')),
                ('name',
                 models.CharField(max_length=128,
                                  verbose_name='name of user')),
                ('sign_pub_key',
                 models.CharField(max_length=255,
                                  unique=True,
                                  verbose_name='verify key')),
                ('api_token',
                 models.CharField(max_length=255,
                                  null=True,
                                  unique=True,
                                  verbose_name='api token')),
            ],
            options={
                'verbose_name': 'my_user',
            },
        ),
    ]
Example #19
0
class Migration(migrations.Migration):

    initial = True

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

    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(error_messages={'unique': 'A user with that username already exists.'}, help_text='Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.', max_length=150, unique=True, validators=[django.contrib.auth.validators.UnicodeUsernameValidator()], verbose_name='username')),
                ('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')),
                ('email', models.EmailField(blank=True, max_length=254, verbose_name='email address')),
                ('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')),
                ('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', django.contrib.auth.models.UserManager()),
            ],
        ),
        migrations.CreateModel(
            name='SongModel',
            fields=[
                ('id', models.AutoField(primary_key=True, serialize=False)),
                ('song_file', models.FileField(blank=True, null=True, upload_to=core.models.upload_song_to)),
                ('song_title', models.CharField(max_length=300, null=True)),
                ('bpm', models.IntegerField(null=True)),
                ('key', models.CharField(max_length=2, null=True)),
                ('key_scale', models.CharField(max_length=5, null=True)),
                ('key_strength', models.FloatField(null=True)),
                ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
            ],
        ),
    ]
class Migration(migrations.Migration):

    dependencies = [("core", "0001_initial")]

    operations = [
        migrations.AlterModelManagers(name="user",
                                      managers=[("objects",
                                                 core.models.UserManager())]),
        migrations.AlterField(
            model_name="user",
            name="email",
            field=models.EmailField(max_length=254,
                                    unique=True,
                                    verbose_name="email address"),
        ),
    ]
class Migration(migrations.Migration):

    initial = True

    dependencies = [
    ]

    operations = [
        migrations.CreateModel(
            name='ImageSar',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('image', models.ImageField(upload_to=core.models.recipe_image_file_path)),
                ('type', models.CharField(max_length=255)),
                ('version', models.IntegerField(default=0)),
            ],
        ),
        migrations.CreateModel(
            name='TestUser',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=255)),
                ('email', models.EmailField(blank=True, max_length=254)),
                ('level', models.IntegerField()),
            ],
        ),
        migrations.CreateModel(
            name='TuringTest',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='core.testuser')),
            ],
        ),
        migrations.CreateModel(
            name='ImageTest',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('userGuess', models.BooleanField()),
                ('image', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='core.imagesar')),
                ('testTuring', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='core.turingtest')),
            ],
        ),
    ]
class Migration(migrations.Migration):

    initial = True

    dependencies = []

    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')),
                ('email', models.EmailField(max_length=254, unique=True)),
                ('first_name',
                 models.CharField(blank=True, default='', max_length=50)),
                ('last_name',
                 models.CharField(blank=True, default='', max_length=50)),
                ('avatar',
                 models.ImageField(blank=True,
                                   default='',
                                   upload_to=core.models.make_upload_path)),
                ('last_request',
                 models.DateTimeField(blank=True,
                                      help_text='When user make last request',
                                      null=True)),
            ],
            options={
                'abstract': False,
            },
        ),
    ]
Example #23
0
class Migration(migrations.Migration):

    initial = True

    dependencies = []

    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')),
                ('first_name', models.CharField(max_length=255)),
                ('last_name', models.CharField(max_length=255)),
                ('email',
                 models.EmailField(max_length=255,
                                   unique=True,
                                   verbose_name='email address')),
                ('is_active', models.BooleanField(default=True)),
                ('is_admin', models.BooleanField(default=False)),
            ],
            options={
                'abstract': False,
            },
            managers=[
                ('objects', core.models.UserManager()),
            ],
        ),
    ]
Example #24
0
class Migration(migrations.Migration):

    initial = True

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

    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')),
                ('email', models.EmailField(max_length=255, unique=True)),
                ('username', models.CharField(blank=True, max_length=255)),
                ('name', models.CharField(blank=True, max_length=255)),
                ('surname', models.CharField(blank=True, max_length=255)),
                ('image', models.ImageField(null=True, upload_to=core.models.avatar_image_file_path)),
                ('about_me', models.TextField(blank=True)),
                ('linkedin', models.CharField(blank=True, max_length=255)),
                ('is_notification_email', models.BooleanField(default=True)),
                ('is_active', models.BooleanField(default=False)),
                ('is_staff', models.BooleanField(default=False)),
                ('is_ban', models.BooleanField(default=False)),
                ('is_delete', models.BooleanField(default=False)),
                ('create_date', models.DateTimeField(auto_now_add=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={
                'abstract': False,
            },
        ),
    ]
Example #25
0
class Migration(migrations.Migration):

    initial = True

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

    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')),
                ('email', models.EmailField(max_length=255, unique=True)),
                ('name', models.CharField(max_length=255)),
                ('user_role', models.CharField(blank=True, default='client', max_length=20, null=True)),
                ('is_active', models.BooleanField(default=True)),
                ('is_staff', models.BooleanField(default=False)),
                ('is_user_manager', models.BooleanField(default=False)),
                ('login_attempt_count', models.PositiveSmallIntegerField(default=0)),
                ('is_locked', models.BooleanField(default=False)),
                ('avatar', models.ImageField(blank=True, null=True, upload_to=core.models.avatar_upload_path)),
                ('avatar_url', models.URLField(blank=True, max_length=1024, null=True)),
                ('provider', models.CharField(default='native', max_length=32)),
                ('phone', models.CharField(max_length=32)),
                ('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={
                'abstract': False,
            },
        ),
    ]
Example #26
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')),
                ('email',
                 models.EmailField(max_length=254,
                                   unique=True,
                                   verbose_name='Correo Electronico')),
                ('first_name',
                 models.CharField(blank=True,
                                  max_length=30,
                                  verbose_name='Nombre')),
                ('last_name',
                 models.CharField(blank=True,
                                  max_length=30,
                                  verbose_name='Apellido')),
                ('date_joined',
                 models.DateTimeField(auto_now_add=True,
                                      verbose_name='date joined')),
                ('is_active',
                 models.BooleanField(default=True, verbose_name='activo')),
                ('is_superuser',
                 models.BooleanField(default=True,
                                     verbose_name='superusuario')),
                ('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', core.models.UserManager()),
            ],
        ),
    ]
Example #27
0
class Migration(migrations.Migration):

    initial = True

    dependencies = []

    operations = [
        migrations.CreateModel(
            name='Scan',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('started_at', models.DateTimeField(blank=True, null=True)),
                ('finished_at', models.DateTimeField(blank=True, null=True)),
                ('name', models.CharField(max_length=255)),
                ('status',
                 models.CharField(choices=[
                     (core.models.Status['COMPLETED'], 'completed'),
                     (core.models.Status['FAILED'], 'failed')
                 ],
                                  max_length=50)),
                ('scanners',
                 django.contrib.postgres.fields.ArrayField(
                     base_field=models.CharField(blank=True,
                                                 max_length=50,
                                                 null=True),
                     size=None)),
                ('severity_counts',
                 django.contrib.postgres.fields.jsonb.JSONField(blank=True,
                                                                null=True)),
            ],
        ),
        migrations.CreateModel(
            name='User',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('username', models.CharField(max_length=255)),
                ('email', models.EmailField(max_length=254)),
                ('first_name', models.CharField(max_length=255)),
                ('last_name', models.CharField(max_length=255)),
            ],
        ),
        migrations.CreateModel(
            name='Vulnerability',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('severity',
                 models.CharField(choices=[
                     (core.models.Severity['INFORMATION'], 'information'),
                     (core.models.Severity['MEDIUM'], 'medium'),
                     (core.models.Severity['HIGH'], 'high'),
                     (core.models.Severity['LOW'], 'low')
                 ],
                                  max_length=50)),
                ('name', models.CharField(max_length=255)),
                ('description', models.TextField()),
                ('solution', models.TextField()),
                ('references',
                 django.contrib.postgres.fields.ArrayField(
                     base_field=models.URLField(blank=True, null=True),
                     size=None)),
                ('cvss_base_score',
                 models.DecimalField(decimal_places=1, max_digits=2)),
                ('scans',
                 models.ForeignKey(
                     on_delete=django.db.models.deletion.DO_NOTHING,
                     related_name='vulnerabilities',
                     to='core.scan')),
            ],
        ),
        migrations.AddField(
            model_name='scan',
            name='requested_by',
            field=models.ForeignKey(
                on_delete=django.db.models.deletion.DO_NOTHING,
                related_name='user',
                to='core.user'),
        ),
        migrations.CreateModel(
            name='Asset',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('name', models.CharField(max_length=255)),
                ('description', models.TextField()),
                ('created', models.DateTimeField(auto_now_add=True)),
                ('scan',
                 models.ForeignKey(
                     on_delete=django.db.models.deletion.DO_NOTHING,
                     related_name='assets_scanned',
                     to='core.scan')),
                ('vulnerability',
                 models.ForeignKey(
                     on_delete=django.db.models.deletion.DO_NOTHING,
                     related_name='affected_assets',
                     to='core.vulnerability')),
            ],
        ),
    ]
Example #28
0
class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('auth', '0007_alter_validators_add_error_messages'),
    ]

    operations = [
        migrations.CreateModel(
            name='Pipol',
            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')),
                ('email',
                 models.EmailField(help_text='Escriba un correo electrónico',
                                   max_length=254,
                                   unique=True,
                                   verbose_name='email')),
                ('username',
                 models.CharField(
                     error_messages={
                         'unique': 'Ya existe un usuario con ese nombre.'
                     },
                     help_text=
                     '\n            Obligatorio. 30 caracteres o menos. Letras, números\n            ó @ . + - _ solamente.\n        ',
                     max_length=30,
                     unique=True,
                     validators=[
                         django.core.validators.RegexValidator(
                             '^[\\w.@+-]+$',
                             'Enter a valid username. This value may contain only letters, numbers and @/./+/-/_ characters.'
                         )
                     ],
                     verbose_name='nombre de usuario')),
                ('first_name',
                 models.CharField(blank=True,
                                  max_length=70,
                                  verbose_name='Nombre')),
                ('last_name', models.CharField(blank=True, max_length=70)),
                ('rfc',
                 models.CharField(blank=True,
                                  help_text='Escriba el RFC del usuario',
                                  max_length=13,
                                  verbose_name='RFC')),
                ('entidad',
                 models.PositiveSmallIntegerField(choices=[(29, 'Tlaxcala')],
                                                  default=29)),
                ('sitio',
                 models.PositiveSmallIntegerField(
                     blank=True,
                     choices=[(0, 'Junta Local'), (1, '01 Junta Distrital'),
                              (2, '02 Junta Distrital'),
                              (3, 'O3 Junta Distrital')],
                     null=True)),
                ('puesto',
                 models.CharField(
                     blank=True,
                     choices=[
                         ('VEL', 'Vocal Ejecutivo de Junta Local'),
                         ('VSL', 'Vocal Secretario de Junta Local'),
                         ('VRL', 'Vocal del RFE de Junta Local'),
                         ('VCL', 'Vocal de Capacitación de Junta Local'),
                         ('VOL', 'Vocal de Organización de Junta Local'),
                         ('VED', 'Vocal Ejecutivo de Junta Distrital'),
                         ('VSD', 'Vocal Secretario de Junta Distrital'),
                         ('VRD', 'Vocal del RFE de Junta Distrital'),
                         ('VCD', 'Vocal de Capacitación de Junta Distrital'),
                         ('VOD', 'Vocal de Organización de Junta Distrital'),
                         ('JOSA', 'JOSA'),
                         ('JMM', 'Jefe de Monitoreo a Módulos'),
                         ('JOCE', 'Jefe de Cartografía'),
                         ('RA', 'Rama Administrativa')
                     ],
                     max_length=4,
                     null=True)),
                ('orden', models.PositiveSmallIntegerField(default=99)),
                ('is_staff',
                 models.BooleanField(
                     default=False,
                     help_text=
                     'Determina quienes pueden acceder al área interna.',
                     verbose_name='es staff')),
                ('is_active',
                 models.BooleanField(
                     default=True,
                     help_text=
                     'Indica si el usuario debe ser tratado como un usuario activo. Desactive este campo en lugar de eliminar usuarios.',
                     verbose_name='activo')),
                ('date_joined',
                 models.DateTimeField(default=django.utils.timezone.now,
                                      verbose_name='fecha de creación')),
                ('created_at', models.DateTimeField(auto_now_add=True)),
                ('updated_at', models.DateTimeField(auto_now=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={
                'abstract': False,
            },
            managers=[
                ('objects', core.models.PipolManager()),
            ],
        ),
    ]
Example #29
0
class Migration(migrations.Migration):

    initial = True

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

    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')),
                ('email',
                 models.EmailField(max_length=254,
                                   unique=True,
                                   verbose_name='email address')),
                ('age',
                 models.PositiveIntegerField(default=18, verbose_name='age')),
                ('gender',
                 models.CharField(choices=[('male', 'male'),
                                           ('female', 'female')],
                                  default='male',
                                  max_length=16,
                                  verbose_name='gender')),
                ('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')),
                ('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', core.models.UserManager()),
            ],
        ),
    ]
Example #30
0
class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('auth', '0012_alter_user_first_name_max_length'),
    ]

    operations = [
        migrations.CreateModel(
            name='CustomUsuario',
            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(
                     error_messages={
                         'unique': 'A user with that username already exists.'
                     },
                     help_text=
                     'Required. 150 characters or fewer. Letters, digits and @/./+/-/_ only.',
                     max_length=150,
                     unique=True,
                     validators=[
                         django.contrib.auth.validators.
                         UnicodeUsernameValidator()
                     ],
                     verbose_name='username')),
                ('first_name',
                 models.CharField(blank=True,
                                  max_length=150,
                                  verbose_name='first name')),
                ('last_name',
                 models.CharField(blank=True,
                                  max_length=150,
                                  verbose_name='last name')),
                ('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='E-mail')),
                ('telefone',
                 models.CharField(max_length=50, verbose_name='Telefone')),
                ('cpf', models.CharField(max_length=20, verbose_name='Cpf')),
                ('is_staff',
                 models.BooleanField(default=True,
                                     verbose_name='Membro da equipe')),
                ('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', core.models.UsuarioManager()),
            ],
        ),
    ]