Module: ForemanOpenscap::ScapContentExtensions
- Extended by:
- ActiveSupport::Concern
- Includes:
- Authorizable, Taxonomix
- Defined in:
- app/models/concerns/foreman_openscap/scap_content_extensions.rb
Instance Method Summary collapse
Instance Method Details
#used_location_ids ⇒ Object
28 29 30 31 32 |
# File 'app/models/concerns/foreman_openscap/scap_content_extensions.rb', line 28 def used_location_ids Location.joins(:taxable_taxonomies).where( 'taxable_taxonomies.taxable_type' => 'Scaptimony::ScapContent', 'taxable_taxonomies.taxable_id' => id).pluck("#{Location.arel_table.name}.id") end |
#used_organization_ids ⇒ Object
34 35 36 37 38 |
# File 'app/models/concerns/foreman_openscap/scap_content_extensions.rb', line 34 def used_organization_ids Organization.joins(:taxable_taxonomies).where( 'taxable_taxonomies.taxable_type' => 'Scaptimony::ScapContent', 'taxable_taxonomies.taxable_id' => id).pluck("#{Location.arel_table.name}.id") end |