Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 1048641

Summary: Using a subform to map object graphs doesn't work on task input
Product: [Retired] JBoss BPMS Platform 6 Reporter: Babak Mozaffari <bmozaffa>
Component: Form ModelerAssignee: Pere Fernàndez <pere.fernandez>
Status: CLOSED NOTABUG QA Contact: Jan Hrcek <jhrcek>
Severity: medium Docs Contact:
Priority: medium    
Version: 6.0.0CC: bmozaffa, kverlaen, lpetrovi, pzapataf
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: All   
OS: All   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-06-27 06:15:16 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Unzip and use the .git directory in it as a repository to clone
none
Unzip and use the .git directory in it as a repository to clone
none
Screenshot none

Description Babak Mozaffari 2014-01-06 01:33:52 UTC
Created attachment 845872 [details]
Unzip and use the .git directory in it as a repository to clone

Description of problem:

The Java class in use embeds another custom Java type. For both the process instantiation and the task creation, a subform is successfully used to populate the "Application" object as well as its "Property" field but the same approach does not work to populate the Property field from existing values when entering the task.

Version-Release number of selected component (if applicable):

BPMS 6.0 ER7 with EAP 6.1.1

How reproducible:

Steps to Reproduce:
1. Clone attached repository.
2. Build project.
3. Start process and populate all form fields
4. Claim task (as user with role of manager) and observe the task form when completing

Actual results:
Application fields are populated, except for the fields of the Property inside the Application, which are left blank.

Expected results:
The two Property fields should also be populated

Additional info:

Comment 2 Pedro Zapata 2014-01-07 16:01:17 UTC
As a first step, please verify if the bindings are well configured and it's working as expected.

Comment 3 Jan 2014-01-13 12:23:02 UTC
Hi Jan,

I've checked the form and process mappings and it seems the problem was in the ApplicationProperty.form. Its data origin entry id was empty, but should also point to 'property'. Once I changed this it started working correctly.
Could you recheck this in your local environment?

Regards,

Jan.

Comment 4 Babak Mozaffari 2014-01-13 19:57:08 UTC
Ok that's really odd. I was able to verify it in this test case but in the original application, I seemed to be getting errors that led me to remove the data origin input id (since it was null on form instantiation, I assumed that may have been causing the NPE).

I will reopen if I find an issue but I can confirm that the attached test case does not expose any issues.

Comment 5 Babak Mozaffari 2014-01-13 21:59:28 UTC
Created attachment 849639 [details]
Unzip and use the .git directory in it as a repository to clone

Actually my previous comment was (vaguely) right. New problems arise from setting this input, even on this simplified test case. In this example, it is an error in the log while building (java.lang.NullPointerException at org.uberfire.metadata.io.BatchIndex$1.run(BatchIndex.java:57)) but after the task input is correctly rendered, trying to submit it results in an error on the form with a red message saying "There is no default form." for property, even though one is clearly present and even used. Functional code, at least in this example, appears to be ok and work.

Comment 6 Jan 2014-01-15 10:45:46 UTC
Hi,

I've deployed your project in a recent build of business-central from the master branch (tried to do it in ER7, but this has a bug related to git cloning so with this version I could not deploy your project).

I have not been able to reproduce the error that you say happens when building&deploying the project. Also, the process seems to run just fine, I have not met with any errors there either. Perhaps you could recheck this also on a more recent build?

Regards

Comment 7 Babak Mozaffari 2014-01-16 22:18:17 UTC
Created attachment 851293 [details]
Screenshot

Please look at the attached screenshot. The task form is ok functionally but the user is left with an error on the screen that they should ignore, however this error and the incorrectly rendered form after completion of the task pose a problem themselves.

Comment 10 Jan Hrcek 2014-06-25 08:08:05 UTC
QE update for BPMS 6.0.2 CR2: It is no longer possible to reproduce the issue with Babak's attached project, because once task is completed, the project is also completed and the panel "Task details" is automatically closed. In order to reproduce this we need a process with multiple human tasks, so that when we complete one task, the task details panel is not automatically closed and we can see "No default subform" error after completing the task.

@Babak: can you still reproduce the problem?

Comment 12 Jan Hrcek 2014-06-27 06:15:16 UTC
I updated Babak's reproducer process to include one extra dummy human task, so that after completing the first task, the "Task details" dialog in the task list is no longer automatically closed. I was no longer able to reproduce this issue with 6.0.2 CR2, it is working correctly now. Closing as not a bug.