I am facing sort of problem while validating .
Two models User & Product.
class User < ActiveRecord::Base
has_many :products, :dependent => :destroy
class Product < ActiveRecord::Base
validates :itemcode, :uniqueness => true
System has number of users who can insert product information with
uniqueness, but we need uniqueness validation with user_id and
itemcode.System need to check join table validation for new item with
user_id and itemcode.
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 post to this group, send email to firstname.lastname@example.org.
To unsubscribe from this group, send email to email@example.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.