OSDN Git Service

t#32246:add sheet
[pettanr/pettanr.git] / app / views / sheet_panels / _play_header.html.erb
index 09251ee..6743faa 100644 (file)
@@ -1,21 +1,20 @@
-<% if sheet.own? author -%>
-  <%= form_for(sheet) do |f| %>
-    <div class="field">
-      <%= f.label :caption %><br />
-      <%= f.text_field :caption %>
-    </div>
-    <div class="field">
-      <%= f.label :visible %><br />
-      <%= f.collection_select :visible, t_select_items(MagicNumber['sheet_visible_items']), :last, :first, :html => {:selected => @sheet.visible} %>
-    </div>
-    <div class="actions">
-      <%= f.submit %>
-    </div>
-  <% end %>
-<% else %>
-<% end %>
-
-<div>
-  <%= link_to author_icon(:object => sheet.author, :size => 25), author_path(sheet.author) %>
-  <%= link_to h(truncate(sheet.author.name, :length => 12)), author_path(sheet.author) %>
-</div>
+<h1>
+  <%= link_to sheet_icon(:object => sheet, :size => 25), sheet_path(sheet) %>
+  <%= link_to h(sheet.caption), play_sheet_path(sheet) %>
+</h1>
+<table class="no-border" style="margin: 0px; padding: 0px; width=100%">
+  <tr>
+    <td>
+    </td>
+    <td>
+      <%= link_to author_icon(:object => sheet.author, :size => 17), author_path(sheet.author) %>
+      <%= link_to h(truncate(sheet.author.name, :length => 12)), play_sheet_path(sheet.author) %>
+    </td>
+    <td>
+      <% if sheet.own? author %>
+        <%= link_to t('link.edit'), edit_sheet_path(sheet) %>
+        <%= link_to t('link.destroy'), sheet_path(sheet), :method => :delete %>
+      <% end %>
+    </td>
+  </tr>
+</table>