Error occurred when fetching sidebar data
Bugfix: Feeds total notifications
On this MR we did an improvement of only loading/processing 3 notifications per channel to the templates: !90 (merged)
However we need the total notifications per channel, for this part https://gitlab.cern.ch/push-notifications/notifications-consumer/-/blob/master/notifications_consumer/processors/email_feed/templates/feed_notification.html#L43
Adapt templates's payload, and the template itself to fix this problem.
Suggestion: change current payload from
channel_notifications = {
channel_id1 = [notification1, notification2, notification3],
channel_id2 = [notification4, notification5]
}
to
channel_notifications = {
channel_id1 = {
notifications: [notification1, notification2, notification3]
total: 10
},
channel_id2 = {
notifications: [notification4, notification5]
total: 2
}
}