Module: Garage
- Defined in:
- lib/garage/authorizable.rb,
lib/garage.rb,
lib/garage/docs.rb,
lib/garage/meta.rb,
lib/garage/utils.rb,
lib/garage/config.rb,
lib/garage/tracer.rb,
lib/garage/version.rb,
lib/garage/exceptions.rb,
lib/garage/permission.rb,
lib/garage/docs/config.rb,
lib/garage/docs/engine.rb,
lib/garage/meta/engine.rb,
lib/garage/permissions.rb,
lib/garage/token_scope.rb,
lib/garage/docs/example.rb,
lib/garage/docs/document.rb,
lib/garage/docs/renderer.rb,
lib/garage/meta_resource.rb,
lib/garage/strategy/test.rb,
lib/garage/test/migrator.rb,
lib/garage/restful_actions.rb,
lib/garage/docs/application.rb,
lib/garage/controller_helper.rb,
lib/garage/docs/toc_renderer.rb,
lib/garage/hypermedia_filter.rb,
lib/garage/nested_field_query.rb,
lib/garage/meta/remote_service.rb,
lib/garage/docs/anchor_building.rb,
lib/garage/hypermedia_responder.rb,
lib/garage/paginating_responder.rb,
lib/garage/strategy/auth_server.rb,
lib/garage/strategy/access_token.rb,
app/helpers/garage/application_helper.rb,
lib/garage/docs/console_link_building.rb,
lib/garage/strategy/no_authentication.rb,
app/controllers/garage/meta/docs_controller.rb,
app/controllers/garage/application_controller.rb,
app/controllers/garage/meta/services_controller.rb
Overview
Public: mixes in CRUD controller actions to your Action Controller classes to provide a simple RESTful actions that provides resource-based permissions with built-in integrations with Doorkeeper scopes.
Examples
class PostsController < ApiController
include Garage::RestfulActions
def require_resources
@resources = Post.all
end
def require_resource
@resource = Post.find(params[:id])
end
end
Defined Under Namespace
Modules: ApplicationHelper, Authorizable, ControllerHelper, Docs, HypermediaResponder, Meta, NestedFieldQuery, OptionalResponseBodyResponder, PaginatingResponder, Representer, ResourceCastingResponder, RestfulActions, Strategy, Test, Tracer, Utils Classes: AppResponder, ApplicationController, AuthBackendError, AuthBackendTimeout, BadRequest, Config, HTTPError, HashRepresenter, HypermediaFilter, MetaResource, MissingScopeError, Permission, PermissionError, Permissions, TokenScope, Unauthorized
Constant Summary collapse
- VERSION =
'2.8.2'