예제 #1
0
 /**
  * Lists all Competition models.
  * @return mixed
  */
 public function actionIndex2($type = Competition::TYPE_SEASON)
 {
     $searchModel = new CompetitionSearch();
     $dataProvider = $searchModel->search(Yii::$app->request->queryParams);
     $dataProvider->query->andWhere(['competition_type' => $type]);
     return $this->render('index', ['searchModel' => $searchModel, 'dataProvider' => $dataProvider, 'type' => $type]);
 }
 /**
  * Lists all Competition models.
  * @return mixed
  */
 public function actionIndex()
 {
     $searchModel = new CompetitionSearch();
     $dataProvider = $searchModel->search(Yii::$app->request->queryParams);
     return $this->render('index', ['searchModel' => $searchModel, 'dataProvider' => $dataProvider]);
 }