A toolkit for building modeling frameworks like Active Record.
I have the following validator: # Source: http://guides.rubyonrails.org/active_record_validations_callbacks.html#custom-validators # app/validators/email_validator.…
ruby-on-rails testing rspec validation activemodelWhen I attempt to view the user profile page, I get the error above. Here's my show.html.erb code: &…
ruby-on-rails activemodelI have a rails model which has 7 numeric attributes filled in by the user via a form. I need to …
ruby-on-rails ruby-on-rails-3 validation activemodelIs there anyone who can help me by defining the exact difference between Active Model, Active Record and Active Resource. …
ruby-on-rails-3 rails-activerecord activemodel activeresourceI am wondering how to do the association in Rails correct. First I create a City model and an Organisation. …
ruby-on-rails ruby-on-rails-3.1 activemodelHow do I get ActiveRecord attributes method functionality? I have this class: class PurchaseForm include ActiveModel::Validations include ActiveModel::Conversion …
ruby-on-rails ruby ruby-on-rails-3 activemodelHow can I write this query in Ruby on Rails? Query inside a select SELECT id, company_id, (SELECT name …
ruby-on-rails ruby ruby-on-rails-3 activerecord activemodelRails has introduced this throw(:abort) syntax, but now how do I get meaningful destroy errors ? For validation errors one …
activemodel ruby-on-rails-5I heard rails has a dirty/change flag. Is it possible to use that in the after_commit callback? In …
ruby-on-rails ruby-on-rails-3 activemodelHow cat I get list of validations defined in model Example: class ModelName validates_presence_of :field_name validates_inclusion_…
ruby-on-rails validation activemodel