diff options
Diffstat (limited to 'app')
-rw-r--r-- | app/controllers/reports_controller.rb | 4 | ||||
-rw-r--r-- | app/views/reports/new.html.erb | 2 | ||||
-rw-r--r-- | app/views/request/_sidebar.html.erb | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/app/controllers/reports_controller.rb b/app/controllers/reports_controller.rb index 070a91421..924eb0108 100644 --- a/app/controllers/reports_controller.rb +++ b/app/controllers/reports_controller.rb @@ -1,6 +1,6 @@ class ReportsController < ApplicationController def create - info_request = InfoRequest.find_by_url_title!(params[:url_title]) + info_request = InfoRequest.find_by_url_title!(params[:request_id]) if !authenticated_user flash[:notice] = _("You need to be logged in to report a request for administrator attention") elsif info_request.attention_requested @@ -13,7 +13,7 @@ class ReportsController < ApplicationController end def new - @info_request = InfoRequest.find_by_url_title!(params[:url_title]) + @info_request = InfoRequest.find_by_url_title!(params[:request_id]) if authenticated?( :web => _("To report this request"), :email => _("Then you can report the request '{{title}}'", :title => @info_request.title), diff --git a/app/views/reports/new.html.erb b/app/views/reports/new.html.erb index 11b682282..58e80f3ad 100644 --- a/app/views/reports/new.html.erb +++ b/app/views/reports/new.html.erb @@ -8,7 +8,7 @@ </p> <p>Why specifically do you consider this request unsuitable?</p> - <%= form_tag request_report_path(:url_title => @info_request.url_title) do %> + <%= form_tag request_report_path(:request_id => @info_request.url_title) do %> <p> <label class="form_label" for="reason">Reason:</label> <%= select_tag :reason, options_for_select(["Contains defamatory material", "Not a valid request", "Request for personal information", "Contains personal information", "Vexatious", "Other"]), :prompt => "Choose a reason" %> diff --git a/app/views/request/_sidebar.html.erb b/app/views/request/_sidebar.html.erb index 03185c44b..302172555 100644 --- a/app/views/request/_sidebar.html.erb +++ b/app/views/request/_sidebar.html.erb @@ -25,7 +25,7 @@ <% else %> <p><%= _('Requests for personal information and vexatious requests are not considered valid for FOI purposes (<a href="/help/about">read more</a>).') %></p> <p><%= _('If you believe this request is not suitable, you can report it for attention by the site administrators') %></p> - <%= link_to _("Report this request"), new_request_report_path(:url_title => @info_request.url_title) %> + <%= link_to _("Report this request"), new_request_report_path(:request_id => @info_request.url_title) %> <% end %> <% end %> <h2><%= _("Act on what you've learnt") %></h2> |