Changes between Initial Version and Version 2 of Ticket #28573
- Timestamp:
- Sep 25, 2017, 11:31:24 AM (7 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #28573 – Description
initial v2 4 4 5 5 Putting aside most of it; when running it, I was getting the following error: 6 6 {{{ 7 7 django.db.utils.ProgrammingError: column "customer_from_source_id" does not exist 8 8 }}} 9 9 That was very confusing, but when debugging it I found out that it's choking all the way at the end on the following sql statement: 10 10 … … 12 12 13 13 Now, that's weird because it shouldn't be creating that index on "customer_from_source_id" but on "customer_id" instead. The field is first created like so: 14 14 {{{ 15 15 migrations.AddField( 16 16 model_name="card", … … 18 18 field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name="sources", to="djstripe.Customer"), 19 19 ), 20 20 }}} 21 21 Then, it is renamed: 22 22 {{{ 23 23 migrations.RenameField( 24 24 model_name="card", … … 26 26 new_name="customer", 27 27 ), 28 }}}