Class: SocialNetworking::ActionItem

Inherits:
Object
  • Object
show all
Defined in:
app/models/social_networking/action_item.rb

Overview

A helper for aggregating “todo” items.

Class Attribute Summary collapse

Class Method Summary collapse

Class Attribute Details

.source_class_name=(value) ⇒ Object (writeonly)

Sets the attribute source_class_name

Parameters:

  • value

    the value to set the attribute source_class_name to.



6
7
8
# File 'app/models/social_networking/action_item.rb', line 6

def source_class_name=(value)
  @source_class_name = value
end

Class Method Details

.for(participant) ⇒ Object



8
9
10
11
12
# File 'app/models/social_networking/action_item.rb', line 8

def for(participant)
  return [] if @source_class_name.nil?

  @source_class_name.constantize.for(participant)
end