From fdadac10b22325722726b7ac44fc12690907695d Mon Sep 17 00:00:00 2001 From: Jason Cleeland Date: Wed, 10 Jun 2009 04:18:07 +0000 Subject: [PATCH] fixed bug #03241: Mandatory requirement not working on Array (Multi-flexbile) (Number) with Checkbox layout is 1 dev note; this is only partially fixed, see notes on bug git-svn-id: file:///Users/Shitiz/Downloads/lssvn/source/limesurvey@7052 b72ed6b6-b9f8-46b5-92b4-906544132732 --- qanda.php | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/qanda.php b/qanda.php index b7992aee7e6..a332bef4005 100644 --- a/qanda.php +++ b/qanda.php @@ -358,7 +358,6 @@ function setman_multiflex($ia) } $qidattributes=getQuestionAttributes($ia[0]); - while ($ansrow = $ansresult->FetchRow()) { //Don't add to mandatory list if the row is filtered out with the array_filter option @@ -372,7 +371,12 @@ function setman_multiflex($ia) } else { - //This one's not hidden. so add it to the mandatory list + //This one's not hidden. so add it to the mandatory list + foreach($lset as $ls) + { + $mandatorys[]=$ia[1].$ansrow['code']."_".$ls['code']; + $mandatoryfns[]=$ia[1]; + } } } else { //There is no array_filter option, so we should definitely add to the mandatory list here! foreach($lset as $ls) @@ -3644,7 +3648,8 @@ function do_multiplenumeric($ia) } $answer .= $question_tip.'\n".$answer_computed; } - + $answer_computed = isset($answer_computed)?$answer_computed:''; + $answer .= $answer_computed; //just added these here so its easy to change in one place $errorClass = 'tip error'; $goodClass = ' tip good';