Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | load active_support/core_ext/class/attribute in active_support/rails | Xavier Noria | 2012-08-02 | 1 | -1/+0 |
| | |||||
* | load active_support/core_ext/object/inclusion in active_support/rails | Xavier Noria | 2012-08-02 | 1 | -1/+0 |
| | |||||
* | Simplify AR configuration code. | Jon Leighton | 2012-06-15 | 1 | -4/+9 |
| | | | | | Get rid of ActiveModel::Configuration, make better use of ActiveSupport::Concern + class_attribute, etc. | ||||
* | Fix #6591. If a field with timezone isn't changed, we don't call will_change!. | kennyj | 2012-06-04 | 1 | -1/+2 |
| | |||||
* | force datetime attributes to be changed, fix GH #3965 | Sergey Nartimov | 2012-02-28 | 1 | -0/+1 |
| | |||||
* | removing dead code | Aaron Patterson | 2012-02-09 | 1 | -10/+0 |
| | |||||
* | give each PG type a `type` method and decortate tz attributes | Aaron Patterson | 2012-02-07 | 1 | -1/+18 |
| | |||||
* | moved most of the evald code in to regular ruby code | Aaron Patterson | 2012-02-07 | 1 | -5/+2 |
| | |||||
* | copy the columns hash to the active record instances, typecast using columns ↵ | Aaron Patterson | 2012-02-07 | 1 | -33/+46 |
| | | | | looked up on the instance | ||||
* | Support configuration on ActiveRecord::Model. | Jon Leighton | 2011-12-28 | 1 | -3/+4 |
| | | | | | | | | | | | | | | | 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. | ||||
* | Deal with global config better between AR::Base and AR::Model | Jon Leighton | 2011-12-24 | 1 | -3/+2 |
| | |||||
* | Fix #3837. | Jon Leighton | 2011-12-03 | 1 | -11/+5 |
| | | | | | We also need to time zone convert time zone aware attributes when accessed via read_attribute, not only when via direct access. | ||||
* | Remove some unnecessary code etc | Jon Leighton | 2011-12-01 | 1 | -19/+3 |
| | |||||
* | Remove the need for type_cast_attribute. | Jon Leighton | 2011-12-01 | 1 | -3/+16 |
| | | | | This is good because it reduces duplication. | ||||
* | Don't rely on underscore-prefixed attribute methods. | Jon Leighton | 2011-12-01 | 1 | -11/+15 |
| | | | | | | Define singleton methods on the attributes module instead. This reduces method pollution on the actual model classes. It also seems to make something faster, I am unsure why! O_o | ||||
* | Remove `#among?` from Active Support | Prem Sichanugrist | 2011-04-13 | 1 | -1/+1 |
| | | | | | | After a long list of discussion about the performance problem from using varargs and the reason that we can't find a great pair for it, it would be best to remove support for it for now. It will come back if we can find a good pair for it. For now, Bon Voyage, `#among?`. | ||||
* | Change Object#either? to Object#among? -- thanks to @jamesarosen for the ↵ | David Heinemeier Hansson | 2011-04-12 | 1 | -1/+1 |
| | | | | suggestion! | ||||
* | Using Object#in? and Object#either? in various places | Prem Sichanugrist | 2011-04-11 | 1 | -1/+2 |
| | | | | There're a lot of places in Rails source code which make a lot of sense to switching to Object#in? or Object#either? instead of using [].include?. | ||||
* | Fix before_type_cast for timezone aware attributes by caching converted ↵ | Adam Meehan | 2011-03-23 | 1 | -4/+5 |
| | | | | value on write. Also remove read method reload arg on timezone attributes. | ||||
* | avoid nil.dup | Akira Matsuda | 2011-02-07 | 1 | -1/+1 |
| | | | | Signed-off-by: Santiago Pastorino <santiago@wyeworks.com> | ||||
* | Make before_type_cast available for datetime fields | Akira Matsuda | 2011-02-01 | 1 | -2/+3 |
| | | | | | | [#3973 state:committed] Signed-off-by: Santiago Pastorino <santiago@wyeworks.com> | ||||
* | class inheritable attributes is used no more! all internal use of class ↵ | Josh Kalderimis | 2010-11-20 | 1 | -2/+4 |
| | | | | | | inheritable has been changed to class_attribute. class inheritable attributes has been deprecated. Signed-off-by: José Valim <jose.valim@gmail.com> | ||||
* | Cheaper attribute reads and respond_to?. Add underscore-prefixed method ↵ | Jeremy Kemper | 2010-09-09 | 1 | -2/+3 |
| | | | | aliased to the attribute name so it can be overridden but still called internally. | ||||
* | Deletes trailing whitespaces (over text files only find * -type f -exec sed ↵ | Santiago Pastorino | 2010-08-14 | 1 | -1/+1 |
| | | | | 's/[ \t]*$//' -i {} \;) | ||||
* | ensuring that description does not exceed 100 columns | Neeraj Singh | 2010-08-02 | 1 | -1/+2 |
| | |||||
* | fix stack trace lines on class_eval | Santiago Pastorino | 2010-04-09 | 1 | -4/+4 |
| | | | | Signed-off-by: José Valim <jose.valim@gmail.com> | ||||
* | Revert "Refactoring attributes/types" [#3348 state:open] | Pratik Naik | 2010-01-22 | 1 | -10/+38 |
| | | | | | | | | | | | | | | | | | This reverts commit f936a1f100e75082081e782e5cceb272885c2df7. Conflicts: activerecord/lib/active_record.rb activerecord/lib/active_record/base.rb Revert "Fixed: #without_typecast should only disable typecasting on the duplicated attributes" [#3387 state:open] This reverts commit 2831996483c6a045f1f38d8030256eb58d9771c3. Reason : It's not generating attribute methods properly, making object.column 5x slower. | ||||
* | Refactoring attributes/types [#3348 state:resolved] | Eric Chapweske | 2009-10-17 | 1 | -38/+10 |
| | | | | Signed-off-by: Joshua Peek <josh@joshpeek.com> | ||||
* | Extract generic attribute method generation to AMo | Joshua Peek | 2009-08-04 | 1 | -2/+2 |
| | |||||
* | Modified ActiveRecord::AttributeMethods to allow classes to specify ↵ | Paul Gillard | 2009-08-04 | 1 | -2/+2 |
| | | | | | | attribute method prefixes and/or suffixes. Previously only suffixes were allowed. Signed-off-by: Joshua Peek <josh@joshpeek.com> | ||||
* | Track generated attribute methods in a separate module | Joshua Peek | 2009-08-02 | 1 | -2/+2 |
| | |||||
* | Don't need to pass attr_name to evaluate_attribute_method anymore | Joshua Peek | 2009-07-30 | 1 | -2/+2 |
| | |||||
* | Concernify AR AttributeMethods | Joshua Peek | 2009-07-30 | 1 | -0/+60 |