2020-06-11 00:54:34 +02:00
|
|
|
import django.db.models.deletion
|
2020-04-15 12:34:26 +02:00
|
|
|
from django.conf import settings
|
|
|
|
from django.db import migrations, models
|
|
|
|
|
|
|
|
|
|
|
|
class Migration(migrations.Migration):
|
|
|
|
dependencies = [
|
2021-02-12 08:20:45 +01:00
|
|
|
("zerver", "0275_remove_userprofile_last_pointer_updater"),
|
2020-04-15 12:34:26 +02:00
|
|
|
]
|
|
|
|
|
|
|
|
operations = [
|
|
|
|
migrations.CreateModel(
|
2021-02-12 08:20:45 +01:00
|
|
|
name="AlertWord",
|
2020-04-15 12:34:26 +02:00
|
|
|
fields=[
|
2021-02-12 08:19:30 +01:00
|
|
|
(
|
2021-02-12 08:20:45 +01:00
|
|
|
"id",
|
2021-02-12 08:19:30 +01:00
|
|
|
models.AutoField(
|
2021-02-12 08:20:45 +01:00
|
|
|
auto_created=True, primary_key=True, serialize=False, verbose_name="ID"
|
2021-02-12 08:19:30 +01:00
|
|
|
),
|
|
|
|
),
|
2021-02-12 08:20:45 +01:00
|
|
|
("word", models.TextField()),
|
2021-02-12 08:19:30 +01:00
|
|
|
(
|
2021-02-12 08:20:45 +01:00
|
|
|
"realm",
|
2021-02-12 08:19:30 +01:00
|
|
|
models.ForeignKey(
|
2021-02-12 08:20:45 +01:00
|
|
|
on_delete=django.db.models.deletion.CASCADE, to="zerver.Realm"
|
2021-02-12 08:19:30 +01:00
|
|
|
),
|
|
|
|
),
|
|
|
|
(
|
2021-02-12 08:20:45 +01:00
|
|
|
"user_profile",
|
2021-02-12 08:19:30 +01:00
|
|
|
models.ForeignKey(
|
|
|
|
on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL
|
|
|
|
),
|
|
|
|
),
|
2020-04-15 12:34:26 +02:00
|
|
|
],
|
|
|
|
options={
|
2021-02-12 08:20:45 +01:00
|
|
|
"unique_together": {("user_profile", "word")},
|
2020-04-15 12:34:26 +02:00
|
|
|
},
|
|
|
|
),
|
|
|
|
]
|