app/models/page.rb in locomotive_cms-0.0.3.1 vs app/models/page.rb in locomotive_cms-0.0.3.3
- old
+ new
@@ -4,10 +4,11 @@
## Extensions ##
include Models::Extensions::Page::Tree
include Models::Extensions::Page::Parts
include Models::Extensions::Page::Render
+ include Models::Extensions::Page::Templatized
## fields ##
field :title
field :slug
field :fullpath
@@ -29,11 +30,11 @@
validates_uniqueness_of :slug, :scope => [:site_id, :parent_id]
validates_exclusion_of :slug, :in => Locomotive.config.reserved_slugs, :if => Proc.new { |p| p.depth == 0 }
## named scopes ##
named_scope :latest_updated, :order_by => [[:updated_at, :desc]], :limit => Locomotive.config.lastest_items_nb
- named_scope :index, :where => { :slug => 'index', :depth => 0, :published => true }
- named_scope :not_found, :where => { :slug => '404', :depth => 0, :published => true }
+ named_scope :index, :where => { :slug => 'index', :depth => 0 }
+ named_scope :not_found, :where => { :slug => '404', :depth => 0 }
named_scope :published, :where => { :published => true }
## behaviours ##
liquify_template :joined_parts
\ No newline at end of file