The "Recent Actions" panel in Django Admin displays LogEntry
models. To clear it you would just delete all the objects:
from django.contrib.admin.models import LogEntry
LogEntry.objects.all().delete()
Pregunta
How would I go about clearing or re-setting the "Recent Actions" Panel in the Django Admin?
I want the admin interface to look like a fresh install.
Solución
The "Recent Actions" panel in Django Admin displays LogEntry
models. To clear it you would just delete all the objects:
from django.contrib.admin.models import LogEntry
LogEntry.objects.all().delete()
Otros consejos
You can clear Recent Actions of Django Admin.
First, open Django Shell with this command below:
python manage.py shell
Then, copy & paste these 2 lines of code below to Django Shell then press "Enter". That's it:
from django.contrib.admin.models import LogEntry
LogEntry.objects.all().delete()
Run in command prompt : python manage.py shell
Then type these lines one by one:
from django.contrib.admin.models import LogEntry
LogEntry.objects.all().delete()
and after excuting these lines type this line inside the shell to exit the shell:
exit()