Bug 125658 - conditional section hiding does not work as expected - condition text is set to 0
Summary: conditional section hiding does not work as expected - condition text is set ...
Status: RESOLVED DUPLICATE of bug 104816
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
6.2.4.2 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-06-03 14:18 UTC by Sergey Spiridonov
Modified: 2019-06-03 17:21 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments
That file I created myself. It contains the section and the field - you can try starting from step 5. (8.61 KB, application/vnd.oasis.opendocument.text)
2019-06-03 14:18 UTC, Sergey Spiridonov
Details
The file that suprisingly works!!! But it is downloaded, not created by myself (8.63 KB, application/vnd.oasis.opendocument.text)
2019-06-03 14:20 UTC, Sergey Spiridonov
Details
this one is working (18.11 KB, application/vnd.oasis.opendocument.text)
2019-06-03 17:08 UTC, Sergey Spiridonov
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Sergey Spiridonov 2019-06-03 14:18:29 UTC
Created attachment 151876 [details]
That file I created myself. It contains the section and the field - you can try starting from step 5.

reproduced on 

1. Windows10 LO version 6.2.1.2
2. Debian Linux Stretch LO version 5.2.7.2 (stable)
3. Debian Linux Stretch LO version 6.1.5.1 (backports)
4. Debian Linux Stretch LO version 6.2.4.2 (flatpak)

Steps to reproduce:

1. Create new document.
2. Menu: Insert->Fields->More fields
2.1. Tab Variable
2.2. Set variable
2.3. Format: general
2.4. Name: mycondb
2.5. Value: 2
2.6. Button "Insert"
3. Type some text and select it
4. Menu: Insert->Section
4.1. Section name for example mycond
4.2. Check box "Hide" 
4.3. In field "With condition" type in "mycondb LEQ 1"
4.4. Button "Insert"
5. Double click field mycondb and set value to 1

If section will disappear, then set field value again to 2 and then again to 1.

Result: section does not disappear, if you go to Format->Sections, you will see that condition text that we entered at the step 4.3 disappeared and there is only "0" there.

Expected result: section will appear and disappear, condition will not be changed.

Additional information:

attaching 2 example files.

File #1 test_section_condition_broken.odt That file I created myself. It contains the section and the field - you can try starting from step 5.

File #2 test_section_condition_working.odt - file with the section and field which is surprisingly working! The difference is that I do not created that file, but downloaded from the link on this page https://ask.libreoffice.org/en/question/132219/can-you-use-conditional-text-in-libreoffice/
Comment 1 Sergey Spiridonov 2019-06-03 14:20:27 UTC
Created attachment 151877 [details]
The file that suprisingly works!!! But it is downloaded, not created by myself
Comment 2 Oliver Brinzing 2019-06-03 15:02:27 UTC
confirming with LO 6.2.4.2, but not with LO 6.3 Master

maybe a duplicate of:

Bug 104816 - Inserting a user field will lose the condition of section
https://bugs.documentfoundation.org/show_bug.cgi?id=104816
Comment 3 Justin L 2019-06-03 16:24:35 UTC
The "working" version didn't work for me.  Used bibisect to confirm that this is a duplicate of 104816, so it is fixed in 6.3.
(tested with Ubuntu 18.04)

*** This bug has been marked as a duplicate of bug 104816 ***
Comment 4 Sergey Spiridonov 2019-06-03 17:08:47 UTC
Created attachment 151880 [details]
this one is working

try to set the field to 1, 2, 3, 4, 5
Comment 5 Sergey Spiridonov 2019-06-03 17:09:35 UTC
Is there flatpak version of 6.3?
Comment 6 Sergey Spiridonov 2019-06-03 17:21:01 UTC
Tested with debian packages, confirming it is fixed. Thank you.