[1.11.x] Removed unused imports in example migrations.
Backport of a76d12ceb4
from master
This commit is contained in:
parent
6bb01b0b3c
commit
a15d81a183
|
@ -158,7 +158,7 @@ the respective field according to your needs.
|
||||||
# Generated by Django A.B on YYYY-MM-DD HH:MM
|
# Generated by Django A.B on YYYY-MM-DD HH:MM
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import migrations, models
|
from django.db import migrations
|
||||||
import uuid
|
import uuid
|
||||||
|
|
||||||
def gen_uuid(apps, schema_editor):
|
def gen_uuid(apps, schema_editor):
|
||||||
|
|
|
@ -317,7 +317,7 @@ model::
|
||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import migrations, models
|
from django.db import migrations
|
||||||
|
|
||||||
def forwards_func(apps, schema_editor):
|
def forwards_func(apps, schema_editor):
|
||||||
# We get the model from the versioned app registry;
|
# We get the model from the versioned app registry;
|
||||||
|
|
|
@ -463,7 +463,7 @@ Then, open up the file; it should look something like this::
|
||||||
# Generated by Django A.B on YYYY-MM-DD HH:MM
|
# Generated by Django A.B on YYYY-MM-DD HH:MM
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import migrations, models
|
from django.db import migrations
|
||||||
|
|
||||||
class Migration(migrations.Migration):
|
class Migration(migrations.Migration):
|
||||||
initial = True
|
initial = True
|
||||||
|
@ -493,7 +493,7 @@ need to do is use the historical model and iterate over the rows::
|
||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
from django.db import migrations, models
|
from django.db import migrations
|
||||||
|
|
||||||
def combine_names(apps, schema_editor):
|
def combine_names(apps, schema_editor):
|
||||||
# We can't import the Person model directly as it may be a newer
|
# We can't import the Person model directly as it may be a newer
|
||||||
|
|
Loading…
Reference in New Issue