aboutsummaryrefslogtreecommitdiffstats
path: root/app
diff options
context:
space:
mode:
Diffstat (limited to 'app')
-rw-r--r--app/views/request/_correspondence.rhtml14
1 files changed, 13 insertions, 1 deletions
diff --git a/app/views/request/_correspondence.rhtml b/app/views/request/_correspondence.rhtml
index d5edd1e4b..f7e6870e0 100644
--- a/app/views/request/_correspondence.rhtml
+++ b/app/views/request/_correspondence.rhtml
@@ -2,7 +2,16 @@
if !info_request_event.nil? && info_request_event.event_type == 'response'
incoming_message = info_request_event.incoming_message
end
-
+
+# cache against all the parameters that there are to this partial
+cache_name = "correspondence/" + info_request_event.id.to_s
+if !incoming_message.nil?
+ cache_name = cache_name + "/incoming_message/" + incoming_message.id.to_s
+end
+# yeuch, must be nicer way of telling cache just to use this cache_name, than
+# putting it falsely in list action
+cache(:controller => 'request', :action => 'list', :extra => cache_name) do
+
if not incoming_message.nil?
%>
<div class="correspondence" id="incoming-<%=incoming_message.id.to_s%>">
@@ -75,3 +84,6 @@ elsif info_request_event.event_type == 'sent' || info_request_event.event_type =
end
%>
+
+<% end %>
+