app/models/tramway/landing/block.rb in tramway-landing-1.1.3.1 vs app/models/tramway/landing/block.rb in tramway-landing-1.2
- old
+ new
@@ -1,7 +1,10 @@
class Tramway::Landing::Block < ::Tramway::Landing::ApplicationRecord
- enumerize :block_type, in: [ :header, :footer, :page, :cards, :features, :contacts, :news ]
+ belongs_to :link_object, polymorphic: true
+
+ enumerize :block_type, in: [ :header, :footer, :page, :cards, :features, :contacts, :news, :link ]
enumerize :navbar_link, in: [ :exist, :not_exist ], default: :not_exist
+ enumerize :link_object_type, in: [ 'Tramway::SportSchool::Document' ]
mount_uploader :background, PhotoUploader
state_machine :view_state, initial: :published do
state :published