Rails and metaphors MVC

I am working on re-writing my application based on what I learned in RailsConf 2009. I understand that Model, Controller and View are related. However, one thing I struggled with is the "correct" level for the controller.

If the Rails model displays (approximately) the database table ... And if the Rails View displays (approximately) the browser page ...

What does the Rails controller point to?

+3
source share
6 answers

A controller is a means of connecting models (models) to View (s) using the logic, constraints and conditions of your decision.

So, I suppose it can display the brains of your decision.

+3

, . , .

.

.

... .

+1

- , , . , , . , .

MVC , , . , ( ) , . , - , , , , , , .

, . - , . - , , , , " ", - , .

, "".

+1

. (, ). - , , .

, - . , , , . .

0

URL-, RESTFUL-.

URL- .

0

MVC, , :

  • - ( )

  • - ( )

  • - ( , )

, , "Get It", , . , "" , .

-2

Source: https://habr.com/ru/post/1708700/


All Articles