Esempio n. 1
0
def group_by_node(notifications, limit=15):
    """Take list of notifications and group by node.

    :param notifications: List of stored email notifications
    :return:
    """
    emails = NotificationsDict()
    for notification in notifications[:15]:
        emails.add_message(notification['node_lineage'], notification['message'])
    return emails
Esempio n. 2
0
def group_by_node(notifications, limit=15):
    """Take list of notifications and group by node.

    :param notifications: List of stored email notifications
    :return:
    """
    emails = NotificationsDict()
    for notification in notifications[:15]:
        emails.add_message(notification['node_lineage'], notification['message'])
    return emails
Esempio n. 3
0
def group_by_node(notifications):
    """Take list of notifications and group by node.

    :param notifications: List of stored email notifications
    :return:
    """
    emails = NotificationsDict()
    for notification in notifications:
        emails.add_message(notification["node_lineage"], notification["message"])
    return emails
Esempio n. 4
0
def group_messages_by_node(notifications):
    d = NotificationsDict()
    for notification in notifications:
        d.add_message(notification['node_lineage'], notification['message'])
    return d
Esempio n. 5
0
def group_messages_by_node(notifications):
    d = NotificationsDict()
    for notification in notifications:
        d.add_message(notification['node_lineage'], notification['message'])
    return d