Bug 1007783 - Html label doens't save edited text
Summary: Html label doens't save edited text
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: JBoss BPMS Platform 6
Classification: Retired
Component: Form Modeler
Version: 6.0.0
Hardware: Unspecified
OS: Unspecified
high
medium
Target Milestone: ER5
: 6.0.0
Assignee: Neus Miras
QA Contact: Jan Hrcek
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-09-13 10:01 UTC by Michael
Modified: 2014-08-06 20:10 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-08-06 20:10:38 UTC
Type: Bug


Attachments (Terms of Use)
save button in the middle (39.86 KB, image/png)
2013-09-13 13:32 UTC, Michael
no flags Details
Video showing current behavior - not saving edits (5.73 MB, video/webm)
2013-10-21 06:34 UTC, Jan Hrcek
no flags Details

Description Michael 2013-09-13 10:01:47 UTC
Description of problem:
When adding a HTML field to a form and editing this the "save" button appears in the middle of the raised window (see attachment).
If we save something in the HTML label we have to do it twice. The first time the change isn't changed.


Version-Release number of selected component (if applicable):
kie-wb.SNAPSHOT-6.0.0-as-7.war in JBoss EAP 6.1

How reproducible:


Steps to Reproduce:
1. Create a form and add a HTML label
2. Edit HTML label
3. Add a text and save

Actual results:
You will see thta nothing is saved. You have to repeat this operation.

Expected results:
The edited text in the HTML label should be saved

Comment 3 Michael 2013-09-13 13:32:59 UTC
Created attachment 797338 [details]
save button in the middle

Comment 4 Pedro Zapata 2013-09-18 09:36:58 UTC
Related to this, if the form is closed and reopened, you can't edit labels. The following error appears: 



11:35:36,762 ERROR [org.jbpm.formModeler.core.processing.impl.FormStatusDataImpl] (http-localhost/127.0.0.1:8080-7) Error: : java.lang.ClassCastException: org.jbpm.formModeler.api.model.wrappers.I18nSet cannot be cast to org.jbpm.formModeler.core.wrappers.HTMLi18n
        at org.jbpm.formModeler.core.processing.fieldHandlers.HTMLi18nFieldHandler.isEmpty(HTMLi18nFieldHandler.java:87) [jbpm-form-modeler-ui-6.0.0-SNAPSHOT.jar:]
        at org.jbpm.formModeler.core.processing.fieldHandlers.HTMLi18nFieldHandler$Proxy$_$$_WeldClientProxy.isEmpty(HTMLi18nFieldHandler$Proxy$_$$_WeldClientProxy.java) [jbpm-form-modeler-ui-6.0.0-SNAPSHOT.jar:]
        at org.jbpm.formModeler.core.processing.impl.FormStatusDataImpl.<init>(FormStatusDataImpl.java:65) [jbpm-form-modeler-ui-6.0.0-SNAPSHOT.jar:]
        at org.jbpm.formModeler.core.processing.impl.FormProcessorImpl.read(FormProcessorImpl.java:435) [jbpm-form-modeler-ui-6.0.0-SNAPSHOT.jar:]
        at org.jbpm.formModeler.core.processing.impl.FormProcessorImpl.read(FormProcessorImpl.java:425) [jbpm-form-modeler-ui-6.0.0-SNAPSHOT.jar:]

Comment 6 Jan Hrcek 2013-10-21 06:33:01 UTC
I checked with BPMS 6.0.0 ER4 deployed on EAP 6.1.

The problem with the save button appearing in the middle seems to be gone, but the HTML label text is still not saved - the HTML label text remains unchanged when edited and saved.

Please watch the current behavior in the video attached.

Comment 7 Jan Hrcek 2013-10-21 06:33:38 UTC
I forgot to add: there are no exceptions in the server console / server.log

Comment 8 Jan Hrcek 2013-10-21 06:34:57 UTC
Created attachment 814414 [details]
Video showing current behavior - not saving edits

Comment 9 Neus Miras 2013-10-21 10:08:10 UTC
It was needed to launch the change event to update the html content. The fix is modify the script to intercept the event 'dataReady' too, which is thrown by the source mode change and allow update the content with what the user is viewing. This is done in the follow commits:

Commits
Master
https://github.com/droolsjbpm/jbpm-form-modeler/commit/9eb383641ba49246c8ba5c37f3a8365e952d992b

6.0.x
https://github.com/droolsjbpm/jbpm-form-modeler/commit/cd0eb2f59fbc98b54d6492c106abb0aa4d508cc6

Comment 10 Jan Hrcek 2013-12-02 09:39:51 UTC
Ok, in ER5 it saves the edits correctly. Verified with BPMS 6.0.0 ER5


Note You need to log in before you can comment on or make changes to this bug.