Your current issue is that you are trying to change the app_label
and db_table
, which ends up changing the location of the model data within the database. By default, the database table is generated as [app_label]_[model_name]
(backend_transportationrequest
in your case), so when you modify both of these, South detects that the model has been removed and created again, even if this isn't actually the case.
The Django migrations framework introduced in 1.7 should have fixed this, so it detects that the model was moved (instead of deleted and created). You may need to fake a migration along the same lines as this with south, which can be done by modifying the two mgirations it generates to not actually delete and create the tables, but rename them.
Django does not currently allow you to easily do this, as the admin site expects that each application that is registered has a unique app_label
. You may have luck playing with the label
property of your AppConfig, but this is specifically not recommended and has been historically known to cause massive headaches.
One possibility may be to create a clone of your previous model, and only use it to register the app with the Django admin. You would need to create a proxy model with the custom app_label
and db_table
. If this didn't work (though it should), the other option would be to clone the model as a unmanaged model using the app_label
and db_table
.