问题
Hy!
I have my models in a hierarchy below "models" package:
models
|-a.py
|-b.py
instead of having all my models into the models.py
But when I run the migration command for South it doesn't find any of them:
schemamigration my_app --auto
In the meta class already exists the app_label='my_app'
I use auto because the tables are already changed.
回答1:
Have you imported all the models in __init__.py
? If you've done that, there's effectively no difference in how it works.
来源:https://stackoverflow.com/questions/8123125/how-to-migrate-models-from-a-models-package-hierarchy-and-not-from-models-py-wit