Hey, I know that in a MVC type design, your view should contain all presentation of data to the user.
I have some conflicts with this. I want to be able to show my user something depending on some data. So I would have to query the database and check for a piece of info and then show the user something depending on that info.
Does this break MVC conventions or am I ok doing it this way? Other method suggestions welcome.
Example:
I want to mark a blog post if the user has commented on it.
The right way: get all the data in controller (including that post have user’s comment) and pass it to your view. In view you can use simple check like