Sha256: fb49f2a2d7c8f711f26cceb95a3c1f14aefa140f45468e3edb6dc1e9d4f30613

Contents?: true

Size: 863 Bytes

Versions: 52

Compression:

Stored size: 863 Bytes

Contents

module ForemanTasks
  module Concerns
    module Parameters
      module Triggering
        extend ActiveSupport::Concern

        class_methods do
          def triggering_params_filter
            Foreman::ParameterFilter.new(::ForemanTasks::Triggering).tap do |filter|
              filter.permit_by_context(
                [
                  :mode,
                  :start_at,
                  :start_before,
                  *::ForemanTasks::Triggering::PARAMS,
                  :days_of_week => {},
                  :time => {},
                  :end_time => {}
                ],
                :nested => true
              )
            end
          end
        end

        def triggering_params
          self.class.triggering_params_filter.filter_params(params, parameter_filter_context, :triggering)
        end
      end
    end
  end
end

Version data entries

52 entries across 52 versions & 1 rubygems

Version Path
foreman-tasks-2.0.3 app/controllers/foreman_tasks/concerns/parameters/triggering.rb
foreman-tasks-2.0.2 app/controllers/foreman_tasks/concerns/parameters/triggering.rb
foreman-tasks-1.1.3 app/controllers/foreman_tasks/concerns/parameters/triggering.rb
foreman-tasks-1.1.2 app/controllers/foreman_tasks/concerns/parameters/triggering.rb
foreman-tasks-2.0.1 app/controllers/foreman_tasks/concerns/parameters/triggering.rb
foreman-tasks-2.0.0 app/controllers/foreman_tasks/concerns/parameters/triggering.rb
foreman-tasks-1.2.0 app/controllers/foreman_tasks/concerns/parameters/triggering.rb
foreman-tasks-1.1.1 app/controllers/foreman_tasks/concerns/parameters/triggering.rb
foreman-tasks-1.1.0 app/controllers/foreman_tasks/concerns/parameters/triggering.rb
foreman-tasks-0.17.6 app/controllers/foreman_tasks/concerns/parameters/triggering.rb
foreman-tasks-1.0.1 app/controllers/foreman_tasks/concerns/parameters/triggering.rb
foreman-tasks-1.0.0 app/controllers/foreman_tasks/concerns/parameters/triggering.rb
foreman-tasks-0.17.5 app/controllers/foreman_tasks/concerns/parameters/triggering.rb
foreman-tasks-0.17.4 app/controllers/foreman_tasks/concerns/parameters/triggering.rb
foreman-tasks-0.17.3 app/controllers/foreman_tasks/concerns/parameters/triggering.rb
foreman-tasks-0.17.2 app/controllers/foreman_tasks/concerns/parameters/triggering.rb
foreman-tasks-0.16.3 app/controllers/foreman_tasks/concerns/parameters/triggering.rb
foreman-tasks-0.17.1 app/controllers/foreman_tasks/concerns/parameters/triggering.rb
foreman-tasks-0.15.11 app/controllers/foreman_tasks/concerns/parameters/triggering.rb
foreman-tasks-0.16.2 app/controllers/foreman_tasks/concerns/parameters/triggering.rb