Quiz

Форк
0
/
0001_initial.py 
48 строк · 2.2 Кб
1
# Generated by Django 4.1.7 on 2023-04-10 17:41
2

3
from django.conf import settings
4
from django.db import migrations, models
5
import django.db.models.deletion
6

7

8
class Migration(migrations.Migration):
9

10
    initial = True
11

12
    dependencies = [
13
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
14
        ('games', '0006_alter_game_type_alter_lobby_type_alter_queue_type'),
15
    ]
16

17
    operations = [
18
        migrations.CreateModel(
19
            name='LobbyMessage',
20
            fields=[
21
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
22
                ('text', models.CharField(max_length=128)),
23
                ('created_at', models.DateTimeField(auto_now=True)),
24
                ('lobby', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='games.lobby')),
25
                ('sender', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
26
            ],
27
        ),
28
        migrations.CreateModel(
29
            name='GameMessage',
30
            fields=[
31
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
32
                ('text', models.CharField(max_length=128)),
33
                ('created_at', models.DateTimeField(auto_now=True)),
34
                ('game', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='games.game')),
35
                ('sender', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)),
36
            ],
37
        ),
38
        migrations.CreateModel(
39
            name='FriendMessage',
40
            fields=[
41
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
42
                ('text', models.CharField(max_length=128)),
43
                ('created_at', models.DateTimeField(auto_now=True)),
44
                ('receiver', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='receiver', to=settings.AUTH_USER_MODEL)),
45
                ('sender', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='sender', to=settings.AUTH_USER_MODEL)),
46
            ],
47
        ),
48
    ]
49

Использование cookies

Мы используем файлы cookie в соответствии с Политикой конфиденциальности и Политикой использования cookies.

Нажимая кнопку «Принимаю», Вы даете АО «СберТех» согласие на обработку Ваших персональных данных в целях совершенствования нашего веб-сайта и Сервиса GitVerse, а также повышения удобства их использования.

Запретить использование cookies Вы можете самостоятельно в настройках Вашего браузера.