Example #1
0
    def notify_incident(incident):
        notifications = NotificationHelper.generate_notifications_for_incident(
            incident)

        for notification in notifications:
            notification.save()
            send_notifications.apply_async((notification.id, ),
                                           eta=notification.send_at)
Example #2
0
    def notify_user_about_incident(incident,
                                   user,
                                   delay=None,
                                   preparedmsg=None):
        notifications = NotificationHelper.generate_notifications_for_user(
            incident, user, delay, preparedmsg)

        for notification in notifications:
            notification.save()
            send_notifications.apply_async((notification.id, ),
                                           eta=notification.send_at)
Example #3
0
    def notify_user_about_incident(incident, user):
        notifications = NotificationHelper.generate_notifications_for_user(incident, user)

        for notification in notifications:
            notification.save()
            send_notifications.apply_async((notification.id,) ,eta=notification.send_at)
Example #4
0
    def notify_user_about_incident(incident, user, delay=None, preparedmsg = None):
        notifications = NotificationHelper.generate_notifications_for_user(incident, user, delay, preparedmsg)

        for notification in notifications:
            notification.save()
            send_notifications.apply_async((notification.id,) ,eta=notification.send_at)