summaryrefslogtreecommitdiffstats
path: root/app/views/settings
diff options
context:
space:
mode:
authorEric Davis <edavis@littlestreamsoftware.com>2009-09-13 17:14:35 +0000
committerEric Davis <edavis@littlestreamsoftware.com>2009-09-13 17:14:35 +0000
commit7b0cb6aba8715aff00519f200060fbf46ae9bb97 (patch)
treec4dc3bcac1a48020c2afef87094056a9a5e06b6f /app/views/settings
parentfb349dc4abe283481984c67cd1287312f128dbfc (diff)
downloadredmine-7b0cb6aba8715aff00519f200060fbf46ae9bb97.tar.gz
redmine-7b0cb6aba8715aff00519f200060fbf46ae9bb97.zip
Upgraded to Rails 2.3.4 (#3597)
* Ran the Rails upgrade * Upgraded to Rails Engines 2.3.2 * Added a plugin to let Engines override application views. * Converted tests to use the new classes: ** ActionController::TestCase for functional ** ActiveSupport::TestCase for units * Converted ActiveRecord::Error message to a string. * ActiveRecord grouping returns an ordered hash which doesn't have #sort! * Updated the I18n storage_units format. * Added some default initializers from a fresh rails app * Changed the order of check_box_tags and hidden_field_tags. The hidden tag needs to appear first in Rails 2.3, otherwise it will override any value in the check_box_tag. * Removed the custom handler for when the cookie store is tampered with. Rails 2.3 removed the TamperedWithCookie exception and instead Rails will not load the data from it when it's been tampered with (e.g. no user login). * Fixed mail layouts, 2.3 has problems with implicit multipart emails that use layouts. Also removed some custom Redmine mailer code. * Fixed a bug that occurred in tests where the "required" span tag would be added to the :field_status translation. This resulted in an email string of: <li>Status<span class="required"> *</span><span class="required"> *</span> Instead of: <li>Status: New</li> git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@2887 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/views/settings')
-rw-r--r--app/views/settings/_authentication.rhtml12
-rw-r--r--app/views/settings/_display.rhtml4
-rw-r--r--app/views/settings/_issues.rhtml8
-rw-r--r--app/views/settings/_mail_handler.rhtml3
-rw-r--r--app/views/settings/_notifications.rhtml6
-rw-r--r--app/views/settings/_projects.rhtml8
-rw-r--r--app/views/settings/_repositories.rhtml8
7 files changed, 36 insertions, 13 deletions
diff --git a/app/views/settings/_authentication.rhtml b/app/views/settings/_authentication.rhtml
index 25d344da6..f4b8dbf52 100644
--- a/app/views/settings/_authentication.rhtml
+++ b/app/views/settings/_authentication.rhtml
@@ -2,7 +2,9 @@
<div class="box tabular settings">
<p><label><%= l(:setting_login_required) %></label>
-<%= check_box_tag 'settings[login_required]', 1, Setting.login_required? %><%= hidden_field_tag 'settings[login_required]', 0 %></p>
+<%= hidden_field_tag 'settings[login_required]', 0 %>
+<%= check_box_tag 'settings[login_required]', 1, Setting.login_required? %>
+</p>
<p><label><%= l(:setting_autologin) %></label>
<%= select_tag 'settings[autologin]', options_for_select( [[l(:label_disabled), "0"]] + [1, 7, 30, 365].collect{|days| [l('datetime.distance_in_words.x_days', :count => days), days.to_s]}, Setting.autologin) %></p>
@@ -19,10 +21,14 @@
<%= text_field_tag 'settings[password_min_length]', Setting.password_min_length, :size => 6 %></p>
<p><label><%= l(:label_password_lost) %></label>
-<%= check_box_tag 'settings[lost_password]', 1, Setting.lost_password? %><%= hidden_field_tag 'settings[lost_password]', 0 %></p>
+<%= hidden_field_tag 'settings[lost_password]', 0 %>
+<%= check_box_tag 'settings[lost_password]', 1, Setting.lost_password? %>
+</p>
<p><label><%= l(:setting_openid) %></label>
-<%= check_box_tag 'settings[openid]', 1, Setting.openid?, :disabled => !Object.const_defined?(:OpenID) %><%= hidden_field_tag 'settings[openid]', 0 %></p>
+<%= hidden_field_tag 'settings[openid]', 0 %>
+<%= check_box_tag 'settings[openid]', 1, Setting.openid?, :disabled => !Object.const_defined?(:OpenID) %>
+</p>
</div>
<div style="float:right;">
diff --git a/app/views/settings/_display.rhtml b/app/views/settings/_display.rhtml
index a14ff47ce..984f762e4 100644
--- a/app/views/settings/_display.rhtml
+++ b/app/views/settings/_display.rhtml
@@ -17,7 +17,9 @@
<%= select_tag 'settings[user_format]', options_for_select( @options[:user_format], Setting.user_format.to_s ) %></p>
<p><label><%= l(:setting_gravatar_enabled) %></label>
-<%= check_box_tag 'settings[gravatar_enabled]', 1, Setting.gravatar_enabled? %><%= hidden_field_tag 'settings[gravatar_enabled]', 0 %></p>
+<%= hidden_field_tag 'settings[gravatar_enabled]', 0 %>
+<%= check_box_tag 'settings[gravatar_enabled]', 1, Setting.gravatar_enabled? %>
+</p>
</div>
<%= submit_tag l(:button_save) %>
diff --git a/app/views/settings/_issues.rhtml b/app/views/settings/_issues.rhtml
index 0703661e0..b0277fab3 100644
--- a/app/views/settings/_issues.rhtml
+++ b/app/views/settings/_issues.rhtml
@@ -2,10 +2,14 @@
<div class="box tabular settings">
<p><label><%= l(:setting_cross_project_issue_relations) %></label>
-<%= check_box_tag 'settings[cross_project_issue_relations]', 1, Setting.cross_project_issue_relations? %><%= hidden_field_tag 'settings[cross_project_issue_relations]', 0 %></p>
+<%= hidden_field_tag 'settings[cross_project_issue_relations]', 0 %>
+<%= check_box_tag 'settings[cross_project_issue_relations]', 1, Setting.cross_project_issue_relations? %>
+</p>
<p><label><%= l(:setting_display_subprojects_issues) %></label>
-<%= check_box_tag 'settings[display_subprojects_issues]', 1, Setting.display_subprojects_issues? %><%= hidden_field_tag 'settings[display_subprojects_issues]', 0 %></p>
+<%= hidden_field_tag 'settings[display_subprojects_issues]', 0 %>
+<%= check_box_tag 'settings[display_subprojects_issues]', 1, Setting.display_subprojects_issues? %>
+</p>
<p><label><%= l(:setting_issues_export_limit) %></label>
<%= text_field_tag 'settings[issues_export_limit]', Setting.issues_export_limit, :size => 6 %></p>
diff --git a/app/views/settings/_mail_handler.rhtml b/app/views/settings/_mail_handler.rhtml
index 830b1ba4a..8d83358b7 100644
--- a/app/views/settings/_mail_handler.rhtml
+++ b/app/views/settings/_mail_handler.rhtml
@@ -2,9 +2,10 @@
<div class="box tabular settings">
<p><label><%= l(:setting_mail_handler_api_enabled) %></label>
+<%= hidden_field_tag 'settings[mail_handler_api_enabled]', 0 %>
<%= check_box_tag 'settings[mail_handler_api_enabled]', 1, Setting.mail_handler_api_enabled?,
:onclick => "if (this.checked) { Form.Element.enable('settings_mail_handler_api_key'); } else { Form.Element.disable('settings_mail_handler_api_key'); }" %>
-<%= hidden_field_tag 'settings[mail_handler_api_enabled]', 0 %></p>
+</p>
<p><label><%= l(:setting_mail_handler_api_key) %></label>
<%= text_field_tag 'settings[mail_handler_api_key]', Setting.mail_handler_api_key,
diff --git a/app/views/settings/_notifications.rhtml b/app/views/settings/_notifications.rhtml
index bc0141187..1b1b294b2 100644
--- a/app/views/settings/_notifications.rhtml
+++ b/app/views/settings/_notifications.rhtml
@@ -6,12 +6,14 @@
<%= text_field_tag 'settings[mail_from]', Setting.mail_from, :size => 60 %></p>
<p><label><%= l(:setting_bcc_recipients) %></label>
+<%= hidden_field_tag 'settings[bcc_recipients]', 0 %>
<%= check_box_tag 'settings[bcc_recipients]', 1, Setting.bcc_recipients? %>
-<%= hidden_field_tag 'settings[bcc_recipients]', 0 %></p>
+</p>
<p><label><%= l(:setting_plain_text_mail) %></label>
+<%= hidden_field_tag 'settings[plain_text_mail]', 0 %>
<%= check_box_tag 'settings[plain_text_mail]', 1, Setting.plain_text_mail? %>
-<%= hidden_field_tag 'settings[plain_text_mail]', 0 %></p>
+</p>
</div>
<fieldset class="box" id="notified_events"><legend><%=l(:text_select_mail_notifications)%></legend>
diff --git a/app/views/settings/_projects.rhtml b/app/views/settings/_projects.rhtml
index 2f831c8fd..704905af2 100644
--- a/app/views/settings/_projects.rhtml
+++ b/app/views/settings/_projects.rhtml
@@ -2,10 +2,14 @@
<div class="box tabular settings">
<p><label><%= l(:setting_default_projects_public) %></label>
-<%= check_box_tag 'settings[default_projects_public]', 1, Setting.default_projects_public? %><%= hidden_field_tag 'settings[default_projects_public]', 0 %></p>
+<%= hidden_field_tag 'settings[default_projects_public]', 0 %>
+<%= check_box_tag 'settings[default_projects_public]', 1, Setting.default_projects_public? %>
+</p>
<p><label><%= l(:setting_sequential_project_identifiers) %></label>
-<%= check_box_tag 'settings[sequential_project_identifiers]', 1, Setting.sequential_project_identifiers? %><%= hidden_field_tag 'settings[sequential_project_identifiers]', 0 %></p>
+<%= hidden_field_tag 'settings[sequential_project_identifiers]', 0 %>
+<%= check_box_tag 'settings[sequential_project_identifiers]', 1, Setting.sequential_project_identifiers? %>
+</p>
<p><label><%= l(:setting_new_project_user_role_id) %></label>
<%= select_tag('settings[new_project_user_role_id]', options_for_select([["--- #{l(:actionview_instancetag_blank_option)} ---", '']] + Role.find_all_givable.collect {|r| [r.name, r.id]}, Setting.new_project_user_role_id.to_i)) %></p>
diff --git a/app/views/settings/_repositories.rhtml b/app/views/settings/_repositories.rhtml
index a20fc5131..4f07f053a 100644
--- a/app/views/settings/_repositories.rhtml
+++ b/app/views/settings/_repositories.rhtml
@@ -2,10 +2,14 @@
<div class="box tabular settings">
<p><label><%= l(:setting_autofetch_changesets) %></label>
-<%= check_box_tag 'settings[autofetch_changesets]', 1, Setting.autofetch_changesets? %><%= hidden_field_tag 'settings[autofetch_changesets]', 0 %></p>
+<%= hidden_field_tag 'settings[autofetch_changesets]', 0 %>
+<%= check_box_tag 'settings[autofetch_changesets]', 1, Setting.autofetch_changesets? %>
+</p>
<p><label><%= l(:setting_sys_api_enabled) %></label>
-<%= check_box_tag 'settings[sys_api_enabled]', 1, Setting.sys_api_enabled? %><%= hidden_field_tag 'settings[sys_api_enabled]', 0 %></p>
+<%= hidden_field_tag 'settings[sys_api_enabled]', 0 %>
+<%= check_box_tag 'settings[sys_api_enabled]', 1, Setting.sys_api_enabled? %>
+</p>
<p><label><%= l(:setting_enabled_scm) %></label>
<% REDMINE_SUPPORTED_SCM.each do |scm| -%>