nuking out routes, leaving basic crud
Oleg
committed Aug 27, 2010
commit 8ba942cb7c6ce48c408d951bc84fe4650ac44660
Showing 5
changed files with
45 additions
and 91 deletions
Gemfile
+1
-5
| @@ | @@ -1,10 +1,6 @@ |
| source 'http://rubygems.org' | |
| - | gem 'rails', '3.0.0.rc' |
| + | gem 'rails', '3.0.0.rc2' |
| gem 'sqlite3-ruby', :require => 'sqlite3' | |
| gem 'active_link_to', '>=0.0.6' | |
| - | |
| - | group :test do |
| - | gem 'redgreen' |
| - | end |
Gemfile.lock
+34
-36
| @@ | @@ -2,34 +2,34 @@ GEM |
| remote: http://rubygems.org/ | |
| specs: | |
| abstract (1.0.0) | |
| - | actionmailer (3.0.0.rc) |
| - | actionpack (= 3.0.0.rc) |
| + | actionmailer (3.0.0.rc2) |
| + | actionpack (= 3.0.0.rc2) |
| mail (~> 2.2.5) | |
| - | actionpack (3.0.0.rc) |
| - | activemodel (= 3.0.0.rc) |
| - | activesupport (= 3.0.0.rc) |
| + | actionpack (3.0.0.rc2) |
| + | activemodel (= 3.0.0.rc2) |
| + | activesupport (= 3.0.0.rc2) |
| builder (~> 2.1.2) | |
| erubis (~> 2.6.6) | |
| i18n (~> 0.4.1) | |
| rack (~> 1.2.1) | |
| - | rack-mount (~> 0.6.9) |
| + | rack-mount (~> 0.6.12) |
| rack-test (~> 0.5.4) | |
| - | tzinfo (~> 0.3.22) |
| + | tzinfo (~> 0.3.23) |
| active_link_to (0.0.6) | |
| - | activemodel (3.0.0.rc) |
| - | activesupport (= 3.0.0.rc) |
| + | activemodel (3.0.0.rc2) |
| + | activesupport (= 3.0.0.rc2) |
| builder (~> 2.1.2) | |
| i18n (~> 0.4.1) | |
| - | activerecord (3.0.0.rc) |
| - | activemodel (= 3.0.0.rc) |
| - | activesupport (= 3.0.0.rc) |
| - | arel (~> 0.4.0) |
| - | tzinfo (~> 0.3.22) |
| - | activeresource (3.0.0.rc) |
| - | activemodel (= 3.0.0.rc) |
| - | activesupport (= 3.0.0.rc) |
| - | activesupport (3.0.0.rc) |
| - | arel (0.4.0) |
| + | activerecord (3.0.0.rc2) |
| + | activemodel (= 3.0.0.rc2) |
| + | activesupport (= 3.0.0.rc2) |
| + | arel (~> 1.0.0.rc1) |
| + | tzinfo (~> 0.3.23) |
| + | activeresource (3.0.0.rc2) |
| + | activemodel (= 3.0.0.rc2) |
| + | activesupport (= 3.0.0.rc2) |
| + | activesupport (3.0.0.rc2) |
| + | arel (1.0.0.rc1) |
| activesupport (>= 3.0.0.beta) | |
| builder (2.1.2) | |
| erubis (2.6.6) | |
| @@ | @@ -42,36 +42,34 @@ GEM |
| mime-types (1.16) | |
| polyglot (0.3.1) | |
| rack (1.2.1) | |
| - | rack-mount (0.6.9) |
| + | rack-mount (0.6.12) |
| rack (>= 1.0.0) | |
| rack-test (0.5.4) | |
| rack (>= 1.0) | |
| - | rails (3.0.0.rc) |
| - | actionmailer (= 3.0.0.rc) |
| - | actionpack (= 3.0.0.rc) |
| - | activerecord (= 3.0.0.rc) |
| - | activeresource (= 3.0.0.rc) |
| - | activesupport (= 3.0.0.rc) |
| - | bundler (>= 1.0.0.rc.1) |
| - | railties (= 3.0.0.rc) |
| - | railties (3.0.0.rc) |
| - | actionpack (= 3.0.0.rc) |
| - | activesupport (= 3.0.0.rc) |
| + | rails (3.0.0.rc2) |
| + | actionmailer (= 3.0.0.rc2) |
| + | actionpack (= 3.0.0.rc2) |
| + | activerecord (= 3.0.0.rc2) |
| + | activeresource (= 3.0.0.rc2) |
| + | activesupport (= 3.0.0.rc2) |
| + | bundler (>= 1.0.0.rc.6) |
| + | railties (= 3.0.0.rc2) |
| + | railties (3.0.0.rc2) |
| + | actionpack (= 3.0.0.rc2) |
| + | activesupport (= 3.0.0.rc2) |
| rake (>= 0.8.3) | |
| thor (~> 0.14.0) | |
| rake (0.8.7) | |
| - | redgreen (1.2.2) |
| - | sqlite3-ruby (1.2.5) |
| + | sqlite3-ruby (1.3.1) |
| thor (0.14.0) | |
| treetop (1.4.8) | |
| polyglot (>= 0.3.1) | |
| - | tzinfo (0.3.22) |
| + | tzinfo (0.3.23) |
| PLATFORMS | |
| ruby | |
| DEPENDENCIES | |
| active_link_to (>= 0.0.6) | |
| - | rails (= 3.0.0.rc) |
| - | redgreen |
| + | rails (= 3.0.0.rc2) |
| sqlite3-ruby | |
app/controllers/cms_content_controller.rb
+3
-1
| @@ | @@ -1,5 +1,7 @@ |
| class CmsContentController < ApplicationController | |
| - | # TODO |
| + | def render_page |
| + | # TODO |
| + | end |
| end | |
config/initializers/cms.rb
+0
-15
| @@ | @@ -1,15 +0,0 @@ |
| - | require 'comfortable_mexican_sofa' |
| - | ### CMS Configuration |
| - | # Available configuration options: |
| - | |
| - | # http_auth_enabled: enable authentication or not. Default: true |
| - | # http_auth_username: the username for /cms-admin. Default: username |
| - | # http_auth_password: the password for /cms-admin Default: password |
| - | # cms_title: If set, this overrides the randomly changing CMS title. Only set this if you're boring. Default: not set |
| - | # |
| - | ComfortableMexicanSofa.config do |config| |
| - | # #config.http_auth_enabled = true |
| - | # #config.http_auth_username = 'some_other_username' |
| - | # #config.http_auth_password = 'some_other_password' |
| - | # #config.cms_title = 'some_other_boring_title' |
| - | end |
| \ No newline at end of file | |
config/routes.rb
+7
-34
| @@ | @@ -1,38 +1,11 @@ |
| Rails.application.routes.draw do | |
| - | scope '/cms-admin', :module => 'cms_admin', :as => 'cms_admin' do |
| - | match '/', :to => "base#index" |
| - | resources :layouts do |
| - | collection do |
| - | put :reorder |
| - | end |
| - | |
| - | member do |
| - | match :toggle |
| - | match :children |
| - | end |
| - | end |
| - | |
| - | resources :pages do |
| - | collection do |
| - | put :reorder |
| - | end |
| - | |
| - | member do |
| - | match :toggle |
| - | match :form_blocks |
| - | end |
| - | end |
| - | |
| - | resources :snippets do |
| - | collection do |
| - | put :reorder |
| - | end |
| - | end |
| - | end |
| - | controller :cms_content do |
| - | match '/sitemap.xml', :to => :sitemap |
| - | match '*path', :to => :show |
| - | root :to => :show |
| + | namespace :cms_admin do |
| + | resources :layouts |
| + | resources :pages |
| + | resources :snippets |
| end | |
| + | |
| + | match '*cms_path', :to => 'cms_content#render_page', :via => :get |
| + | |
| end | |