Hi, well im getting this error “The “query” property must be an instance of a class that implements the QueryInterface” with this code, i know that it should be easy to solve but im new in yii2 and active record, if you can please tell me what im doing wrong , ive looking for an answer for the last three days , a guy asked for the same problem few days ago but no one helped him
$query = Place::findAll([1,2,3]);
$dataProvider = new ActiveDataProvider([
'query' => $query,
]);
if (!($this->load($params) && $this->validate())) {
return $dataProvider;
}
$query->andFilterWhere([
'id' => $this->id,
]);
.
.
return $dataProvider;
}