diff --git a/app/models/booth.rb b/app/models/booth.rb index 71ab6e98..14740745 100644 --- a/app/models/booth.rb +++ b/app/models/booth.rb @@ -25,10 +25,15 @@ class Booth < ApplicationRecord :state, :responsibles, :conference_id, + :email, :website_url, :submitter_relationship, presence: true + validates :accepted_code_of_conduct, acceptance: { + if: -> { conference.try(:code_of_conduct).present? } + } + scope :accepted, -> { where(state: 'accepted') } scope :confirmed, -> { where(state: 'confirmed') }