<% map = @map %> <% cl = cycle('table0', 'table1') %> <%= image_tag(map.upload.url(:thumb)) %> <%=h map.title %> <% if !map.public? %>Private<% end-%>
<%=h map.description -%> <%- if map.owner -%>Uploaded by <%= link_to(map.owner.login, user_path(map.owner)) -%>.<%-end-%> Last modified <%=h time_ago_in_words(map.last_changed) -%> ago. <%if map.gcps.size > 0 %> <%=pluralize(map.gcps.size, "control point") -%>. <%else-%> Unrectified. <%end-%>
<% if map.tags.count > 0 -%> Tags: <% map.tags.each do | tag | -%> <%= link_to tag.name, { :controller=> :maps, :action => :tag, :id => tag.name } %> <% end %>
<% end -%> <%- if logged_in? -%> <%- if current_user.maps.include?(map) -%> <%= link_to 'Remove from My Maps', destroy_my_map_path(:user_id => current_user, :map_id => map), :method => :post, :confirm => "really remove this map from your list?" -%> | <%- else -%> <%= link_to 'Save to My Maps', add_my_map_path(:user_id => current_user, :map_id => map), :method => :post -%> | <%- end #if mymaps -%> <%- end # if logged in-%> <%- if map.status == :warped -%> <%- if admin_authorized? -%> | <%= link_to "Publish",{:controller => "maps", :action => "publish", :id => map}, :confirm => "Really publish this map? This will mean that no further editing can be done" -%> <%- end -%> <%- end -%> <%# render :partial => 'shared/addthis', :locals => {:title => map.title, :description =>map.description} %>