Reputation: 497
I am looking for information on how to add entirely new pages to the django admin interface. I need to add a view that allows admins to change the contents of an existing text file. This view needs to exist within the existing django admin app. I am using django 1.9.
I found information on extending existing pages, but not adding entirely new pages. Is this possible?
Upvotes: 5
Views: 1231
Reputation: 308849
Once you've written your view, you can include it in the admin by overriding get_urls
.
An alternative is to override the AdminSite
class, which also has a get_urls
method. However this will require changing more code if you are not already using a custom AdminSite
subclass.
Upvotes: 1