Displaying table header even when there is no content? (django admin page) -


i want table appear headings when there no content. now, 'add' button appears when there isn't in database. how do this? please help

it looks no content:

enter image description here

it looks content:

enter image description here

so no content, should still show table headings. suggest way?

copy template @ django/contrib/admin/templates/admin/change_list_results.html admin template folder.

keep structure:

project -app -templates -admin -change_list_results.html -manage.py

than, remove {% if results %} - {% endif %} tags new template file , should work.


Comments

Popular posts from this blog

twig - Using Twigbridge in a Laravel 5.1 Package -

firemonkey - How do I make a beep sound in Android using Delphi and the API? -

jdbc - Not able to establish database connection in eclipse -