From f59700138f7360436767fddea554c739e2cd484b Mon Sep 17 00:00:00 2001 From: Matthew Landauer Date: Tue, 25 Sep 2012 08:55:35 +1000 Subject: Extract configuration with defaults into one module --- app/controllers/admin_request_controller.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'app/controllers/admin_request_controller.rb') diff --git a/app/controllers/admin_request_controller.rb b/app/controllers/admin_request_controller.rb index 53ff2957b..b8f2de968 100644 --- a/app/controllers/admin_request_controller.rb +++ b/app/controllers/admin_request_controller.rb @@ -42,9 +42,9 @@ class AdminRequestController < AdminController # XXX is this *really* the only way to render a template to a # variable, rather than to the response? vars = OpenStruct.new(:name_to => @info_request.user_name, - :name_from => MySociety::Config.get("CONTACT_NAME", 'Alaveteli'), + :name_from => Configuration::contact_name, :info_request => @info_request, :reason => params[:reason], - :info_request_url => 'http://' + MySociety::Config.get('DOMAIN') + request_url(@info_request), + :info_request_url => 'http://' + Configuration::domain + request_url(@info_request), :site_name => site_name) template = File.read(File.join(File.dirname(__FILE__), "..", "views", "admin_request", "hidden_user_explanation.rhtml")) @request_hidden_user_explanation = ERB.new(template).result(vars.instance_eval { binding }) -- cgit v1.2.3 From 28ae5eb5595b41e06da5d74a6670b806364ef23a Mon Sep 17 00:00:00 2001 From: Matthew Landauer Date: Tue, 9 Oct 2012 11:38:23 +1100 Subject: Remove svn tags that are out of date as we are now using git --- app/controllers/admin_request_controller.rb | 2 -- 1 file changed, 2 deletions(-) (limited to 'app/controllers/admin_request_controller.rb') diff --git a/app/controllers/admin_request_controller.rb b/app/controllers/admin_request_controller.rb index b8f2de968..39f6ff506 100644 --- a/app/controllers/admin_request_controller.rb +++ b/app/controllers/admin_request_controller.rb @@ -3,8 +3,6 @@ # # Copyright (c) 2007 UK Citizens Online Democracy. All rights reserved. # Email: francis@mysociety.org; WWW: http://www.mysociety.org/ -# -# $Id: admin_request_controller.rb,v 1.42 2009-10-03 01:28:33 francis Exp $ require 'ostruct' -- cgit v1.2.3 From 2be203025b14fd7f4b8deb207c1138be724978d1 Mon Sep 17 00:00:00 2001 From: Louise Crow Date: Wed, 17 Oct 2012 11:30:48 +0100 Subject: Bugfix - fixed cut and paste error. --- app/controllers/admin_request_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'app/controllers/admin_request_controller.rb') diff --git a/app/controllers/admin_request_controller.rb b/app/controllers/admin_request_controller.rb index 39f6ff506..c97ef7f1e 100644 --- a/app/controllers/admin_request_controller.rb +++ b/app/controllers/admin_request_controller.rb @@ -93,7 +93,7 @@ class AdminRequestController < AdminController :old_allow_new_responses_from => old_allow_new_responses_from, :allow_new_responses_from => @info_request.allow_new_responses_from, :old_handle_rejected_responses => old_handle_rejected_responses, :handle_rejected_responses => @info_request.handle_rejected_responses, :old_tag_string => old_tag_string, :tag_string => @info_request.tag_string, - :old_comments_allowed => old_comments_allowed, :tag_string => @info_request.comments_allowed + :old_comments_allowed => old_comments_allowed, :comments_allowed => @info_request.comments_allowed }) # expire cached files expire_for_request(@info_request) -- cgit v1.2.3