Email Notification System

22 vues
Accéder directement au premier message non lu

Ramez Kabbani

non lue,
12 févr. 2018, 16:00:5312/02/2018
à Django users
I'm trying to build an email notification system, and would appreciate some guidance.

Triggers:
  1. New item created & user assigned to instance
  2. Existing item edited & user assigned to instance
  3. Comment added to object where user is involved
  4. Item date field expires & user opts in to this notification type & user part of item's project

My thoughts:

  • I can use the post_save signal to trigger a Celery task that sends the email.
  • I would need to create a decorator to register models to be monitored
  • I could create a separate notification app so I can build a setting interface that exposes criteria like which projects get monitored.
  • For trigger #2 I can create a celery task that runs at, say, 9am everyday and checks all instances for expired date. It would send an email if the condition is True

This is as much as I have figured out. I need to work on implementation now, but would like some feedback.

Répondre à tous
Répondre à l'auteur
Transférer
0 nouveau message