Currently, the model layer's service section holds MainService
with the following objectives
MainService => Communicates with persistence layer,
does the UI logic,
renders the respective view
The OP of the question here describes the idea; views should do the UI and then render (depends) the respective template.
An example of MainService
is similar to
echo $this->factory->template()
->file('/path/to/template')
->set('url', 'some/url')
->render();
It is clear that this contradicts clearly with the concept of Views
. And this is where I get confused - the current implementation of service looks a lot like a view. Is it a view then?