Skip to content

Commit

Permalink
Merge pull request #280 from gabrieljenik/patch-4
Browse files Browse the repository at this point in the history
Fixed Issue: On RemoteControl2, no message set when reordering not possible.
  • Loading branch information
c-schmitz committed Feb 25, 2015
2 parents f01d67d + 32a9265 commit 04351d0
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions application/helpers/remotecontrol/remotecontrol_handle.php
Expand Up @@ -1108,11 +1108,12 @@ public function set_group_properties($sSessionKey, $iGroupID, $aGroupData)
//We do not allow groups with dependencies to change order - that would lead to broken dependencies

if((isset($has_dependencies) || isset($depented_on)) && $sFieldName == 'group_order')
$aFailed[$sFieldName]='Group with dependencies - Order cannot be changed';
else
{
$oGroup->setAttribute($sFieldName,$sValue);
$aResult[$sFieldName]='Group with dependencies - Order cannot be changed';
continue;
}
$oGroup->setAttribute($sFieldName,$sValue);

try
{
// save the change to database - one by one to allow for validation to work
Expand Down Expand Up @@ -1488,11 +1489,11 @@ public function set_question_properties($sSessionKey, $iQuestionID, $aQuestionDa
//We do not allow questions with dependencies in the same group to change order - that would lead to broken dependencies

if((isset($dependencies) || isset($is_criteria_question)) && $sFieldName == 'question_order')
$aFailed[$sFieldName]='Questions with dependencies - Order cannot be changed';
else
{
$oQuestion->setAttribute($sFieldName,$sValue);
$aResult[$sFieldName]='Questions with dependencies - Order cannot be changed';
continue;
}
$oQuestion->setAttribute($sFieldName,$sValue);

try
{
Expand Down

0 comments on commit 04351d0

Please sign in to comment.