aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLouise Crow <louise.crow@gmail.com>2012-10-18 18:05:44 +0100
committerLouise Crow <louise.crow@gmail.com>2012-10-18 18:05:44 +0100
commit066651bb03dfedbd705df2ca90c1b3c3261ce9f9 (patch)
tree3f80b7414cdab21d72343d430a2fd8f553b79edb
parent32ac4ff55f2e174718fad97fcbd57b50a3daef7b (diff)
Add slightly more sensible request description text for the case where the requests are not necessarily answered.
-rw-r--r--app/views/general/frontpage.rhtml11
1 files changed, 9 insertions, 2 deletions
diff --git a/app/views/general/frontpage.rhtml b/app/views/general/frontpage.rhtml
index 7f25cdd14..ec7b9bd8f 100644
--- a/app/views/general/frontpage.rhtml
+++ b/app/views/general/frontpage.rhtml
@@ -63,11 +63,18 @@
<ul>
<% for event in @request_events %>
<li>
- <%= public_body_link(event.info_request.public_body) %> <%= _('answered a request about') %>
+ <% if @request_events_all_successful %>
+ <%= _("{{public_body_link}} answered a request about",
+ :public_body_link => public_body_link(event.info_request.public_body)) %>
+ <% else %>
+ <%= _("{{public_body_link}} was sent a request about",
+ :public_body_link => public_body_link(event.info_request.public_body)) %>
+ <% end %>
+
<%=link_to h(event.info_request.title), request_url(event.info_request)%>
<%= _('{{length_of_time}} ago', :length_of_time => time_ago_in_words(event.described_at)) %>
<p class="excerpt" onclick="document.location.href='<%=request_url(event.info_request)%>'"><%= excerpt(event.search_text_main(true), "", 200) %></p>
- </li>
+ </li>
<% end %>
</ul>
<p><strong>