VRFS-1243 VRFS-1310 fix regression in session notifications in sidebar
This commit is contained in:
parent
798ccc4529
commit
9c2b10dd5f
|
|
@ -143,7 +143,7 @@
|
|||
var template = $('#template-notification-panel').html();
|
||||
var notificationHtml = context.JK.fillTemplate(template, {
|
||||
notificationId: val.notification_id,
|
||||
sessionId: val.sessionId,
|
||||
sessionId: val.session_id,
|
||||
avatar_url: context.JK.resolveAvatarUrl(val.photo_url),
|
||||
text: val.formatted_msg,
|
||||
date: $.timeago(val.created_at)
|
||||
|
|
|
|||
|
|
@ -4,4 +4,23 @@ attributes :description, :source_user_id, :target_user_id, :session_id, :recordi
|
|||
|
||||
node :notification_id do |n|
|
||||
n.id
|
||||
end
|
||||
end
|
||||
|
||||
# this has to be flat like this so this payload is the same as the protocol buffer (see initializeActions in sidebar.js)
|
||||
node :fan_access do |n|
|
||||
unless n.session_id.blank?
|
||||
n.session.fan_access
|
||||
end
|
||||
end
|
||||
|
||||
node :musician_access do |n|
|
||||
unless n.session_id.blank?
|
||||
n.session.musician_access
|
||||
end
|
||||
end
|
||||
|
||||
node :approval_required do |n|
|
||||
unless n.session_id.blank?
|
||||
n.session.approval_required
|
||||
end
|
||||
end
|
||||
|
|
|
|||
Loading…
Reference in New Issue