Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master' into cint
Browse files Browse the repository at this point in the history
  • Loading branch information
olleharstedt committed Aug 8, 2016
2 parents 407eb5a + 457cdba commit 5e9355f
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions application/controllers/admin/surveyadmin.php
Expand Up @@ -676,11 +676,13 @@ public function activate($iSurveyID)
$aData['surveyid'] = $iSurveyID;
$surveyinfo = Survey::model()->findByPk($iSurveyID)->surveyinfo;
$aData['title_bar']['title'] = $surveyinfo['surveyls_title']." (".gT("ID").":".$iSurveyID.")";
// Die if this is not possible
// Redirect if this is not possible
if (!isset($aData['aSurveysettings']['active']) || $aData['aSurveysettings']['active'] == 'Y')
$this->getController()->error('Survey not active');
{
Yii::app()->setFlashMessage(gT("This survey is already active."),'error');
$this->getController()->redirect(array('admin/survey','sa'=>'view','surveyid'=>$iSurveyID));

$qtypes = getQuestionTypeList('', 'array');
} $qtypes = getQuestionTypeList('', 'array');
Yii::app()->loadHelper("admin/activate");

if (Yii::app()->request->getPost('ok')=='')
Expand Down

0 comments on commit 5e9355f

Please sign in to comment.