You can use django post_save signals
# models.py from django.db.models import signals class MyModel(models.Model): pass def my_model_post_save(sender, instance, created, *args, **kwargs): """Argument explanation: sender - The model class. (MyModel) instance - The actual instance being saved. created - Boolean; True if a new record was created. *args, **kwargs - Capture the unneeded `raw` and `using`(1.3) arguments. """ if created:
source share