Module: ForemanPuppet::Extensions::ApiV2HostsController::PatchMethods
- Defined in:
- app/controllers/concerns/foreman_puppet/extensions/api_v2_hosts_controller.rb
Instance Method Summary collapse
Instance Method Details
#allowed_nested_id ⇒ Object
38 39 40 41 42 |
# File 'app/controllers/concerns/foreman_puppet/extensions/api_v2_hosts_controller.rb', line 38 def allowed_nested_id ids = super ids << 'environment_id' ids.uniq end |
#resource_name(*attrs) ⇒ Object
32 33 34 35 36 |
# File 'app/controllers/concerns/foreman_puppet/extensions/api_v2_hosts_controller.rb', line 32 def resource_name(*attrs) return 'foreman_puppet/environment' if attrs.first.is_a?(String) && attrs.first.start_with?('environment') super(*attrs) end |