Refactor admin/call_for_booth controller
This commit is contained in:
parent
9103f511a7
commit
318c0d15a4
17 changed files with 182 additions and 18 deletions
|
|
@ -4,13 +4,13 @@ class Booth < ActiveRecord::Base
|
|||
has_many :users, through: :booth_requests
|
||||
|
||||
validates :title,
|
||||
uniqueness: { case_sensitive: fasle},
|
||||
uniqueness: { case_sensitive: false },
|
||||
presence: true
|
||||
|
||||
validates :description,
|
||||
:reasoning,
|
||||
:state,
|
||||
:logo_link
|
||||
:logo_link,
|
||||
:conference_id,
|
||||
presence: true
|
||||
end
|
||||
|
|
|
|||
|
|
@ -1,8 +1,6 @@
|
|||
class CallForBooth < ActiveRecord::Base
|
||||
belongs_to :conference
|
||||
|
||||
has_one :conference
|
||||
|
||||
validates :start_date, :end_date, :booth_limit, presence: true
|
||||
validate :before_end_of_conference
|
||||
validate :start_date_before_end_date
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue