0002_auto_20180424_2119.py 1.17 KB
Newer Older
Florent Chehab's avatar
Florent Chehab committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
# Generated by Django 2.0.3 on 2018-04-24 19:19

from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):

    dependencies = [
        ('rex', '0001_initial'),
    ]

    operations = [
        migrations.CreateModel(
            name='Region',
            fields=[
                ('name', models.CharField(max_length=200)),
                ('un_code', models.CharField(max_length=3, primary_key=True, serialize=False)),
                ('parent', models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, to='rex.Region')),
            ],
        ),
        migrations.RemoveField(
            model_name='country',
            name='iso_code',
        ),
        migrations.AddField(
            model_name='country',
            name='iso_alpha3_code',
            field=models.CharField(default='TMP', max_length=3, primary_key=True, serialize=False),
            preserve_default=False,
        ),
        migrations.AddField(
            model_name='country',
            name='region',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.PROTECT, to='rex.Region'),
        ),
    ]