Hi, here are some ideas about the newly created struts2 codes.
1) The new MenuHelper system looks much clearer than old tag version. Since
the tag version classes is special designed for JSP pages, and the JSP pages
are not using them any more, the MenuModel can switch to the same MenuHelper
system now. It's great no more complex tag methods and share same Velocity
context as whole page models in the Velocity menu templates.
2) MenuTab and MenuTabItem may share same super class. Most of their codes
are same. More meaningful, this makes it possible to define MenuTab’s item
as another MenuTab (multi-level menu), which may be presented like a real
menu or tree like widgets. Same case as the parsed menu classes.
3) There are currently 2 different locations to define an action's required
privileges, the action itself by code and the menu system. I guess they
should be always consistent and would be better if they can be defined at
single place outside the action code, and then inject the configuration
value into the action. There should be some special consideration for
actions not appeared in any menus. May be a never rendered menu define
gathers all those actions in it.

Miles.
-- 
View this message in context: 
http://www.nabble.com/Some-ideas-about-new-struts2-codes-tf3851828s12275.html#a10911385
Sent from the Roller - Dev mailing list archive at Nabble.com.

Reply via email to