summaryrefslogtreecommitdiff
path: root/app/views/characters
diff options
context:
space:
mode:
Diffstat (limited to 'app/views/characters')
-rw-r--r--app/views/characters/items/index.html.erb36
1 files changed, 36 insertions, 0 deletions
diff --git a/app/views/characters/items/index.html.erb b/app/views/characters/items/index.html.erb
new file mode 100644
index 0000000..e313f7e
--- /dev/null
+++ b/app/views/characters/items/index.html.erb
@@ -0,0 +1,36 @@
+<h1 class="text-xl">Inventory</h1>
+
+<table class="table-auto">
+ <thead>
+ <tr>
+ <th class="table-header-padded">Amount</th>
+ <th class="table-header-padded">Item</th>
+ <th class="table-header-padded">Equip</th>
+ <th class="table-header-padded">Use</th>
+ <th class="table-header-padded">Destroy</th>
+ </tr>
+ </thead>
+ <tbody>
+ <% @character_items.ordered_by_item_name.each do |ci| %>
+ <tr>
+ <td class="table-cell-padded text-right"><%= ci.quantity %></td>
+ <td class="table-cell-padded"><%= ci.item.name %></td>
+ <td class="table-cell-padded">
+ <% if ci.item.equip_slot %>
+ <%= link_to "[Equip]", "#" %>
+ <% end %>
+ </td>
+ <td class="table-cell-padded">
+ <% if ci.item.usable? %>
+ <%= link_to "[Use]", "#" %>
+ <% end %>
+ </td>
+ <td class="table-cell-padded">
+ <%= link_to "[Destroy]", "#" %>
+ <%= link_to "[Destroy All]", "#" %>
+ </td>
+ </tr>
+ <% end %>
+ </tbody>
+</table>
+