as this url mentioned https://docs.djangoproject.com/en/dev/topics/forms/media/#assets-as-a-static-definition I know that and it does work by adding each custom js into each model one by one BUT is there a way to add into ALL models so I do not have to add each model one by one?
1 Answer
Make an admin folder inside the templates folder and then create a base.html file or add below code in html file:
{% extends 'admin/base.html' %}
{% block extrahead %}
<<< add your css and js >>>
{% endblock %}
but make sure project app name must be above from django.contrib.admin in INSTALLED_APP of django settings