OSDN Git Service

t30329#:i18n flash message
[pettanr/pettanr.git] / app / views / stories / comic.html.erb
1 <h1><%= t '.title' -%></h1>
2 <p id="notice"><%= notice %></p>
3 <%= render 'comic_header', :comic => @comic, :author => @author %>
4
5 <% if @stories.empty? -%>
6   <h2><%= t('stories.comic.empty') %></h2>
7 <% else %>
8   <% @stories.each do |story| %>
9     <% if story.panel -%>
10       <%= render 'panels/body', :panel => story.panel, :author => @author %>
11     <% end %>
12     <%= render 'footer', :story => story, :author => @author %>
13   <% end %>
14   <%= render 'licensed_pictures', :licensed_pictures => Story.licensed_pictures(@stories) %>
15 <% end %>
16 <% if @comic.own? @author -%>
17   <h3><%= t('stories.new.title') %></h3>
18   <% @story = Story.new ; @story.comic_id = @comic.id ; @story.t = Story.new_t @comic.id -%>
19   <%= form_for(@story) do |f| %>
20
21     <div class="field">
22       <%= f.hidden_field :comic_id %>
23     </div>
24     <div class="field">
25       <%= f.label :t %><br />
26       <%= f.number_field :t %>
27     </div>
28     <div class="field">
29       <%= f.label :panel_id %><br />
30       <%= f.number_field :panel_id %>
31     </div>
32
33     <div class="actions">
34       <%= f.submit %>
35     </div>
36   <% end %>
37 <% end %>