View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
08832 | Bug reports | Expression Manager | public | 2014-03-09 23:44 | 2014-06-11 16:30 |
Reporter | mfaber | Assigned To | c_schmitz | ||
Priority | normal | Severity | minor | ||
Status | closed | Resolution | fixed | ||
Product Version | 2.05+ | ||||
Summary | 08832: Relevance not observed (questions dependent on LATER matrix question with exclusive option) | ||||
Description | OK, here's a weirdo that i finally was able to boil down to a test case: See step by step and attached lss. Relevance logic works oddly enough for saving only relevant values but does not work to display only relevant questions | ||||
Steps To Reproduce | Load the attached lss. In the matrix question choose Yes for "Bananas" Now choose Yes for Apples in matrix (exclusive option) Problem: Now, only Q2 disappears. Q1 stays. Even though both have the same relevance equation, depending on matrix_2 (Bananas). Press submit and have a look at the recorded responses in response browser | ||||
Tags | No tags attached. | ||||
Attached Files | |||||
Bug heat | 6 | ||||
Complete LimeSurvey version number (& build) | 20140309 | ||||
I will donate to the project if issue is resolved | No | ||||
Browser | FF | ||||
Database type & version | MySql 5.6.14 | ||||
Server OS (if known) | Win7 | ||||
Webserver software & version (if known) | Apache 2.4.7 | ||||
PHP Version | PhP 5.4.19 | ||||
Relevance based on questions after the current question is currently not well supported. This is also obvious if you move the first question to a different group that appears before the first group. It will always be shown. (and a proper error is shown by 'show logic'). You could make it work on the same page somehow but then you have a differing behaviour to the 'different group' scenario. However in this case it seems to be a propagation JS issue. When following your instructions in the survey and activatning the exclusive option and then click the disabled 2nd row in the matrix question, then the 1st question suddenly disappears. |
|
Carsten, I'm afraid I'm stumped on this one. I've spent a lot of time trying to unravel em_manager_helper.php and really can't see a way around this. My recommendation would be to say "relevance and conditions can only be based on preceding question(s)". |
|
Tony, can you spot the error in the JS on the page? If yes maybe you can show it to me and I will unravel em_manager_helper.php for you ;). |
|
No, that's the problem - I don't see any obvious errors. |
|
Another option might be to keep the current functionality, since it "works as designed", but update the documentation to strongly recommend only basing branching on variables that occur on the same or prior pages. Also update it to explain that the color coding in the Show Logic File feature displays variables in a different color if they are on the prior, same, or future page. This way an author can tell if that has happened. Personally, I sometimes put equation variables at the end of the survey, and use variable assignment (the single equals operator) to change their values and branch based upon those changed values (such as maintaining counters of answered + verified questions). It is possible, and probably more robust, to always compute the full equation. However, the use-case I was tackling was an hour long diagnostic interview where we needed to ask the minimum number of questions needed to rule in or rule-out the each diagnosis. The full equation would have had a hundred+ variables, so it was easier to read and maintain with counters. So, 99% of users should not base their relevance equations on values set on future pages, but there are few rare cases where it can be helpful. |
|
I agree, but in this case everything is on the same page so we may need to change that to "only basing branching on variables that occur in preceding pages or questions". |
|
Updated documentation |
|
Date Modified | Username | Field | Change |
---|---|---|---|
2014-03-09 23:44 | mfaber | New Issue | |
2014-03-09 23:51 | mfaber | File Added: relevance_bug_8832.lss | |
2014-03-10 12:22 | DenisChenu | Relationship added | related to 08823 |
2014-03-10 12:27 | DenisChenu | Relationship deleted | related to 08823 |
2014-03-18 15:56 | c_schmitz | Note Added: 29346 | |
2014-03-18 15:57 | c_schmitz | Assigned To | => tpartner |
2014-03-18 15:57 | c_schmitz | Status | new => assigned |
2014-04-21 21:39 | tpartner | Note Added: 29836 | |
2014-04-21 21:39 | tpartner | Assigned To | tpartner => c_schmitz |
2014-04-23 12:51 | c_schmitz | Note Added: 29867 | |
2014-04-23 12:51 | c_schmitz | Status | assigned => feedback |
2014-04-23 12:57 | tpartner | Note Added: 29868 | |
2014-04-23 18:21 | TMSWhite | Note Added: 29871 | |
2014-04-23 18:49 | tpartner | Note Added: 29872 | |
2014-06-11 16:30 | c_schmitz | Note Added: 30082 | |
2014-06-11 16:30 | c_schmitz | Status | feedback => closed |
2014-06-11 16:30 | c_schmitz | Resolution | open => fixed |