View Issue Details

This bug affects 1 person(s).
 6
IDProjectCategoryView StatusLast Update
17599Bug reportsLabel setspublic2021-11-17 12:32
ReporterMazi Assigned Togabrieljenik  
PriorityhighSeveritycrash 
Status closedResolutionfixed 
Product Version3.25.20 
Summary17599: Loading a label set at multilingual survey fails
Description

When loading an EN label set as answer options for a multilingual survey having EN set as base language, the answers are correctly loaded into the answers list. But when clicking save, the list is blank again and the options are gone.

Steps To Reproduce
  1. Import the attached EN label set.
  2. Import the attached sample survey.
  3. Go to question "q1firstday", second group, first question.
  4. Edit the answer oiptions.
  5. Select the "Predefine dlabel sets" option.
  6. Select the previously imported 2a MT Satisfaction scale
  7. The answer are loaded. Click "Save" top right
    -> All answers are gone
Additional Information

I can safely reproduce this at our test system using the latest Version 3.27.17+210911

TagsNo tags attached.
Attached Files
limesurvey_labelset_2.lsl (2,265 bytes)   
<?xml version="1.0" encoding="UTF-8"?>
<document>
 <LimeSurveyDocType>Label set</LimeSurveyDocType>
 <DBVersion>365</DBVersion>
 <labelsets>
  <fields>
   <fieldname>lid</fieldname>
   <fieldname>label_name</fieldname>
   <fieldname>languages</fieldname>
  </fields>
  <rows>
   <row>
    <lid><![CDATA[2]]></lid>
    <label_name><![CDATA[2a MT Satisfaction Scale]]></label_name>
    <languages><![CDATA[en]]></languages>
   </row>
  </rows>
 </labelsets>
 <labels>
  <fields>
   <fieldname>lid</fieldname>
   <fieldname>code</fieldname>
   <fieldname>title</fieldname>
   <fieldname>sortorder</fieldname>
   <fieldname>language</fieldname>
   <fieldname>assessment_value</fieldname>
  </fields>
  <rows>
   <row>
    <lid><![CDATA[2]]></lid>
    <code><![CDATA[1]]></code>
    <title><![CDATA[Very bad]]></title>
    <sortorder><![CDATA[0]]></sortorder>
    <language><![CDATA[en]]></language>
    <assessment_value><![CDATA[0]]></assessment_value>
   </row>
   <row>
    <lid><![CDATA[2]]></lid>
    <code><![CDATA[2]]></code>
    <title><![CDATA[Bad]]></title>
    <sortorder><![CDATA[1]]></sortorder>
    <language><![CDATA[en]]></language>
    <assessment_value><![CDATA[0]]></assessment_value>
   </row>
   <row>
    <lid><![CDATA[2]]></lid>
    <code><![CDATA[3]]></code>
    <title><![CDATA[Neutral]]></title>
    <sortorder><![CDATA[2]]></sortorder>
    <language><![CDATA[en]]></language>
    <assessment_value><![CDATA[0]]></assessment_value>
   </row>
   <row>
    <lid><![CDATA[2]]></lid>
    <code><![CDATA[4]]></code>
    <title><![CDATA[Good]]></title>
    <sortorder><![CDATA[3]]></sortorder>
    <language><![CDATA[en]]></language>
    <assessment_value><![CDATA[0]]></assessment_value>
   </row>
   <row>
    <lid><![CDATA[2]]></lid>
    <code><![CDATA[5]]></code>
    <title><![CDATA[Very good]]></title>
    <sortorder><![CDATA[4]]></sortorder>
    <language><![CDATA[en]]></language>
    <assessment_value><![CDATA[0]]></assessment_value>
   </row>
   <row>
    <lid><![CDATA[2]]></lid>
    <code><![CDATA[6]]></code>
    <title><![CDATA[Not applicable]]></title>
    <sortorder><![CDATA[5]]></sortorder>
    <language><![CDATA[en]]></language>
    <assessment_value><![CDATA[0]]></assessment_value>
   </row>
  </rows>
 </labels>
