Page Resources allows you to relate one or more resources to any page in Refinery.
- refinerycms >= 2.1.0
- Ability to select one or more resources from the resource picker and relate them to a page
- Reordering support, simply drag into order
Add this line to your applications Gemfile
gem 'refinerycms-page-resources'
Next run
bundle install
rails generate refinery:page_resources
rake db:migrate
Now when you start up your Refinery application, edit a page and there should be a new "Resources" tab.
app/views/refinery/pages/show.html.erb
<% content_for :body_content_right do %>
<ul id='files'>
<% @page.resources.each do |file| %>
<li>
<%= link_to file.title, file.url %>
</li>
<% end %>
</ul>
<% end %>
<%= render :partial => "/refinery/content_page" %>