python - How to call up the modal box through buttons on the django list page
phpcn_u1582
phpcn_u1582 2017-05-19 10:06:50
0
2
609

As shown above, I want to call up a modal box through a button on the Django list page to confirm and cancel the operation. I don’t know how to operate the template.
The template of the list page is provided in the Django source code. If the ordinary template file can write the modal box code into the current template file, but the source code cannot be modified, if the template change_list.html of the list page can be made to include the modal The box code can be adjusted

phpcn_u1582
phpcn_u1582

reply all(2)
仅有的幸福

Django will first look for the html file in the templates directory of your project
Once you know this, you can copy the corresponding html under your django admin to your templates directory
For example, your current link is /admin/a /b
You put the corresponding change_list.html in /templates/admin/a/b/change_list.html

漂亮男人

I personally prefer not to rely too much on the admin backend, especially when there are a lot of customization requirements. I usually write a web app myself

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!