pdf collection. links for pdf
This commit is contained in:
parent
af589525c9
commit
a887a5e67d
|
@ -24,6 +24,7 @@
|
|||
|
||||
<% content_for :action_links do %>
|
||||
<% if has_role?("admin") %>
|
||||
<%= link_to "PDF", album_path(@album, :format => 'pdf') %> |
|
||||
<%= link_to "Edit album", edit_album_path(@album) %> |
|
||||
<%= link_to "Edit all photos", edit_multiple_album_photos_path(@album) %> |
|
||||
<%= link_to "Add photos", upload_album_photos_path(@album) %>
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
<h1><%= @album.title %></h1>
|
||||
|
||||
<%= render :partial => @album.photos.find(:all, :limit => 10) %>
|
||||
<%= render :partial => @album.photos %>
|
|
@ -15,6 +15,7 @@
|
|||
|
||||
<% content_for :action_links do %>
|
||||
<% if has_role?("admin") %>
|
||||
<%= link_to "PDF", collection_path(@collection, :format => 'pdf') %> |
|
||||
<%= link_to "Edit collection", edit_collection_path(@collection) %> |
|
||||
<%= link_to "New album", new_collection_album_path(@collection) %>
|
||||
<% end %>
|
||||
|
|
8
app/views/collections/show.pdf.erb
Normal file
8
app/views/collections/show.pdf.erb
Normal file
|
@ -0,0 +1,8 @@
|
|||
<h2><%= h @collection.title %></h2>
|
||||
<p><%= h @collection.description %></p>
|
||||
|
||||
<% for album in @collection.albums %>
|
||||
<h3><%= album.title %></h3>
|
||||
<p><%= render :partial => album.photos %></p>
|
||||
|
||||
<% end %>
|
|
@ -1 +1 @@
|
|||
<%= image_tag photo.public_path_original %><br/>
|
||||
<%= image_tag photo.path_modified_public("single") %><br/>
|
Loading…
Reference in a new issue