mirror of
https://github.com/ae-utbm/sith.git
synced 2026-10-30 22:29:32 +00:00
Use signals to update internal ics
This commit is contained in:
1 parent
a60e1f1fdc
commit
65df55a635
5 files changed
+53
-26
No files matched your search
@@ -0,0 +1,9 @@
|
||||
from django.db.models.base import post_save
|
||||
from django.dispatch import receiver
|
||||
|
||||
from com.models import IcsCalendar, News
|
||||
|
||||
|
||||
@receiver(post_save, sender=News, dispatch_uid="update_internal_ics")
|
||||
def update_internal_ics(*args, **kwargs):
|
||||
_ = IcsCalendar.make_internal()
|
||||
Reference in new issue
Block a user