public function search($params) { $query = GlHeader::find(); $dataProvider = new ActiveDataProvider(['query' => $query]); if (!($this->load($params) && $this->validate())) { return $dataProvider; } $query->andFilterWhere(['id_gl' => $this->id_gl, 'gl_date' => $this->gl_date, 'id_branch' => $this->id_branch, 'id_periode' => $this->id_periode, 'type_reff' => $this->type_reff, 'id_reff' => $this->id_reff, 'status' => $this->status, 'create_at' => $this->create_at, 'create_by' => $this->create_by, 'update_at' => $this->update_at, 'update_by' => $this->update_by]); $query->andFilterWhere(['like', 'gl_num', $this->gl_num])->andFilterWhere(['like', 'gl_memo', $this->gl_memo])->andFilterWhere(['like', 'description', $this->description]); return $dataProvider; }