<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <div class="moz-cite-prefix">The issue seems to be your assignment
      mapping of the task data outputs. Please note the "To" and "From"
      columns in the data assignments editor: <br>
      ** When you are mapping DATA INPUTS:<br>
      "From" columns should have the object you are mapping from, so
      like process variables, globals, etc<br>
      "To" columns should have the object you are mapping to, so the
      data input of your task<br>
      <br>
      ** When you are mapping DATA OUTPUTS:<br>
      "From" columns should have the object you are mapping from, so
      your data output of your Task<br>
      "To" columns should have the object you are mapping to, so like
      your process variables, globals, etc.<br>
      <br>
      I think in your case you should just switch your assignments for
      your task data outputs, so:<br>
      ** Task 1:<br>
      from Object="Approve" is mapped to "ApprovedRequest"<br>
      should be<br>
      from Object="ApprovedRequest" is mapped to "Approve"<br>
      <br>
      ** Task 2: <br>
      from Object="Order" is mapped to "OrderItem"<br>
      should be <br>
      from Object="OrderItem" is mapped to "Order"<br>
      <br>
      Hope this helps.<br>
      Tihomir<br>
      On 8/7/12 10:06 AM, Saadi Ajam wrote:<br>
    </div>
    <blockquote
cite="mid:CAAqxCsUexJp_y6ZrKbOeQSqPset8UcioSOeLprPmTi5h59nbvw@mail.gmail.com"
      type="cite">
      <div dir="ltr">Thanks a lot for reply,<br>
        Actually I was searching the internet and I found your post in
        wordpress. And yes it was a variable or binding error. I removed
        all the variables and the forms generated with the no data.<br>
        <br>
        So, Could you please give me some hints about the variables in
        Drools. My whole process example is composed of 2 user tasks
        only:<br>
        <ul>
          <li>In the process properties under "<b>Variable Definition</b>",
            I add "ItemID" = Integer and "ItemName" = String and
            "Approve"=Boolean and "Order"=Boolean<br>
          </li>
          <li>In the first task properties: under "<b>DataInputSet</b>",
            I add "AddItemID"=Integer and "AddItemName"=String | Under "<b>DataOutputSet"</b>
            I add "ApproveRequest"=Boolean</li>
          <ul>
            <li>Under assignments, From Object= "ItemID" is mapped to
              "AddItemID", From Object="ItemName" is mapped to
              "AddItemName", from Object="Approve" is mapped to
              "ApprovedRequest"<br>
            </li>
          </ul>
          <li>In the second task properties: under<b> "DataInputSet"</b>,
            I add "OrderItemID"=Integet and "OrderItemName"=String |
            Inder <b>"DataOutputSet"</b> I add "OrderItem"=Boolean</li>
          <ul>
            <li>Under assignments, From Object= "ItemID" is mapped to
              "OrderItemID", From Object="ItemName" is mapped to
              "OrderItemName", from Object="Order" is mapped to
              "OrderItem"</li>
          </ul>
        </ul>
        Thanks,<br>
        <br>
        <br>
        <br>
        <div class="gmail_quote">On Tue, Aug 7, 2012 at 4:44 PM, Tihomir
          Surdilovic <span dir="ltr">&lt;<a moz-do-not-send="true"
              href="mailto:tsurdilo@redhat.com" target="_blank">tsurdilo@redhat.com</a>&gt;</span>
          wrote:<br>
          <blockquote class="gmail_quote" style="margin:0 0 0
            .8ex;border-left:1px #ccc solid;padding-left:1ex">Task Form
            generation parses your process BPMN2 and it looks as you
            have<br>
            some issues with it - click on the "BPMN2" button in the
            Designer footer<br>
            and then either provide the BPMN2 shown, or the server log
            error(s) it<br>
            generates. If you get errors, provide those, and also click
            on the<br>
            "JSON" button in the footer and provide the JSON
            representation of your<br>
            process.<br>
            <br>
            You can click on the "info" button in the Designer header to
            provide the<br>
            Designer version you are using...that will help as well<br>
            <br>
            Thanks.<br>
            Tihomir<br>
            On 8/7/12 9:02 AM, Sadiroveski wrote:<br>
            &gt; Dear helpers,<br>
            &gt;<br>
            &gt; I designed process in drools with human tasks included,
            add the variables,<br>
            &gt; inputsets and bindings.<br>
            &gt; When I clicked on the "Generate Task Form Templates",
            to add forms I got the<br>
            &gt; following:<br>
            &gt;<br>
            &gt;
