Module: NotificationRecipients::BuildService
- Defined in:
- app/services/notification_recipients/build_service.rb
Class Method Summary collapse
- .build_merge_request_unmergeable_recipients(*args) ⇒ Object
- .build_new_note_recipients(*args) ⇒ Object
- .build_new_release_recipients(*args) ⇒ Object
- .build_new_review_recipients(*args) ⇒ Object
- .build_project_maintainers_recipients(*args) ⇒ Object
- .build_recipients(*args) ⇒ Object
- .notifiable?(user, *args) ⇒ Boolean
- .notifiable_users(users, *args) ⇒ Object
Class Method Details
.build_merge_request_unmergeable_recipients(*args) ⇒ Object
24 25 26 |
# File 'app/services/notification_recipients/build_service.rb', line 24 def self.build_merge_request_unmergeable_recipients(*args) ::NotificationRecipients::Builder::MergeRequestUnmergeable.new(*args).notification_recipients end |
.build_new_note_recipients(*args) ⇒ Object
20 21 22 |
# File 'app/services/notification_recipients/build_service.rb', line 20 def self.build_new_note_recipients(*args) ::NotificationRecipients::Builder::NewNote.new(*args).notification_recipients end |
.build_new_release_recipients(*args) ⇒ Object
32 33 34 |
# File 'app/services/notification_recipients/build_service.rb', line 32 def self.build_new_release_recipients(*args) ::NotificationRecipients::Builder::NewRelease.new(*args).notification_recipients end |
.build_new_review_recipients(*args) ⇒ Object
36 37 38 |
# File 'app/services/notification_recipients/build_service.rb', line 36 def self.build_new_review_recipients(*args) ::NotificationRecipients::Builder::NewReview.new(*args).notification_recipients end |
.build_project_maintainers_recipients(*args) ⇒ Object
28 29 30 |
# File 'app/services/notification_recipients/build_service.rb', line 28 def self.build_project_maintainers_recipients(*args) ::NotificationRecipients::Builder::ProjectMaintainers.new(*args).notification_recipients end |
.build_recipients(*args) ⇒ Object
16 17 18 |
# File 'app/services/notification_recipients/build_service.rb', line 16 def self.build_recipients(*args) ::NotificationRecipients::Builder::Default.new(*args).notification_recipients end |
.notifiable?(user, *args) ⇒ Boolean
12 13 14 |
# File 'app/services/notification_recipients/build_service.rb', line 12 def self.notifiable?(user, *args) NotificationRecipient.new(user, *args).notifiable? end |
.notifiable_users(users, *args) ⇒ Object
8 9 10 |
# File 'app/services/notification_recipients/build_service.rb', line 8 def self.notifiable_users(users, *args) users.compact.map { |u| NotificationRecipient.new(u, *args) }.select(&:notifiable?).map(&:user) end |