Hello all. I have a view where I need to render an action. If i do a render_component in the view, my action code is not executed, and that''s bad for me... My workaround is to do a render_component_as_string in the first action and render this result along with my action rendering... and that''s pretty ugly :( Is there a way to do it another way? -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ 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?hl=en -~----------~----~----~----~------~----~------~--~---
Pedro Cardoso wrote:> Hello all. > > I have a view where I need to render an action. > > If i do a render_component in the view, my action code is not executed, > and that''s bad for me... > > My workaround is to do a render_component_as_string in the first action > and render this result along with my action rendering... and that''s > pretty ugly :( > > Is there a way to do it another way?Put the action in the controller code? If you are going to do this in a lot of places you could put the action as a method in application.rb and use a shared partial for its view. -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ 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?hl=en -~----------~----~----~----~------~----~------~--~---