----------------------------------------------------------------------------------------<br>
            &gt; type Exception report<br>
            &gt;<br>
            &gt; message<br>
            &gt;<br>
            &gt; description The server encountered an internal error ()
            that prevented it<br>
            &gt; from fulfilling this request.<br>
            &gt;<br>
            &gt; exception<br>
            &gt;<br>
            &gt; java.lang.ArrayIndexOutOfBoundsException: 1<br>
            &gt;<br>
            &gt;
org.jbpm.designer.bpmn2.impl.Bpmn2JsonUnmarshaller.applyTaskProperties(Bpmn2JsonUnmarshaller.java:3482)<br>
            &gt;<br>
            &gt;
org.jbpm.designer.bpmn2.impl.Bpmn2JsonUnmarshaller.applyProperties(Bpmn2JsonUnmarshaller.java:1921)<br>
            &gt;<br>
            &gt;
org.jbpm.designer.bpmn2.impl.Bpmn2JsonUnmarshaller.unmarshallItem(Bpmn2JsonUnmarshaller.java:1645)<br>
            &gt;<br>
            &gt;
org.jbpm.designer.bpmn2.impl.Bpmn2JsonUnmarshaller.unmarshallItem(Bpmn2JsonUnmarshaller.java:1560)<br>
            &gt;<br>
            &gt;
org.jbpm.designer.bpmn2.impl.Bpmn2JsonUnmarshaller.unmarshall(Bpmn2JsonUnmarshaller.java:225)<br>
            &gt;<br>
            &gt;
org.jbpm.designer.bpmn2.impl.Bpmn2JsonUnmarshaller.unmarshall(Bpmn2JsonUnmarshaller.java:201)<br>
            &gt;<br>
            &gt;
org.jbpm.designer.web.server.TaskFormsServlet.doPost(TaskFormsServlet.java:73)<br>
            &gt; &nbsp; &nbsp; &nbsp;
            javax.servlet.http.HttpServlet.service(HttpServlet.java:754)<br>
            &gt; &nbsp; &nbsp; &nbsp;
            javax.servlet.http.HttpServlet.service(HttpServlet.java:847)<br>
            &gt;<br>
            &gt;
org.jbpm.designer.web.filter.impl.PluggableFilter.doFilter(PluggableFilter.java:70)<br>
            &gt;<br>
            &gt; note The full stack trace of the root cause is
            available in the JBoss<br>
            &gt; Web/7.0.1.Final logs.<br>
            &gt;
-------------------------------------------------------------------------------------------<br>
            &gt;<br>
            &gt;<br>
            &gt; Any help please,<br>
            &gt;<br>
            &gt;<br>
            &gt;<br>
            &gt; --<br>
            &gt; View this message in context: <a
              moz-do-not-send="true"
href="http://drools.46999.n3.nabble.com/Error-in-Drools-when-clicking-Generate-Task-Form-Template-tp4019040.html"
              target="_blank">http://drools.46999.n3.nabble.com/Error-in-Drools-when-clicking-Generate-Task-Form-Template-tp4019040.html</a><br>
            &gt; Sent from the Drools: User forum mailing list archive
            at Nabble.com.<br>
            &gt; _______________________________________________<br>
            &gt; rules-users mailing list<br>
            &gt; <a moz-do-not-send="true"
              href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br>
            &gt; <a moz-do-not-send="true"
              href="https://lists.jboss.org/mailman/listinfo/rules-users"
              target="_blank">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
            <br>
            _______________________________________________<br>
            rules-users mailing list<br>
            <a moz-do-not-send="true"
              href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br>
            <a moz-do-not-send="true"
              href="https://lists.jboss.org/mailman/listinfo/rules-users"
              target="_blank">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
          </blockquote>
        </div>
        <br>
      </div>
    </blockquote>
    <br>
  </body>
</html>