%= error_messages_for 'custom_field' %>
<%= f.select :field_format, custom_field_formats_for_select(@custom_field), {}, :disabled => !@custom_field.new_record? %>
<%= f.text_field :name, :size => 50, :required => true %>
<%= f.text_area :description, :rows => 7 %>
<% if @custom_field.format.multiple_supported %><%= f.check_box :multiple %> <% if !@custom_field.new_record? && @custom_field.multiple %> <%= l(:text_turning_multiple_off) %> <% end %>
<% end %> <%= render_custom_field_format_partial f, @custom_field %> <%= call_hook(:view_custom_fields_form_upper_box, :custom_field => @custom_field, :form => f) %><%= submit_tag l(:button_save) %>
<%= f.check_box :is_required %>
<% if @custom_field.format.is_filter_supported %><%= f.check_box :is_filter %>
<% end %> <% if @custom_field.format.searchable_supported %><%= f.check_box :searchable %>
<% end %> <% when "UserCustomField" %><%= f.check_box :is_required %>
<%= f.check_box :visible %>
<%= f.check_box :editable %>
<% if @custom_field.format.is_filter_supported %><%= f.check_box :is_filter %>
<% end %> <% when "ProjectCustomField" %><%= f.check_box :is_required %>
<%= f.check_box :visible %>
<% if @custom_field.format.searchable_supported %><%= f.check_box :searchable %>
<% end %> <% if @custom_field.format.is_filter_supported %><%= f.check_box :is_filter %>
<% end %> <% when "VersionCustomField" %><%= f.check_box :is_required %>
<% if @custom_field.format.is_filter_supported %><%= f.check_box :is_filter %>
<% end %> <% when "GroupCustomField" %><%= f.check_box :is_required %>
<% if @custom_field.format.is_filter_supported %><%= f.check_box :is_filter %>
<% end %> <% when "TimeEntryCustomField" %><%= f.check_box :is_required %>
<% if @custom_field.format.is_filter_supported %><%= f.check_box :is_filter %>
<% end %> <% else %><%= f.check_box :is_required %>
<% end %> <%= call_hook(:"view_custom_fields_form_#{@custom_field.type.to_s.underscore}", :custom_field => @custom_field, :form => f) %>