View Issue Details

This bug affects 1 person(s).
 16
IDProjectCategoryView StatusLast Update
07315Bug reportsExpression Managerpublic2013-03-17 12:12
Reporterdigmxl Assigned ToDenisChenu  
PrioritynormalSeverityminor 
Status closedResolutionfixed 
Fixed in Version2.00+ 
Summary07315: Validation regex not being checked / not working (logic test ok)
Description

The regex appears to not being checked at all
I tried on a fresh new survey, and it worked !

Steps To Reproduce

Question group : "Questionnaire Facture"
Question : "Q81a"
Enter time validation regex : /^(?:[01][0-9]|2[0-3]):[0-5][0-9]$/
Try the question

TagsNo tags attached.
Bug heat16
Complete LimeSurvey version number (& build)130219
I will donate to the project if issue is resolvedNo
Browser
Database type & versionmysql 5.5
Server OS (if known)linux
Webserver software & version (if known)apache2
PHP Versionphp5

Relationships

related to 06998 closedDenisChenu question is hidden by condition - no single preview anymore 
has duplicate 06338 closedDenisChenu Group preview and question preview : exclusive_option don't work 

Users monitoring this issue

There are no users monitoring this issue.

Activities

c_schmitz

c_schmitz

2013-02-20 17:16

administrator   ~24181

I am sorry but we will not debug a 425 question survey for you, sorry.
Please reduce the survey to a minimal test case and attach it as a new file.

digmxl

digmxl

2013-02-23 15:49

reporter   ~24211

i know its a big survey, i clearly fill the "steps to reproduce" field for this reason; i wasnt able to reproduce the bug on a new survey
its not about debugging a survey for me, more about helping you debug your software :-)

digmxl

digmxl

2013-02-23 15:50

reporter   ~24212

if i can reproduce the bug on a shorter survey, be sure i will post it !

c_schmitz

c_schmitz

2013-02-24 17:54

administrator   ~24235

Denis, the workaround on 06998 does not take validation into consideration.
It seems that validation JS is not properly executed if the question has conditions (in single question preview only).
Can you have a look at this issue, please?

DenisChenu

DenisChenu

2013-02-24 18:02

developer   ~24238

Surely:

  • In EM: we do test only if the question are relevant
  • If the question is hidden, then the regexp are not tested. Like some other validation.

Have another issue with relevance ....

DenisChenu

DenisChenu

2013-02-24 18:59

developer   ~24240

All EM is broken in preview.

http://bugs.limesurvey.org/view.php?id=6998 is really a workaround.

DenisChenu

DenisChenu

2013-02-24 19:24

developer   ~24242

In include lss file, i have some error in

  • Q81b
  • Q82b

q81b is in the same group than Q81a, then EM javascript are surely breaked.

sammousa

sammousa

2013-02-24 21:34

reporter   ~24244

Shnoulle, just for reference.
In 2.1 (currently Plugin branch) question preview is handled by a separate controller (QuestionsController) in the actionPreview function.

This is still very alpha, but I would like to implement some options here using some kind of preview toolbar:

  • Force question (and subquestions / all answers) to be relevant.
  • Manually enter values for variables used in relevance equations.
  • Switch template for question (?)

When you are done using this ticket for master branch please assign it to me for 2.1.

DenisChenu

DenisChenu

2013-02-25 09:39

developer   ~24247

Last edited: 2013-02-25 09:42

<quote> - Manually enter values for variables used in relevance equations.</quote>
Yes, good idea.

<quote> - Force question (and subquestions / all answers) to be relevant.</quote> This one is done BUT: at doc.reafy test is #javasssXgid-1XQQQ=="condition" (a answer from precedent group).

Think we must have, for the javascript (with a question in G2 and a condition with a question in GA)

G1Q1=="Y" become G1Q1=="Y" OR true

DenisChenu

DenisChenu

2013-02-25 19:47

developer   ~24285

Think i add a new var to LimeExpressionManager

