wordpress-import/spec/dummy/db/seeds/refinerycms_blog.rb
Marc Remolt 1a68663552 project setup
* added refinerycms(-blog) as depencies
* removed capybara (we won't do any browsertests here)
* initialized refinery in dummy app
2011-06-01 21:07:20 +02:00

17 lines
498 B
Ruby

User.find(:all).each do |user|
user.plugins.create(:name => "refinerycms_blog",
:position => (user.plugins.maximum(:position) || -1) +1)
end
page = Page.create(
:title => "Blog",
:link_url => "/blog",
:deletable => false,
:position => ((Page.maximum(:position, :conditions => {:parent_id => nil}) || -1)+1),
:menu_match => "^/blogs?(\/|\/.+?|)$"
)
Page.default_parts.each do |default_page_part|
page.parts.create(:title => default_page_part, :body => nil)
end