[phase-1]index view

This commit is contained in:
Toru Takahashi 2018-05-02 00:42:01 +09:00 committed by TAKAHASHI,Toru
parent 02548925a9
commit 8f01c1db2a
2 changed files with 22 additions and 0 deletions

View File

@ -1,5 +1,6 @@
class GlossaryTermsController < ApplicationController
def index
@glossary_terms = GlossaryTerm.all
end
end

View File

@ -1 +1,22 @@
<h2>GlossaryTermsController#index</h2>
<table>
<thead>
<tr>
<td>name</td>
<td>description</td>
</tr>
</thead>
<tbody>
<% @glossary_terms.each do |term| %>
<tr>
<td>
<%= term.name %>
</td>
<td>
<%= term.description %>
</td>
</tr>
<% end %>
</tbody>
</table>