aboutsummaryrefslogtreecommitdiffstats
path: root/activemodel/lib/active_model/mass_assignment_security.rb
Commit message (Collapse)AuthorAgeFilesLines
* Array.wrap no longer neededAaron Patterson2012-01-041-3/+2
|
* Support configuration on ActiveRecord::Model.Jon Leighton2011-12-281-10/+12
| | | | | | | | | | | | | | | The problem: We need to be able to specify configuration in a way that can be inherited to models that include ActiveRecord::Model. So it is no longer sufficient to put 'top level' config on ActiveRecord::Base, but we do want configuration specified on ActiveRecord::Base and descendants to continue to work. So we need something like class_attribute that can be defined on a module but that is inherited when ActiveRecord::Model is included. The solution: added ActiveModel::Configuration module which provides a config_attribute macro. It's a bit specific hence I am not putting this in Active Support or making it a 'public API' at present.
* AM::MAS.attr_protected: rework usage example.Bogdan Gusiev2011-12-231-9/+9
|
* Fixed AM::MasAsSec.attr_protected usage example. Bogdan Gusiev2011-12-221-15/+16
| | | | | | | | Problems with current example: * DOESN'T WORK ** attr_protected :last_login, :as => :admin # doesn't make it accessible for admin * Uses ActiveSupport Fixnum extension
* Fix AM::MassAssignementSecurity docBogdan Gusiev2011-12-221-1/+1
|
* Minor formating fixAlexander Uvarov2011-06-241-2/+2
|
* Follow rails convention by using Array.wrapAlexander Uvarov2011-06-231-2/+3
|
* Allow to specify mass-assignment roles as arrayAlexander Uvarov2011-06-231-2/+8
|
* no need for .rbDamien Mathieu2011-05-311-1/+1
|
* string inflections are needed for running tests in isolationDamien Mathieu2011-05-311-0/+1
|
* Transform the symbol into a constant lookup.José Valim2011-05-311-17/+13
|
* ActiveModel::MassAssignmentSecurity.mass_assignment_sanitizer methodBogdan Gusiev2011-05-301-6/+24
| | | | | In order to specify your own sanitize method Implemented .mass_assignment_sanitizer configuration option
* MassAssignmentSecurity: add ability to specify your own sanitizerBogdan Gusiev2011-05-261-5/+9
| | | | | | Added an ability to specify your own behavior on mass assingment protection, controlled by option: ActiveModel::MassAssignmentSecurity.mass_assignment_sanitizer
* renamed mass-assignment scopes to roles, updated code, tests, docs and ↵Josh Kalderimis2011-05-081-23/+23
| | | | security guide
* minor correction to the AMo mass-assignment security docsJosh Kalderimis2011-04-241-1/+1
|
* AM mass assignment security attr_accessible and attr_protected now allow for ↵Josh Kalderimis2011-04-241-34/+85
| | | | | | | | scopes using :as => scope eg. attr_accessible :name attr_accessible :name, :admin, :as => :admin
* Remove Example headers. Code just flows with the text. 6ce844a3Paco Guzman2011-03-061-3/+1
|
* Properly indent code example blockDaniel Schierbeck2011-01-151-19/+19
|
* Change documentation for ActiveModel::MassAssignmentSecurity a bit and make ↵José Valim2010-07-081-26/+41
| | | | debug always be called since some people may overwrite warn! to add extra behavior even if logger is not available.
* mass_assignment_security moved from AR to AMo, and minor test cleanupJosh Kalderimis2010-07-081-0/+145
Signed-off-by: José Valim <jose.valim@gmail.com>