示例#1
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')),
                ('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')),
                ('fio', models.CharField(blank=True, max_length=50, null=True, verbose_name='ФИО')),
                ('phone', models.CharField(blank=True, max_length=50, null=True, verbose_name='Телефон')),
                ('email', models.EmailField(max_length=254, unique=True, verbose_name='Эл. почта')),
                ('avatar', models.ImageField(blank=True, upload_to='ava_img/', verbose_name='Фото')),
                ('info', models.TextField(blank=True, null=True, verbose_name='О себе')),
                ('profession', models.CharField(blank=True, max_length=50, null=True, verbose_name='Профессия')),
                ('hobby', models.CharField(blank=True, max_length=50, null=True, verbose_name='Хобби')),
                ('study', models.CharField(blank=True, max_length=50, null=True, verbose_name='Образование')),
                ('isOfferRent', models.BooleanField(default=True, verbose_name='Арендадатель?')),
                ('profile_ok', 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={
                'verbose_name': 'user',
                'verbose_name_plural': 'users',
                'abstract': False,
            },
            managers=[
                ('objects', customuser.models.UserManager()),
            ],
        ),
    ]
示例#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')),
                ('order_number',
                 models.IntegerField(default=0,
                                     verbose_name='Порядок отображения')),
                ('email',
                 models.EmailField(max_length=254,
                                   unique=True,
                                   verbose_name='Эл. почта')),
                ('name',
                 models.CharField(blank=True,
                                  max_length=50,
                                  null=True,
                                  verbose_name='ФИО')),
                ('phone',
                 models.CharField(blank=True,
                                  max_length=50,
                                  null=True,
                                  verbose_name='Телефон')),
                ('avatar',
                 models.ImageField(blank=True,
                                   upload_to='avatar/',
                                   verbose_name='Фото профиля')),
                ('profile_ok', 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={
                'verbose_name': 'user',
                'verbose_name_plural': 'users',
                'abstract': False,
            },
            managers=[
                ('objects', customuser.models.UserManager()),
            ],
        ),
        migrations.CreateModel(
            name='Company',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('name',
                 models.CharField(max_length=100,
                                  null=True,
                                  verbose_name='Название организации')),
                ('name_slug',
                 models.CharField(blank=True,
                                  editable=False,
                                  max_length=255,
                                  null=True)),
                ('site',
                 models.CharField(blank=True,
                                  max_length=50,
                                  null=True,
                                  verbose_name='Сайт организации (без http)')),
                ('address',
                 models.TextField(blank=True,
                                  null=True,
                                  verbose_name='Адрес организации')),
                ('description',
                 ckeditor_uploader.fields.RichTextUploadingField(
                     blank=True,
                     null=True,
                     verbose_name='Полное описание организации')),
                ('short_description',
                 models.CharField(
                     blank=True,
                     max_length=100,
                     null=True,
                     verbose_name='Краткое описание организации')),
                ('avatar',
                 models.ImageField(blank=True,
                                   upload_to='company/',
                                   verbose_name='Фото организации')),
                ('vk',
                 models.CharField(blank=True,
                                  max_length=100,
                                  null=True,
                                  verbose_name='Ссылка на VK')),
                ('fb',
                 models.CharField(blank=True,
                                  max_length=100,
                                  null=True,
                                  verbose_name='Ссылка на FB')),
                ('inst',
                 models.CharField(blank=True,
                                  max_length=100,
                                  null=True,
                                  verbose_name='Ссылка на Instagram')),
                ('yt',
                 models.CharField(blank=True,
                                  max_length=100,
                                  null=True,
                                  verbose_name='Ссылка на YouTube')),
                ('ok',
                 models.CharField(blank=True,
                                  max_length=100,
                                  null=True,
                                  verbose_name='Ссылка на OK')),
                ('views',
                 models.IntegerField(default=0, verbose_name='Просмотров')),
                ('created_at', models.DateTimeField(auto_now_add=True)),
                ('user',
                 models.ForeignKey(null=True,
                                   on_delete=django.db.models.deletion.CASCADE,
                                   to=settings.AUTH_USER_MODEL,
                                   verbose_name='Принадлежит пользователю')),
            ],
        ),
    ]
