Class: UserUnfollowEventJob
- Defined in:
- app/jobs/user_unfollow_event_job.rb
Overview
Log user unfollowing another user to activity streams
Constant Summary
Constants included from Sufia::CitationsBehaviors::TitleBehavior
Sufia::CitationsBehaviors::TitleBehavior::EXPANDED_NOCAPS, Sufia::CitationsBehaviors::TitleBehavior::TITLE_NOCAPS
Instance Attribute Summary collapse
-
#unfollowee ⇒ Object
Returns the value of attribute unfollowee.
-
#unfollower ⇒ Object
Returns the value of attribute unfollower.
Attributes inherited from EventJob
Instance Method Summary collapse
- #action ⇒ Object
-
#log_user_event(_unfollower) ⇒ Object
log the event to the users event stream.
- #perform(unfollower, unfollowee) ⇒ Object
Methods inherited from EventJob
Methods included from Sufia::SufiaHelperBehavior
#application_name, #browser_supports_directory_upload?, #collection_thumbnail, #current_search_parameters, #error_messages_for, #has_collection_search_parameters?, #human_readable_date, #iconify_auto_link, #index_field_link, #institution_name, #institution_name_full, #link_to_facet, #link_to_facet_list, #link_to_field, #link_to_profile, #link_to_telephone, #number_of_deposits, #orcid_label, #render_visibility_link, #rights_statement_links, #search_form_action, #show_transfer_request_title, #user_display_name_and_key, #zotero_label, #zotero_profile_url
Methods included from Sufia::CitationsBehavior
#export_as_apa_citation, #export_as_chicago_citation, #export_as_endnote, #export_as_mla_citation, #export_as_openurl_ctx_kev
Methods included from Sufia::CitationsBehaviors::TitleBehavior
#chicago_citation_title, #mla_citation_title, #process_title_parts, #setup_title_info
Methods included from Sufia::CitationsBehaviors::CommonBehavior
#clean_end_punctuation, #persistent_url
Methods included from Sufia::CitationsBehaviors::NameBehavior
#abbreviate_name, #all_authors, #author_list, #given_name_first, #surname_first
Methods included from Sufia::CitationsBehaviors::PublicationBehavior
#setup_pub_date, #setup_pub_info, #setup_pub_place, #setup_pub_publisher
Methods included from Sufia::BlacklightOverride
#fields_to_exclude_from_constraint_element
Instance Attribute Details
#unfollowee ⇒ Object
Returns the value of attribute unfollowee.
3 4 5 |
# File 'app/jobs/user_unfollow_event_job.rb', line 3 def unfollowee @unfollowee end |
#unfollower ⇒ Object
Returns the value of attribute unfollower.
3 4 5 |
# File 'app/jobs/user_unfollow_event_job.rb', line 3 def unfollower @unfollower end |
Instance Method Details
#action ⇒ Object
17 18 19 |
# File 'app/jobs/user_unfollow_event_job.rb', line 17 def action "User #{link_to_profile unfollower} has unfollowed #{link_to_profile unfollowee}" end |
#log_user_event(_unfollower) ⇒ Object
log the event to the users event stream
12 13 14 15 |
# File 'app/jobs/user_unfollow_event_job.rb', line 12 def log_user_event(_unfollower) super unfollowee.log_event(event) end |
#perform(unfollower, unfollowee) ⇒ Object
5 6 7 8 9 |
# File 'app/jobs/user_unfollow_event_job.rb', line 5 def perform(unfollower, unfollowee) @unfollower = unfollower @unfollowee = unfollowee super(unfollower) end |