Bug 118862 - XML Form Document: Impossible to create a second instance in the same model
Summary: XML Form Document: Impossible to create a second instance in the same model
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
4.4 all versions
Hardware: All All
: medium normal
Assignee: Caolán McNamara
URL:
Whiteboard: target:6.2.0 target:6.0.7 target:6.1....
Keywords: bibisected, bisected, regression
Depends on:
Blocks:
 
Reported: 2018-07-20 19:37 UTC by Robert Großkopf
Modified: 2018-08-02 15:40 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Robert Großkopf 2018-07-20 19:37:48 UTC
Open LO.
File > New > XML Form Document
On the right you could see the Data Navigator. If not switch to the bottom of the window, 4th button from the left.
Data Navigator shows "Instance 1" and there "instanceData".
There is a listfield right down there called "Instances".
You could create new instances there or delete instances or change instances.
Create a new instance and give it a name.
The instance appears but couldn't be changed any more.

Now save the form, close and reopen it. Doesn't changed it's behavior.
Delete the first instance, "Instance 1".
Save the form, close and reopen it. The new created instance has now a node "InstanceData" and could be changed.

Two solutions: 
Let it be possible to create more than one instance in one model.
Disable the possibility to create a new instance if an instance exists.

All tested with LO 6.0.5.2 on OpenSUSE 42.3 64bit rpm Linux. But it's the same behavior all the time before. XML-Forms were not changed since the beginning of LO.
Comment 1 Xisco Faulí 2018-07-25 08:36:26 UTC
Regression introduced by:

https://cgit.freedesktop.org/libreoffice/core/commit/?id=38cbb4c7176d85973c4945a10a262bb487388246

author	Caolán McNamara <caolanm@redhat.com>	2014-08-15 15:09:57 +0100
committer	Caolán McNamara <caolanm@redhat.com>	2014-08-15 16:05:39 +0100
commit 38cbb4c7176d85973c4945a10a262bb487388246 (patch)
tree 03f39e4f86bce9295cdade2de73d9490edd7da99
parent 221c21b433970acbdc9368120371c39e3934ff18 (diff)
convert datanavigator sport to .ui

Bisected with: bibisect-44max

Adding Cc: to Caolán McNamara

Before this commit, the item instanceData is displayed in the navigator when a new instance is created...
Comment 2 Caolán McNamara 2018-07-25 09:12:07 UTC
IsAdditionalPage doesn't seem to be working right
Comment 3 Commit Notification 2018-07-25 10:44:46 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=e161206709ea4bd6182fa9feeedf4b3f08231fe5

Resolves: tdf#118862 new instances cannot be edited

It will be available in 6.2.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 4 Caolán McNamara 2018-07-25 10:47:46 UTC
backports in gerrit
Comment 5 Commit Notification 2018-07-25 22:50:54 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "libreoffice-6-0":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=239ce8ea56527c96bd1b30b68a3448872f382b47&h=libreoffice-6-0

Resolves: tdf#118862 new instances cannot be edited

It will be available in 6.0.7.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 6 Commit Notification 2018-07-25 22:51:05 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "libreoffice-6-1":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=9b18192fc3af465fb424dd8d5a81cd46fc3331b6&h=libreoffice-6-1

Resolves: tdf#118862 new instances cannot be edited

It will be available in 6.1.1.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 7 Xisco Faulí 2018-07-26 09:37:08 UTC
Issue verified in

Version: 6.2.0.0.alpha0+
Build ID: 96faaa6005465661d74b6dbf4879c43b85c68a55
CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: gtk3; 
Locale: ca-ES (ca_ES.UTF-8); Calc: group threaded

@Caolán, thanks for fixing this!!!
Comment 8 Robert Großkopf 2018-07-26 13:25:27 UTC
You could now create a second instance. Great!

... but a new problem appeared: No data type could be saved for the elements of this instance ...

Created a new bug118954 for this.
Comment 9 Commit Notification 2018-08-02 15:40:37 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "libreoffice-6-1-0":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=6f8e4f7df7190ce1a1751bf968a5d899e95bc1b9&h=libreoffice-6-1-0

Resolves: tdf#118862 new instances cannot be edited

It will be available in 6.1.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.