original_string: protected function filterTimestamp(&$query, $attr = 'updated_at')
      {
          if (!is_null($this->{$attr}) && strpos($this->{$attr}, ' - ') !== false ) {
              list($start_date, $end_date) = explode(' - ', $this->{$attr});
              $query->andFilterWhere(['>=', $attr, (int)strtotime($start_date)]);
              $query->andFilterWhere(['<=', $attr, (int)strtotime($end_date) + 24 * 3600]);
          }
      }
code: protected function filterTimestamp(&$query, $attr = 'updated_at')
      {
          if (!is_null($this->{$attr}) && strpos($this->{$attr}, ' - ') !== false ) {
              list($start_date, $end_date) = explode(' - ', $this->{$attr});
              $query->andFilterWhere(['>=', $attr, (int)strtotime($start_date)]);
              $query->andFilterWhere(['<=', $attr, (int)strtotime($end_date) + 24 * 3600]);
          }
      }
code_tokens: protected function filterTimestamp ( & $ query , $ attr = 'updated_at' ) { if ( ! is_null ( $ this -> { $ attr } ) && strpos ( $ this -> { $ attr } , ' - ' ) !== false ) { list ( $ start_date , $ end_date ) = explode ( ' - ' , $ this -> { $ attr } ) ; $ query -> andFilterWhere ( [ '>=' , $ attr , ( int ) strtotime ( $ start_date ) ] ) ; $ query -> andFilterWhere ( [ '<=' , $ attr , ( int ) strtotime ( $ end_date ) + 24 * 3600 ] ) ; } }
docstring: Add filter on timestamp.
  @param string $attr
docstring_tokens: Add filter on timestamp .