Add GamePlatform to Game pages
[cs356-p2-videostore.git] / app / views / game / list.rhtml
index 123e767..4528322 100644 (file)
@@ -3,8 +3,8 @@
 <table border="1">
   <tr>
     <th>Game ID</th>
-    <th>Checked Out</th>
     <th>Title</th>
+    <th>Checked Out</th>
     <th>New Release</th>
     <th>Genre</th>
     <th>Platform</th>
@@ -16,8 +16,8 @@
     <td><%=h game.title %></td>
     <td><%=h tf_to_yesno(game.checkedout?) %></td>
     <td><%=h tf_to_yesno(game.newrelease) %></td>
-    <td><%=h game.genre %></td>
-    <td><%=h game.game_platform %></td>
+    <td><%=h game.genre.name %></td>
+    <td><%=h game.platform.name %></td>
     <td><%= link_to 'View', :action => 'show', :id => game %></td>
     <td><%= link_to 'Edit', :action => 'edit', :id => game %></td>
     <td><%= link_to 'Remove', { :action => 'destroy', :id => game }, :confirm => 'Are you sure?', :method => :post %></td>