From 3da7b1bc2882cfb02c5068680979158322242398 Mon Sep 17 00:00:00 2001 From: Jean-Philippe Lang Date: Sat, 14 Feb 2015 08:03:51 +0000 Subject: Implements /issues/new form for creating issues outside a project (#1003). git-svn-id: http://svn.redmine.org/redmine/trunk@13999 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- app/helpers/issues_helper.rb | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'app/helpers') diff --git a/app/helpers/issues_helper.rb b/app/helpers/issues_helper.rb index e34039d76..a88adceb9 100644 --- a/app/helpers/issues_helper.rb +++ b/app/helpers/issues_helper.rb @@ -202,10 +202,15 @@ module IssuesHelper # Returns the path for updating the issue form # with project as the current project def update_issue_form_path(project, issue) + options = {:format => 'js'} if issue.new_record? - new_project_issue_path(project, :format => 'js') + if project + new_project_issue_path(project, options) + else + new_issue_path(options) + end else - edit_issue_path(issue, :format => 'js') + edit_issue_path(issue, options) end end -- cgit v1.2.3