Migration for regions and organizations
This commit is contained in:
parent
85d94d342e
commit
5b29ab92ea
1 changed files with 33 additions and 0 deletions
|
|
@ -0,0 +1,33 @@
|
|||
# Generated by Django 3.2.15 on 2022-10-25 03:16
|
||||
|
||||
from django.db import migrations, models
|
||||
import django.db.models.deletion
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('user_management', '0003_user_hide_phone_number'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.CreateModel(
|
||||
name='Region',
|
||||
fields=[
|
||||
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('name', models.CharField(max_length=300)),
|
||||
('slug', models.CharField(max_length=50, unique=True)),
|
||||
('oncall_backend_url', models.URLField(null=True)),
|
||||
],
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='organization',
|
||||
name='region_slug',
|
||||
field=models.CharField(default=None, max_length=300, null=True),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='organization',
|
||||
name='migration_destination',
|
||||
field=models.ForeignKey(db_column='migration_destination_slug', default=None, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='regions', to='user_management.region', to_field='slug'),
|
||||
),
|
||||
]
|
||||
Loading…
Add table
Reference in a new issue