OSDN Git Service

t#31326:drop color
[pettanr/pettanr.git] / app / views / authors / ground_colors.html.erb
index 9684ca8..4395ceb 100644 (file)
@@ -3,19 +3,12 @@
 <table>
   <tr>
     <th><%= t_m 'GroundColor.panel_id' -%></th>
-    <th><%= t_m 'GroundColor.color_id' -%></th>
+    <th><%= t_m 'GroundColor.code' -%></th>
     <th><%= t_m 'GroundColor.z' -%></th>
-    <th><%= t_m 'GroundColor.created_at' -%></th>
     <th><%= t_m 'GroundColor.updated_at' -%></th>
   </tr>
 
   <% @ground_colors.each do |ground_color| %>
-    <tr>
-      <td><%= link_to gc.panel_id, panel_path(gc.panel_id) %></td>
-      <td style="color: #<%= format("%06x", gc.color.code ^ 0xffffff) -%>; background-color: #<%= format("%06x", gc.color.code) -%>;"><%= h gc.color.name %></td>
-      <td><%= gc.z %></td>
-      <td><%= distance_of_time_in_words_to_now gc.created_at %></td>
-      <td><%= distance_of_time_in_words_to_now gc.updated_at %></td>
-    </tr>
+    <%= render 'ground_colors/list_item', :ground_color => ground_color, :author => @author %>
   <% end -%>
 </table>