diff options
Diffstat (limited to 'app/views')
-rw-r--r-- | app/views/admin/index.rhtml | 3 | ||||
-rw-r--r-- | app/views/request/_describe_state.rhtml | 34 | ||||
-rw-r--r-- | app/views/request/describe_state.rhtml | 4 | ||||
-rw-r--r-- | app/views/request/show.rhtml | 4 | ||||
-rw-r--r-- | app/views/request_mailer/new_response.rhtml | 5 | ||||
-rw-r--r-- | app/views/request_mailer/new_response_reminder_alert.rhtml | 13 |
6 files changed, 39 insertions, 24 deletions
diff --git a/app/views/admin/index.rhtml b/app/views/admin/index.rhtml index 9d330784c..116d38500 100644 --- a/app/views/admin/index.rhtml +++ b/app/views/admin/index.rhtml @@ -71,7 +71,7 @@ Missing outgoing message, internal error. <% end %> <% elsif event.event_type == 'response' %> - <% incoming_message = IncomingMessage.find(event.params[:incoming_message_id]) %> + <% incoming_message = event.incoming_message %> received <%= link_to 'a response', main_url(show_response_url(:id => incoming_message.info_request.id, :incoming_message_id => incoming_message.id, :only_path => true)) %> @@ -82,7 +82,6 @@ <% elsif event.event_type == 'resent' %> had the request resent to <%=h event.params[:email]%> at <%=h event.info_request.public_body.name %>. <% elsif event.event_type == 'followup_sent' %> - <% outgoing_messages = OutgoingMessage.find(:all, event.params[:outgoing_message_id].to_i) %> had a follow up message sent to <%=h event.info_request.public_body.name %>. <% else %> had '<%=event.event_type%>' done to it, parameters <%=h event.params_yaml%>. diff --git a/app/views/request/_describe_state.rhtml b/app/views/request/_describe_state.rhtml index 1dd789998..d05ea531b 100644 --- a/app/views/request/_describe_state.rhtml +++ b/app/views/request/_describe_state.rhtml @@ -2,33 +2,35 @@ <% form_for(:incoming_message, @info_request, :url => describe_state_url(:id => @info_request.id)) do |f| %> <h2>What is the status of this request now?</h2> <p> - <%= radio_button "incoming_message", "described_state", "waiting_response" %> - <label for="incoming_message_described_state_waiting_response">I'm still <strong>waiting</strong> for my information / a rejection (e.g. if the new response was just an acknowledgement)</label> + <%= radio_button "incoming_message", "described_state", "waiting_response", :id => 'waiting_response' + id_suffix %> + <label for="waiting_response<%=id_suffix%>">I'm still <strong>waiting</strong> for my information / a rejection (e.g. if the new response was just an acknowledgement)</label> <br> - <%= radio_button "incoming_message", "described_state", "waiting_clarification" %> - <label for="incoming_message_described_state_waiting_clarification">I'm about to <strong>clarify</strong> my request</label> + <%= radio_button "incoming_message", "described_state", "waiting_clarification", :id => 'waiting_clarification' + id_suffix %> + <label for="waiting_clarification<%=id_suffix%>">I'm about to <strong>clarify</strong> my request</label> <br> - <%= radio_button "incoming_message", "described_state", "not_held" %> - <label for="incoming_message_described_state_not_held">The authority <strong>does not have</strong> the information (perhaps they suggest making the request elsewhere)</label> + <%= radio_button "incoming_message", "described_state", "not_held", :id => 'not_held' + id_suffix %> + <label for="not_held<%=id_suffix%>">The authority <strong>does not have</strong> the information (perhaps they suggest making the request elsewhere)</label> <br> - <%= radio_button "incoming_message", "described_state", "rejected" %> - <label for="incoming_message_described_state_rejected">My request has been <strong>rejected</strong></label> + <%= radio_button "incoming_message", "described_state", "rejected", :id => 'rejected' + id_suffix %> + <label for="rejected<%=id_suffix%>">My request has been <strong>rejected</strong></label> <br> - <%= radio_button "incoming_message", "described_state", "successful" %> - <label for="incoming_message_described_state_successful">I've received <strong>all the information</strong> (or equivalents) that I asked for</label> + <%= radio_button "incoming_message", "described_state", "successful", :id => 'successful' + id_suffix %> + <label for="successful<%=id_suffix%>">I've received <strong>all the information</strong> (or equivalents) that I asked for</label> <br> - <%= radio_button "incoming_message", "described_state", "partially_successful" %> - <label for="incoming_message_described_state_partially_successful">I've received <strong>some of the information</strong> that I asked for</label> + <%= radio_button "incoming_message", "described_state", "partially_successful", :id => 'partially_successful' + id_suffix %> + <label for="partially_successful<%=id_suffix%>">I've received <strong>some of the information</strong> that I asked for</label> <br> - <%= radio_button "incoming_message", "described_state", "requires_admin" %> - <label for="incoming_message_described_state_requires_admin"><strong>None</strong> of the above - e.g. add a new option here</label> + <%= radio_button "incoming_message", "described_state", "requires_admin", :id => 'requires_admin' + id_suffix %> + <label for="requires_admin<%=id_suffix%>"><strong>None</strong> of the above - e.g. add a new option here</label> </p> <p>Filling this in each time you get a new response helps us track the progress of your request. </p> - <%= hidden_field_tag 'last_info_request_event_id', @last_info_request_event_id %> - <%= hidden_field_tag 'submitted_describe_state', 1 %> + <p> + <%= hidden_field_tag 'last_info_request_event_id', @last_info_request_event_id, :id => 'last_info_request_event_id' + id_suffix %> + <%= hidden_field_tag 'submitted_describe_state', 1, :id => 'submitted_describe_state' + id_suffix %> <%= submit_tag "Next" %> + </p> <% end %> <% else %> We don't know whether the most recent response to this request contains diff --git a/app/views/request/describe_state.rhtml b/app/views/request/describe_state.rhtml index 354cab447..e65823e3e 100644 --- a/app/views/request/describe_state.rhtml +++ b/app/views/request/describe_state.rhtml @@ -4,7 +4,7 @@ <%= foi_error_messages_for :incoming_message, :outgoing_message %> <div class="describe_state_form"> - <%= render :partial => 'describe_state' %> + <%= render :partial => 'describe_state', :locals => { :id_suffix => "1" } %> </div> <div id="show_response_view"> @@ -17,6 +17,6 @@ </div> <div class="describe_state_form"> - <%= render :partial => 'describe_state' %> + <%= render :partial => 'describe_state', :locals => { :id_suffix => "2" } %> </div> diff --git a/app/views/request/show.rhtml b/app/views/request/show.rhtml index 9627d5d29..8e5ac5f4f 100644 --- a/app/views/request/show.rhtml +++ b/app/views/request/show.rhtml @@ -2,7 +2,7 @@ <% if @info_request.awaiting_description %> <div class="describe_state_form"> - <%= render :partial => 'describe_state' %> + <%= render :partial => 'describe_state', :locals => { :id_suffix => "1" } %> </div> <% end %> @@ -84,7 +84,7 @@ <% if @info_request.awaiting_description %> <div class="describe_state_form"> - <%= render :partial => 'describe_state' %> + <%= render :partial => 'describe_state', :locals => { :id_suffix => "2" } %> </div> <% end %> diff --git a/app/views/request_mailer/new_response.rhtml b/app/views/request_mailer/new_response.rhtml index 947558c4d..c55289b04 100644 --- a/app/views/request_mailer/new_response.rhtml +++ b/app/views/request_mailer/new_response.rhtml @@ -1,5 +1,6 @@ -You have a new response to the FOI request '<%= @info_request.title %>' -that you made to <%= @info_request.public_body.name %>. +You have a new response to the Freedom of Information request +'<%= @info_request.title %>' that you made to +<%= @info_request.public_body.name %>. To view the response, click on the link below. diff --git a/app/views/request_mailer/new_response_reminder_alert.rhtml b/app/views/request_mailer/new_response_reminder_alert.rhtml new file mode 100644 index 000000000..fe1bf2d40 --- /dev/null +++ b/app/views/request_mailer/new_response_reminder_alert.rhtml @@ -0,0 +1,13 @@ +Please let us know whether there was information in the recent +response to your Freedom of Information request. To do this, +click on the link below. + +<%=@url%> + +Thanks very much - this will help others find useful stuff. We'll +also, if you need it, give advice on what to do next about your +request. + +-- the WhatDoTheyKnow team + + |