Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <table>
- <tr>
- <th>Product</th>
- <th>Title</th>
- <th>Role</th>
- <th>Kind</th>
- <th>State</th>
- <th>Template</th>
- <th>AMI ID</th>
- <th>Last update</th>
- <th></th>
- </tr>
- <% @cb_templates.each do |cb_template| %>
- <tr>
- <th><%= cb_template.product ? cb_template.product.name : '' %></th>
- <td><%= cb_template.title %></td>
- <td><%= cb_template.role %></td>
- <td><%= @kind_options[cb_template.kind][0] %></td>
- <td><%= @state_options[cb_template.state][0] %></td>
- <td><%= cb_template.template_id %></td>
- <td><%= link_to cb_template.ami_id, @vdi_view_image_uri + cb_template.ami_id %></td>
- <td><%= cb_template.updated_at.strftime("%b %d, %H:%M") %></td>
- <td style="white-space: nowrap;">
- <%= link_to "Show", product %>
- <%= link_to "Edit", edit_product_path(cb_template)%>
- </td>
- </tr>
- < % end %>
- </table>
- #app/assets/stylesheets/application.css.sass
- table
- tr
- th
- width: 150px
- overflow: hidden
- text:
- overflow: ellipsis
- white:
- space: no-wrap
- <%= cb_template.product ? truncate(cb_template.product.name, length: 20) : '' %>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement