[Rails] Re: Does using :render = :partial breaks the MVC separation during an ajax call

2010-12-24 Thread ivanpoval
The code sample you provided is very common and many respectful Rails developers use it. If we go out of the scope of Rails and start speaking very strictly about MVC, then probably we can say that it is not actually the controller's job to do that type of things. But I think that render :update

[Rails] Re: Does using :render = :partial breaks the MVC separation during an ajax call

2010-12-24 Thread Marnen Laibow-Koser
ivanpoval wrote in post #970446: The code sample you provided is very common and many respectful Rails developers use it. If we go out of the scope of Rails and start speaking very strictly about MVC, then probably we can say that it is not actually the controller's job to do that type of

Re: [Rails] Re: Does using :render = :partial breaks the MVC separation during an ajax call

2010-12-24 Thread Colin Law
On 24 December 2010 14:29, Marnen Laibow-Koser li...@ruby-forum.com wrote: ivanpoval wrote in post #970446: The code sample you provided is very common and many respectful Rails developers use it. If we go out of the scope of Rails and start speaking very strictly about MVC, then probably we

[Rails] Re: Does using :render = :partial breaks the MVC separation during an ajax call

2010-12-24 Thread ivanpoval
No. It *is* the controller's job to trigger render operations. There's nothing un-MVC about this at all. Sure it's a controller's job to trigger render operations. But render :update is a special kind of operation that generates JavaScript in your action, and sometimes that JavaScript can