Problem or use case
I would like to let my users subscribe notifications from a specific notifiable instance, e.g. if my application has Posts with many Comments, I can subscribe to Post #1 and Post #4 and get the comment.created notification for only those posts, but not the others.
Similar to how notifications work here in Github, it's possible to subscribe to notifications about a specific issue.
Expected solution
When creating a subscription, I want to specify a notification instance next to the key, so when that notification instance sends out a notification, I want to get notified, regardless of what is set up in targets of the acts_as_notifiable
I'm also open to suggestions, I'm curious to hear how you would solve this.
Alternatives
I can use the existing targets on acts_as_notifiable but there's not always a clear link between the notifiable and the targets.
I also considered abusing the notification keys for it (something like post.1.comment_created), but the key is used to look up the views for the notifications, so that's not viable. Maybe if we could specify the view to use for each notification key...?
Problem or use case
I would like to let my users subscribe notifications from a specific notifiable instance, e.g. if my application has
Posts with manyComments, I can subscribe toPost #1andPost #4and get thecomment.creatednotification for only those posts, but not the others.Similar to how notifications work here in Github, it's possible to subscribe to notifications about a specific issue.
Expected solution
When creating a subscription, I want to specify a notification instance next to the key, so when that notification instance sends out a notification, I want to get notified, regardless of what is set up in
targetsof theacts_as_notifiableI'm also open to suggestions, I'm curious to hear how you would solve this.
Alternatives
I can use the existing
targetsonacts_as_notifiablebut there's not always a clear link between the notifiable and the targets.I also considered abusing the notification keys for it (something like
post.1.comment_created), but the key is used to look up the views for the notifications, so that's not viable. Maybe if we could specify the view to use for each notification key...?