aboutsummaryrefslogtreecommitdiffstats
path: root/app/controllers/request_controller.rb
diff options
context:
space:
mode:
authorFrancis Irving <francis@mysociety.org>2010-10-04 01:14:10 +0100
committerFrancis Irving <francis@mysociety.org>2010-10-04 01:14:10 +0100
commit759ddc5ad79189dc6ce9b2ae44296b6fa1076e39 (patch)
tree727918f9517ade33fd2ba01f0c1d1b7c69243ea9 /app/controllers/request_controller.rb
parenta6e8aba3630eb1d0da5c36ae176e8bfe478cb851 (diff)
Allow specifying body and title in simple way too
Diffstat (limited to 'app/controllers/request_controller.rb')
-rw-r--r--app/controllers/request_controller.rb8
1 files changed, 4 insertions, 4 deletions
diff --git a/app/controllers/request_controller.rb b/app/controllers/request_controller.rb
index 382575a06..49b19ba37 100644
--- a/app/controllers/request_controller.rb
+++ b/app/controllers/request_controller.rb
@@ -188,14 +188,14 @@ class RequestController < ApplicationController
return
end
- # ... next any tags
- if params[:tags]
- params[:info_request][:tag_string] = params[:tags]
- end
+ # ... next any tags or other things
+ params[:info_request][:title] = params[:title] if params[:title]
+ params[:info_request][:tag_string] = params[:tags] if params[:tags]
@info_request = InfoRequest.new(params[:info_request])
params[:info_request_id] = @info_request.id
params[:outgoing_message] = {} if !params[:outgoing_message]
+ params[:outgoing_message][:body] = params[:body] if params[:body]
params[:outgoing_message][:info_request] = @info_request
@outgoing_message = OutgoingMessage.new(params[:outgoing_message])
@outgoing_message.set_signature_name(@user.name) if !@user.nil?