This commit is contained in:
Nicolas Bally 2020-07-09 10:44:40 +02:00
parent df67e25266
commit e4e3ba871f
2 changed files with 4 additions and 1 deletions

View File

@ -9,6 +9,6 @@ class AdminMailer < ActionMailer::Base
end end
def notify_order def notify_order
mail :to => "ducoin@jrh.fr", :subject => "Nouvelle commande enregistrée par le site", :from => "n.bally@quartz.xyz" mail :to => "jp.vallon@abela.fr", :subject => "Nouvelle commande enregistrée par le site", :from => "n.bally@quartz.xyz"
end end
end end

View File

@ -14,6 +14,9 @@ class Particular < ActiveRecord::Base
#validates :tel, :presence => true, :if => :force_validation? #validates :tel, :presence => true, :if => :force_validation?
validates :organisation, :presence => true, :if => :validate_pro validates :organisation, :presence => true, :if => :validate_pro
attr_accessor :force_validation attr_accessor :force_validation
def validate_pro def validate_pro
true if self.force_validation and self.pro true if self.force_validation and self.pro
end end