OSDN Git Service

t#32046:
[pettanr/pettanr.git] / app / views / stories / comic.html.erb
1 <% @page_title = @comic.title %>
2 <h1><%= t '.title' -%></h1>
3 <p id="notice"><%= notice %></p>
4 <%= render 'comic_header', :comic => @comic, :author => @author %>
5
6 <% if @stories.empty? -%>
7   <h2><%= t('stories.comic.empty') %></h2>
8 <% else %>
9   <% @stories.each do |story| %>
10     <% if story.panel -%>
11       <%= render 'panels/body', :panel => story.panel, :author => @author, :spot => nil %>
12     <% end %>
13     <%= render 'footer', :story => story, :author => @author %>
14   <% end %>
15   <%= render 'licensed_pictures', :licensed_pictures => Story.licensed_pictures(@stories) %>
16
17   <% if @prev_offset -%>
18     <%= link_to h('<<prev'), comic_story_path(@comic, {:offset => @prev_offset, :count => @panel_count}) %>
19   <% end %>
20
21   <% if @next_offset -%>
22     <%= link_to h('next>>'), comic_story_path(@comic, {:offset => @next_offset, :count => @panel_count}) %>
23   <% end %>
24
25 <% end %>
26 <% if @comic.own? @author -%>
27   <h3><%= t('stories.comic.new_panels') -%></h3>
28   <table>
29     <% @new_panels.each do |panel| %>
30       <%= render 'append_panel', :comic => @comic, :panel => panel, :author => @author %>
31     <% end %>
32   </table>
33 <% end %>