public function actionIndex()
{
$searchModel = new TweetSearch();
$params = Yii::$app->request->queryParams;
$params['TweetSearch']['content'] = empty($params['topic']) ? '' : $params['topic'];
$dataProvider = $searchModel->search($params);
$dataProvider->query->andWhere([Post::tableName() . '.type' => Tweet::TYPE, 'status' => [Post::STATUS_ACTIVE, Post::STATUS_EXCELLENT]]);
$model = new Tweet();
return $this->render('index', ['model' => $model, 'searchModel' => $searchModel, 'dataProvider' => $dataProvider]);
}