Hello, i have a form like this :
<?php $form = ActiveForm::begin(['options' => ['enctype' => 'multipart/form-data']]) ?>
	<?= $form->field($model, 'myFile')->fileInput()?>
	<?= $form->field($model, 'test')->radioList($model->getStatusList())?>
	<button>Submit</button>
	<?php ActiveForm::end() ?>
I want to make a redirect who depends of ‘test’ value
public static function getStatusList()
{
return [
self::CATALOG_MOODLE => ‘Catalog Moodle’,
self::CATALOG_SECRETARIAT => ‘Catalog Secretariat’,
//other values
];
}
i have an if :
      if($this->test->value == 'Catalog Moodle')
        Yii::$app->response->redirect(Url::to(['catalogmoodle/index']));
      else
        Yii::$app->response->redirect(Url::to(['catalogsecretariat/index']));
But I always go on else
Any Ideas?