Ticket #30966: 0001_initial.py

File 0001_initial.py, 1.6 KB (added by Peter Thomassen, 5 years ago)
Line 
1from django.db import migrations, models
2import django.db.models.deletion
3import uuid
4
5
6class Migration(migrations.Migration):
7
8 initial = True
9
10 dependencies = [
11 ]
12
13 operations = [
14 migrations.CreateModel(
15 name='User',
16 fields=[
17 ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False)),
18 ('email', models.EmailField(max_length=191, unique=True)),
19 ],
20 ),
21 migrations.CreateModel(
22 name='Domain',
23 fields=[
24 ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False)),
25 ('owner', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='desecapi.User')),
26 ],
27 ),
28 migrations.CreateModel(
29 name='RRset',
30 fields=[
31 ('id', models.UUIDField(default=uuid.uuid4, editable=False, primary_key=True, serialize=False)),
32 ('subname', models.CharField(blank=True, max_length=178)),
33 ('domain', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='desecapi.Domain')),
34 ],
35 ),
36 migrations.CreateModel(
37 name='Token',
38 fields=[
39 ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False)),
40 ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='desecapi.User')),
41 ],
42 ),
43 migrations.AlterField(
44 model_name='rrset',
45 name='subname',
46 field=models.CharField(blank=False, max_length=178),
47 ),
48 ]
Back to Top