<commit_before>- url = url_for(:action => 'tasks_change_options')
#tasks_options_div
  %h3
    = _("Filter By")
  .form-horizontal
    - if %w(my_tasks all_tasks).include?(@layout)
      .form-group
        %label.control-label.col-md-2
          = _("Zone")
        .col-md-8
          - my_zone = MiqServer.my_server(true).my_zone
          - opts = [["<#{_('All Zones')}>", "<all>"]] + @tasks_options[:zones].sort.collect { |a| [a == my_zone ? a + " (current)" : a, a] }
          = select_tag("chosen_zone",
            options_for_select(opts, @tasks_options[@tabform][:zone]),
            :class => "selectpicker")
          :javascript
            miqInitSelectPicker();
            miqSelectPickerEvent("chosen_zone", "#{url}");
    - if @lastaction == "all_jobs" || @lastaction == "all_ui_jobs"
      .form-group
        %label.control-label.col-md-2
          = _("User")
        .col-md-8
          = select_tag("user_choice",
            options_for_select([["#{_('All Users')}", "all"]] + @user_names.sort, @tasks_options[@tabform][:user_choice]),
            :class => "selectpicker")
          :javascript
            miqInitSelectPicker();
            miqSelectPickerEvent("user_choice", "#{url}");
    .form-group
      %label.control-label.col-md-2
        = _("24 Hour Time Period")
      .col-md-8
        = select_tag("time_period",
          options_for_select(Array(TASK_TIME_PERIODS.invert).sort_by(&:last).map{|x| [_(x[0]), x[1]]}, @tasks_options[@tabform][:time_period]),
          :class => "selectpicker")
        :javascript
          miqInitSelectPicker();
          miqSelectPickerEvent("time_period", "#{url}");
    .form-group
      %label.control-label.col-md-2
        = _("Task Status")
      .col-md-8
        = check_box_tag("queued", "1", @tasks_options[@tabform][:queued], "data-miq_observe_checkbox" => {:url => url}.to_json)
        &nbsp;
        %img{:src => image_path('16/job-queued.png'), :valign => "middle", :title => _("Queued")}= _("Queued")
        &nbsp;
        = check_box_tag("running", "1", @tasks_options[@tabform][:running], "data-miq_observe_checkbox" => {:url => url}.to_json)
        &nbsp;
        %img{:src => image_path('16/job-running.png'), :valign => "middle", :title => _("Warn")}= _("Running")
        &nbsp;
        = check_box_tag("ok", "1", @tasks_options[@tabform][:ok], "data-miq_observe_checkbox" => {:url => url}.to_json)
        &nbsp;
        %img{:src => image_path('100/checkmark.png'), :valign => "middle", :title => _("Ok"), :style => "height: 16px;"}= _("Ok")
        &nbsp;
        = check_box_tag("error", "1", @tasks_options[@tabform][:error], "data-miq_observe_checkbox" => {:url => url}.to_json)
        &nbsp;
        %img{:src => image_path('100/x.png'), :valign => "middle", :title => _("Error"), :style => "height: 16px;"}= _("Error")
        &nbsp;
        = check_box_tag("warn", "1", @tasks_options[@tabform][:warn], "data-miq_observe_checkbox" => {:url => url}.to_json)
        &nbsp;
        %img{:src => image_path('16/warning.png'), :valign => "middle", :title => _("Warn")}= _("Warn")
    .form-group
      %label.control-label.col-md-2
        = _("Task State")
      .col-md-8
        = select_tag("state_choice",
          options_for_select([["#{_('All')}", "all"]] + @tasks_options[@tabform][:states].sort.map{|x| [_(x[0]), x[1]]}, @tasks_options[@tabform][:state_choice]),
          :class => "selectpicker")
        :javascript
          miqInitSelectPicker();
          miqSelectPickerEvent("state_choice", "#{url}");
    #form_buttons_div.clearfix{:style => "padding-right: 10px"}
      #buttons_off.pull-right
        = button_tag(_("Apply"), :class => "btn btn-primary disabled")
        = button_tag(_("Reset"), :class => "btn btn-default disabled")
        = link_to(_('Default'),
          {:action => "tasks_button", :button => "default"},
          :class                 => "btn btn-default",
          :alt                   => (t = _("Set filters to default")),
          "data-miq_sparkle_on"  => true,
          "data-miq_sparkle_off" => true,
          :remote                => true,
          "data-method"          => :post,
          :title                 => t)
      #buttons_on.pull-right{:style => "display:none"}
        = link_to(_('Apply'),
          {:action => "tasks_button", :button => "apply"},
          :class                 => "btn btn-primary",
          :alt                   => (t = _("Apply the selected filters")),
          "data-miq_sparkle_on"  => true,
          "data-miq_sparkle_off" => true,
          :remote                => true,
          "data-method"          => :post,
          :title                 => t)
        = link_to(_('Reset'),
          {:action => "tasks_button", :button => "reset"},
          :class                 => "btn btn-default",
          :alt                   => (t = _("Reset filter changes")),
          "data-miq_sparkle_on"  => true,
          "data-miq_sparkle_off" => true,
          :remote                => true,
          "data-method"          => :post,
          :title                 => t)
        = link_to(_('Default'),
          {:action => "tasks_button", :button => "default"},
          :class                 => "btn btn-default",
          :alt                   => (t = _("Set filters to default")),
          "data-miq_sparkle_on"  => true,
          "data-miq_sparkle_off" => true,
          :remote                => true,
          "data-method"          => :post,
          :title                 => t)
  %hr
