Fixed: Cannot create a new category on ticket creation/update page with 0.8.7 (#4400).

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/branches/0.8-stable@3304 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang committed 2010-01-10 13:49:09 +00:00
1 parent be146d492a
commit 8bab5b4730
2 files changed
+3 -2

No files matched your search

+1 -1
View File
@@ -28,7 +28,7 @@
<p><%= f.select :category_id, (@project.issue_categories.collect {|c| [c.name, c.id]}), :include_blank => true %> <p><%= f.select :category_id, (@project.issue_categories.collect {|c| [c.name, c.id]}), :include_blank => true %>
<%= prompt_to_remote(l(:label_issue_category_new), <%= prompt_to_remote(l(:label_issue_category_new),
l(:label_issue_category_new), 'category[name]', l(:label_issue_category_new), 'category[name]',
{:controller => 'projects', :action => 'add_issue_category', :id => @project}, {:controller => 'projects', :action => 'add_issue_category', :id => @project, :authenticity_token => form_authenticity_token},
:class => 'small', :tabindex => 199) if authorize_for('projects', 'add_issue_category') %></p> :class => 'small', :tabindex => 199) if authorize_for('projects', 'add_issue_category') %></p>
<% end %> <% end %>
<%= content_tag('p', f.select(:fixed_version_id, <%= content_tag('p', f.select(:fixed_version_id,
+2 -1
View File
@@ -69,7 +69,8 @@ function setPredecessorFieldsVisibility() {
function promptToRemote(text, param, url) { function promptToRemote(text, param, url) {
value = prompt(text + ':'); value = prompt(text + ':');
if (value) { if (value) {
new Ajax.Request(url + '?' + param + '=' + encodeURIComponent(value), {asynchronous:true, evalScripts:true}); var sep = (url.indexOf('?') < 0 ? '?' : '&' )
new Ajax.Request(url + sep + param + '=' + encodeURIComponent(value), {asynchronous:true, evalScripts:true});
return false; return false;
} }
} }