</document>
limesurvey_labelset_2.lsl (2,265 bytes)   
Bug heat6
Complete LimeSurvey version number (& build)LimeSurvey Cloud Version 3.27.16
I will donate to the project if issue is resolvedNo
BrowserChrome
Database type & versionMySQL
Server OS (if known)Ubuntu 20
Webserver software & version (if known)Apache 2.0
PHP Version7.3

Users monitoring this issue

There are no users monitoring this issue.

Activities

Mazi

Mazi

2021-09-15 22:58

updater   ~66495

The problem does not seems to show up when e.g. saving the answer options of question "q1overall" as label set and loading these at step #6 above.

ollehar

ollehar

2021-09-17 16:22

administrator   ~66523

Last edited: 2021-10-12 15:45

Added to next sprint, thanks for reporting!

gabrieljenik

gabrieljenik

2021-10-12 15:43

manager   ~66838

Last edited: 2021-10-12 15:45

PR: https://github.com/LimeSurvey/LimeSurvey/pull/2093

The fix is for the specific problem of the ticket, which is the loading of labelsets in multilanguage surveys.

But in the attached images you can see another problem, which I don't know if it has any impact but it would be good to correct: when you add answer options with the Quick Add option, the rows in the secondary languages are removable, movable, and with the editable Code. That can lead to inconsistencies.

In master I could not reproduce the error because when trying to load the labelset it throws me this other error in a JS alert

image.png (4,707 bytes)   
image.png (4,707 bytes)   
image-2.png (65,459 bytes)   
image-2.png (65,459 bytes)   
image-3.png (64,651 bytes)   
image-3.png (64,651 bytes)   
gabrieljenik

gabrieljenik

2021-11-01 16:42

manager   ~67035

Fix committed to 3.x-LTS branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&id=32852

Related Changesets

LimeSurvey: 3.x-LTS cc1040f7

2021-10-11 18:45

gabrieljenik


Details Diff
Fixed issue 17599: Loading a label set at multilingual survey fails Affected Issues
17599
mod - assets/scripts/admin/answers.js Diff File

LimeSurvey: 3.x-LTS 032b8689

2021-11-01 17:25

Ahmed Galad's

Committer: GitHub


Details Diff
Merge pull request #2093 from gabrieljenik/bug/17599--Loading-a-label-set-at-multilingual-survey-fails

Fixed issue 17599: Loading a label set at multilingual survey fails
Affected Issues
17599
mod - assets/scripts/admin/answers.js Diff File

Issue History

Date Modified Username Field Change
2021-09-15 22:56 Mazi New Issue
2021-09-15 22:56 Mazi File Added: limesurvey_labelset_2.lsl
2021-09-15 22:56 Mazi File Added: limesurvey_survey_943782.lss
2021-09-15 22:58 Mazi Note Added: 66495
2021-09-15 22:58 Mazi Bug heat 0 => 2
2021-09-16 10:42 galads Assigned To => galads
2021-09-16 10:42 galads Status new => confirmed
2021-09-17 16:21 ollehar Priority none => high
2021-09-17 16:21 ollehar Steps to Reproduce Updated
2021-09-17 16:21 ollehar Zoho Project Synchronization => |Yes|
2021-09-17 16:22 ollehar Note Added: 66523
2021-09-17 16:22 ollehar Bug heat 2 => 4
2021-10-12 15:43 gabrieljenik Note Added: 66838
2021-10-12 15:43 gabrieljenik File Added: image.png
2021-10-12 15:43 gabrieljenik File Added: image-2.png
2021-10-12 15:43 gabrieljenik File Added: image-3.png
2021-10-12 15:43 gabrieljenik Bug heat 4 => 6
2021-10-12 15:45 gabrieljenik Status confirmed => ready for testing
2021-11-01 16:42 Changeset attached => LimeSurvey 3.x-LTS 032b8689
2021-11-01 16:42 gabrieljenik Changeset attached => LimeSurvey 3.x-LTS cc1040f7
2021-11-01 16:42 gabrieljenik Note Added: 67035
2021-11-01 16:42 gabrieljenik Assigned To galads => gabrieljenik
2021-11-01 16:42 gabrieljenik Resolution open => fixed
2021-11-17 12:32 ollehar Status ready for testing => resolved
2021-11-17 12:32 ollehar Status resolved => closed