Hey guys I was reading JSF redirect via commandButton to see if maybe I was doing the redirect wrong, but I am not, this commandButton redirect with a relative path worked on PrimeFaces 3.5 but now on PrimeFaces 7.0 it just won't, however if I paste the exact absolute redirect url it will work, any idea why?
It was working on PF 3.5 but doesn't on 7.0:
<p:commandButton
value="#{plantillaGeneralMB.cantTrasladosPendientes}"
styleClass="cds-icon-traslados"
onclick="return !validarPaginaActual('solicitartraslados.xhtml');"
action="../movimientos/solicitartraslados.xhtml?faces-redirect=true"
rendered="#{plantillaGeneralMB.blTrasladosPendientes}"
title="#{tooltipsMsg.caja_traslados_pendientes}" ajax="false" />
This works on 7.0:
<p:commandButton
value="#{plantillaGeneralMB.cantTrasladosPendientes}"
styleClass="cds-icon-traslados"
onclick="return !validarPaginaActual('solicitartraslados.xhtml');"
action="/XHTML/movimientos/solicitartraslados.xhtml?faces-redirect=true"
rendered="#{plantillaGeneralMB.blTrasladosPendientes}"
title="#{tooltipsMsg.caja_traslados_pendientes}" ajax="false" />
Notice that I just have to put exactly where the xhtml is to make it work and I think that shouldn't be the way.
This is my project xhtml structure:
whats going on? or am I missing something really obvious?
Also commandButton is on plantillaGeneral.xhtml which is on here: