<%= f.field_container :name do %>
<%= f.label :name, class: 'required' %>
<%= f.text_field :name, class: 'fullwidth', required: true %>
<% end %>
<%= f.field_container :customer_label do %>
<%= f.label :customer_label, class: 'required' %>
<%= f.text_field :customer_label, class: 'fullwidth', required: true %>
<% end %>
<%= f.field_container :description do %>
<%= f.label :description %>
<%= f.text_area :description, rows: 7, class: 'fullwidth' %>
<%= t('spree.character_limit') %>
<% end %>
<%= f.field_container :category do %>
<%= f.label :promotion_category_id, SolidusFriendlyPromotions::PromotionCategory.model_name.human %>
<%=
f.collection_select(:promotion_category_id, @promotion_categories, :id, :name, { include_blank: t('solidus_friendly_promotions.match_choices.none') },
{ class: 'custom-select fullwidth' })
%>
<% end %>
<%= f.field_container :overall_usage_limit do %>
<%= f.label :usage_limit %>
<%= f.number_field :usage_limit, min: 0, class: 'fullwidth' %>
<%= t('solidus_friendly_promotions.current_promotion_usage', count: @promotion.usage_count) %>
<% end %>
<% if @promotion.persisted? %>
<%= f.field_container :per_code_usage_limit do %>
<%= f.label :per_code_usage_limit %>
<%= f.number_field :per_code_usage_limit, min: 0, class: 'fullwidth' %>
<% end %>
<% end %>
<%= f.label :starts_at %>
<%= f.field_hint :starts_at %>
<%=
f.text_field :starts_at,
value: datepicker_field_value(@promotion.starts_at, with_time: true),
placeholder: t(".starts_at_placeholder"),
class: 'datepicker datepicker-from fullwidth',
data: { :'enable-time' => true, :'default-hour' => 0 }
%>
<%= f.label :expires_at %>
<%= f.field_hint :expires_at %>
<%=
f.text_field :expires_at,
value: datepicker_field_value(@promotion.expires_at,
with_time: true),
placeholder: t(".expires_at_placeholder"),
class: 'datepicker datepicker-to fullwidth',
data: { :'enable-time' => true, :'default-hour' => 0 }
%>
<%= f.field_container :lane do %>
<%= f.label :lane %>
<%=
f.select(:lane, SolidusFriendlyPromotions::Promotion.lane_options, {}, { class: 'custom-select fullwidth' })
%>
<% end %>