Grant Rodgers
Not a member
Grant Rodgers's latest activity
Saturday, February 16 2008
-
Grant Rodgers commented at 5:01 PMPretty simple really, I just replaced the contents of the define_method block in collection_reader_method with
reflection.klass.query_context.select { |entity...
Friday, February 15 2008
-
Grant Rodgers commented at 7:53 PMActiveRecord associations already support Enumerable methods, but they're useless in large scale apps because the entire collection is loaded, and you could ha...
Tuesday, November 13 2007
-
Grant Rodgers created the ticket at 5:04 PM(sorry, sql is oracle)
The paginate finder handles a nil value for page:
Company.paginate(:page => nil, :per_page => 10) => select * from (select raw_sql_.*...
Friday, September 21 2007
-
Grant Rodgers commented at 12:06 PMYep, that occurred to me. Certainly a matter of taste which you prefer.
I think it might be a bit better encapsulated as a special method, and maybe faster s...
Thursday, September 20 2007
-
Grant Rodgers commented at 6:47 PMNot sure how add-ons are packaged, unfortunately - let me know if there's something else to be done.
-
Grant Rodgers commented at 6:46 PMworks like this:
class User < ActiveRecord::Base scoped_context :admins do |context| context.select { |u| u.type == 'Admin' } end end User.admi... -
Thursday, September 06 2007
-
Grant Rodgers created the ticket at 5:07 PMSeems like a natural addition: add all the goodness from ActiveRecord classes to associations!
We have this kind of stuff all over our app:
current_user.answ...
-
Grant Rodgers created the ticket at 4:53 PMIt would be really cool if Ambition had scoped finders, ala scope_out, has_finder, and scoped_proxy
Combining nested scopes with kicker methods would do wonde...