<h2>RedmineLE</h2>

<% unless RedmineLeSetting.use_external_ldap %>
  <p><%= link_to l(:label_ldap_user_administration), :controller => "ldap_users", :action => "index" %></p>
<% end %>

<% labelled_tabular_form_for :redmine_le_setting, @setting, :url => {:action => 'update'}, :html => {:method => :put} do |f| %>
  <%= f.error_messages %>

<% if RedmineLeSetting.use_external_ldap %>
  <h3><%= l(:label_change_admin_account) %></h3>
  <div class="box">
    <p><%= f.text_field :admin_account, :required => true, :size => 25 %></p>
    <p><%= f.password_field :admin_password, :required => true, :size => 25 %></p>
  </div>
<% end %>

  <h3><%= l(:label_smtp_setting) %></h3>
  <div class="box">
    <p><%= f.text_field :smtp_server, :size => 25 %></p>
    <p><%= f.text_field :smtp_port, :size => 25, :label => l(:field_port) %></p>
    <p><%= f.text_field :smtp_sender, :size => 25, :label => l(:setting_mail_from) %></p>
    <p><%= f.text_field :smtp_user, :size => 25 %></p>
    <p><%= f.password_field :smtp_password, :size => 25, :label => l(:field_password) %></p>
  </div>

  <%= f.submit l(:button_save) %>
<% end %>

<% html_title "RedmineLE" %>
