Class: ShowcaseFaq

Inherits:
ApplicationRecord show all
Defined in:
app/models/showcase_faq.rb

Overview

== Schema Information

Table name: showcase_faqs
Database name: primary

id :bigint not null, primary key
answer :text
position :integer default(999)
question :string not null
created_at :datetime not null
updated_at :datetime not null
showcase_id :bigint not null

Indexes

index_showcase_faqs_on_showcase_id_and_position (showcase_id,position)

Foreign Keys

fk_rails_... (showcase_id => showcases.id)

Instance Attribute Summary collapse

Belongs to collapse

Methods inherited from ApplicationRecord

ransackable_associations, ransackable_attributes, ransackable_scopes, ransortable_attributes, #to_relation

Methods included from Models::EventPublishable

#publish_event

Instance Attribute Details

#answerObject (readonly)



70
# File 'app/models/showcase_faq.rb', line 70

validates :question, :answer, presence: true

#questionObject (readonly)



70
# File 'app/models/showcase_faq.rb', line 70

validates :question, :answer, presence: true

Instance Method Details

#showcaseShowcase

Returns:

See Also:



68
# File 'app/models/showcase_faq.rb', line 68

belongs_to :showcase