refinerycms 0.9.1 → 0.9.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/lib/refinery_initializer.rb
CHANGED
@@ -1,4 +1,7 @@
|
|
1
|
-
|
1
|
+
# Get library path without '..' directories.
|
2
|
+
dir_parts = (File.join File.dirname(__FILE__), '..').split(File::SEPARATOR)
|
3
|
+
dir_parts = dir_parts[0..(dir_parts.length-3)] until dir_parts[dir_parts.length-1] != ".."
|
4
|
+
REFINERY_ROOT = File.join dir_parts
|
2
5
|
|
3
6
|
unless REFINERY_ROOT == RAILS_ROOT # e.g. only if we're in a gem.
|
4
7
|
$LOAD_PATH.unshift "#{REFINERY_ROOT}/vendor/plugins"
|
@@ -2,6 +2,14 @@ class Admin::PagesController < Admin::BaseController
|
|
2
2
|
|
3
3
|
crudify :page, :conditions => "parent_id IS NULL", :order => "position ASC", :include => [:parts, :slugs, :children, :images]
|
4
4
|
|
5
|
+
def index
|
6
|
+
if searching?
|
7
|
+
@pages = Page.find_with_index params[:search]
|
8
|
+
else
|
9
|
+
@pages = Page.find_all_by_parent_id(nil, :order => "position ASC")
|
10
|
+
end
|
11
|
+
end
|
12
|
+
|
5
13
|
def new
|
6
14
|
@page = Page.new
|
7
15
|
RefinerySetting.find_or_set(:default_page_parts, ["body", "side_body"]).each do |page_part|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: refinerycms
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.9.1
|
4
|
+
version: 0.9.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Resolve Digital
|
@@ -11,7 +11,7 @@ autorequire:
|
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
13
|
|
14
|
-
date: 2009-10-
|
14
|
+
date: 2009-10-06 00:00:00 +13:00
|
15
15
|
default_executable:
|
16
16
|
dependencies:
|
17
17
|
- !ruby/object:Gem::Dependency
|