<commit_before>= form_for [current_circle, @form] do |f|
  - if errors.present?
    .form-introduction.error
      p= t('error_correction')


  .field-row.single
    .field.required class=errors.css(:name)
      = f.label :name
      = f.text_field :name, placeholder: true
      = errors.message_for(:name)


  .field-row
    .field.required class=errors.css(:working_group)
      = f.label :working_group_id
      = f.collection_select :working_group_id, @form.available_working_groups, :id, :name, {}, disabled: @form.available_working_groups_disabled?
      = errors.message_for(:working_group)

    .field.required class=errors.css(:organizer_id)
      = f.label :organizer_id
      = f.grouped_collection_select(:organizer_id, @form.available_working_groups, :users, :name, :id, :name)
      = errors.message_for(:organizer_id)


  .field-row.single
    .field.required class=errors.css(:description)
      = f.label :description
      = f.text_area :description
      = errors.message_for(:description)


  .field-row
    .field.required class=errors.css(:volunteer_count_required)
      = f.label :volunteer_count_required
      = f.select :volunteer_count_required do
        = options_for_select(1..5, @form.volunteer_count_required)
      = errors.message_for(:volunteer_count_required)

    .field.required class=errors.css(:primary_location)
      = f.label :primary_location
      = f.text_field :primary_location
      = errors.message_for(:primary_location)


  .field-row
    .field.required class=errors.css(:due_date)
      = f.label :due_date
      = f.text_field :due_date, type: :date, min: Time.now.strftime("%Y-%m-%d")
      = errors.message_for(:due_date)

    .field.required class=errors.css(:duration)
      = f.label :duration
      = f.select :duration do
        = options_for_select(@form.duration_options, @form.duration)

      = errors.message_for(:duration)


  .field-row
    .field class=errors.css(:scheduled_time_type)
      = f.label :scheduled_time_type
      = f.select :scheduled_time_type do
        = options_for_select(@form.scheduled_time_type_options, @form.scheduled_time_type)
      = errors.message_for(:scheduled_time_type)

    .field.scheduled-time
      = f.label :scheduled_time_start
      span.start
        = f.select :scheduled_time_start, nil, {}, {class: 'timeselect'} do
          = options_for_select(@form.scheduled_time_options, @form.scheduled_time_start)
      span.end
        | to
        = f.select :scheduled_time_end, nil, {}, {class: 'timeselect'}
          = options_for_select(@form.scheduled_time_options, @form.scheduled_time_end)

      = errors.message_for(:scheduled_time_start)
      = errors.message_for(:scheduled_time_end)


  .submit-row
    = f.submit
    - cancel_path = @form.task.persisted? ? circle_tasks_path(current_circle, current_task) : circle_path(current_circle)
    = link_to t('task_edit.cancel'), cancel_path
    - if locals[:delete]
      = link_to t('delete'), [current_circle, current_task], class: 'button secondary-action', data: {:confirm => t('helpers.confirm.task.delete')}, :method => :delete<commit_msg>Fix for edit task link to go back to show task page<commit_after>= form_for [current_circle, @form] do |f|
  - if errors.present?
    .form-introduction.error
      p= t('error_correction')


  .field-row.single
    .field.required class=errors.css(:name)
      = f.label :name
      = f.text_field :name, placeholder: true
      = errors.message_for(:name)


  .field-row
    .field.required class=errors.css(:working_group)
      = f.label :working_group_id
      = f.collection_select :working_group_id, @form.available_working_groups, :id, :name, {}, disabled: @form.available_working_groups_disabled?
      = errors.message_for(:working_group)

    .field.required class=errors.css(:organizer_id)
      = f.label :organizer_id
      = f.grouped_collection_select(:organizer_id, @form.available_working_groups, :users, :name, :id, :name)
      = errors.message_for(:organizer_id)


  .field-row.single
    .field.required class=errors.css(:description)
      = f.label :description
      = f.text_area :description
      = errors.message_for(:description)


  .field-row
    .field.required class=errors.css(:volunteer_count_required)
      = f.label :volunteer_count_required
      = f.select :volunteer_count_required do
        = options_for_select(1..5, @form.volunteer_count_required)
      = errors.message_for(:volunteer_count_required)

    .field.required class=errors.css(:primary_location)
      = f.label :primary_location
      = f.text_field :primary_location
      = errors.message_for(:primary_location)


  .field-row
    .field.required class=errors.css(:due_date)
      = f.label :due_date
      = f.text_field :due_date, type: :date, min: Time.now.strftime("%Y-%m-%d")
      = errors.message_for(:due_date)

    .field.required class=errors.css(:duration)
      = f.label :duration
      = f.select :duration do
        = options_for_select(@form.duration_options, @form.duration)

      = errors.message_for(:duration)


  .field-row
    .field class=errors.css(:scheduled_time_type)
      = f.label :scheduled_time_type
      = f.select :scheduled_time_type do
        = options_for_select(@form.scheduled_time_type_options, @form.scheduled_time_type)
      = errors.message_for(:scheduled_time_type)

    .field.scheduled-time
      = f.label :scheduled_time_start
      span.start
        = f.select :scheduled_time_start, nil, {}, {class: 'timeselect'} do
          = options_for_select(@form.scheduled_time_options, @form.scheduled_time_start)
      span.end
        | to
        = f.select :scheduled_time_end, nil, {}, {class: 'timeselect'}
          = options_for_select(@form.scheduled_time_options, @form.scheduled_time_end)

      = errors.message_for(:scheduled_time_start)
      = errors.message_for(:scheduled_time_end)


  .submit-row
    = f.submit
    - cancel_path = @form.task.persisted? ? circle_task_path(current_circle, current_task) : circle_path(current_circle)
    = link_to t('task_edit.cancel'), cancel_path
    - if locals[:delete]
      = link_to t('delete'), [current_circle, current_task], class: 'button secondary-action', data: {:confirm => t('helpers.confirm.task.delete')}, :method => :delete
{'fraction_non_alphanumeric': 0.12382320089356949, 'fraction_numerical': 0.0006382639221318015, 'mean_word_length': 3.5552325581395348, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7644302', 'n_tokens_mistral': 2072, 'n_tokens_neox': 2027, 'n_words': 312}