[openstreetmap/openstreetmap-website] Display how long until a note will disappear (PR #3676)

Harry Wood notifications at github.com
Thu Sep 15 09:14:01 UTC 2022


@harry-wood commented on this pull request.



> -    <p><small class="text-muted"><%= t "javascripts.notes.show.report_link_html", :link => report_link(t(".report"), @note) %></small></p>
+    <p>
+      <small class="text-muted">
+        <%= t "javascripts.notes.show.report_link_html", :link => report_link(t(".report"), @note) %>
+        <% if @note.status == "open" %>
+          <%= t "javascripts.notes.show.other_problems_resolve", :link => report_link(t(".report"), @note) %>
+        <% elsif @note.status == "closed" %>
+          <%= t "javascripts.notes.show.other_problems_resolved" %>
+        <% end %>
+      </small>
+    </p>
+  <% end %>
+
+  <% if @note.freshly_closed? %>
+    <small class="text-muted">
+      <%= t("javascripts.notes.show.disappear_date", :disappear_in => disappear_in(@note)).html_safe %>

Ah yes. I had a feeling there might be a way to avoid html_safe. That's better. So it's called `disappear_date_html` in en.yml now. 

-- 
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/3676#discussion_r971736855
You are receiving this because you are subscribed to this thread.

Message ID: <openstreetmap/openstreetmap-website/pull/3676/review/1108830375 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20220915/4b77d95a/attachment-0001.htm>


More information about the rails-dev mailing list