| Author |
Action as a tile
|
Fedor Smirnoff
Ranch Hand
Joined: Apr 21, 2003
Posts: 45
|
|
Is it against MVC pattern to include an action, which prepares the data, as a tile? something like this: <tiles:insert page="/prepareData.do"/> The reason for that is that I cannot forward to this action and than have action forward to jsp due to the fact that I am using a UrlController for tiles. Thank you.
|
 |
Lasse Koskela
author
Sheriff
Joined: Jan 23, 2002
Posts: 11962
|
|
|
I guess that depends on what this "preparing of data" means? Having your JSP include the results of a servlet or a Struts action is not that different from including the results of another JSP -- it's the semantics, not the technology, that matters most here.
|
Author of Test Driven (2007) and Effective Unit Testing (2013) [Blog] [HowToAskQuestionsOnJavaRanch]
|
 |
Jitesh Sinha
Ranch Hand
Joined: Jun 19, 2004
Posts: 144
|
|
Well,I don't think it matters... Main advantage of tiles is that it makes our JSP coding pattern based... If you can do that,then you are using tiles to your advantage,otherwise not...
|
 |
Fedor Smirnoff
Ranch Hand
Joined: Apr 21, 2003
Posts: 45
|
|
|
Well, this action gets the data from database and populates one of the beans that is used on the jsp page.
|
 |
 |
|
|
subject: Action as a tile
|
|
|