<% if record.statusable? %>
  <% label = local_assigns.fetch(:label, nil) %>
  <% date_label = local_assigns.fetch(:date_label, 'Published date') %>
  <div class="status-scheduler form-group">
    <%= f.input :status, as: :select, collection: record.class.statuses_for_select.collect { |k, v| [k.titleize, k] }, include_blank: false, label: label %>
    <% if record.respond_to?(:published_date) %>
      <%= f.input :published_date,
                  as: :datepicker,
                  timepicker: false,
                  hint: "Set the date of this record to a future date and it will be hidden until the start of this date.",
                  label: date_label %>
    <% elsif record.respond_to?(:scheduled_date) %>
      <%= f.input :scheduled_date,
                  as: :datepicker,
                  timepicker: false,
                  hint: "Set the date of this record to a future date and it will be hidden until the start of this date.",
                  label: date_label,
                  wrapper_html: {
                    class: ('active' if record.scheduled?) } %>
    <% end %>
  </div>
<% end %>

<% if record.statusable? %>
  <% label = local_assigns.fetch(:label, nil) %>
  <% hint = local_assigns.fetch(:hint, nil) %>
  <% date_label = local_assigns.fetch(:date_label, 'Published date') %>
  <div class="status-scheduler form-group">
    <%= f.input :status, as: :select, collection: record.class.statuses_for_select.collect { |k, v| [k.titleize, k] }, include_blank: false, label: label, hint: hint %>
    <% if record.respond_to?(:published_date) %>
      <%= f.input :published_date,
                  as: :datepicker,
                  timepicker: false,
                  hint: "Set the date of this record to a future date and it will be hidden until the start of this date.",
                  label: date_label %>
    <% elsif record.respond_to?(:scheduled_date) %>
      <%= f.input :scheduled_date,
                  as: :datepicker,
                  timepicker: false,
                  hint: "Set the date of this record to a future date and it will be hidden until the start of this date.",
                  label: date_label,
                  wrapper_html: {
                    class: ('active' if record.scheduled?) } %>
    <% end %>
  </div>
<% end %>

Allow setting status hint from partial
Allow setting status hint from partial
