diff --git a/app/models/page.rb b/app/models/page.rb index 7a5f945..6cf0cb0 100644 --- a/app/models/page.rb +++ b/app/models/page.rb @@ -25,6 +25,8 @@ class Page < ActiveRecord::Base acts_as_commentable has_settings + validates_presence_of :name, :title + named_scope :visible, :conditions => ["(expires_on > ? OR expires_on IS NULL) AND published = ? AND (publish_at <= ? OR publish_at IS NULL )", Time.now.getgm, true, Time.now.getgm] named_scope :self_and_siblings, lambda {|page| {:conditions => ["parent_id = ?", page.parent_id], :order => 'page_order'}} named_scope :expired, lambda {|p| { :conditions => ["expires_on < ?", Time.now.getgm] } } diff --git a/vendor/plugins/ansuz_theme_installer/app/views/admin/ansuz_theme_installers/index.html.erb b/vendor/plugins/ansuz_theme_installer/app/views/admin/ansuz_theme_installers/index.html.erb index b7ff485..b526280 100644 --- a/vendor/plugins/ansuz_theme_installer/app/views/admin/ansuz_theme_installers/index.html.erb +++ b/vendor/plugins/ansuz_theme_installer/app/views/admin/ansuz_theme_installers/index.html.erb @@ -2,7 +2,7 @@ <% content_for :sidebar do -%> <%= link_to "Choose the theme for your site", '/admin/site_settings/choose_theme', :class => 'button icon edit' -%>