Module: Rubix::Associations::BelongsToAction

Defined in:
lib/rubix/associations/belongs_to_action.rb

Instance Method Summary collapse

Instance Method Details

#actionObject



12
13
14
# File 'lib/rubix/associations/belongs_to_action.rb', line 12

def action
  @action
end

#action=(a) ⇒ Object



6
7
8
9
10
# File 'lib/rubix/associations/belongs_to_action.rb', line 6

def action= a
  return unless a
  @action    = a
  @action_id = a.id
end

#action_idObject



21
22
23
24
25
# File 'lib/rubix/associations/belongs_to_action.rb', line 21

def action_id
  return @action_id if @action_id
  return unless @action
  @action_id = @action.id
end

#action_id=(aid) ⇒ Object



16
17
18
19
# File 'lib/rubix/associations/belongs_to_action.rb', line 16

def action_id= aid
  return unless aid
  @action_id = aid
end