openaustralia/planningalerts

View on GitHub
app/views/_tailwind/applications/_scraped_and_received_text.html.erb

Summary

Maintainability
Test Coverage
We found this application on the planning authority's website on
<%# TODO: Do we want to use ordinal numbers in the date as per the design? %>
<%= time_tag application.first_date_scraped, application.first_date_scraped.to_date.to_fs(:long) %>,
<%= time_ago_in_words(application.first_date_scraped) %>
ago.
<% if application.date_received %>
  It was received by them
  <%= time_tag_with_hover(application.date_received, distance_of_time_in_words(application.date_received, application.first_date_scraped)) %>
  earlier.
<% else %>
  The date it was received by them was not recorded.
<% end %>