Skip to content
This repository has been archived by the owner on Aug 15, 2018. It is now read-only.

Commit

Permalink
fixed a named_scope warning in page model, merged in cgrusden's test-…
Browse files Browse the repository at this point in the history
…related updates
  • Loading branch information
Josh Adams committed Jan 15, 2009
1 parent 42e81f3 commit 4a337b8
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 82 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Expand Up @@ -20,5 +20,7 @@ public/photo_album_photo_images/
public/photo_album_photo_images/*
public/uploads/*/*
themes/*
public/themes
public/themes/*
config/deploy.rb
public/ansuz_themes.xml
2 changes: 1 addition & 1 deletion app/models/page.rb
Expand Up @@ -22,7 +22,7 @@
class Page < ActiveRecord::Base
include AASM
include ActionView::Helpers::DateHelper
named_scope :visible, lambda {|p| { :conditions => ["published = ? AND (publish_at <= ? OR publish_at IS NULL )", true, Time.now.getgm] } }
named_scope :visible, { :conditions => ["published = ? AND (publish_at <= ? OR publish_at IS NULL )", true, Time.now.getgm] }
named_scope :self_and_siblings, lambda {|page| {:conditions => ["parent_id = ?", page.parent_id], :order => 'page_order'}}

aasm_column :status
Expand Down
1 change: 1 addition & 0 deletions config/environment.rb
Expand Up @@ -46,6 +46,7 @@
:source => 'http://gems.github.com'

config.gem 'rubyist-aasm', :version => '~> 2.0.2', :lib => 'aasm', :source => "http://gems.github.com"
config.gem 'mocha'

# Only load the plugins named here, in the order given. By default, all plugins
# in vendor/plugins are loaded in alphabetical order.
Expand Down
81 changes: 0 additions & 81 deletions db/schema.rb
Expand Up @@ -11,32 +11,6 @@

ActiveRecord::Schema.define(:version => 20090103012646) do

create_table "ansuz_themes", :force => true do |t|
t.string "name"
t.string "repository_url"
t.datetime "created_at"
t.datetime "updated_at"
end

create_table "blog_comments", :force => true do |t|
t.string "author"
t.string "email"
t.string "website"
t.text "text"
t.integer "blog_post_id"
t.datetime "created_at"
t.datetime "updated_at"
end

create_table "blog_posts", :force => true do |t|
t.string "title"
t.text "contents"
t.integer "created_by"
t.datetime "created_at"
t.datetime "updated_at"
t.string "url"
end

create_table "content_section_versions", :force => true do |t|
t.integer "content_section_id"
t.integer "version"
Expand All @@ -55,12 +29,6 @@
t.integer "version", :default => 1
end

create_table "feed_readers", :force => true do |t|
t.string "name"
end

add_index "feed_readers", ["name"], :name => "index_feed_readers_on_name"

create_table "form_builder_responses", :force => true do |t|
t.integer "form_builder_id"
t.datetime "created_at"
Expand Down Expand Up @@ -108,28 +76,6 @@
t.text "description_html"
end

create_table "fyles", :force => true do |t|
t.string "mime_type"
t.string "file_name"
t.datetime "created_at"
t.datetime "updated_at"
end

create_table "has_settings_settings", :force => true do |t|
t.text "settings"
t.integer "configurable_id"
t.string "configurable_type"
end

create_table "menu_entries", :force => true do |t|
t.string "name"
t.string "link"
t.integer "position"
t.integer "parent_id"
t.datetime "created_at"
t.datetime "updated_at"
end

create_table "moderatorships", :force => true do |t|
t.integer "forum_id"
t.integer "user_id"
Expand Down Expand Up @@ -196,7 +142,6 @@

create_table "photo_albums", :force => true do |t|
t.string "name"
t.string "display_type"
end

create_table "posts", :force => true do |t|
Expand All @@ -213,20 +158,11 @@
add_index "posts", ["topic_id", "created_at"], :name => "index_posts_on_topic_id"
add_index "posts", ["user_id", "created_at"], :name => "index_posts_on_user_id"

create_table "proto_page_plugin_versions", :force => true do |t|
t.integer "content_section_id"
t.integer "version"
t.string "name"
t.datetime "updated_at"
t.string "versioned_type"
end

create_table "proto_page_plugins", :force => true do |t|
t.string "name"
t.string "type"
t.datetime "created_at"
t.datetime "updated_at"
t.integer "version"
end

create_table "roles", :force => true do |t|
Expand All @@ -244,16 +180,6 @@
t.datetime "updated_at"
end

create_table "scrollable_content_sections", :force => true do |t|
t.integer "scrollable_content_id"
t.string "title"
t.text "contents"
end

create_table "scrollable_contents", :force => true do |t|
t.string "name"
end

create_table "site_settings", :force => true do |t|
t.string "name"
t.string "user_theme_name"
Expand Down Expand Up @@ -284,13 +210,6 @@
add_index "tags", ["name"], :name => "index_tags_on_name"
add_index "tags", ["taggings_count"], :name => "index_tags_on_taggings_count"

create_table "testimonials", :force => true do |t|
t.text "content"
t.string "attributed_to"
t.datetime "created_at"
t.datetime "updated_at"
end

create_table "topics", :force => true do |t|
t.integer "forum_id"
t.integer "user_id"
Expand Down
1 change: 1 addition & 0 deletions vendor/plugins/haml/init.rb
Expand Up @@ -4,4 +4,5 @@
require 'haml' # From gem
end

# Load Haml and Sass
Haml.init_rails(binding)

0 comments on commit 4a337b8

Please sign in to comment.