示例#1
0
 /**
  * Lists all User models.
  * @return mixed
  */
 public function actionIndex()
 {
     $searchModel = new UserSearch();
     $dataProvider = $searchModel->search(Yii::$app->request->queryParams);
     $query = User::find();
     return $this->render('index', ['searchModel' => $searchModel, 'dataProvider' => $dataProvider, 'query' => $query]);
 }
示例#2
0
 public function actionAdministrators()
 {
     $this->isSuperAdmin();
     $params = Yii::$app->request->queryParams;
     $searchModel = new UserSearch();
     $dataProvider = $searchModel->searchAdministrators($params);
     return $this->render('administrators', ['searchModel' => $searchModel, 'dataProvider' => $dataProvider]);
 }