Ruby on Rails Wednesday, June 4, 2014

Jesse Knutsen wrote in post #1148805:
> I am not a huge fan of an approach that would need to redirect in this
> way.
>
> Instead, why not create a new class called login or something like that.
>
> You will need to adapt a bit to your needs, but the basics are sound and
> should apply nicely.

I don't think this would really solve the problem:

From the model, user and login data are already separated from the Dicts
data (the user id is a foreign key in the Dicts mode, pointing to the
user who owns the Dict).

In the controller side, I have them also separated: The HomeController
is responsible for the Login (I could also have named it
LoginController), and the DictController is responsible for managing the
Dict objects. I don't see wll how what can be improved in this area.

The problem is the user interface. Clicking one button performs a login
AND at the same time either CREATES or OPENS a dict object.

If I would split this into two views, one for login and one for the
usual interface of maintaining dictionaries, I wouldn't run into this
problem, but this would be less convenient to the user.

--
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 unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/734d7bdc034dbe3094b14cd77314d635%40ruby-forum.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment