Displaying 3 results from an estimated 3 matches for "validates_email_format_of".
2011 Sep 27
0
accepts_nested_attributes_for is not working for uniqueness
class User < ActiveRecord::Base
accepts_nested_attributes_for :emails, :allow_destroy => true,
:reject_if => proc { |attributes| attributes[''address''].blank? }
end
class Email < ActiveRecord::Base
belongs_to :user
validates_presence_of :address
validates_email_format_of :address
validates_uniqueness_of :address, :scope=>''user_id''
end
when i am saving multiple same emails at one time it is saving , but it
should not
Please suggest what i am missing
Thanks
Rajeev sharma
--
You received this message because you are subscribed to the Goo...
2011 Nov 21
1
uninitialized constant Sass::Script::Functions::EvaluationContext
...7''
config.gem "haml", :version => ">=3.0.0"
config.gem "friendly_id"
config.gem "will_paginate"
config.gem ''sanitize''
config.gem "paperclip"
config.gem ''fastercsv''
config.gem ''validates_email_format_of''
config.middleware.use "Sass::Plugin::Rack"
with rails 2.3.8... another application, with the same sass code and
environment, works fine! What''s the deal?
Attachments:
http://www.ruby-forum.com/attachment/6773/haml_sass
--
Posted via http://www.ruby-forum.com/....
2013 Apr 15
3
No validation_context methods in Rails API. What for are they?
There is no validation_context methods in API. But the instance has
them:
validation_context
validation_context=
What are these methods? What do they do? Where to get info about them?
--
Posted via http://www.ruby-forum.com/.
--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving