class Tag
Attributes
id[R]
post_id[R]
relevances[RW]
Public Class Methods
new(id = nil, post_id = nil)
click to toggle source
# File actionview/test/lib/controller/fake_models.rb, line 106 def initialize(id = nil, post_id = nil); @id, @post_id = id, post_id end
Public Instance Methods
persisted?()
click to toggle source
# File actionview/test/lib/controller/fake_models.rb, line 109 def persisted?; @id.present? end
relevances_attributes=(attributes)
click to toggle source
# File actionview/test/lib/controller/fake_models.rb, line 116 def relevances_attributes=(attributes); end
save()
click to toggle source
# File actionview/test/lib/controller/fake_models.rb, line 108 def save; @id = 1; @post_id = 1 end
to_key()
click to toggle source
# File actionview/test/lib/controller/fake_models.rb, line 107 def to_key; id ? [id] : nil end
to_param()
click to toggle source
# File actionview/test/lib/controller/fake_models.rb, line 110 def to_param; @id && @id.to_s; end
value()
click to toggle source
# File actionview/test/lib/controller/fake_models.rb, line 111 def value @id.nil? ? "new #{self.class.name.downcase}" : "#{self.class.name.downcase} ##{@id}" end