View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
16124 | Bug reports | Theme editor | public | 2020-04-10 18:06 | 2021-08-12 08:46 |
Reporter | tpartner | Assigned To | ollehar | ||
Priority | normal | Severity | partial_block | ||
Status | closed | Resolution | fixed | ||
Product Version | 4.1.16 | ||||
Target Version | 4.1.17 | ||||
Summary | 16124: In custom question theme, cannot hide core attribute and set a default value | ||||
Description | In config.xml, I can hide core attributes with code like this: <attribute> However, when I try to hide the attribute AND set a default value like this, the default value is not picked up (in this case, the question is always hidden). <attribute> This is a regression as it worked in 3.x. Sample survey and question theme attached. | ||||
Steps To Reproduce | In config.xml of the attached theme, I have commented out the code to hide the "hidden" attribute (lines 94-101). Un-comment that code block and you will see that the questions are hidden despite the fact that a value of 0 is set as default. | ||||
Tags | No tags attached. | ||||
Attached Files | |||||
Bug heat | 8 | ||||
Complete LimeSurvey version number (& build) | 4.1.16 | ||||
I will donate to the project if issue is resolved | No | ||||
Browser | N/A | ||||
Database type & version | mysqlnd 5.0.12 | ||||
Server OS (if known) | Windows 10 | ||||
Webserver software & version (if known) | Apache/2.4.39 (Win64) | ||||
PHP Version | 7.3.7 | ||||
This sounds like you used a property to fake-hide an input field. |
|
Yes, I used the only way that I know to hide the attribute. It was suggested by Louis. It is definitely sub-optimal as the parent divs and sibling labels are still rendered. If there is better way I would be happy to test. Documentation is extremely limited. I would love to see a "hidden" attribute property. |
|
...also, a method to hide entire categories would be cool. For example, I often use multiple-numerics without sliders or to render my own custom sliders so would like to hide the entire "Slider" category. |
|
So what you want, tpartner, is to apply custom CSS to the question editor for a certain question theme? |
|
Maybe we should add a feature to include custom JS that is loaded when a question theme is loaded in question editor? Then you could change the appearance anyhow you want. |
|
Not oinly CSS : just don't send HTML See
|
|
Yes, loading custom JS and CSS when viewing/editing the custom question theme would do the trick, providing we could still set defaults for any attributes hidden with that JS/CSS. |
|
In my opinion :
With custom css and js : you can hack, but still an hack. To hide other label :
|
|
Good point, Denis. Using element id is not stable long-term. A new XML tag, then, maybe? For <show>1</show>
? |
|
Good lord, Mantis is stupid with HTML tags... |
|
Yes! :) |
|
...and JS and CSS so I can hide entire group elements? |
|
Let's create a new ticker for JS/CSS support. I'm not sure how to apply CSS dynamically. JS is no problem. |
|
Thanks Olle. |
|
@tpartner : this mantis issue have a parent ? |
|
Yeah, we did discuss it - https://bugs.limesurvey.org/view.php?id=14185 In my opinion, it was never resolved satisfactorily, or if it was, I can't find any documentation. |
|
Did you try in |
|
Didn't work in 3.25.8 add input in a "model" Updated version of autoComplete … |
|
The |
|
Just to sum it up: The property "visible" is used to hide attributes in the UI, but you want still use the property itself with a default value. This works in 3.x (hide + default value) In LS4 the default value does not work. Correct? |
|
3.x:
4.x:
|
|
Thank you for the clarification. |
|
Date Modified | Username | Field | Change |
---|---|---|---|
2020-04-10 18:06 | tpartner | New Issue | |
2020-04-10 18:06 | tpartner | Status | new => assigned |
2020-04-10 18:06 | tpartner | Assigned To | => cdorin |
2020-04-10 18:06 | tpartner | File Added: cardSort.zip | |
2020-04-10 18:06 | tpartner | File Added: Card_Sort_for_4.x.lss | |
2020-04-10 18:06 | tpartner | Description Updated | |
2020-04-10 18:07 | tpartner | Description Updated | |
2020-04-10 18:08 | tpartner | Description Updated | |
2020-04-10 18:08 | tpartner | Description Updated | |
2020-04-10 18:10 | tpartner | Description Updated | |
2020-04-10 18:10 | tpartner | Description Updated | |
2020-04-10 18:11 | tpartner | Description Updated | |
2020-04-10 18:12 | tpartner | Description Updated | |
2020-04-10 18:13 | tpartner | Description Updated | |
2020-04-10 18:13 | tpartner | Description Updated | |
2020-10-19 18:49 | cdorin | Assigned To | cdorin => |
2020-10-19 18:49 | cdorin | Priority | none => normal |
2020-10-19 18:49 | cdorin | Status | assigned => confirmed |
2021-01-14 12:08 | c_schmitz | Note Added: 61539 | |
2021-01-14 13:04 | tpartner | Note Added: 61540 | |
2021-01-14 13:13 | tpartner | Note Added: 61541 | |
2021-01-22 10:53 | ollehar | Note Added: 61633 | |
2021-01-22 10:53 | ollehar | Note Added: 61634 | |
2021-01-22 11:36 | DenisChenu | Note Added: 61639 | |
2021-01-22 11:39 | tpartner | Note Added: 61640 | |
2021-01-22 11:45 | DenisChenu | Note Added: 61641 | |
2021-01-22 12:12 | ollehar | Note Added: 61643 | |
2021-01-22 12:12 | ollehar | Note Edited: 61643 | |
2021-01-22 12:13 | ollehar | Note Added: 61644 | |
2021-01-22 12:17 | ollehar | Note Edited: 61643 | |
2021-01-22 13:01 | tpartner | Note Added: 61645 | |
2021-01-22 13:01 | tpartner | Note Edited: 61645 | |
2021-01-22 13:02 | tpartner | Note Added: 61646 | |
2021-01-22 13:16 | ollehar | Note Added: 61647 | |
2021-01-22 14:22 | tpartner | Note Added: 61648 | |
2021-01-22 14:58 | DenisChenu | Note Added: 61651 | |
2021-01-22 18:10 | tpartner | Note Added: 61652 | |
2021-01-22 18:23 | DenisChenu | Note Added: 61653 | |
2021-01-22 18:32 | DenisChenu | Note Added: 61654 | |
2021-01-22 18:32 | DenisChenu | File Added: autoComplete.zip | |
2021-01-22 20:57 | tpartner | Note Added: 61655 | |
2021-01-22 20:57 | tpartner | Note Edited: 61655 | |
2021-03-15 15:08 | c_schmitz | Note Added: 63367 | |
2021-03-15 15:08 | c_schmitz | Assigned To | => c_schmitz |
2021-03-15 15:08 | c_schmitz | Status | confirmed => feedback |
2021-03-15 15:10 | c_schmitz | Note Edited: 63367 | |
2021-03-15 15:10 | c_schmitz | Note Edited: 63367 | |
2021-03-15 19:23 | tpartner | Note Added: 63385 | |
2021-03-15 19:23 | tpartner | File Added: cardSort-2.zip | |
2021-03-15 19:23 | tpartner | File Added: limesurvey_survey_515183.lss | |
2021-03-15 19:23 | tpartner | File Added: 16124_3.png | |
2021-03-15 19:23 | tpartner | File Added: 16124_2.png | |
2021-03-15 19:23 | tpartner | File Added: 16124_1.png | |
2021-03-15 19:23 | tpartner | Status | feedback => assigned |
2021-03-26 14:49 | c_schmitz | Assigned To | c_schmitz => |
2021-03-26 14:49 | c_schmitz | Status | assigned => confirmed |
2021-03-26 14:49 | c_schmitz | Note Added: 63653 | |
2021-05-20 11:04 | ollehar | Working Git branch (developer only) | => origin/feature/L41-T54-can-not-hide-attribute |
2021-05-20 11:04 | ollehar | Working Git branch (developer only) | origin/feature/L41-T54-can-not-hide-attribute => feature/L41-T54-can-not-hide-attribute |
2021-05-20 11:59 | ollehar | Assigned To | => ollehar |
2021-05-20 11:59 | ollehar | Status | confirmed => ready for testing |
2021-07-21 17:24 | ollehar | Status | ready for testing => resolved |
2021-07-21 17:24 | ollehar | Resolution | open => fixed |
2021-08-12 08:46 | c_schmitz | Status | resolved => closed |