Search code examples
pythondjangodjango-modelsdjango-admindjango-database

django: automatically detect CRUD changes done on database


I'm building an application(log) which stores the CRUD operations done on database.Is there any way to detect the CRUD operations directly?


Solution

  • You can accomplish this using django's model signals.

    Alternatively, you could use one of the many existing packages that provide this functionality. Find a comparison here: https://www.djangopackages.com/grids/g/model-audit/