1 <% content_for :heading do %>
2 <h2><%= t ".heading", :name => @trace.name %></h2>
5 <% if Settings.status != "gpx_offline" %>
6 <% if @trace.inserted %>
7 <img src="<%= url_for :controller => "traces", :action => "picture", :id => @trace.id, :display_name => @trace.user.display_name %>">
9 <span class="text-danger"><%= t ".pending" %></span>
13 <table class="table table-borderless table-sm">
15 <td><%= t ".filename" %></td>
16 <td><%= @trace.name %> (<%= link_to t(".download"), trace_data_path(@trace) %>)</td>
19 <td><%= t ".uploaded" %></td>
20 <td><%= l @trace.timestamp, :format => :friendly %></td>
22 <% if @trace.inserted? %>
24 <td><%= t ".points" %></td>
25 <td><%= @trace.size.to_s.gsub(/(\d)(?=(\d{3})+$)/, '\1,') %></td></tr>
27 <td><%= t ".start_coordinates" %></td>
28 <td><div class="d-inline"><span class="latitude"><%= @trace.latitude %></span>; <span class="longitude"><%= @trace.longitude %></span></div> (<%= link_to t(".map"), :controller => "site", :action => "index", :mlat => @trace.latitude, :mlon => @trace.longitude, :anchor => "map=14/#{@trace.latitude}/#{@trace.longitude}" %> / <%= link_to t(".edit"), :controller => "site", :action => "edit", :gpx => @trace.id, :anchor => "map=14/#{@trace.latitude}/#{@trace.longitude}" %>)</td>
32 <td><%= t ".owner" %></td>
33 <td><%= link_to @trace.user.display_name, user_path(@trace.user) %></td>
36 <td><%= t ".description" %></td>
37 <td><%= @trace.description %></td>
40 <td><%= t ".tags" %></td>
42 <% unless @trace.tags.empty? %>
43 <%= safe_join(@trace.tags.collect { |tag| link_to tag.tag, :controller => "traces", :action => "index", :tag => tag.tag, :id => nil }, ", ") %>
45 <i><%= t ".none" %></i>
50 <td><%= t ".visibility" %></td>
51 <td><%= t "traces.visibility.#{@trace.visibility}" %></td>
57 <% if current_user && (current_user==@trace.user || current_user.administrator? || current_user.moderator?) %>
59 <% if current_user == @trace.user %>
60 <%= link_to t(".edit_trace"), edit_trace_path(@trace), :class => "button" %>
62 <%= button_to t(".delete_trace"), { :controller => "traces", :action => "destroy", :id => @trace.id }, { :method => :delete, :data => { :confirm => t(".confirm_delete") } } %>