]> source.dussan.org Git - redmine.git/commitdiff
added a setting option to disable "password lost" functionality
authorJean-Philippe Lang <jp_lang@yahoo.fr>
Sun, 4 Feb 2007 09:37:28 +0000 (09:37 +0000)
committerJean-Philippe Lang <jp_lang@yahoo.fr>
Sun, 4 Feb 2007 09:37:28 +0000 (09:37 +0000)
git-svn-id: http://redmine.rubyforge.org/svn/trunk@231 e93f8b46-1217-0410-a6f0-8f06a7374b81

app/views/account/login.rhtml
app/views/settings/edit.rhtml
config/settings.yml

index a5d31c2ee750002ba41fec7ca0042c41a0add991..9f1e3dc6310593591fdeee22b3454e25dd851c06 100644 (file)
 <p><center><input type="submit" name="login" value="<%=l(:button_login)%> &#187;" class="primary" /></center>
 <% end %>\r
 \r
-<br><% if Setting.self_registration? %><%= link_to l(:label_register), :action => 'register' %> |<% end %>\r
-<%= link_to l(:label_password_lost), :action => 'lost_password' %></p>
+<br>\r
+<% links = []\r
+   links << link_to(l(:label_register), :action => 'register') if Setting.self_registration?\r
+   links << link_to(l(:label_password_lost), :action => 'password_lost') if Setting.password_lost?\r
+%>\r
+<%= links.join(" | ") %>\r
+</p>\r
+
 </div>\r
 </center>
\ No newline at end of file
index 625daa09a6cdd3937c134cfa5b8efc960f01d6dd..04bb771e7560a87237c78361ef97d3e67db39e55 100644 (file)
@@ -20,6 +20,9 @@
 <p><label><%= l(:setting_self_registration) %></label>
 <%= check_box_tag 'settings[self_registration]', 1, Setting.self_registration? %><%= hidden_field_tag 'settings[self_registration]', 0 %></p>
 
+<p><label><%= l(:label_password_lost) %></label>
+<%= check_box_tag 'settings[password_lost]', 1, Setting.password_lost? %><%= hidden_field_tag 'settings[password_lost]', 0 %></p>
+
 <p><label><%= l(:setting_attachment_max_size) %></label>
 <%= text_field_tag 'settings[attachment_max_size]', Setting.attachment_max_size, :size => 6 %> KB</p>
 
index 3712099264270a5184cba547c38873398aa0951f..54b3a6c4edb8a9f267439d34e09f359ea6211c59 100644 (file)
@@ -29,6 +29,8 @@ login_required:
   default: 0\r
 self_registration:\r
   default: 1\r
+password_lost:\r
+  default: 1\r
 attachment_max_size:\r
   format: int\r
   default: 5120\r