View Issue Details

This bug affects 1 person(s).
 2
IDProjectCategoryView StatusLast Update
13505Bug reportsExpression Managerpublic2018-04-06 11:47
Reportervkuzmin Assigned ToDenisChenu  
PrioritynoneSeverityminor 
Status closedResolutionfixed 
Product Version3.3.x 
Summary13505: that.QNAME.shown have different behaviour if PHP and JS
Description

Php expression manager ignore "Other" option in Multiple choice questions but JS count them.
So {count(that.QNAME.shown)} in JS can be higher than result of same expression in PHP.

Steps To Reproduce

Make new Multiple choice question with allowed Option 'Other'. Take survey, type something in other option. Try to count answers.
https://demo.limesurvey.org/index.php/admin/survey/sa/view/surveyid/617582

Additional Information

Also {list(that.QNAME.shown)} in JS show "Other" for Other answers and {list(that.QNAME.NAOK)} show other answer itself. Is it possible to show answer itself in {list(that.QNAME.shown)} too?

TagsNo tags attached.
Attached Files
thatshown.png (14,803 bytes)   
thatshown.png (14,803 bytes)   
Bug heat2
Complete LimeSurvey version number (& build)3.5.3 demo.limesurvey.org
I will donate to the project if issue is resolvedNo
BrowserChrome 55
Database type & versiondemo.limesurvey.org
Server OS (if known)demo.limesurvey.org
Webserver software & version (if known)demo.limesurvey.org
PHP Versiondemo.limesurvey.org

Users monitoring this issue

There are no users monitoring this issue.

Activities

DenisChenu

DenisChenu

2018-03-21 19:34

developer   ~47166

2.5X have same issue. And there are another issue : show must be take from attribute (if admin user set it).

Maybe time to update other system

  • shown show the other input (like NAOK currently).
DenisChenu

DenisChenu

2018-03-28 17:02

developer   ~47268

Fix committed to master branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=26885

DenisChenu

DenisChenu

2018-03-28 17:05

developer   ~47269

Count other.shown in PHP like in JS
{count(that.QNAME.shown)} must return the count including other.

Old issue here …

NAOK still return value entered by user, .shown show Other text.

Related Changesets

LimeSurvey: master 29d0a002

2018-03-28 17:02:43

DenisChenu

Details Diff
Fixed issue 13505 : Q_other.shown are difference between PHP and JS
Dev: Replace other by the real string seen by user
Dev: replace test $code=='Y' by !empty($code) to get other too
Affected Issues
13505
mod - application/helpers/expressions/em_manager_helper.php Diff File

Issue History

Date Modified Username Field Change
2018-03-20 15:32 vkuzmin New Issue
2018-03-20 15:32 vkuzmin File Added: thatshown.png
2018-03-20 15:32 vkuzmin File Added: limesurvey_survey_617582.lss
2018-03-20 16:46 DenisChenu Assigned To => DenisChenu
2018-03-20 16:46 DenisChenu Status new => assigned
2018-03-21 19:34 DenisChenu Note Added: 47166
2018-03-28 17:02 DenisChenu Changeset attached => LimeSurvey master 29d0a002
2018-03-28 17:02 DenisChenu Note Added: 47268
2018-03-28 17:02 DenisChenu Resolution open => fixed
2018-03-28 17:05 DenisChenu Status assigned => resolved
2018-03-28 17:05 DenisChenu Note Added: 47269
2018-04-06 11:47 markusfluer Status resolved => closed