My favorites | Sign in
Project Home Wiki Issues
New issue   Search
for
  Advanced search   Search tips   Subscriptions

Issue 71 attachment: db_column.diff (637 bytes)

1
2
3
4
5
6
7
8
9
10
11
12
13
diff --git a/apps/django_evolution/signature.py b/apps/django_evolution/signature.py
--- a/apps/django_evolution/signature.py
+++ b/apps/django_evolution/signature.py
@@ -68,7 +68,8 @@
for field in model._meta.local_fields + model._meta.local_many_to_many:
# Special case - don't generate a signature for generic relations
if not isinstance(field, generic.GenericRelation):
- model_sig['fields'][field.name] = create_field_sig(field)
+ name = field.db_column or field.name
+ model_sig['fields'][name] = create_field_sig(field)
return model_sig

def create_app_sig(app):
Powered by Google Project Hosting