public function actionIndex() { $model = new Guest(); if ($model->load(Yii::$app->request->post())) { $model->approved = false; $model->done = false; $model->save(); } $data = Guest::find()->where(['done' => false])->all(); return $this->render('index', ['data' => $data]); }