private(/public?) $preview=false;
Can be question and group

And do relevance test with this one :)

DenisChenu

DenisChenu

2013-03-12 14:23

developer   ~24670

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

DenisChenu

DenisChenu

2013-03-12 14:43

developer   ~24671

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

c_schmitz

c_schmitz

2013-03-17 12:12

administrator   ~24723

New version released.

Related Changesets

LimeSurvey: master 518041b3

2013-03-12 14:19

DenisChenu


Details Diff
Fixed issue 07315: Validation regex not being checked / not working (logic test ok) in preview mode
Fixed issue: Can not test group if token exist or if survey is not started
New feature: can use SGQA identifier to prefill some answer with URL in preview mode
Dev: add LimeExpressionManager->$sPreviewMode to be used and test if we are in preview mode
Dev: add LimeExpressionManager::SetPreviewMode public function to set previewmode
Affected Issues
07315
mod - application/controllers/survey/index.php Diff File
mod - application/helpers/SurveyRuntimeHelper.php Diff File
mod - application/helpers/expressions/em_manager_helper.php Diff File
mod - application/helpers/frontend_helper.php Diff File

LimeSurvey: 2.05 c31be8fb

2013-03-12 14:39

DenisChenu


Details Diff
Fixed issue 07315: Validation regex not being checked / not working (logic test ok) in preview mode
Fixed issue: Can not test group if token exist or if survey is not started
New feature: can use SGQA identifier to prefill some answer with URL in preview mode
Dev: add LimeExpressionManager->$sPreviewMode to be used and test if we are in preview mode
Dev: add LimeExpressionManager::SetPreviewMode public function to set previewmode
Affected Issues
07315
mod - application/controllers/survey/index.php Diff File
mod - application/helpers/SurveyRuntimeHelper.php Diff File
mod - application/helpers/expressions/em_manager_helper.php Diff File
mod - application/helpers/frontend_helper.php Diff File

Issue History

Date Modified Username Field Change
2013-02-20 15:02 digmxl New Issue
2013-02-20 15:02 digmxl File Added: limesurvey_survey_73712(1).lss
2013-02-20 17:16 c_schmitz Note Added: 24181
2013-02-20 17:16 c_schmitz Assigned To => c_schmitz
2013-02-20 17:16 c_schmitz Status new => feedback
2013-02-23 15:49 digmxl Note Added: 24211
2013-02-23 15:49 digmxl Status feedback => assigned
2013-02-23 15:50 digmxl Note Added: 24212
2013-02-24 17:52 c_schmitz Relationship added related to 06998
2013-02-24 17:53 c_schmitz Assigned To c_schmitz => DenisChenu
2013-02-24 17:54 c_schmitz Note Added: 24235
2013-02-24 18:02 DenisChenu Note Added: 24238
2013-02-24 18:59 DenisChenu Note Added: 24240
2013-02-24 19:24 DenisChenu Note Added: 24242
2013-02-24 21:34 sammousa Note Added: 24244
2013-02-25 09:39 DenisChenu Note Added: 24247
2013-02-25 09:42 DenisChenu Note Edited: 24247
2013-02-25 19:47 DenisChenu Note Added: 24285
2013-03-12 14:23 DenisChenu Changeset attached => LimeSurvey master 518041b3
2013-03-12 14:23 DenisChenu Note Added: 24670
2013-03-12 14:23 DenisChenu Resolution open => fixed
2013-03-12 14:43 DenisChenu Changeset attached => LimeSurvey 2.05 c31be8fb
2013-03-12 14:43 DenisChenu Note Added: 24671
2013-03-12 14:48 DenisChenu Status assigned => resolved
2013-03-12 14:48 DenisChenu Fixed in Version => 2.00+
2013-03-12 14:51 DenisChenu Relationship added has duplicate 06338
2013-03-17 12:12 c_schmitz Note Added: 24723
2013-03-17 12:12 c_schmitz Status resolved => closed