2
votes
0answers
37 views

Do Rails Join Models Get Controllers?

I have a rails app where my users can buddy up with other users. Since that relationship can have a status (approved/rejected/pending), I decided to go with a join model (UserRelationship) so now I ...
-1
votes
2answers
42 views

Embedded Model Designing — top down or bottom up? [closed]

I am trying to learn RoR and develop a webapp. I have a few models I have thought of for this app, and they are fairly embedded. For example (please excuse my lack of RoR syntax): Model: textbook ...
4
votes
3answers
771 views

Is it okay to call a model method in my view?

In the interest of keeping my Controller's skinny, I put a headline method in a Model. # My Model class Property def headline "#{name} | #{address}" end end (Then, Property Controller for ...
0
votes
2answers
140 views

Which controller should I put for a search action that touches many different models?

I currently have the following models and am designing search functionality that searches within these 3 models: Locations Users User_friends Should I create a search controller or should I put the ...
1
vote
1answer
591 views

Should one declare alternative response types (e.g. JSON) in Rails controller actions even if not utilising them?

Just wondering what the accepted convention is for Rails controller design. Currently, every controller in my app that I've written it set up to send a JSON response when necessary. Thing is, I only ...
3
votes
2answers
679 views

Are session aware Models a bad thing?

I'm thinking specifically in Rails here, but I suspect this is a wider question. In a Rails web application I'm using data from the session in models in order that the models know who is logged in. I ...
7
votes
3answers
444 views

Why decouple view and controller (web)?

Why can't we put them in the same page, like each action paired up with its view? Not using code island, but controller code at top then view code at bottom? What are the problems with this approach? ...
1
vote
3answers
863 views

Organising MVC App with virtual model using external API

I am creating a rails app with following constraints It has no database It uses a web API to store and retrieve the data The connection to the web API is via a custom gem. The Gem has a basic ...
4
votes
2answers
927 views

Rails: controllers vs models which should handle file manipulation

This post by Jamis Buck about keeping Rails controllers skinny has always stuck with me. I have an app in which a zip file consisting of an XML file and some images is uploaded and used to create the ...
5
votes
5answers
838 views

Multi MVC processing vs Single MVC process

I've worked fairly extensively with the MVC framework cakephp, however I'm finding that I would rather have my pages driven by the multiple MVC than by just one MVC. My reason is primarily to maintain ...
13
votes
7answers
8k views

Do experienced Ruby on Rails developers use scaffolding?

In the Ruby on Rails tutorial, I read something that suggested that experienced developers do not use scaffolding since they tend to like to just write the code to connect the MVC on their own. In a ...