<% content_for :side_bar do %> <%= render :partial => 'layouts/side_bar', :locals => {:link_name => t('site.settings'), :link_url => admin_site_site_info_path(@site), :icon => 'icons-cog', :side_bar_content => 'admin/sites/side_bar'} %> <% end %> <%= stylesheet_link_tag "lib/wrap-nav"%> <%= stylesheet_link_tag "lib/main-forms"%> <%= stylesheet_link_tag "lib/fileupload"%> <%= stylesheet_link_tag "lib/togglebox"%> <%= javascript_include_tag 'lib/bootstrap-fileupload' %> <%= javascript_include_tag 'lib/site_set' %> <%= form_for @site, :url => admin_site_path(@site), :html => {:class => "form-horizontal main-forms"} do |f| %>
<%= f.fields_for :site_settings, @site['site_settings'] do |f| %>
<%= f.text_field :address, :value => (@site['site_settings']['address'] rescue nil), :class=>"input-large", :placeholder=>"Email Address" %>
<%= f.text_field :port, :value => (@site['site_settings']['port'] rescue nil), :class=>"input-large", :placeholder=>"Domain" %>
<%= f.text_field :authentication, :value => (@site['site_settings']['authentication'] rescue nil), :class=>"input-large", :placeholder =>"Authentication" %>
<%= f.text_field :user_name, :value => (@site['site_settings']['user_name'] rescue nil), :class=>"input-large", :placeholder=>"User Name" %>
<%= f.text_field :password, :value => (@site['site_settings']['password'] rescue nil), :class=>"input-large", :placeholder=>"Password" %>
<%= f.text_field :port, :value => (@site['site_settings']['port'] rescue nil),:placeholder=>"Port", :class=>"input-mini" %>
<%= f.check_box :tls, :checked => (@site['site_settings']['tls'].eql?('1') rescue false),:class=>"toggle-check" %>
<%= f.check_box 'enable_starttls_auto', :checked => (@site['site_settings']['enable_starttls_auto'].eql?('1') rescue false), :class=>"toggle-check" %>
<% end %>
<%= f.check_box :frontend_closed , :class=>"toggle-check"%> Only can be viewed by users logged in
<%= f.check_box :backend_openness_on , :class=>"toggle-check" %> All users can visit backend pages
<%= f.check_box :desktop_closed , :class=>"toggle-check" %>
<% @site_in_use_locales.each do |locale| %> <%= check_box_tag :default_locale, locale, (@site.enabled_for.nil?), :class=>"toggle-check" %> <%= I18nVariable.from_locale(locale) %> <% end %>
<% @site_valid_locales.each do |valid_locale| %> <%= check_box_tag 'site[enabled_for][]', valid_locale, (@site.enabled_for.nil?), :class=>"toggle-check" %> <%= I18nVariable.from_locale(valid_locale) %> <% end %> <%= hidden_field_tag 'site[enabled_for][]', '' %>
<% if @site.default_image %> <%= image_tag( @site.default_image, :size=>"120x120") rescue ''%> <% else %> <% end %>
<%= f.file_field :default_image, :id => "input-upload", :class => 'fileupload-new', :onchange => "document.getElementById('fu').innerHTML = this.form.fu.value = this.value;" %>Select Image <% if @site.default_image.file.present?%> <%= f.file_field :default_image, :id => "input-upload", :class => 'fileupload-new', :onchange => "document.getElementById('fu').innerHTML = this.form.fu.value = this.value;" %>Change <%end%> Cancel
  • <%= image_tag "orbitbar-theme_A.png", :alt =>""%>
  • <%= image_tag "orbitbar-theme_B.png", :alt =>""%>
<%= f.submit t("submit"), :class => "btn btn-primary" %> <%= f.submit t("cancel"), :class => "btn ", :type => 'reset' %>
<%end%>