X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/5f2a5cadcb693b34b81a9232b8879c3b4f12843d..ca719af262380a906103e7aec9befb4c903693a1:/app/views/notes/show.html.erb?ds=inline
diff --git a/app/views/notes/show.html.erb b/app/views/notes/show.html.erb
index 4aa2e7fd3..d17612e29 100644
--- a/app/views/notes/show.html.erb
+++ b/app/views/notes/show.html.erb
@@ -9,25 +9,49 @@
-
- - <%= note_event("opened", @note.created_at, @note.author) %>
- <% if @note.status == "closed" %>
- - <%= note_event(@note.status, @note.closed_at, @note.all_comments.last.author) %>
- <% end %>
- -
- <%= t "browse.location" %>
- <%= link_to(t(".coordinates_html",
- :latitude => tag.span(number_with_delimiter(@note.lat), :class => "latitude"),
- :longitude => tag.span(number_with_delimiter(@note.lon), :class => "longitude")),
- root_path(:anchor => "map=18/#{@note.lat}/#{@note.lon}")) %>
-
-
+
<%= note_event("opened", @note.created_at, @note.author) %>
+ <% if @note.status == "closed" %>
+
<%= note_event(@note.status, @note.closed_at, @note.all_comments.last.author) %>
+ <% end %>
+
+ <%= t "browse.location" %>
+ <%= link_to t(".coordinates_html",
+ :latitude => tag.span(number_with_delimiter(@note.lat), :class => "latitude"),
+ :longitude => tag.span(number_with_delimiter(@note.lon), :class => "longitude")),
+ root_path(:anchor => "map=18/#{@note.lat}/#{@note.lon}") %>
+
<% if @note_comments.find { |comment| comment.author.nil? } -%>
<%= t ".anonymous_warning" %>
<% end -%>
+
+
+
<%= t(".discussion") %>
+
+
+ <% if current_user %>
+
+ <% if @note.subscribers.exists?(current_user.id) %>
+ <%= tag.button t(".unsubscribe"),
+ :type => "button",
+ :class => "btn btn-sm btn-primary",
+ :name => "unsubscribe",
+ :data => { :method => "DELETE",
+ :url => api_note_subscription_path(@note) } %>
+ <% else %>
+ <%= tag.button t(".subscribe"),
+ :type => "button",
+ :class => "btn btn-sm btn-primary",
+ :name => "subscribe",
+ :data => { :method => "POST",
+ :url => api_note_subscription_path(@note) } %>
+ <% end %>
+
+ <% end %>
+
+
<% if @note_comments.length > 1 %>