Class: Api::V1::AuthSourceLdapsController

Inherits:
BaseController show all
Defined in:
app/controllers/api/v1/auth_source_ldaps_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

#createObject


37
38
39
40
# File 'app/controllers/api/v1/auth_source_ldaps_controller.rb', line 37

def create
  @auth_source_ldap = AuthSourceLdap.new(params[:auth_source_ldap])
  process_response @auth_source_ldap.save
end

#destroyObject


66
67
68
# File 'app/controllers/api/v1/auth_source_ldaps_controller.rb', line 66

def destroy
  process_response @auth_source_ldap.destroy
end

#indexObject


11
12
13
# File 'app/controllers/api/v1/auth_source_ldaps_controller.rb', line 11

def index
  @auth_source_ldaps = AuthSourceLdap.paginate(paginate_options)
end

#showObject


18
19
# File 'app/controllers/api/v1/auth_source_ldaps_controller.rb', line 18

def show
end

#updateObject


59
60
61
# File 'app/controllers/api/v1/auth_source_ldaps_controller.rb', line 59

def update
  process_response @auth_source_ldap.update_attributes(params[:auth_source_ldap])
end