Class: Api::V1::FactValuesController

Inherits:
BaseController show all
Defined in:
app/controllers/api/v1/fact_values_controller.rb

Instance Method Summary collapse

Methods included from Api::Version1

#api_version

Methods inherited from BaseController

#get_resource, #resource_class, #resource_name, #resource_scope

Methods included from Foreman::ThreadSession::Cleaner

#clear_thread, included

Instance Method Details

#indexObject


14
15
16
17
18
19
# File 'app/controllers/api/v1/fact_values_controller.rb', line 14

def index
  values = FactValue.my_facts.no_timestamp_facts.
    search_for(*search_options).paginate(paginate_options).
    includes(:fact_name, :host)
  render :json => FactValue.build_facts_hash(values.all)
end