OSDN Git Service

add comic story
[pettanr/pettanr.git] / app / views / comics / show.html.erb
1 <% @page_title = t('.title') + ':' + @item.title %>
2 <h1><%= @item.title %></h1>
3 <p>
4   <b><%= t_m 'Comic.author_id' -%>:</b>
5   <%= link_to h(@item.author.name), author_path(@item.author) %>
6   <b><%= t_m 'Comic.updated_at' -%>:</b>
7   <%= l @item.updated_at %>
8 </p>
9
10 <p id="notice"><%= notice %></p>
11
12 <p>
13   <b><%= t_m 'Comic.description' -%>:</b>
14   <%= h(@item.description) %>
15 </p>
16
17 <div>
18   <% @comic_stories.each do |comic_story| %>
19     <% if comic_story.story -%>
20       <%= link_to comic_story.title, play_story_path(comic_story.story) %>
21     <% end %>
22   <% end %>
23 </div>
24
25 <% if @item.own? @operators -%>
26 <p>
27   <b><%= t_m 'Comic.visible' -%>:</b>
28   <%= t_selected_item('comic_visible_items', @item.visible) %>
29 </p>
30
31   <%= link_to t('link.edit'), edit_comic_path(@item) %>
32   <%= link_to t('link.destroy'), comic_path(@item), :method => :delete %>
33   <h3><%= t('comic_stories.append.new_stories') -%></h3>
34   <table>
35     <% @new_story_items.each do |story| %>
36       <%= render 'comic_stories/append_story', :story => story, :comic => @item, :operators => @operators %>
37     <% end %>
38   </table>
39 <% end %>