You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
29 lines
591 B
29 lines
591 B
<h1>Listing bikes</h1>
|
|
|
|
<table>
|
|
<thead>
|
|
<tr>
|
|
<th> Brand </th>
|
|
<th> Model </th>
|
|
<th></th>
|
|
<th></th>
|
|
<th></th>
|
|
</tr>
|
|
</thead>
|
|
|
|
<tbody>
|
|
<% @bikes.each do |bike| %>
|
|
<tr>
|
|
<td><%= bike.brand %></td>
|
|
<td><%= bike.model %></td>
|
|
<td><%= link_to 'Show', bike %></td>
|
|
<td><%= link_to 'Edit', edit_bike_path(bike) %></td>
|
|
<td><%= link_to 'Destroy', bike, method: :delete, data: { confirm: 'Are you sure?' } %></td>
|
|
</tr>
|
|
<% end %>
|
|
</tbody>
|
|
</table>
|
|
|
|
<br>
|
|
|
|
<%= link_to 'New Bike', new_bike_path %>
|
|
|