Just to get up to date I used the comfortupdate (great addition by the way) to get us to the latest stable build.
When I delete a condition I get the following PHP warning.
PHP warning
Invalid argument supplied for foreach()
/usr/local/www/apache22/data/application/helpers/expressions/em_manager_helper.php(772)
760
761 if (is_null($surveyId))
762 {
763 $sQuery='SELECT sid FROM {{surveys}}';
764 $aSurveyIDs = Yii::app()->db->createCommand($sQuery)->queryColumn();
765 }
766 else{
767 $aSurveyIDs=array($surveyId);
768 }
769 foreach ($aSurveyIDs as $surveyId ) {
770 // echo $surveyId.'<br>';flush();@ob_flush();
771 $releqns = self::ConvertConditionsToRelevance($surveyId,$qid);
772 foreach ($releqns as $key=>$value) {
773 $sQuery = "UPDATE {{questions}} SET relevance=".Yii::app()->db->quoteValue($value)." WHERE qid=".$key;
774 Yii::app()->db->createCommand($sQuery)->execute();
775 }
776 }
777
778 LimeExpressionManager::SetDirtyFlag();
779 }
780
781 /**
782 * This reverses UpgradeConditionsToRelevance(). It removes Relevance for questions that have Condition
783 * @param <integer> $surveyId
784 * @param <integer> $qid
Stack Trace
#0
–
/usr/local/www/apache22/data/application/controllers/admin/conditionsaction.php(368): LimeExpressionManager::UpgradeConditionsToRelevance(null, "6577")
363 // DELETE ENTRY IF THIS IS DELETE
364 if (isset($p_subaction) && $p_subaction == "delete")
365 {
366 LimeExpressionManager::RevertUpgradeConditionsToRelevance(NULL,$qid); // in case deleted the last condition
367 $result = Condition::model()->deleteRecords(array('cid'=>$p_cid));
368 LimeExpressionManager::UpgradeConditionsToRelevance(NULL,$qid);
369 }
370
371 // DELETE ALL CONDITIONS IN THIS SCENARIO
372 if (isset($p_subaction) && $p_subaction == "deletescenario")
373 {
#1
unknown(0): conditionsaction->index("editconditionsform", "22785", "129", "6577")
#2
+
/usr/local/www/apache22/data/framework/web/actions/CAction.php(108): ReflectionMethod->invokeArgs(conditionsaction, array("editconditionsform", "22785", "129", "6577"))
#3
–
/usr/local/www/apache22/data/application/core/Survey_Common_Action.php(99): CAction->runWithParamsInternal(conditionsaction, ReflectionMethod, array("subaction" => "editconditionsform", "surveyid" => "22785", "gid" => "129", "qid" => "6577", ...))
094 $oMethod = new ReflectionMethod($this, $sDefault);
095 }
096
097 // We're all good to go, let's execute it
098 // runWithParamsInternal would automatically get the parameters of the method and populate them as required with the params
099 return parent::runWithParamsInternal($this, $oMethod, $params);
100 }
101
102 /**
103 * Some functions have different parameters, which are just an alias of the
104 * usual parameters we're getting in the url. This function just populates
#4
+
/usr/local/www/apache22/data/framework/web/CController.php(308): Survey_Common_Action->runWithParams(array("subaction" => "editconditionsform", "surveyid" => "22785", "gid" => "129", "qid" => "6577", ...))
#5
+
/usr/local/www/apache22/data/framework/web/CController.php(286): CController->runAction(conditionsaction)
#6
+
/usr/local/www/apache22/data/framework/web/CController.php(265): CController->runActionWithFilters(conditionsaction, array())
#7
–
/usr/local/www/apache22/data/application/controllers/AdminController.php(169): CController->run("conditions")
164 $this->redirect(array('/admin/authentication/sa/login'));
165 }
166
167 }
168
169 return parent::run($action);
170 }
171
172 /**
173 * Routes all the actions to their respective places
174 *
#8
+
/usr/local/www/apache22/data/framework/web/CWebApplication.php(282): AdminController->run("conditions")
#9
+
/usr/local/www/apache22/data/framework/web/CWebApplication.php(141): CWebApplication->runController("admin/conditions/sa/index")
#10
+
/usr/local/www/apache22/data/framework/base/CApplication.php(180): CWebApplication->processRequest()
#11
+
/usr/local/www/apache22/data/index.php(207): CApplication->run()
The topic has been locked.