示例#3
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')),
                ('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')),
                ('avatar',
                 models.ImageField(blank=True,
                                   null=True,
                                   upload_to='user',
                                   verbose_name='Фото')),
                ('photo',
                 models.CharField(blank=True,
                                  max_length=255,
                                  null=True,
                                  verbose_name='VK аватар')),
                ('first_name',
                 models.CharField(blank=True,
                                  max_length=50,
                                  null=True,
                                  verbose_name='Имя')),
                ('last_name',
                 models.CharField(blank=True,
                                  max_length=50,
                                  null=True,
                                  verbose_name='Фамилия')),
                ('genre',
                 models.BooleanField(blank=True,
                                     null=True,
                                     verbose_name='Пол мужской?')),
                ('nickname',
                 models.CharField(blank=True,
                                  max_length=50,
                                  null=True,
                                  verbose_name='Ник')),
                ('email',
                 models.EmailField(blank=True,
                                   max_length=254,
                                   null=True,
                                   unique=True,
                                   verbose_name='Эл. почта')),
                ('birthday',
                 models.DateField(blank=True,
                                  null=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': 'user',
                'verbose_name_plural': 'users',
                'abstract': False,
            },
            managers=[
                ('objects', customuser.models.UserManager()),
            ],
        ),
    ]
示例#4
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')),
                ('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='эл. почта')),
                ('phone',
                 models.CharField(blank=True,
                                  max_length=50,
                                  null=True,
                                  verbose_name='Телефон')),
                ('avatar',
                 models.ImageField(blank=True,
                                   upload_to='avatar/',
                                   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': 'user',
                'verbose_name_plural': 'users',
                'abstract': False,
            },
            managers=[
                ('objects', customuser.models.UserManager()),
            ],
        ),
        migrations.CreateModel(
            name='Message',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('text', models.TextField(blank=True, null=True)),
                ('user',
                 models.ForeignKey(null=True,
                                   on_delete=django.db.models.deletion.CASCADE,
                                   to=settings.AUTH_USER_MODEL)),
            ],
            options={
                'ordering': ('-id', ),
            },
        ),
    ]
