Hi! I have simple JSF form:
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:t="http://myfaces.apache.org/tomahawk" xmlns:h="http://java.sun.com/jsf/html" xmlns:f="http://java.sun.com/jsf/core">
<ui:composition template="layout.jsp">
<ui:define name="title">Редактирование шаблона</ui:define>
<ui:define name="content">
<t:div rendered="#{template.hasErrors}">
#{template.errorText}
</t:div>
<t:div rendered="#{template.hasMessage}">
#{template.messageText}
<p>
<a href="/templates.jsf">Все шаблоны</a>
</p>
</t:div>
<t:div rendered="#{template.canEdit}">
<h:form>
Name: <h:inputText value="#{template.name}"/> <br/>
Content Type: <h:inputText value="#{template.contentType}"/> <br/>
Content: <h:inputTextarea value="#{template.content}"/> <br/>
Description: <h:inputTextarea value="#{template.description}"/> <br/>
<h:commandButton value="Сохранить" action="#{template.submit}">
</h:commandButton>
</h:form>
</t:div>
</ui:define>
</ui:composition>
</html>
Everything works, but when I'm trying to use this page with query string parameters (template.jsf?Id=5) and then sumbit command button -- page is redirected to template.jsf (witout query string parameter. And it is clear -- form action attribute always ="template.jsf", even query string parameters are passed). So I can't call submit method for TemplateBean with specified query string parameter.