Hi everyone, I''ve just found out that the :model method in ActionController is now depricated. According to the source it suggests that it is now taken care of via ActiveSupport. Can anyone tell me the equivelant method in ActiveSupport? I''ve had a look and the candidates for what I think is equivelant are :depend_on :associate_with (a wrapper around :depend_on) :require_or_load I''m leaning toward :depend_on can someone confirm or point me in the right direction please? I''ve also noticed that with these methods multiple models can no longer be specified in a single call. Any help would be great. Cheers Daniel --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk -~----------~----~----~----~------~----~------~--~---
On 2006-09-20, at 22:47 , Daniel N wrote:> Hi everyone, > > I''ve just found out that the :model method in ActionController is > now depricated. According to the source it suggests that it is now > taken care of via ActiveSupport. > > Can anyone tell me the equivelant method in ActiveSupport? I''ve > had a look and the candidates for what I think is equivelant are >There''s no method in active_support. What the deprecation means is that if you reference a constant, say, Post and it''s undefined, then rails will try to load post.rb, and expect it to define Post. So it''s all automagic now. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk -~----------~----~----~----~------~----~------~--~---
On 9/21/06, Caio Chassot <lists-eaoxph6vF1dWk0Htik3J/w@public.gmane.org> wrote:> > > > On 2006-09-20, at 22:47 , Daniel N wrote: > > > Hi everyone, > > > > I''ve just found out that the :model method in ActionController is > > now depricated. According to the source it suggests that it is now > > taken care of via ActiveSupport. > > > > Can anyone tell me the equivelant method in ActiveSupport? I''ve > > had a look and the candidates for what I think is equivelant are > > > > There''s no method in active_support. What the deprecation means is > that if you reference a constant, say, Post and it''s undefined, then > rails will try to load post.rb, and expect it to define Post. > > So it''s all automagic now.The main reason that I used the :model method was if I was storing objects in the session. Does the automagic happen with re-constituded objects from the session? Thanx for the reply --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk -~----------~----~----~----~------~----~------~--~---
On 2006-09-21, at 03:19 , Daniel N wrote:> The main reason that I used the :model method was if I was storing > objects in the session. > > Does the automagic happen with re-constituded objects from the > session? >I don''t really know. I often disrecommend storeing ARs in the session (store the id instead) Try without model and let''s see how it goes. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk -~----------~----~----~----~------~----~------~--~---