-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Revert "Remove unnecessary address field from workflowlevel2"
- Loading branch information
Rafael Muñoz Cárdenas
committed
Sep 7, 2018
1 parent
c630608
commit e9caa3e
Showing
4 changed files
with
93 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# -*- coding: utf-8 -*- | ||
# Generated by Django 1.11.3 on 2018-09-07 14:04 | ||
from __future__ import unicode_literals | ||
|
||
import django.contrib.postgres.fields.hstore | ||
from django.db import migrations | ||
from django.db.utils import ProgrammingError | ||
|
||
|
||
def create_fields(apps, schema_editor): | ||
# If fields are not there, add them. If they were added before, then | ||
# ignore the error. | ||
try: | ||
migrations.AddField( | ||
model_name='historicalworkflowlevel2', | ||
name='address', | ||
field=django.contrib.postgres.fields.hstore.HStoreField(blank=True, help_text='Address object with the structure: street (string), house_number (string), postal_code: (string), city (string), country (string)', null=True), | ||
) | ||
migrations.AddField( | ||
model_name='workflowlevel2', | ||
name='address', | ||
field=django.contrib.postgres.fields.hstore.HStoreField(blank=True, help_text='Address object with the structure: street (string), house_number (string), postal_code: (string), city (string), country (string)', null=True), | ||
) | ||
except ProgrammingError: | ||
pass | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
dependencies = [ | ||
('workflow', '0029_auto_20180831_0452'), | ||
] | ||
|
||
operations = [ | ||
migrations.RunPython(create_fields), | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters