在一个模型中,我有以下验证:
validates_presence_of :company_name, :message => "Must have a company name"
validates_uniqueness_of :company_name, :message => "Does this company exist? As this company name isn't unique."
这是否意味着它会在唯一性之前检查公司名称的存在?
在一个模型中,我有以下验证:
validates_presence_of :company_name, :message => "Must have a company name"
validates_uniqueness_of :company_name, :message => "Does this company exist? As this company name isn't unique."
这是否意味着它会在唯一性之前检查公司名称的存在?