Hi All! This is my first e-mail. My name is Márcio Gurgel, I'm from Brasília (Brazil). My english isn't very well, I hope you understand (: There's 10 months that I'm working with J2EE. I'll finish my graduation this semester, than I'm developing a final project using Struts 2.
So, I have a question.. Hope you can help me. My aplication uses displayTag for list rendering. To make search's I use two tabs (Criteria and Results). My problem is on the tab Results when it has paging. When I click in the pagination, it just got lost. I tried do resolve this doing: 1 - Seting requestURI="" to call the action that returns the jsp with my tabbed panel. This way, returns the tab of Criteria selected (I want the Results tab). 2 - Seting requestURI="" to call the action that returns the jsp with my list (inside the Results tab). This way my list opens in another frame. Here's my code (I changed the Labels to english) I atached a screen, as I sayd I dont trust in my english... File UsuSeach.jsp (Contains tabbedPanel) ----------------------------------------------------------------------------------------------------------------------- <%@ taglib prefix="s" uri="/struts-tags" %> <%@ taglib prefix="sx" uri="/struts-dojo-tags" %> <%@ taglib prefix="d" uri="sgvdba-tags" %> <script type="text/javascript"> function selectTab(id) { var tabContainer = dojo.widget.byId("panelUsu"); tabContainer.selectTab(id); } </script> <sx:head /> <d:titleBar title="User's search"/> <s:url id="urlOpenCriteria" action="OpenCriteria" namespace="/user"/> <s:url id="urlSearch" action="search" namespace="/user"/> <sx:tabbedpanel id="panelUsu" templateCssPath="/css/dojo/TabContainer.css"> <sx:div label="Criteria" id="tabCriteria" href="%{urlOpenCriteria}" loadingText="Carregando" /> <sx:div label="Results" id="tabResults" href="%{urlSearch}" loadingText="Carregando" refreshOnShow="false" preload="false" executeScripts="true"/> </sx:tabbedpanel> File UsuSeachCriteria.jsp (Criteria) ----------------------------------------------------------------------------------------------------------------------- <%@ taglib prefix="s" uri="/struts-tags" %> <%@ taglib prefix="sx" uri="/struts-dojo-tags" %> <%@ taglib prefix="d" uri="sgvdba-tags" %> <sx:head/> <s:div cssClass="errors"> <s:actionerror /> <s:fielderror /> </s:div> <s:form action="search" namespace="/user"> <s:textfield name="currentUsu.chv" id="currentUsu.chv" label="User's name" /> <s:textfield name="currentUsu.eMail" id="usu.eMail" label="E-mail" /> <sx:datetimepicker name="currentUsu.dtGvr" id="currentUsu.dtGvr" label="Data gravação" toggleType="fade" toggleDuration="500"/> <d:buttonBar> <sx:submit id="buttonSearch" name="buttonSearch" value="Search" onclick="selectTab('tabResults')" targets="tabResults" /> </d:buttonBar> </s:form> File UsuSeachResults.jsp (Results) ----------------------------------------------------------------------------------------------------------------------- <%@ taglib prefix="s" uri="/struts-tags"%> <%@ taglib prefix="sx" uri="/struts-dojo-tags" %> <%@ taglib prefix="d" uri="sgvdba-tags"%> <%@ taglib prefix="display" uri="http://displaytag.sf.net"%> <sx:head /> <br/> <sx:div cssClass="errors"> <s:actionerror /> <s:fielderror /> </sx:div> <s:form action="exclude" namespace="/user"> <display:table sort="page" requestURI="/usuario/abrirPesquisa.action" cellpadding="0" cellspacing="0" id="listUsu" class="list" name="listUsuPesquisa" pagesize="10"> <display:column title='<input type="checkbox" name="selectAll" id="selectAll" value="" onclick="checkAll()"/>'> <s:checkbox name="checkBox" id="checkBox" value="idUsus" theme="simple" onclick="confirmAllChecked()" /> </display:column> <display:column sortProperty="chv" title="User" property="chv"/>//It's gonna be a link.. <display:column title="E-mail" property="EMail"/> <display:column title="Date" property="dtGvr"/> <display:column title="Access level" property="nvlAcso.dcr" /> <display:footer /> </display:table> <br> <d:buttonBar> <sx:submit id="buttonNew" name="buttonNew" value="New" /> <sx:submit id="buttonExclude" name="buttonExclude" value="Exclude"/> </d:buttonBar> </s:form> Tanks all!!! []'s