- 06 10月, 2014 1 次提交
-
-
由 Alexander Balashov 提交于
-
- 20 6月, 2014 1 次提交
-
-
由 Rafael Mendonça França 提交于
Now the following case will work fine class Tag < ActiveRecord::Base end class Publisher::Article < ActiveRecord::Base has_and_belongs_to_many :tags end Fixes #15761
-
- 25 5月, 2014 1 次提交
-
-
由 Arthur Neves 提交于
Fix habtm reflection Conflicts: activerecord/CHANGELOG.md activerecord/lib/active_record/counter_cache.rb activerecord/lib/active_record/reflection.rb activerecord/test/cases/reflection_test.rb
-
- 20 5月, 2014 1 次提交
-
-
由 Eric Chahin 提交于
Fixes #14824.
-
- 17 5月, 2014 2 次提交
-
-
由 Rafael Mendonça França 提交于
- 15 5月, 2014 1 次提交
-
-
由 Rafael Mendonça França 提交于
parent_name is a string of nil, never a blank string so we don't need to use presence.
-
- 13 5月, 2014 1 次提交
-
-
由 Kassio Borges 提交于
Thank's for @laurocaetano for the help with tests.
😃 Fixes #14709
-
- 13 12月, 2013 1 次提交
-
-
由 Aaron Patterson 提交于
-
- 12 12月, 2013 1 次提交
-
-
由 Rafael Mendonça França 提交于
This is to get activerecord-deprecated_finders work again
-
- 10 10月, 2013 1 次提交
-
-
由 Rafael Mendonça França 提交于
All the job can be done at class level so we can avoid some object allocation
-
- 03 10月, 2013 7 次提交
-
-
由 Aaron Patterson 提交于
-
由 Aaron Patterson 提交于
-
由 Aaron Patterson 提交于
-
由 Aaron Patterson 提交于
-
由 Aaron Patterson 提交于
-
由 Aaron Patterson 提交于
-
由 Aaron Patterson 提交于
-
- 02 8月, 2013 1 次提交
-
-
由 Aaron Patterson 提交于
-
- 03 7月, 2013 2 次提交
-
-
由 Neeraj Singh 提交于
-
由 Neeraj Singh 提交于
-
- 02 7月, 2013 1 次提交
-
-
由 Neeraj Singh 提交于
Deprecated options `delete_sql`, `insert_sql`, `finder_sql` and `counter_sql` have been deleted.
-
- 11 8月, 2012 2 次提交
-
-
由 Jon Leighton 提交于
Method compilation provides better performance and I think the code comes out cleaner as well. A knock on effect is that methods that get redefined produce warnings. I think this is a good thing. I had to deal with a bunch of warnings coming from our tests, though.
-
由 Jon Leighton 提交于
Well, not all of them, but some of them. I don't think there's much reason for these methods to be private.
-
- 02 8月, 2012 2 次提交
-
-
由 Jon Leighton 提交于
-
由 Jon Leighton 提交于
This reverts commit 3803fcce. Conflicts: activerecord/CHANGELOG.md It will be deprecated only in 4.0, and removed properly in 4.1.
-
- 21 7月, 2012 1 次提交
-
-
由 Jon Leighton 提交于
-
- 14 7月, 2012 1 次提交
-
-
由 Jon Leighton 提交于
-
- 22 6月, 2012 1 次提交
-
-
由 Andrew White 提交于
Improve the derivation of HABTM join table name to take account of nesting. It now takes the table names of the two models, sorts them lexically and then joins them, stripping any common prefix from the second table name. Some examples: Top level models (Category <=> Product) Old: categories_products New: categories_products Top level models with a global table_name_prefix (Category <=> Product) Old: site_categories_products New: site_categories_products Nested models in a module without a table_name_prefix method (Admin::Category <=> Admin::Product) Old: categories_products New: categories_products Nested models in a module with a table_name_prefix method (Admin::Category <=> Admin::Product) Old: categories_products New: admin_categories_products Nested models in a parent model (Catalog::Category <=> Catalog::Product) Old: categories_products New: catalog_categories_products Nested models in different parent models (Catalog::Category <=> Content::Page) Old: categories_pages New: catalog_categories_content_pages Also as part of this commit the validity checks for HABTM assocations have been moved to ActiveRecord::Reflection One side effect of this is to move when the exceptions are raised from the point of declaration to when the association is built. This is consistant with other association validity checks.
-
- 19 5月, 2012 1 次提交
-
-
由 Jon Leighton 提交于
-
- 15 12月, 2011 1 次提交
-
-
由 Jon Leighton 提交于
-
- 28 11月, 2011 1 次提交
-
-
由 Josh Susser 提交于
-
- 16 11月, 2011 1 次提交
-
-
由 Josh Susser 提交于
Instead of generating association methods directly in the model class, they are generated in an anonymous module which is then included in the model class. There is one such module for each association. The only subtlety is that the generated_attributes_methods module (from ActiveModel) must be forced to be included before association methods are created so that attribute methods will not shadow association methods.
-
- 09 7月, 2011 1 次提交
-
-
由 Tomas D'Stefano 提交于
-
- 26 5月, 2011 1 次提交
-
-
由 Mohammad El-Abid 提交于
-
- 24 3月, 2011 1 次提交
-
-
由 Murray Steele 提交于
The old method of redefining destroy meant that clearing the HABTM join table would happen as long as the call to destroy succeeded. Which meant if there was a before_destroy that stopped the instance being destroyed using normal means (returning false, raising ActiveRecord::Rollback) rather than exceptional means the join table would be cleared even though the instance wasn't destroyed. Doing it in an after_destroy hook avoids this and has the advantage of happening inside the DB transaction too.
-
- 22 2月, 2011 1 次提交
-
-
由 Jon Leighton 提交于
Use proper objects to do the work to build the associations (adding methods, callbacks etc) rather than calling a whole bunch of methods with rather long names.
-