<struts>
<package name="employee" extends="struts-default" namespace="/employee">
<default-interceptor-ref name="crudStack"/>
<action name="list" method="list"
class="org.apache.struts2.showcase.action.EmployeeAction" >
<result>/empmanager/listEmployees.jsp</result>
<interceptor-ref name="basicStack"/>
</action>
<action name="edit-*" class="org.apache.struts2.showcase.action.EmployeeAction">
<param name="empId">{1}</param>
<result>/empmanager/editEmployee.jsp</result>
<interceptor-ref name="crudStack">
<param name="validation.excludeMethods">execute</param>
</interceptor-ref>
</action>
<action name="save" method="save"
class="org.apache.struts2.showcase.action.EmployeeAction" >
<result name="input">/empmanager/editEmployee.jsp</result>
<result type="redirect">edit-${currentEmployee.empId}.action</result>
</action>
<action name="delete" method="delete"
class="org.apache.struts2.showcase.action.EmployeeAction" >
<result name="error">/empmanager/editEmployee.jsp</result>
<result type="redirect">edit-${currentEmployee.empId}.action</result>
</action>
</package>
</struts>
|