<commit_msg>Correct task icon styling<commit_after>- url = url_for(:action => 'tasks_change_options')
#tasks_options_div
  %h3
    = _("Filter By")
  .form-horizontal
    - if %w(my_tasks all_tasks).include?(@layout)
      .form-group
        %label.control-label.col-md-2
          = _("Zone")
        .col-md-8
          - my_zone = MiqServer.my_server(true).my_zone
          - opts = [["<#{_('All Zones')}>", "<all>"]] + @tasks_options[:zones].sort.collect { |a| [a == my_zone ? a + " (current)" : a, a] }
          = select_tag("chosen_zone",
            options_for_select(opts, @tasks_options[@tabform][:zone]),
            :class => "selectpicker")
          :javascript
            miqInitSelectPicker();
            miqSelectPickerEvent("chosen_zone", "#{url}");
    - if @lastaction == "all_jobs" || @lastaction == "all_ui_jobs"
      .form-group
        %label.control-label.col-md-2
          = _("User")
        .col-md-8
          = select_tag("user_choice",
            options_for_select([["#{_('All Users')}", "all"]] + @user_names.sort, @tasks_options[@tabform][:user_choice]),
            :class => "selectpicker")
          :javascript
            miqInitSelectPicker();
            miqSelectPickerEvent("user_choice", "#{url}");
    .form-group
      %label.control-label.col-md-2
        = _("24 Hour Time Period")
      .col-md-8
        = select_tag("time_period",
          options_for_select(Array(TASK_TIME_PERIODS.invert).sort_by(&:last).map{|x| [_(x[0]), x[1]]}, @tasks_options[@tabform][:time_period]),
          :class => "selectpicker")
        :javascript
          miqInitSelectPicker();
          miqSelectPickerEvent("time_period", "#{url}");
    .form-group
      %label.control-label.col-md-2
        = _("Task Status")
      .col-md-8
        = check_box_tag("queued", "1", @tasks_options[@tabform][:queued], "data-miq_observe_checkbox" => {:url => url}.to_json)
        &nbsp;
        %i.fa.fa-step-forward
        = _("Queued")
        &nbsp;
        = check_box_tag("running", "1", @tasks_options[@tabform][:running], "data-miq_observe_checkbox" => {:url => url}.to_json)
        &nbsp;
        %i.pficon.pficon-running
        = _("Running")
        &nbsp;
        = check_box_tag("ok", "1", @tasks_options[@tabform][:ok], "data-miq_observe_checkbox" => {:url => url}.to_json)
        &nbsp;
        %i.pficon.pficon-ok
        = _("Ok")
        &nbsp;
        = check_box_tag("error", "1", @tasks_options[@tabform][:error], "data-miq_observe_checkbox" => {:url => url}.to_json)
        &nbsp;
        %i.pficon.pficon-error-circle-o
        = _("Error")
        &nbsp;
        = check_box_tag("warn", "1", @tasks_options[@tabform][:warn], "data-miq_observe_checkbox" => {:url => url}.to_json)
        &nbsp;
        %i.pficon.pficon-warning-triangle-o
        = _("Warn")
    .form-group
      %label.control-label.col-md-2
        = _("Task State")
      .col-md-8
        = select_tag("state_choice",
          options_for_select([["#{_('All')}", "all"]] + @tasks_options[@tabform][:states].sort.map{|x| [_(x[0]), x[1]]}, @tasks_options[@tabform][:state_choice]),
          :class => "selectpicker")
        :javascript
          miqInitSelectPicker();
          miqSelectPickerEvent("state_choice", "#{url}");
    #form_buttons_div.clearfix{:style => "padding-right: 10px"}
      #buttons_off.pull-right
        = button_tag(_("Apply"), :class => "btn btn-primary disabled")
        = button_tag(_("Reset"), :class => "btn btn-default disabled")
        = link_to(_('Default'),
          {:action => "tasks_button", :button => "default"},
          :class                 => "btn btn-default",
          :alt                   => (t = _("Set filters to default")),
          "data-miq_sparkle_on"  => true,
          "data-miq_sparkle_off" => true,
          :remote                => true,
          "data-method"          => :post,
          :title                 => t)
      #buttons_on.pull-right{:style => "display:none"}
        = link_to(_('Apply'),
          {:action => "tasks_button", :button => "apply"},
          :class                 => "btn btn-primary",
          :alt                   => (t = _("Apply the selected filters")),
          "data-miq_sparkle_on"  => true,
          "data-miq_sparkle_off" => true,
          :remote                => true,
          "data-method"          => :post,
          :title                 => t)
        = link_to(_('Reset'),
          {:action => "tasks_button", :button => "reset"},
          :class                 => "btn btn-default",
          :alt                   => (t = _("Reset filter changes")),
          "data-miq_sparkle_on"  => true,
          "data-miq_sparkle_off" => true,
          :remote                => true,
          "data-method"          => :post,
          :title                 => t)
        = link_to(_('Default'),
          {:action => "tasks_button", :button => "default"},
          :class                 => "btn btn-default",
          :alt                   => (t = _("Set filters to default")),
          "data-miq_sparkle_on"  => true,
          "data-miq_sparkle_off" => true,
          :remote                => true,
          "data-method"          => :post,
          :title                 => t)
  %hr

{'fraction_non_alphanumeric': 0.18352962997310582, 'fraction_numerical': 0.005935268478160067, 'mean_word_length': 2.0181919955219705, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 134, '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': '4728804', 'n_tokens_mistral': 3533, 'n_tokens_neox': 3472, 'n_words': 558}