_reading.html.erb 587 Bytes
<tr>
  <td><%= reading.label %></td>
  <td><%= reading.grade %></td>
  <td style="background-color: #<%= reading.color %>; width: 20%;">&nbsp;</td>
  <% if reading_groups_owner? @reading_group.id %>
    <td>
      <%= link_to t('edit'), edit_reading_group_reading_path(@reading_group.id, reading.id), class: 'btn btn-info' %>
    </td>
    <td>
      <%= link_to t('destroy'), reading_group_reading_path(@reading_group.id, reading.id), method: :delete, data: { confirm: t('sure_destroy', model: Reading.model_name.human) }, class: 'btn btn-danger' %>
    </td>
    </td>
 <% end %>
</tr>