示例#5
0
class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('auth', '0012_alter_user_first_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='メールアドレス')),
                ('github_url', models.URLField(unique=True)),
                ('image', models.ImageField(upload_to='media/')),
                ('name', models.CharField(max_length=200)),
                ('is_active', models.BooleanField(default=True)),
                ('is_admin', 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', customuser.models.UserManager()),
            ],
        ),
        migrations.CreateModel(
            name='Request',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('is_proceeded', models.BooleanField()),
                ('is_approved', models.BooleanField()),
                ('created_at', models.DateTimeField(auto_now_add=True)),
                ('applicant',
                 models.ForeignKey(on_delete=django.db.models.deletion.CASCADE,
                                   related_name='applicant',
                                   to=settings.AUTH_USER_MODEL)),
                ('recruiter',
                 models.ForeignKey(on_delete=django.db.models.deletion.CASCADE,
                                   related_name='recruiter',
                                   to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.CreateModel(
            name='Recruitment',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('image', models.ImageField(upload_to='media/')),
                ('detail', models.TextField()),
                ('approval_msg', models.CharField(max_length=200)),
                ('refusal_msg', models.CharField(max_length=200)),
                ('title', models.CharField(max_length=100)),
                ('created_at', models.DateTimeField(auto_now_add=True)),
                ('updated_at', models.DateTimeField(auto_now=True)),
                ('created_user',
                 models.ForeignKey(on_delete=django.db.models.deletion.CASCADE,
                                   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.TextField()),
                ('is_read', models.BooleanField()),
                ('created_at', models.DateTimeField(auto_now_add=True)),
                ('accepter',
                 models.ForeignKey(on_delete=django.db.models.deletion.CASCADE,
                                   related_name='accepter',
                                   to=settings.AUTH_USER_MODEL)),
                ('recruitment',
                 models.ForeignKey(on_delete=django.db.models.deletion.CASCADE,
                                   to='customuser.recruitment')),
                ('sender',
                 models.ForeignKey(on_delete=django.db.models.deletion.CASCADE,
                                   related_name='sender',
                                   to=settings.AUTH_USER_MODEL)),
            ],
        ),
    ]
示例#6
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')),
                ('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='Эл. почта')),
                ('phone',
                 models.CharField(blank=True,
                                  max_length=50,
                                  null=True,
                                  verbose_name='Телефон')),
                ('profile_ok', models.BooleanField(default=False)),
                ('avatar',
                 models.ImageField(blank=True,
                                   upload_to='avatar/',
                                   verbose_name='Фото профиля')),
                ('balance',
                 models.DecimalField(decimal_places=2,
                                     default=0,
                                     max_digits=6,
                                     verbose_name='Баланс')),
                ('yandex_wallet',
                 models.CharField(blank=True,
                                  max_length=50,
                                  null=True,
                                  verbose_name='Кошелек ЯД')),
                ('card_number',
                 models.CharField(blank=True,
                                  max_length=50,
                                  null=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': 'user',
                'verbose_name_plural': 'users',
                'abstract': False,
            },
            managers=[
                ('objects', customuser.models.UserManager()),
            ],
        ),
        migrations.CreateModel(
            name='BalanceFreeze',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('amount',
                 models.DecimalField(decimal_places=2,
                                     default=0,
                                     max_digits=6,
                                     verbose_name='Сумма')),
            ],
            options={
                'verbose_name': 'Резервирование на балансе',
                'verbose_name_plural': 'Резервирование на балансе',
            },
        ),
        migrations.CreateModel(
            name='Bet',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('amount',
                 models.DecimalField(decimal_places=2,
                                     default=0,
                                     max_digits=6,
                                     verbose_name='Ставка')),
                ('image',
                 models.ImageField(blank=True,
                                   upload_to='bet/',
                                   verbose_name='Фото')),
                ('coefficient',
                 models.DecimalField(decimal_places=2,
                                     default=0,
                                     max_digits=6,
                                     verbose_name='Коэффициент ')),
                ('cashback',
                 models.IntegerField(default=0, verbose_name='Возврат %')),
                ('bet_result',
                 models.BooleanField(blank=True,
                                     null=True,
                                     verbose_name='Результат')),
                ('bet_result_amount',
                 models.DecimalField(decimal_places=2,
                                     default=0,
                                     max_digits=6,
                                     verbose_name='Результат сумма')),
                ('created_at',
                 models.DateTimeField(auto_now_add=True,
                                      null=True,
                                      verbose_name='Дата создания')),
                ('user',
                 models.ForeignKey(null=True,
                                   on_delete=django.db.models.deletion.CASCADE,
                                   to=settings.AUTH_USER_MODEL)),
            ],
            options={
                'verbose_name': 'Ставка пользователя',
                'verbose_name_plural': 'Ставки пользователей',
            },
        ),
        migrations.CreateModel(
            name='Log',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('text', models.CharField(blank=True,
                                          max_length=255,
                                          null=True)),
                ('user',
                 models.ForeignKey(null=True,
                                   on_delete=django.db.models.deletion.CASCADE,
                                   to=settings.AUTH_USER_MODEL)),
            ],
            options={
                'verbose_name': 'Лог действий',
                'verbose_name_plural': 'Логи действий',
            },
        ),
        migrations.CreateModel(
            name='Message',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('text', models.TextField(blank=True, null=True)),
                ('user',
                 models.ForeignKey(null=True,
                                   on_delete=django.db.models.deletion.CASCADE,
                                   to=settings.AUTH_USER_MODEL)),
            ],
            options={
                'ordering': ('-id', ),
            },
        ),
        migrations.CreateModel(
            name='Payment',
            fields=[
                ('id',
                 models.AutoField(auto_created=True,
                                  primary_key=True,
                                  serialize=False,
                                  verbose_name='ID')),
                ('amount',
                 models.DecimalField(decimal_places=2,
                                     default=0,
                                     max_digits=6,
                                     verbose_name='Сумма')),
                ('status',
                 models.BooleanField(default=False,
                                     verbose_name='Статус платежа')),
                ('created_at',
                 models.DateTimeField(auto_now_add=True,
                                      null=True,
                                      verbose_name='Дата создания')),
                ('user',
                 models.ForeignKey(null=True,
                                   on_delete=django.db.models.deletion.CASCADE,
                                   to=settings.AUTH_USER_MODEL)),
            ],
        ),
        migrations.AddField(
            model_name='balancefreeze',
            name='bet',
            field=models.ForeignKey(
                null=True,
                on_delete=django.db.models.deletion.CASCADE,
                to='customuser.Bet'),
        ),
        migrations.AddField(
            model_name='balancefreeze',
            name='user',
            field=models.ForeignKey(
                null=True,
                on_delete=django.db.models.deletion.CASCADE,
                to=settings.AUTH_USER_MODEL),
        ),
    ]