View Issue Details

This bug affects 1 person(s).
IDProjectCategoryView StatusLast Update
17593Bug reportsSurvey editingpublic2021-10-22 09:45
Reportergalads Assigned Togabrieljenik  
Status resolvedResolutionfixed 
Product Version5.x 
Summary17593: Generated answer code is too long
DescriptionIf I "ADD" (not Replace) the 308 answer options when adding the 308 Answer Options are ALL there . But when I click on "Save" the error persists:
"An error happened: Could not save answer option Array ( [code] => Array ( [0] => Code is too long (maximum is 5 characters). ) )"
Additional InformationRelated issue:
TagsNo tags attached.
Bug heat2
Complete LimeSurvey version number (& build)5.x
I will donate to the project if issue is resolvedNo
Database type & versionNot relevant
Server OS (if known)
Webserver software & version (if known)
PHP VersionNot relevant

Users monitoring this issue

User List There are no users monitoring this issue.




2021-09-14 15:07

manager   ~66477

There are two problems:
1) The "Add" function of the Quick add generates the codes wrong. For example, if you have an option "A01" and you add an option with "quick add", the generated code is "A12". That is resolved in this new branch.

2) The codes have a maximum of 5 characters. If the prefix is "PEPE" and you add 10 options, the error will occur: PHP will fail, because although the field has a limit of 5, through JS you can set a longer text, which is what happens using "quick add".


2021-09-29 22:11

manager   ~66661



2021-10-22 09:45

manager   ~66900

Fix committed to master branch:

Related Changesets

LimeSurvey: master 112e8d92

2021-10-22 09:32:48


Committer: GitHub Details Diff
Fixed issue 17593: Generated answer code is too long (#2059) Affected Issues
mod - assets/scripts/admin/questionEditor.js Diff File

Issue History

Date Modified Username Field Change
2021-09-14 08:40 galads New Issue
2021-09-14 08:40 galads Status new => assigned
2021-09-14 08:40 galads Assigned To => gabrieljenik
2021-09-14 08:41 galads Priority none => urgent
2021-09-14 15:04 gabrieljenik Summary Error adding a large number of answer options () => Generated answer code is too long
2021-09-14 15:07 gabrieljenik Note Added: 66477
2021-09-14 15:07 gabrieljenik Bug heat 0 => 2
2021-09-14 15:10 gabrieljenik Additional Information Updated View Revisions
2021-09-29 22:11 gabrieljenik Note Added: 66661
2021-10-07 12:07 ollehar Status assigned => testing
2021-10-22 09:33 c_schmitz Status testing => resolved
2021-10-22 09:33 c_schmitz Resolution open => fixed
2021-10-22 09:45 gabrieljenik Changeset attached => LimeSurvey master 112e8d92
2021-10-22 09:45 gabrieljenik Note Added: 66900