1 <% content_for :heading do %>
2 <h1><%= t ".heading", :name => @trace.name %></h1>
5 <% if Settings.status != "gpx_offline" %>
6 <% if @trace.inserted %>
7 <%= trace_picture(@trace) %>
9 <span class="text-danger"><%= t ".pending" %></span>
13 <table class="table table-borderless table-sm">
15 <th><%= t ".filename" %></th>
16 <td><%= @trace.name %> (<%= link_to t(".download"), trace_data_path(@trace) %>)</td>
19 <th><%= t ".uploaded" %></th>
20 <td><%= l @trace.timestamp, :format => :friendly %></td>
22 <% if @trace.inserted? %>
24 <th><%= t ".points" %></th>
25 <td><%= number_with_delimiter(@trace.size) %></td></tr>
27 <th><%= t ".start_coordinates" %></th>
29 <div class="d-inline">
30 <%= t ".coordinates_html",
31 :latitude => tag.span(number_with_delimiter(@trace.latitude), :class => "latitude"),
32 :longitude => tag.span(number_with_delimiter(@trace.longitude), :class => "longitude") %>
34 (<%= link_to t(".map"), root_path(:mlat => @trace.latitude, :mlon => @trace.longitude, :anchor => "map=14/#{@trace.latitude}/#{@trace.longitude}") %> / <%= link_to t(".edit"), edit_path(:gpx => @trace.id, :anchor => "map=14/#{@trace.latitude}/#{@trace.longitude}") %>)</td>
38 <th><%= t ".owner" %></th>
39 <td><%= link_to @trace.user.display_name, @trace.user %></td>
42 <th><%= t ".description" %></th>
43 <td><%= @trace.description %></td>
46 <th><%= t ".tags" %></th>
48 <% unless @trace.tags.empty? %>
49 <%= safe_join(@trace.tags.collect { |tag| link_to tag.tag, :controller => "traces", :action => "index", :tag => tag.tag, :id => nil }, ", ") %>
51 <i><%= t ".none" %></i>
56 <th><%= t ".visibility" %></th>
57 <td><%= t "traces.visibility.#{@trace.visibility}" %></td>
61 <% if current_user && (current_user==@trace.user || current_user.administrator? || current_user.moderator?) %>
63 <% if current_user == @trace.user %>
64 <%= link_to t(".edit_trace"), edit_trace_path(@trace), :class => "btn btn-outline-primary" %>
66 <%= link_to t(".delete_trace"), @trace, { :method => :delete, :class => "btn btn-outline-danger", :data => { :confirm => t(".confirm_delete") } } %>