8
0
Fork 0
mirror of https://gitlab2.federez.net/re2o/re2o synced 2024-12-28 09:53:47 +00:00

Post-user et post_del avec model User aussi

This commit is contained in:
Gabriel Detraz 2017-10-27 01:34:28 +02:00 committed by root
parent be6a06ea81
commit fd0cce6f9e

View file

@ -752,6 +752,7 @@ class Club(User):
@receiver(post_save, sender=Adherent)
@receiver(post_save, sender=Club)
@receiver(post_save, sender=User)
def user_post_save(sender, **kwargs):
""" Synchronisation post_save : envoie le mail de bienvenue si creation
Synchronise le ldap"""
@ -765,6 +766,7 @@ def user_post_save(sender, **kwargs):
@receiver(post_delete, sender=Adherent)
@receiver(post_delete, sender=Club)
@receiver(post_delete, sender=User)
def user_post_delete(sender, **kwargs):
"""Post delete d'un user, on supprime son instance ldap"""
user = kwargs['instance']