1 Reply Latest reply on Jan 10, 2010 12:10 PM by Ronald van Kuijk

    How to start a task from UI?

    Sergio Figueras Newbie

      Hi everyone,

       

      I've decided that I need every time when user see the Examine (task.jsf) form, if the task that user is wanting to see isn't started, the task should be started. If it is suspended, the task should be active. So, I've done a little modification at task.xhtml form. Wich is:

       

      <ga:responseActions>
                      <ga:parameter name="id" target="#{id}"/>
                      <j4j:loadTask id="#{id}" target="#{task}"/>
                     
                      <c:if test="#{task.start == null}">
                         
                         <j4j:startTask task="#{task}"/>
                          <n:nav outcome="success" redirect="true" storeMessages="true"/>
                          <n:nav outcome="error" redirect="true" storeMessages="true"/>
                      </c:if>

       

      But, when the condition of c:if is running, there's no task at all. It always run the if statement and executes the statement.

       

      I know that the ga:responseActions is a component that execute commands when the response is being made.

       

      What I need to do? Can somebody help me? Where can I get the actual task?

       

      Thanks!