Module: Padrino::Admin::AccessControl

### Home Classes Methods

### In Files

- lib/padrino-admin/access_control.rb

### Namespace

- CLASS Padrino::Admin::AccessControl::Authorization
- CLASS Padrino::Admin::AccessControl::Base
- CLASS Padrino::Admin::AccessControl::ProjectModule

### Methods

- ::included
- ::registered

### Files

- README.rdoc

### Class/Module Index

Quicksearch

- Padrino
- Padrino::Admin
- Padrino::Admin::AccessControl
- Padrino::Admin::AccessControl::Authorization
- Padrino::Admin::AccessControl::Base
- Padrino::Admin::AccessControl::ProjectModule
- Padrino::Admin::AccessControlError
- Padrino::Admin::Generators
- Padrino::Admin::Generators::Orm
- Padrino::Admin::Generators::OrmError
- Padrino::Admin::Helpers
- Padrino::Admin::Helpers::AuthenticationHelpers
- Padrino::Admin::Helpers::ViewHelpers
- Padrino::Generators
- Padrino::Generators::Admin
- Padrino::Generators::Admin::Actions
- Padrino::Generators::AdminApp
- Padrino::Generators::AdminPage

No matching classes.

# Padrino::Admin::AccessControl

This module enables access control functionality within a Padrino application.

### Public Class Methods

included(app) click to toggle source
Alias for: registered
registered(app) click to toggle source

Method used by Padrino::Application when we register the extension.

    # File lib/padrino-admin/access_control.rb, line 15
    def registered(app)
      app.register Padrino::Admin unless app.extensions.include?(Padrino::Admin)
      app.set :session_id, "_padrino_#{File.basename(Padrino.root)}_#{app.app_name}".to_sym unless app.respond_to?(:session_id)
      app.set :admin_model, 'Account' unless app.respond_to?(:admin_model)
      app.helpers Padrino::Admin::Helpers::AuthenticationHelpers
      app.helpers Padrino::Admin::Helpers::ViewHelpers
      app.before { login_required }
      app.send(:cattr_accessor, :access_control)
      app.send(:access_control=, Padrino::Admin::AccessControl::Base.new)
    end

Also aliased as: included

[Validate]

Generated with the Darkfish Rdoc Generator 2.