instance method
id=
Ruby on Rails 2.3.18
Since v2.2.3 Last seen in v2.3.18Available in: v2.2.3 v2.3.18
Signature
id=(value)
Sets the primary ID.
Parameters
-
valuereq
Source
# File activerecord/lib/active_record/base.rb, line 2558
def id=(value)
write_attribute(self.class.primary_key, value)
end
Defined in activerecord/lib/active_record/base.rb line 2558
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActiveRecord::Base