Sha256: 76de255068dac9ade393acb223f7c6ce4cdbc5374e237d5a87701055330ab36c

Contents?: true

Size: 936 Bytes

Versions: 34

Compression:

Stored size: 936 Bytes

Contents

module Foreman::Controller::Parameters::DiscoveredHost
  extend ActiveSupport::Concern
  include Foreman::Controller::Parameters::Host

  class_methods do
    def discovered_host_params_filter
      Foreman::ParameterFilter.new(::Host::Discovered).tap do |filter|
        filter.permit :discovery_rule_id

        add_host_base_params_filter(filter)
        add_host_common_params_filter(filter)
      end
    end
  end

  def discovered_host_params
    self.class.discovered_host_params_filter.filter_params(params, parameter_filter_context)
  end

  def discovered_host_params_host
    self.class.discovered_host_params_filter.filter_params(params, parameter_filter_context, :host)
  end

  def managed_host_params_host
    self.class.host_params_filter.filter_params(params, parameter_filter_context, :host)
  end

  def managed_host_params
    self.class.host_params_filter.filter_params(params, parameter_filter_context)
  end
end

Version data entries

34 entries across 34 versions & 1 rubygems

Version Path
foreman_discovery-18.0.4 app/controllers/concerns/foreman/controller/parameters/discovered_host.rb
foreman_discovery-18.0.3 app/controllers/concerns/foreman/controller/parameters/discovered_host.rb
foreman_discovery-17.0.5 app/controllers/concerns/foreman/controller/parameters/discovered_host.rb
foreman_discovery-18.0.2 app/controllers/concerns/foreman/controller/parameters/discovered_host.rb
foreman_discovery-17.0.4 app/controllers/concerns/foreman/controller/parameters/discovered_host.rb
foreman_discovery-17.0.3 app/controllers/concerns/foreman/controller/parameters/discovered_host.rb
foreman_discovery-17.0.2 app/controllers/concerns/foreman/controller/parameters/discovered_host.rb
foreman_discovery-18.0.0 app/controllers/concerns/foreman/controller/parameters/discovered_host.rb
foreman_discovery-17.0.1 app/controllers/concerns/foreman/controller/parameters/discovered_host.rb
foreman_discovery-16.3.6 app/controllers/concerns/foreman/controller/parameters/discovered_host.rb
foreman_discovery-17.0.0 app/controllers/concerns/foreman/controller/parameters/discovered_host.rb
foreman_discovery-16.3.5 app/controllers/concerns/foreman/controller/parameters/discovered_host.rb
foreman_discovery-16.1.4 app/controllers/concerns/foreman/controller/parameters/discovered_host.rb
foreman_discovery-16.1.3 app/controllers/concerns/foreman/controller/parameters/discovered_host.rb
foreman_discovery-16.3.4 app/controllers/concerns/foreman/controller/parameters/discovered_host.rb
foreman_discovery-16.3.1 app/controllers/concerns/foreman/controller/parameters/discovered_host.rb
foreman_discovery-16.1.2 app/controllers/concerns/foreman/controller/parameters/discovered_host.rb
foreman_discovery-16.2.0 app/controllers/concerns/foreman/controller/parameters/discovered_host.rb
foreman_discovery-16.1.0 app/controllers/concerns/foreman/controller/parameters/discovered_host.rb
foreman_discovery-16.0.1 app/controllers/concerns/foreman/controller/parameters/discovered_host.rb