You are here

function elasticsearch_connector_views_handler_filter_string_autocomplete::op_not_ends in Elasticsearch Connector 7.5

Same name and namespace in other branches
  1. 7 modules/elasticsearch_connector_views/handlers/elasticsearch_connector_views_handler_filter_string_autocomplete.inc \elasticsearch_connector_views_handler_filter_string_autocomplete::op_not_ends()
  2. 7.2 modules/elasticsearch_connector_views/handlers/elasticsearch_connector_views_handler_filter_string_autocomplete.inc \elasticsearch_connector_views_handler_filter_string_autocomplete::op_not_ends()

Overrides views_handler_filter_string::op_not_ends

File

modules/elasticsearch_connector_views/handlers/elasticsearch_connector_views_handler_filter_string_autocomplete.inc, line 70
Handle the elasticsearch string fields autocomplete filter using views_autocomplete_filters.

Class

elasticsearch_connector_views_handler_filter_string_autocomplete
@file Handle the elasticsearch string fields autocomplete filter using views_autocomplete_filters.

Code

function op_not_ends($field) {
  $this->query
    ->add_where($this->options['group'], array(
    'not' => array(
      'filter' => array(
        'regexp' => array(
          $field => ".*" . $this->value,
        ),
      ),
    ),
  ));
}