|
|
Pessoal, sou um pouco inexperiente em JSF e estou com um problema de
navegação.
Estou usando Richfaces 3.3.3, Facelets 1.1.15, Mojarra 2.1.1 e Tomcat
7.0.8
Tenho um botao nem um fragment:
<ui:fragment>
<table>
<tr>
<td class="primeiraColuna">
<h:outputText
value="#{titulo}" />
</td>
<td>
<h:commandButton
value="Adicionar"
action="#{buscaPessoa.procurar}"
immediate="true">
<f:setPropertyActionListener
target="#{buscaPessoa.voltarPara}" value="#{voltarPara}" >
</f:setPropertyActionListener>
</h:commandButton>
</td>
</tr>
.
.
.
Esse <ui:fragment> está sendo reutilizado em três lugares.
Ao clicar no botao, sou redirecionado para uma pagina onde há um
commandLink dentro de um datatable:
<h:commandLink value="#{item.nome}"
action="#{buscaPessoa.selecionarLinha}" >
<f:param name="idPessoaEscolhida" value="#{item.id}" >
</f:param>
</h:commandLink>
Nesse metodo selecionarLinha retorno a string a ser processada no
<from-outcome>:
<navigation-rule>
<from-view-id>/buscaPessoaFisicaJuridica.xhtml</from-view-id>
<navigation-case>
<from-action>#{buscaPessoa.selecionarLinha}</from-action>
<from-outcome>voltar_PropriedadeRural</from-outcome>
<to-view-id>#{propriedadeRural.setarProprietarioAction()}</to-view-
id>
</navigation-case>
<navigation-case>
<from-action>#{buscaPessoa.selecionarLinha}</from-action>
<from-outcome>voltar_Projeto_Parceiro</from-outcome>
<to-view-id>#{projeto.setarParceiroAction()}</to-view-id>
</navigation-case>
<navigation-case>
<from-action>#{buscaPessoa.selecionarLinha}</from-action>
<from-outcome>voltar_Projeto_Apoio</from-outcome>
<to-view-id>#{projeto.setarApoioAction()}</to-view-id>
</navigation-case>
......
Não sei o que há de errado com essa navigation-rule, ou se o problema
é no frament, mas estão sendo chamados todos os 3 métodos no <to-view-
id> !!!!!
É como se 3 commandButton do fragment estivessem sendo clicados!
Alguém tem alguma dica? Obrigado!
--
Você recebeu esta mensagem por que é membro do Javasf
http://groups.google.com/group/javasf
Conheça também o Java Brazil: http://groups.google.com/group/thejavabrazil
|
|