metamaps--metamaps/app/views/items/show.html.erb

63 lines
1.6 KiB
Text
Raw Normal View History

2012-09-23 02:39:12 +00:00
<div class="focus">
<div class="focusleft">
<p><%= @item.item_category.name %></p>
2012-10-04 01:40:26 +00:00
<%= image_tag @item.item_category.icon, :class => 'icon', :size => '50x50' %>
2012-09-23 02:39:12 +00:00
</div>
<div class="focusmiddle">
2012-09-24 01:30:48 +00:00
<h1 class="title"><%= @item.name %> <%= link_to "[edit]", edit_item_path(@item) %></h1>
2012-09-23 02:39:12 +00:00
<div class="desc">
<p><%= @item.desc %></p>
</div>
</div>
<div class="focusright">
<p>Link</p>
<%= link_to @item.link, @item.link, :class => 'link' %>
</div>
</div>
<div class="clearfloat nodemargin"></div>
<div class="groups">
2012-09-24 01:30:48 +00:00
<div class="divider"><%= @item.name %> is included in these groups</div>
2012-09-23 02:39:12 +00:00
<% @gparents.each do |group| %>
<%= render group %>
<% end %>
<% if @gparents.empty? %>
2012-09-24 01:30:48 +00:00
<p class="empty">Shucks, there are no groups.</p>
2012-09-23 02:39:12 +00:00
<% end %>
</div>
<div class="clearfloat"></div>
<div class="parents">
2012-09-24 01:30:48 +00:00
<div class="divider"><%= @item.name %> is included by these people</div>
2012-09-23 02:39:12 +00:00
<% @pparents.each do |person| %>
<%= render person %>
<% end %>
<% if @pparents.empty? %>
2012-09-24 01:30:48 +00:00
<p class="empty">Shucks, there are no people.</p>
2012-09-23 02:39:12 +00:00
<% end %>
</div>
<div class="clearfloat"></div>
<div class="items">
2012-09-24 01:30:48 +00:00
<div class="divider"><%= @item.name %> is included by these items</div>
2012-09-23 02:39:12 +00:00
<% @iparents.each do |item| %>
<%= render item %>
<% end %>
<% if @iparents.empty? %>
2012-09-24 01:30:48 +00:00
<p class="empty">Shucks, there are no items.</p>
2012-09-23 02:39:12 +00:00
<% end %>
</div>
<div class="clearfloat"></div>
<div class="items">
2012-09-24 01:30:48 +00:00
<div class="divider"><%= @item.name %> includes these items</div>
2012-09-23 02:39:12 +00:00
<% @ichildren.each do |item| %>
<%= render item %>
<% end %>
<% if @ichildren.empty? %>
2012-09-24 01:30:48 +00:00
<p class="empty">Shucks, there are no items.</p>
2012-09-23 02:39:12 +00:00
<% end %>
</div>
<div class="clearfloat"></div>