19 lines
284 B
Ruby
19 lines
284 B
Ruby
class CastingCall < ApplicationRecord
|
|
belongs_to :project
|
|
has_many :casting_call_interviews, dependent: :destroy
|
|
|
|
has_secure_token
|
|
|
|
def status
|
|
if cancelled?
|
|
"Cancelled"
|
|
else
|
|
"Active"
|
|
end
|
|
end
|
|
|
|
def cancelled?
|
|
self.cancelled_at.present?
|
|
end
|
|
end
|