admin is just a python module. So the right way of splitting it would be as follows:
- Create a folder called
- Use multiple files within the admin folder, like your
- Create a
adminfolder and import * all the files into it.
- You might also want to include an
__all__to provide a clean interface.
you should be importing from Some_Model_admin instead.
from my_app.seperated_admins.Some_Model_admin import *
things should be working fine then
alternatively you can import all the split files into the init in which case
from my_app.seperated_admins import *
- Django favicon.ico in development?
- Nginx 504 Gateway Timeout Error for Django
- Object of type 'AuthToken' is not JSON serializable