<%= field(f, :job_category, :label => _('Job category')) do %>
<%= auto_complete_search(:job_category,
f.object.job_category,
:placeholder => _("Job category") + ' ...',
:name => 'job_template[job_category]',
:id => 'search',
:disabled => @template.locked?) %>
<% end %>
<%= text_f f, :description_format,
:disabled => @template.locked?,
:help_inline => popover(_('Explanation'), _('This template is used to generate the description.
Input values can be used using the syntax %{package}.
You may also include the job category and template
name using %{job_category} and %{template_name}.')) %>
<%= select_f f, :provider_type, providers_options, :first, :last, :disabled => @template.locked? %>
<%= new_child_fields_template(f, :template_inputs, { :partial => "template_inputs/form" }) %>
<%= f.fields_for :template_inputs do |ff| %>
<%= render 'template_inputs/form', :f => ff %>
<% end %>
<%= add_child_link '+ ' + _("Add Input"), :template_inputs, { :title => _('add a input for this template')} unless @template.locked? %>
<%= new_child_fields_template(f, :foreign_input_sets, { :partial => "template_inputs/foreign_input_set_form" }) %>
<%= f.fields_for :foreign_input_sets do |ff| %>
<%= render 'template_inputs/foreign_input_set_form', :f => ff %>
<% end %>
<%= add_child_link '+ ' + _("Add Foreign Input Set"), :foreign_input_sets, { :title => _('add an input set for this template to reference a different template inputs') } unless @template.locked? %>
<%= field_set_tag _("Effective user") do %>
<%= f.fields_for :effective_user, @template.effective_user do |ff| %>
<%= text_f ff, :value, :disabled => @template.locked? %>
<%= checkbox_f ff, :current_user, :disabled => @template.locked? %>
<%= checkbox_f ff, :overridable, :disabled => @template.locked? %>
<% end %>
<% end %>
<%= checkbox_f f, :snippet, :onchange => "snippet_changed(this)", :label=>_('Snippet'), :disabled => @template.locked? %>