OSDN Git Service

w
[pettanr/pettanr.git] / app / views / licenses / index.html.erb
index 29afe66..1347bfa 100644 (file)
@@ -1,22 +1,18 @@
-<h1>Listing licenses</h1>
-
+<h1><%= t '.title' -%></h1>
 <table>
   <tr>
-    <th>name</th>
-    <th>caption</th>
-    <th>url</th>
-    <th>created_at</th>
-    <th>updated_at</th>
-    <th></th>
+    <th><%= t_m 'License.caption' -%></th>
+    <th><%= t_m 'License.license_group_id' -%></th>
   </tr>
-
-<% @licenses.each do |license| %>
-  <tr>
-    <td><%= h license.name %></td>
-    <td><%= h license.caption %></td>
-    <td><%= h license.url %></td>
-    <td><%= license.created_at %></td>
-    <td><%= license.updated_at %></td>
-  </tr>
-<% end -%>
+  <% @licenses.each do |license| %>
+    <tr>
+      <td>
+        <%= link_to t('link.marker'), license_path(license) %>
+        <%= link_to h(license.caption), license.url %>
+      </td>
+      <td>
+        <%= link_to h(license.license_group.caption), license_group_path(license.license_group) %>
+      </td>
+    </tr>
+  <% end -%>
 </table>