Welcome To Our Shell

Mister Spy & Souheyl Bypass Shell

Current Path : /var/www/html/rocksensor3/web/modules/contrib/visitors/visitors_geoip/

Linux ift1.ift-informatik.de 5.4.0-216-generic #236-Ubuntu SMP Fri Apr 11 19:53:21 UTC 2025 x86_64
Upload File :
Current File : /var/www/html/rocksensor3/web/modules/contrib/visitors/visitors_geoip/visitors_geoip.install

<?php

/**
 * @file
 * Install/uninstall visitors geoip module.
 */

use Drupal\Core\Datetime\DrupalDateTime;

/**
 * Implements hook_requirements().
 */
function visitors_geoip_requirements($phase) {
  $requirements = [];
  switch ($phase) {
    case 'install':
      $geoip2_installed = class_exists('GeoIp2\Database\Reader');
      if (!$geoip2_installed) {
        $requirements['visitors_geoip'] = [
          'title' => t('Visitors GeoIP'),
          'value' => t('Missing dependency.'),
          'description' => t(
            'The @module module requires the @geoip2 package. Install visitors using composer.',
            [
              '@module' => 'visitors_geoip',
              '@geoip2' => 'geoip2/geoip2',
            ]
          ),
          'severity' => REQUIREMENT_ERROR,
        ];
      }
      break;

    case 'runtime':
      $service = \Drupal::service('visitors_geoip.lookup');
      $meta = $service->metadata();
      $requirements['visitors_geoip'] = [
        'title' => t('Visitors GeoIP'),
        'value' => '',
      ];
      if (!is_null($meta)) {
        $requirements['visitors_geoip']['value'] .= t(
          'Type: @database_type build: @buildEpoch',
          [
            '@database_type' => $meta->databaseType,
            '@buildEpoch' => DrupalDateTime::createFromTimestamp($meta->buildEpoch),
          ]
        );
        $requirements['visitors_geoip']['severity'] = REQUIREMENT_OK;
      }
      if (!extension_loaded('maxminddb')) {
        $requirements['visitors_geoip']['value'] .= ' ' . t(
          'The @extension_geoip PHP extension is not installed.',
          ['@extension_geoip' => 'maxminddb']
        );
        $requirements['visitors_geoip']['severity'] = REQUIREMENT_WARNING;
      }
      break;
  }
  return $requirements;
}

/**
 * Implements hook_install().
 */
function visitors_geoip_install() {
  $schema = \Drupal::database()->schema();
  $table = 'visitors';
  if (!$schema->fieldExists($table, 'location_region')) {
    $schema->addField(
      'visitors',
      'location_region',
      [
        'type' => 'varchar',
        'length' => 128,
        'not null' => TRUE,
        'default' => '',
      ]
    );
  }
  if (!$schema->fieldExists($table, 'location_city')) {
    $schema->addField(
      'visitors',
      'location_city',
      [
        'type' => 'varchar',
        'length' => 128,
        'not null' => TRUE,
        'default' => '',
      ]
    );
  }
  if (!$schema->fieldExists($table, 'location_latitude')) {
    $schema->addField(
      'visitors',
      'location_latitude',
      [
        'type' => 'numeric',
        'precision' => 13,
        'scale' => 10,
        'default' => NULL,
      ]
    );
  }
  if (!$schema->fieldExists($table, 'location_longitude')) {
    $schema->addField(
      'visitors',
      'location_longitude',
      [
        'type' => 'numeric',
        'precision' => 13,
        'scale' => 10,
        'default' => NULL,
      ]
    );
  }

}

/**
 * Implements hook_uninstall().
 */
function visitors_geoip_uninstall() {
  $table = 'visitors';
  $schema = \Drupal::database()->schema();
  $schema->dropField($table, 'location_region');
  $schema->dropField($table, 'location_city');
  $schema->dropField($table, 'location_latitude');
  $schema->dropField($table, 'location_longitude');
}

/**
 * GeoIP2 compatibility.
 */
function visitors_geoip_update_8215(&$sandbox) {
  $schema = \Drupal::database()->schema();
  $schema->dropField('visitors', 'visitors_country_code3');
  $schema->dropField('visitors', 'visitors_dma_code');
  $schema->changeField('visitors', 'visitors_continent_code', 'location_continent_code', [
    'type' => 'varchar',
    'length' => 2,
    'not null' => TRUE,
    'default' => '',
  ]
  );
  $schema->changeField('visitors', 'visitors_country_code', 'location_country_code', [
    'type' => 'varchar',
    'length' => 2,
    'not null' => TRUE,
    'default' => '',
  ]
  );
  $schema->changeField('visitors', 'visitors_country_name', 'location_country_name', [
    'type' => 'varchar',
    'length' => 128,
    'not null' => TRUE,
    'default' => '',
  ]
  );
  $schema->changeField('visitors', 'visitors_region', 'location_region', [
    'type' => 'varchar',
    'length' => 128,
    'not null' => TRUE,
    'default' => '',
  ]
  );
  $schema->changeField('visitors', 'visitors_city', 'location_city', [
    'type' => 'varchar',
    'length' => 128,
    'not null' => TRUE,
    'default' => '',
  ]
  );
  $schema->changeField('visitors', 'visitors_postal', 'location_postal', [
    'type' => 'varchar',
    'length' => 128,
    'not null' => TRUE,
    'default' => '',
  ]
  );
  $schema->changeField('visitors', 'visitors_latitude', 'location_latitude', [
    'type' => 'numeric',
    'precision' => 13,
    'scale' => 10,
    'default' => NULL,
  ]);
  $schema->changeField('visitors', 'visitors_longitude', 'location_longitude', [
    'type' => 'numeric',
    'precision' => 13,
    'scale' => 10,
    'default' => NULL,
  ]);
  $schema->changeField('visitors', 'visitors_area_code', 'location_area_code', [
    'type' => 'int',
    'unsigned' => TRUE,
    'default' => NULL,
  ]);
}

/**
 * GeoIP2 compatibility.
 */
function visitors_geoip_update_8217(&$sandbox) {
  $settings = \Drupal::service('config.factory')
    ->getEditable('visitors_geoip.settings');
  $settings->set('license', '');
  if ($settings->get('geoip_path') == '') {
    $settings->set('geoip_path', '../');
  }
  if (strpos($settings->get('geoip_path'), '.mmdb') !== FALSE) {
    // Make the setting the directory, not the file.
    $settings->set('geoip_path', dirname($settings->get('geoip_path')));
  }
  $settings->save();
}

/**
 * Removes 'location_country_name' field.
 */
function visitors_geoip_update_8220() {
  $table = 'visitors';
  $schema = \Drupal::database()->schema();
  if ($schema->fieldExists($table, 'location_country_name')) {
    $schema->dropField($table, 'location_country_name');
  }
  if ($schema->fieldExists($table, 'location_postal')) {
    $schema->changeField(
      $table,
      'location_postal',
      'location_postal',
      [
        'type' => 'varchar',
        'length' => 128,
        'not null' => FALSE,
        'default' => NULL,
      ]
    );
  }
  $visitors_geoip_view = [
    'langcode' => 'en',
    'status' => TRUE,
    'dependencies' => [
      'module' => [
        0 => 'visitors',
      ],
      'enforced' => [
        'module' => [
          0 => 'visitors_geoip',
        ],
      ],
    ],
    'id' => 'visitors_geoip',
    'label' => 'Visitors GeoIP',
    'module' => 'views',
    'description' => 'Region and City location reports.',
    'tag' => '',
    'base_table' => 'visitors',
    'base_field' => '',
    'display' => [
      'default' => [
        'id' => 'default',
        'display_title' => 'Default',
        'display_plugin' => 'default',
        'position' => 0,
        'display_options' => [
          'fields' => [
            'visitor_id' => [
              'id' => 'visitor_id',
              'table' => 'visitors',
              'field' => 'visitor_id',
              'relationship' => 'none',
              'group_type' => 'count_distinct',
              'admin_label' => '',
              'plugin_id' => 'standard',
              'label' => 'Unique visitors',
              'exclude' => FALSE,
              'alter' => [
                'alter_text' => FALSE,
                'text' => '',
                'make_link' => FALSE,
                'path' => '',
                'absolute' => FALSE,
                'external' => FALSE,
                'replace_spaces' => FALSE,
                'path_case' => 'none',
                'trim_whitespace' => FALSE,
                'alt' => '',
                'rel' => '',
                'link_class' => '',
                'prefix' => '',
                'suffix' => '',
                'target' => '',
                'nl2br' => FALSE,
                'max_length' => 0,
                'word_boundary' => TRUE,
                'ellipsis' => TRUE,
                'more_link' => FALSE,
                'more_link_text' => '',
                'more_link_path' => '',
                'strip_tags' => FALSE,
                'trim' => FALSE,
                'preserve_tags' => '',
                'html' => FALSE,
              ],
              'element_type' => '',
              'element_class' => '',
              'element_label_type' => '',
              'element_label_class' => '',
              'element_label_colon' => TRUE,
              'element_wrapper_type' => '',
              'element_wrapper_class' => '',
              'element_default_classes' => TRUE,
              'empty' => '',
              'hide_empty' => FALSE,
              'empty_zero' => FALSE,
              'hide_alter_empty' => TRUE,
              'set_precision' => FALSE,
              'precision' => 0,
              'decimal' => '.',
              'separator' => ',',
              'format_plural' => 0,
              'format_plural_string' => '1
  \x03
  @count',
              'prefix' => '',
              'suffix' => '',
            ],
          ],
          'pager' => [
            'type' => 'mini',
            'options' => [
              'offset' => 0,
              'items_per_page' => 10,
              'total_pages' => NULL,
              'id' => 0,
              'tags' => [
                'next' => '››',
                'previous' => '‹‹',
              ],
              'expose' => [
                'items_per_page' => FALSE,
                'items_per_page_label' => 'Items per page',
                'items_per_page_options' => '5, 10, 25, 50',
                'items_per_page_options_all' => FALSE,
                'items_per_page_options_all_label' => '- All -',
                'offset' => FALSE,
                'offset_label' => 'Offset',
              ],
            ],
          ],
          'exposed_form' => [
            'type' => 'basic',
            'options' => [
              'submit_button' => 'Apply',
              'reset_button' => FALSE,
              'reset_button_label' => 'Reset',
              'exposed_sorts_label' => 'Sort by',
              'expose_sort_order' => TRUE,
              'sort_asc_label' => 'Asc',
              'sort_desc_label' => 'Desc',
            ],
          ],
          'access' => [
            'type' => 'none',
            'options' => [],
          ],
          'cache' => [
            'type' => 'tag',
            'options' => [],
          ],
          'empty' => [],
          'sorts' => [],
          'arguments' => [],
          'filters' => [
            'bot' => [
              'id' => 'bot',
              'table' => 'visitors',
              'field' => 'bot',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'boolean',
              'operator' => '!=',
              'value' => '1',
              'group' => 1,
              'exposed' => FALSE,
              'expose' => [
                'operator_id' => '',
                'label' => '',
                'description' => '',
                'use_operator' => FALSE,
                'operator' => '',
                'operator_limit_selection' => FALSE,
                'operator_list' => [],
                'identifier' => '',
                'required' => FALSE,
                'remember' => FALSE,
                'multiple' => FALSE,
                'remember_roles' => [
                  'authenticated' => 'authenticated',
                ],
              ],
              'is_grouped' => FALSE,
              'group_info' => [
                'label' => '',
                'description' => '',
                'identifier' => '',
                'optional' => TRUE,
                'widget' => 'select',
                'multiple' => FALSE,
                'remember' => FALSE,
                'default_group' => 'All',
                'default_group_multiple' => [],
                'group_items' => [],
              ],
            ],
            'visitors_date_time' => [
              'id' => 'visitors_date_time',
              'table' => 'visitors',
              'field' => 'visitors_date_time',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'visitors_date',
              'operator' => 'between',
              'value' => [
                'min' => 'to',
                'max' => 'from',
                'value' => '',
                'type' => 'global',
              ],
              'group' => 1,
              'exposed' => FALSE,
              'expose' => [
                'operator_id' => '',
                'label' => '',
                'description' => '',
                'use_operator' => FALSE,
                'operator' => '',
                'operator_limit_selection' => FALSE,
                'operator_list' => [],
                'identifier' => '',
                'required' => FALSE,
                'remember' => FALSE,
                'multiple' => FALSE,
                'remember_roles' => [
                  'authenticated' => 'authenticated',
                ],
                'min_placeholder' => '',
                'max_placeholder' => '',
                'placeholder' => '',
              ],
              'is_grouped' => FALSE,
              'group_info' => [
                'label' => '',
                'description' => '',
                'identifier' => '',
                'optional' => TRUE,
                'widget' => 'select',
                'multiple' => FALSE,
                'remember' => FALSE,
                'default_group' => 'All',
                'default_group_multiple' => [],
                'group_items' => [],
              ],
            ],
          ],
          'style' => [
            'type' => 'table',
            'options' => [
              'grouping' => [],
              'row_class' => '',
              'default_row_class' => TRUE,
              'columns' => [
                'visitors_id' => 'visitors_id',
                'visitors_url' => 'visitors_url',
                'visitors_date_time' => 'visitors_date_time',
                'visitor_id' => 'visitor_id',
                'nothing' => 'nothing',
              ],
              'default' => '-1',
              'info' => [
                'visitors_id' => [
                  'sortable' => FALSE,
                  'default_sort_order' => 'asc',
                  'align' => '',
                  'separator' => '',
                  'empty_column' => FALSE,
                  'responsive' => '',
                ],
                'visitors_url' => [
                  'sortable' => FALSE,
                  'default_sort_order' => 'asc',
                  'align' => '',
                  'separator' => '',
                  'empty_column' => FALSE,
                  'responsive' => '',
                ],
                'visitors_date_time' => [
                  'sortable' => FALSE,
                  'default_sort_order' => 'asc',
                  'align' => '',
                  'separator' => '',
                  'empty_column' => FALSE,
                  'responsive' => '',
                ],
                'visitor_id' => [
                  'sortable' => FALSE,
                  'default_sort_order' => 'desc',
                  'align' => '',
                  'separator' => '',
                  'empty_column' => FALSE,
                  'responsive' => '',
                ],
                'nothing' => [
                  'align' => '',
                  'separator' => '',
                  'empty_column' => FALSE,
                  'responsive' => '',
                ],
              ],
              'override' => TRUE,
              'sticky' => FALSE,
              'summary' => '',
              'empty_table' => FALSE,
              'caption' => '',
              'description' => '',
            ],
          ],
          'row' => [
            'type' => 'fields',
            'options' => [
              'default_field_elements' => TRUE,
              'inline' => [],
              'separator' => '',
              'hide_empty' => FALSE,
            ],
          ],
          'query' => [
            'type' => 'views_query',
            'options' => [
              'query_comment' => '',
              'disable_sql_rewrite' => FALSE,
              'distinct' => FALSE,
              'replica' => FALSE,
              'query_tags' => [],
            ],
          ],
          'relationships' => [],
          'group_by' => TRUE,
          'header' => [],
          'footer' => [],
          'display_extenders' => [],
        ],
        'cache_metadata' => [
          'max-age' => -1,
          'contexts' => [
            0 => 'languages:language_interface',
            1 => 'url.query_args',
          ],
          'tags' => [],
        ],
      ],
      'city_table' => [
        'id' => 'city_table',
        'display_title' => 'City',
        'display_plugin' => 'embed',
        'position' => 3,
        'display_options' => [
          'fields' => [
            'location_country_2' => [
              'id' => 'location_country_2',
              'table' => 'visitors',
              'field' => 'location_country',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'visitors_country',
              'label' => 'Abbreviation',
              'exclude' => TRUE,
              'alter' => [
                'alter_text' => TRUE,
                'text' => '{{ location_country_2|lower }}',
                'make_link' => FALSE,
                'path' => '',
                'absolute' => FALSE,
                'external' => FALSE,
                'replace_spaces' => FALSE,
                'path_case' => 'none',
                'trim_whitespace' => FALSE,
                'alt' => '',
                'rel' => '',
                'link_class' => '',
                'prefix' => '',
                'suffix' => '',
                'target' => '',
                'nl2br' => FALSE,
                'max_length' => 0,
                'word_boundary' => TRUE,
                'ellipsis' => TRUE,
                'more_link' => FALSE,
                'more_link_text' => '',
                'more_link_path' => '',
                'strip_tags' => FALSE,
                'trim' => FALSE,
                'preserve_tags' => '',
                'html' => FALSE,
              ],
              'element_type' => '',
              'element_class' => '',
              'element_label_type' => '',
              'element_label_class' => '',
              'element_label_colon' => TRUE,
              'element_wrapper_type' => '',
              'element_wrapper_class' => '',
              'element_default_classes' => TRUE,
              'empty' => '',
              'hide_empty' => FALSE,
              'empty_zero' => FALSE,
              'hide_alter_empty' => TRUE,
              'icon' => FALSE,
              'text' => FALSE,
              'abbreviation' => TRUE,
            ],
            'location_region' => [
              'id' => 'location_region',
              'table' => 'visitors',
              'field' => 'location_region',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'standard',
              'label' => 'Region url',
              'exclude' => TRUE,
              'alter' => [
                'alter_text' => FALSE,
                'text' => '',
                'make_link' => FALSE,
                'path' => '',
                'absolute' => FALSE,
                'external' => FALSE,
                'replace_spaces' => FALSE,
                'path_case' => 'none',
                'trim_whitespace' => FALSE,
                'alt' => '',
                'rel' => '',
                'link_class' => '',
                'prefix' => '',
                'suffix' => '',
                'target' => '',
                'nl2br' => FALSE,
                'max_length' => 0,
                'word_boundary' => TRUE,
                'ellipsis' => TRUE,
                'more_link' => FALSE,
                'more_link_text' => '',
                'more_link_path' => '',
                'strip_tags' => FALSE,
                'trim' => FALSE,
                'preserve_tags' => '',
                'html' => FALSE,
              ],
              'element_type' => '',
              'element_class' => '',
              'element_label_type' => '',
              'element_label_class' => '',
              'element_label_colon' => TRUE,
              'element_wrapper_type' => '',
              'element_wrapper_class' => '',
              'element_default_classes' => TRUE,
              'empty' => '_none',
              'hide_empty' => FALSE,
              'empty_zero' => FALSE,
              'hide_alter_empty' => TRUE,
            ],
            'location_city_1' => [
              'id' => 'location_city_1',
              'table' => 'visitors',
              'field' => 'location_city',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'standard',
              'label' => 'City url',
              'exclude' => TRUE,
              'alter' => [
                'alter_text' => FALSE,
                'text' => '',
                'make_link' => FALSE,
                'path' => '',
                'absolute' => FALSE,
                'external' => FALSE,
                'replace_spaces' => FALSE,
                'path_case' => 'none',
                'trim_whitespace' => FALSE,
                'alt' => '',
                'rel' => '',
                'link_class' => '',
                'prefix' => '',
                'suffix' => '',
                'target' => '',
                'nl2br' => FALSE,
                'max_length' => 0,
                'word_boundary' => TRUE,
                'ellipsis' => TRUE,
                'more_link' => FALSE,
                'more_link_text' => '',
                'more_link_path' => '',
                'strip_tags' => FALSE,
                'trim' => FALSE,
                'preserve_tags' => '',
                'html' => FALSE,
              ],
              'element_type' => '',
              'element_class' => '',
              'element_label_type' => '',
              'element_label_class' => '',
              'element_label_colon' => TRUE,
              'element_wrapper_type' => '',
              'element_wrapper_class' => '',
              'element_default_classes' => TRUE,
              'empty' => '_none',
              'hide_empty' => FALSE,
              'empty_zero' => FALSE,
              'hide_alter_empty' => TRUE,
            ],
            'location_city' => [
              'id' => 'location_city',
              'table' => 'visitors',
              'field' => 'location_city',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'standard',
              'label' => 'City',
              'exclude' => TRUE,
              'alter' => [
                'alter_text' => FALSE,
                'text' => '',
                'make_link' => FALSE,
                'path' => '',
                'absolute' => FALSE,
                'external' => FALSE,
                'replace_spaces' => FALSE,
                'path_case' => 'none',
                'trim_whitespace' => FALSE,
                'alt' => '',
                'rel' => '',
                'link_class' => '',
                'prefix' => '',
                'suffix' => '',
                'target' => '',
                'nl2br' => FALSE,
                'max_length' => 0,
                'word_boundary' => TRUE,
                'ellipsis' => TRUE,
                'more_link' => FALSE,
                'more_link_text' => '',
                'more_link_path' => '',
                'strip_tags' => FALSE,
                'trim' => FALSE,
                'preserve_tags' => '',
                'html' => FALSE,
              ],
              'element_type' => '',
              'element_class' => '',
              'element_label_type' => '',
              'element_label_class' => '',
              'element_label_colon' => TRUE,
              'element_wrapper_type' => '',
              'element_wrapper_class' => '',
              'element_default_classes' => TRUE,
              'empty' => 'Unknown',
              'hide_empty' => FALSE,
              'empty_zero' => FALSE,
              'hide_alter_empty' => TRUE,
            ],
            'location_country' => [
              'id' => 'location_country',
              'table' => 'visitors',
              'field' => 'location_country',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'visitors_country',
              'label' => 'Country',
              'exclude' => TRUE,
              'alter' => [
                'alter_text' => FALSE,
                'text' => '',
                'make_link' => FALSE,
                'path' => '',
                'absolute' => FALSE,
                'external' => FALSE,
                'replace_spaces' => FALSE,
                'path_case' => 'none',
                'trim_whitespace' => FALSE,
                'alt' => '',
                'rel' => '',
                'link_class' => '',
                'prefix' => '',
                'suffix' => '',
                'target' => '',
                'nl2br' => FALSE,
                'max_length' => 0,
                'word_boundary' => TRUE,
                'ellipsis' => TRUE,
                'more_link' => FALSE,
                'more_link_text' => '',
                'more_link_path' => '',
                'strip_tags' => FALSE,
                'trim' => FALSE,
                'preserve_tags' => '',
                'html' => FALSE,
              ],
              'element_type' => '',
              'element_class' => '',
              'element_label_type' => '',
              'element_label_class' => '',
              'element_label_colon' => TRUE,
              'element_wrapper_type' => '',
              'element_wrapper_class' => '',
              'element_default_classes' => TRUE,
              'empty' => '',
              'hide_empty' => FALSE,
              'empty_zero' => FALSE,
              'hide_alter_empty' => TRUE,
              'icon' => TRUE,
              'text' => FALSE,
            ],
            'location_country_1' => [
              'id' => 'location_country_1',
              'table' => 'visitors',
              'field' => 'location_country',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'visitors_country',
              'label' => 'City',
              'exclude' => FALSE,
              'alter' => [
                'alter_text' => TRUE,
                'text' => '{{ location_country }} {{ location_city }}, {{ location_country_1 }}',
                'make_link' => TRUE,
                'path' => 'internal:/visitors/location/city/{{ location_country_2 }}/{{ location_region }}/{{ location_city_1 }}',
                'absolute' => FALSE,
                'external' => FALSE,
                'replace_spaces' => FALSE,
                'path_case' => 'none',
                'trim_whitespace' => FALSE,
                'alt' => '',
                'rel' => '',
                'link_class' => '',
                'prefix' => '',
                'suffix' => '',
                'target' => '',
                'nl2br' => FALSE,
                'max_length' => 0,
                'word_boundary' => TRUE,
                'ellipsis' => TRUE,
                'more_link' => FALSE,
                'more_link_text' => '',
                'more_link_path' => '',
                'strip_tags' => FALSE,
                'trim' => FALSE,
                'preserve_tags' => '',
                'html' => FALSE,
              ],
              'element_type' => '',
              'element_class' => '',
              'element_label_type' => '',
              'element_label_class' => '',
              'element_label_colon' => TRUE,
              'element_wrapper_type' => '',
              'element_wrapper_class' => '',
              'element_default_classes' => TRUE,
              'empty' => '',
              'hide_empty' => FALSE,
              'empty_zero' => FALSE,
              'hide_alter_empty' => TRUE,
              'icon' => FALSE,
              'text' => TRUE,
              'abbreviation' => FALSE,
            ],
            'visitor_id' => [
              'id' => 'visitor_id',
              'table' => 'visitors',
              'field' => 'visitor_id',
              'relationship' => 'none',
              'group_type' => 'count_distinct',
              'admin_label' => '',
              'plugin_id' => 'standard',
              'label' => 'Unique visitors',
              'exclude' => FALSE,
              'alter' => [
                'alter_text' => FALSE,
                'text' => '',
                'make_link' => FALSE,
                'path' => '',
                'absolute' => FALSE,
                'external' => FALSE,
                'replace_spaces' => FALSE,
                'path_case' => 'none',
                'trim_whitespace' => FALSE,
                'alt' => '',
                'rel' => '',
                'link_class' => '',
                'prefix' => '',
                'suffix' => '',
                'target' => '',
                'nl2br' => FALSE,
                'max_length' => 0,
                'word_boundary' => TRUE,
                'ellipsis' => TRUE,
                'more_link' => FALSE,
                'more_link_text' => '',
                'more_link_path' => '',
                'strip_tags' => FALSE,
                'trim' => FALSE,
                'preserve_tags' => '',
                'html' => FALSE,
              ],
              'element_type' => '',
              'element_class' => '',
              'element_label_type' => '',
              'element_label_class' => '',
              'element_label_colon' => TRUE,
              'element_wrapper_type' => '',
              'element_wrapper_class' => '',
              'element_default_classes' => TRUE,
              'empty' => '',
              'hide_empty' => FALSE,
              'empty_zero' => FALSE,
              'hide_alter_empty' => TRUE,
              'set_precision' => FALSE,
              'precision' => 0,
              'decimal' => '.',
              'separator' => ',',
              'format_plural' => 0,
              'format_plural_string' => '1
  \x03
  @count',
              'prefix' => '',
              'suffix' => '',
            ],
          ],
          'arguments' => [
            'location_country' => [
              'id' => 'location_country',
              'table' => 'visitors',
              'field' => 'location_country',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'string',
              'default_action' => 'ignore',
              'exception' => [
                'value' => 'all',
                'title_enable' => FALSE,
                'title' => 'All',
              ],
              'title_enable' => FALSE,
              'title' => '',
              'default_argument_type' => 'fixed',
              'default_argument_options' => [
                'argument' => '',
              ],
              'summary_options' => [
                'base_path' => '',
                'count' => TRUE,
                'override' => FALSE,
                'items_per_page' => 25,
              ],
              'summary' => [
                'sort_order' => 'asc',
                'number_of_records' => 0,
                'format' => 'default_summary',
              ],
              'specify_validation' => FALSE,
              'validate' => [
                'type' => 'none',
                'fail' => 'not found',
              ],
              'validate_options' => [],
              'glossary' => FALSE,
              'limit' => 0,
              'case' => 'none',
              'path_case' => 'none',
              'transform_dash' => FALSE,
              'break_phrase' => FALSE,
            ],
            'location_region' => [
              'id' => 'location_region',
              'table' => 'visitors',
              'field' => 'location_region',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'string',
              'default_action' => 'ignore',
              'exception' => [
                'value' => 'all',
                'title_enable' => FALSE,
                'title' => 'All',
              ],
              'title_enable' => FALSE,
              'title' => '',
              'default_argument_type' => 'fixed',
              'default_argument_options' => [
                'argument' => '',
              ],
              'summary_options' => [
                'base_path' => '',
                'count' => TRUE,
                'override' => FALSE,
                'items_per_page' => 25,
              ],
              'summary' => [
                'sort_order' => 'asc',
                'number_of_records' => 0,
                'format' => 'default_summary',
              ],
              'specify_validation' => FALSE,
              'validate' => [
                'type' => 'none',
                'fail' => 'not found',
              ],
              'validate_options' => [],
              'glossary' => FALSE,
              'limit' => 0,
              'case' => 'none',
              'path_case' => 'none',
              'transform_dash' => FALSE,
              'break_phrase' => FALSE,
            ],
          ],
          'defaults' => [
            'fields' => FALSE,
            'arguments' => FALSE,
          ],
          'display_description' => '',
          'display_extenders' => [],
        ],
        'cache_metadata' => [
          'max-age' => -1,
          'contexts' => [
            0 => 'languages:language_interface',
            1 => 'url',
            2 => 'url.query_args',
          ],
          'tags' => [],
        ],
      ],
      'recent_view_table' => [
        'id' => 'recent_view_table',
        'display_title' => 'Recent Views',
        'display_plugin' => 'embed',
        'position' => 3,
        'display_options' => [
          'fields' => [
            'visitors_id' => [
              'id' => 'visitors_id',
              'table' => 'visitors',
              'field' => 'visitors_id',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'numeric',
              'label' => 'Visitors ID',
              'exclude' => TRUE,
              'alter' => [
                'alter_text' => FALSE,
                'text' => '',
                'make_link' => FALSE,
                'path' => '',
                'absolute' => FALSE,
                'external' => FALSE,
                'replace_spaces' => FALSE,
                'path_case' => 'none',
                'trim_whitespace' => FALSE,
                'alt' => '',
                'rel' => '',
                'link_class' => '',
                'prefix' => '',
                'suffix' => '',
                'target' => '',
                'nl2br' => FALSE,
                'max_length' => 0,
                'word_boundary' => TRUE,
                'ellipsis' => TRUE,
                'more_link' => FALSE,
                'more_link_text' => '',
                'more_link_path' => '',
                'strip_tags' => FALSE,
                'trim' => FALSE,
                'preserve_tags' => '',
                'html' => FALSE,
              ],
              'element_type' => '',
              'element_class' => '',
              'element_label_type' => '',
              'element_label_class' => '',
              'element_label_colon' => TRUE,
              'element_wrapper_type' => '',
              'element_wrapper_class' => '',
              'element_default_classes' => TRUE,
              'empty' => '',
              'hide_empty' => FALSE,
              'empty_zero' => FALSE,
              'hide_alter_empty' => TRUE,
              'set_precision' => FALSE,
              'precision' => 0,
              'decimal' => '.',
              'separator' => ',',
              'format_plural' => FALSE,
              'format_plural_string' => '1
  \x03
  @count',
              'prefix' => '',
              'suffix' => '',
            ],
            'visitors_url' => [
              'id' => 'visitors_url',
              'table' => 'visitors',
              'field' => 'visitors_url',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'standard',
              'label' => 'URL',
              'exclude' => FALSE,
              'alter' => [
                'alter_text' => FALSE,
                'text' => '',
                'make_link' => FALSE,
                'path' => '',
                'absolute' => FALSE,
                'external' => FALSE,
                'replace_spaces' => FALSE,
                'path_case' => 'none',
                'trim_whitespace' => FALSE,
                'alt' => '',
                'rel' => '',
                'link_class' => '',
                'prefix' => '',
                'suffix' => '',
                'target' => '',
                'nl2br' => FALSE,
                'max_length' => 0,
                'word_boundary' => TRUE,
                'ellipsis' => TRUE,
                'more_link' => FALSE,
                'more_link_text' => '',
                'more_link_path' => '',
                'strip_tags' => FALSE,
                'trim' => FALSE,
                'preserve_tags' => '',
                'html' => FALSE,
              ],
              'element_type' => '',
              'element_class' => '',
              'element_label_type' => '',
              'element_label_class' => '',
              'element_label_colon' => TRUE,
              'element_wrapper_type' => '',
              'element_wrapper_class' => '',
              'element_default_classes' => TRUE,
              'empty' => '',
              'hide_empty' => FALSE,
              'empty_zero' => FALSE,
              'hide_alter_empty' => TRUE,
            ],
            'visitors_date_time' => [
              'id' => 'visitors_date_time',
              'table' => 'visitors',
              'field' => 'visitors_date_time',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'date',
              'label' => 'Date Time',
              'exclude' => FALSE,
              'alter' => [
                'alter_text' => FALSE,
                'text' => '',
                'make_link' => FALSE,
                'path' => '',
                'absolute' => FALSE,
                'external' => FALSE,
                'replace_spaces' => FALSE,
                'path_case' => 'none',
                'trim_whitespace' => FALSE,
                'alt' => '',
                'rel' => '',
                'link_class' => '',
                'prefix' => '',
                'suffix' => '',
                'target' => '',
                'nl2br' => FALSE,
                'max_length' => 0,
                'word_boundary' => TRUE,
                'ellipsis' => TRUE,
                'more_link' => FALSE,
                'more_link_text' => '',
                'more_link_path' => '',
                'strip_tags' => FALSE,
                'trim' => FALSE,
                'preserve_tags' => '',
                'html' => FALSE,
              ],
              'element_type' => '',
              'element_class' => '',
              'element_label_type' => '',
              'element_label_class' => '',
              'element_label_colon' => TRUE,
              'element_wrapper_type' => '',
              'element_wrapper_class' => '',
              'element_default_classes' => TRUE,
              'empty' => '',
              'hide_empty' => FALSE,
              'empty_zero' => FALSE,
              'hide_alter_empty' => TRUE,
              'date_format' => 'short',
              'custom_date_format' => '',
              'timezone' => '',
            ],
            'visitor_id' => [
              'id' => 'visitor_id',
              'table' => 'visitors',
              'field' => 'visitor_id',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'standard',
              'label' => 'Visitor',
              'exclude' => FALSE,
              'alter' => [
                'alter_text' => FALSE,
                'text' => '',
                'make_link' => FALSE,
                'path' => '',
                'absolute' => FALSE,
                'external' => FALSE,
                'replace_spaces' => FALSE,
                'path_case' => 'none',
                'trim_whitespace' => FALSE,
                'alt' => '',
                'rel' => '',
                'link_class' => '',
                'prefix' => '',
                'suffix' => '',
                'target' => '',
                'nl2br' => FALSE,
                'max_length' => 0,
                'word_boundary' => TRUE,
                'ellipsis' => TRUE,
                'more_link' => FALSE,
                'more_link_text' => '',
                'more_link_path' => '',
                'strip_tags' => FALSE,
                'trim' => FALSE,
                'preserve_tags' => '',
                'html' => FALSE,
              ],
              'element_type' => '',
              'element_class' => '',
              'element_label_type' => '',
              'element_label_class' => '',
              'element_label_colon' => TRUE,
              'element_wrapper_type' => '',
              'element_wrapper_class' => '',
              'element_default_classes' => TRUE,
              'empty' => '',
              'hide_empty' => FALSE,
              'empty_zero' => FALSE,
              'hide_alter_empty' => TRUE,
            ],
            'nothing' => [
              'id' => 'nothing',
              'table' => 'views',
              'field' => 'nothing',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'custom',
              'label' => 'Operations',
              'exclude' => FALSE,
              'alter' => [
                'alter_text' => TRUE,
                'text' => 'details',
                'make_link' => TRUE,
                'path' => 'internal:/visitors/hits/{{ visitors_id }}',
                'absolute' => FALSE,
                'external' => FALSE,
                'replace_spaces' => FALSE,
                'path_case' => 'none',
                'trim_whitespace' => FALSE,
                'alt' => '',
                'rel' => '',
                'link_class' => '',
                'prefix' => '',
                'suffix' => '',
                'target' => '',
                'nl2br' => FALSE,
                'max_length' => 0,
                'word_boundary' => TRUE,
                'ellipsis' => TRUE,
                'more_link' => FALSE,
                'more_link_text' => '',
                'more_link_path' => '',
                'strip_tags' => FALSE,
                'trim' => FALSE,
                'preserve_tags' => '',
                'html' => FALSE,
              ],
              'element_type' => '',
              'element_class' => '',
              'element_label_type' => '',
              'element_label_class' => '',
              'element_label_colon' => TRUE,
              'element_wrapper_type' => '',
              'element_wrapper_class' => '',
              'element_default_classes' => TRUE,
              'empty' => '',
              'hide_empty' => FALSE,
              'empty_zero' => FALSE,
              'hide_alter_empty' => FALSE,
            ],
          ],
          'pager' => [
            'type' => 'full',
            'options' => [
              'offset' => 0,
              'items_per_page' => 10,
              'total_pages' => NULL,
              'id' => 0,
              'tags' => [
                'next' => '››',
                'previous' => '‹‹',
                'first' => '« First',
                'last' => 'Last »',
              ],
              'expose' => [
                'items_per_page' => FALSE,
                'items_per_page_label' => 'Items per page',
                'items_per_page_options' => '5, 10, 25, 50',
                'items_per_page_options_all' => FALSE,
                'items_per_page_options_all_label' => '- All -',
                'offset' => FALSE,
                'offset_label' => 'Offset',
              ],
              'quantity' => 9,
            ],
          ],
          'sorts' => [
            'visitors_id' => [
              'id' => 'visitors_id',
              'table' => 'visitors',
              'field' => 'visitors_id',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'standard',
              'order' => 'DESC',
              'expose' => [
                'label' => '',
                'field_identifier' => '',
              ],
              'exposed' => FALSE,
            ],
          ],
          'arguments' => [
            'location_country' => [
              'id' => 'location_country',
              'table' => 'visitors',
              'field' => 'location_country',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'string',
              'default_action' => 'ignore',
              'exception' => [
                'value' => 'all',
                'title_enable' => FALSE,
                'title' => 'All',
              ],
              'title_enable' => FALSE,
              'title' => '',
              'default_argument_type' => 'fixed',
              'default_argument_options' => [
                'argument' => '',
              ],
              'summary_options' => [
                'base_path' => '',
                'count' => TRUE,
                'override' => FALSE,
                'items_per_page' => 25,
              ],
              'summary' => [
                'sort_order' => 'asc',
                'number_of_records' => 0,
                'format' => 'default_summary',
              ],
              'specify_validation' => FALSE,
              'validate' => [
                'type' => 'none',
                'fail' => 'not found',
              ],
              'validate_options' => [],
              'glossary' => FALSE,
              'limit' => 0,
              'case' => 'lower',
              'path_case' => 'none',
              'transform_dash' => FALSE,
              'break_phrase' => FALSE,
            ],
            'location_region' => [
              'id' => 'location_region',
              'table' => 'visitors',
              'field' => 'location_region',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'string',
              'default_action' => 'ignore',
              'exception' => [
                'value' => 'all',
                'title_enable' => FALSE,
                'title' => 'All',
              ],
              'title_enable' => FALSE,
              'title' => '',
              'default_argument_type' => 'fixed',
              'default_argument_options' => [
                'argument' => '',
              ],
              'summary_options' => [
                'base_path' => '',
                'count' => TRUE,
                'override' => FALSE,
                'items_per_page' => 25,
              ],
              'summary' => [
                'sort_order' => 'asc',
                'number_of_records' => 0,
                'format' => 'default_summary',
              ],
              'specify_validation' => FALSE,
              'validate' => [
                'type' => 'none',
                'fail' => 'not found',
              ],
              'validate_options' => [],
              'glossary' => FALSE,
              'limit' => 0,
              'case' => 'none',
              'path_case' => 'none',
              'transform_dash' => FALSE,
              'break_phrase' => FALSE,
            ],
            'location_city' => [
              'id' => 'location_city',
              'table' => 'visitors',
              'field' => 'location_city',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'string',
              'default_action' => 'ignore',
              'exception' => [
                'value' => 'all',
                'title_enable' => FALSE,
                'title' => 'All',
              ],
              'title_enable' => FALSE,
              'title' => '',
              'default_argument_type' => 'fixed',
              'default_argument_options' => [
                'argument' => '',
              ],
              'summary_options' => [
                'base_path' => '',
                'count' => TRUE,
                'override' => FALSE,
                'items_per_page' => 25,
              ],
              'summary' => [
                'sort_order' => 'asc',
                'number_of_records' => 0,
                'format' => 'default_summary',
              ],
              'specify_validation' => FALSE,
              'validate' => [
                'type' => 'none',
                'fail' => 'not found',
              ],
              'validate_options' => [],
              'glossary' => FALSE,
              'limit' => 0,
              'case' => 'none',
              'path_case' => 'none',
              'transform_dash' => FALSE,
              'break_phrase' => FALSE,
            ],
          ],
          'filters' => [
            'bot' => [
              'id' => 'bot',
              'table' => 'visitors',
              'field' => 'bot',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'boolean',
              'operator' => '!=',
              'value' => '1',
              'group' => 1,
              'exposed' => FALSE,
              'expose' => [
                'operator_id' => '',
                'label' => '',
                'description' => '',
                'use_operator' => FALSE,
                'operator' => '',
                'operator_limit_selection' => FALSE,
                'operator_list' => [],
                'identifier' => '',
                'required' => FALSE,
                'remember' => FALSE,
                'multiple' => FALSE,
                'remember_roles' => [
                  'authenticated' => 'authenticated',
                ],
              ],
              'is_grouped' => FALSE,
              'group_info' => [
                'label' => '',
                'description' => '',
                'identifier' => '',
                'optional' => TRUE,
                'widget' => 'select',
                'multiple' => FALSE,
                'remember' => FALSE,
                'default_group' => 'All',
                'default_group_multiple' => [],
                'group_items' => [],
              ],
            ],
            'visitors_date_time' => [
              'id' => 'visitors_date_time',
              'table' => 'visitors',
              'field' => 'visitors_date_time',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'visitors_date',
              'operator' => 'between',
              'value' => [
                'min' => 'to',
                'max' => 'from',
                'value' => '',
                'type' => 'global',
              ],
              'group' => 1,
              'exposed' => FALSE,
              'expose' => [
                'operator_id' => '',
                'label' => '',
                'description' => '',
                'use_operator' => FALSE,
                'operator' => '',
                'operator_limit_selection' => FALSE,
                'operator_list' => [],
                'identifier' => '',
                'required' => FALSE,
                'remember' => FALSE,
                'multiple' => FALSE,
                'remember_roles' => [
                  'authenticated' => 'authenticated',
                ],
                'min_placeholder' => '',
                'max_placeholder' => '',
                'placeholder' => '',
              ],
              'is_grouped' => FALSE,
              'group_info' => [
                'label' => '',
                'description' => '',
                'identifier' => '',
                'optional' => TRUE,
                'widget' => 'select',
                'multiple' => FALSE,
                'remember' => FALSE,
                'default_group' => 'All',
                'default_group_multiple' => [],
                'group_items' => [],
              ],
            ],
            'visitors_path' => [
              'id' => 'visitors_path',
              'table' => 'visitors',
              'field' => 'visitors_path',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'string',
              'operator' => 'starts',
              'value' => '',
              'group' => 1,
              'exposed' => TRUE,
              'expose' => [
                'operator_id' => 'visitors_path_op',
                'label' => 'Path',
                'description' => '',
                'use_operator' => FALSE,
                'operator' => 'visitors_path_op',
                'operator_limit_selection' => FALSE,
                'operator_list' => [],
                'identifier' => 'visitors_path',
                'required' => FALSE,
                'remember' => FALSE,
                'multiple' => FALSE,
                'remember_roles' => [
                  'authenticated' => 'authenticated',
                  'anonymous' => '0',
                  'content_editor' => '0',
                  'administrator' => '0',
                ],
                'placeholder' => '',
              ],
              'is_grouped' => FALSE,
              'group_info' => [
                'label' => '',
                'description' => '',
                'identifier' => '',
                'optional' => TRUE,
                'widget' => 'select',
                'multiple' => FALSE,
                'remember' => FALSE,
                'default_group' => 'All',
                'default_group_multiple' => [],
                'group_items' => [],
              ],
            ],
          ],
          'filter_groups' => [
            'operator' => 'AND',
            'groups' => [
              1 => 'AND',
            ],
          ],
          'defaults' => [
            'pager' => FALSE,
            'group_by' => FALSE,
            'fields' => FALSE,
            'sorts' => FALSE,
            'arguments' => FALSE,
            'filters' => FALSE,
            'filter_groups' => FALSE,
            'header' => FALSE,
          ],
          'group_by' => FALSE,
          'display_description' => '',
          'header' => [
            'result' => [
              'id' => 'result',
              'table' => 'views',
              'field' => 'result',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'result',
              'empty' => FALSE,
              'content' => 'Displaying @start - @end of @total',
            ],
          ],
          'display_extenders' => [],
        ],
        'cache_metadata' => [
          'max-age' => -1,
          'contexts' => [
            0 => 'languages:language_interface',
            1 => 'url',
            2 => 'url.query_args',
          ],
          'tags' => [],
        ],
      ],
      'region_table' => [
        'id' => 'region_table',
        'display_title' => 'Region',
        'display_plugin' => 'embed',
        'position' => 2,
        'display_options' => [
          'fields' => [
            'location_region_1' => [
              'id' => 'location_region_1',
              'table' => 'visitors',
              'field' => 'location_region',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'standard',
              'label' => 'Region link',
              'exclude' => TRUE,
              'alter' => [
                'alter_text' => FALSE,
                'text' => '',
                'make_link' => FALSE,
                'path' => '',
                'absolute' => FALSE,
                'external' => FALSE,
                'replace_spaces' => FALSE,
                'path_case' => 'none',
                'trim_whitespace' => FALSE,
                'alt' => '',
                'rel' => '',
                'link_class' => '',
                'prefix' => '',
                'suffix' => '',
                'target' => '',
                'nl2br' => FALSE,
                'max_length' => 0,
                'word_boundary' => TRUE,
                'ellipsis' => TRUE,
                'more_link' => FALSE,
                'more_link_text' => '',
                'more_link_path' => '',
                'strip_tags' => FALSE,
                'trim' => FALSE,
                'preserve_tags' => '',
                'html' => FALSE,
              ],
              'element_type' => '',
              'element_class' => '',
              'element_label_type' => '',
              'element_label_class' => '',
              'element_label_colon' => FALSE,
              'element_wrapper_type' => '',
              'element_wrapper_class' => '',
              'element_default_classes' => TRUE,
              'empty' => '_none',
              'hide_empty' => FALSE,
              'empty_zero' => FALSE,
              'hide_alter_empty' => TRUE,
            ],
            'location_country_2' => [
              'id' => 'location_country_2',
              'table' => 'visitors',
              'field' => 'location_country',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'visitors_country',
              'label' => 'Abbreviation',
              'exclude' => TRUE,
              'alter' => [
                'alter_text' => TRUE,
                'text' => '{{ location_country_2|lower }}',
                'make_link' => FALSE,
                'path' => 'internal:/visitors/location/region/{{ location_country_2 }}/{{ location_region }}',
                'absolute' => FALSE,
                'external' => FALSE,
                'replace_spaces' => FALSE,
                'path_case' => 'none',
                'trim_whitespace' => FALSE,
                'alt' => '',
                'rel' => '',
                'link_class' => '',
                'prefix' => '',
                'suffix' => '',
                'target' => '',
                'nl2br' => FALSE,
                'max_length' => 0,
                'word_boundary' => TRUE,
                'ellipsis' => TRUE,
                'more_link' => FALSE,
                'more_link_text' => '',
                'more_link_path' => '',
                'strip_tags' => FALSE,
                'trim' => FALSE,
                'preserve_tags' => '',
                'html' => FALSE,
              ],
              'element_type' => '',
              'element_class' => '',
              'element_label_type' => '',
              'element_label_class' => '',
              'element_label_colon' => TRUE,
              'element_wrapper_type' => '',
              'element_wrapper_class' => '',
              'element_default_classes' => TRUE,
              'empty' => '',
              'hide_empty' => FALSE,
              'empty_zero' => FALSE,
              'hide_alter_empty' => TRUE,
              'icon' => FALSE,
              'text' => FALSE,
              'abbreviation' => TRUE,
            ],
            'location_country' => [
              'id' => 'location_country',
              'table' => 'visitors',
              'field' => 'location_country',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'visitors_country',
              'label' => 'Flag',
              'exclude' => TRUE,
              'alter' => [
                'alter_text' => FALSE,
                'text' => '',
                'make_link' => FALSE,
                'path' => '',
                'absolute' => FALSE,
                'external' => FALSE,
                'replace_spaces' => FALSE,
                'path_case' => 'none',
                'trim_whitespace' => FALSE,
                'alt' => '',
                'rel' => '',
                'link_class' => '',
                'prefix' => '',
                'suffix' => '',
                'target' => '',
                'nl2br' => FALSE,
                'max_length' => 0,
                'word_boundary' => TRUE,
                'ellipsis' => TRUE,
                'more_link' => FALSE,
                'more_link_text' => '',
                'more_link_path' => '',
                'strip_tags' => FALSE,
                'trim' => FALSE,
                'preserve_tags' => '',
                'html' => FALSE,
              ],
              'element_type' => '',
              'element_class' => '',
              'element_label_type' => '',
              'element_label_class' => '',
              'element_label_colon' => FALSE,
              'element_wrapper_type' => '',
              'element_wrapper_class' => '',
              'element_default_classes' => TRUE,
              'empty' => '',
              'hide_empty' => FALSE,
              'empty_zero' => FALSE,
              'hide_alter_empty' => TRUE,
              'icon' => TRUE,
              'text' => FALSE,
            ],
            'location_region' => [
              'id' => 'location_region',
              'table' => 'visitors',
              'field' => 'location_region',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'standard',
              'label' => 'Region',
              'exclude' => TRUE,
              'alter' => [
                'alter_text' => FALSE,
                'text' => '',
                'make_link' => FALSE,
                'path' => '',
                'absolute' => FALSE,
                'external' => FALSE,
                'replace_spaces' => FALSE,
                'path_case' => 'none',
                'trim_whitespace' => FALSE,
                'alt' => '',
                'rel' => '',
                'link_class' => '',
                'prefix' => '',
                'suffix' => '',
                'target' => '',
                'nl2br' => FALSE,
                'max_length' => 0,
                'word_boundary' => TRUE,
                'ellipsis' => TRUE,
                'more_link' => FALSE,
                'more_link_text' => '',
                'more_link_path' => '',
                'strip_tags' => FALSE,
                'trim' => FALSE,
                'preserve_tags' => '',
                'html' => FALSE,
              ],
              'element_type' => '',
              'element_class' => '',
              'element_label_type' => '',
              'element_label_class' => '',
              'element_label_colon' => TRUE,
              'element_wrapper_type' => '',
              'element_wrapper_class' => '',
              'element_default_classes' => TRUE,
              'empty' => 'Unknown',
              'hide_empty' => FALSE,
              'empty_zero' => FALSE,
              'hide_alter_empty' => TRUE,
            ],
            'location_country_1' => [
              'id' => 'location_country_1',
              'table' => 'visitors',
              'field' => 'location_country',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'visitors_country',
              'label' => 'Region',
              'exclude' => FALSE,
              'alter' => [
                'alter_text' => TRUE,
                'text' => '{{location_country }} {{ location_region }}, {{ location_country_1 }} ',
                'make_link' => TRUE,
                'path' => 'internal:/visitors/location/region/{{ location_country_2 }}/{{ location_region_1 }}',
                'absolute' => FALSE,
                'external' => FALSE,
                'replace_spaces' => FALSE,
                'path_case' => 'none',
                'trim_whitespace' => FALSE,
                'alt' => '',
                'rel' => '',
                'link_class' => '',
                'prefix' => '',
                'suffix' => '',
                'target' => '',
                'nl2br' => FALSE,
                'max_length' => 0,
                'word_boundary' => TRUE,
                'ellipsis' => TRUE,
                'more_link' => FALSE,
                'more_link_text' => '',
                'more_link_path' => '',
                'strip_tags' => FALSE,
                'trim' => FALSE,
                'preserve_tags' => '',
                'html' => FALSE,
              ],
              'element_type' => '',
              'element_class' => '',
              'element_label_type' => '',
              'element_label_class' => '',
              'element_label_colon' => TRUE,
              'element_wrapper_type' => '',
              'element_wrapper_class' => '',
              'element_default_classes' => TRUE,
              'empty' => 'Unknown',
              'hide_empty' => FALSE,
              'empty_zero' => FALSE,
              'hide_alter_empty' => TRUE,
              'icon' => FALSE,
              'text' => TRUE,
              'abbreviation' => FALSE,
            ],
            'visitor_id' => [
              'id' => 'visitor_id',
              'table' => 'visitors',
              'field' => 'visitor_id',
              'relationship' => 'none',
              'group_type' => 'count_distinct',
              'admin_label' => '',
              'plugin_id' => 'standard',
              'label' => 'Unique visitors',
              'exclude' => FALSE,
              'alter' => [
                'alter_text' => FALSE,
                'text' => '',
                'make_link' => FALSE,
                'path' => '',
                'absolute' => FALSE,
                'external' => FALSE,
                'replace_spaces' => FALSE,
                'path_case' => 'none',
                'trim_whitespace' => FALSE,
                'alt' => '',
                'rel' => '',
                'link_class' => '',
                'prefix' => '',
                'suffix' => '',
                'target' => '',
                'nl2br' => FALSE,
                'max_length' => 0,
                'word_boundary' => TRUE,
                'ellipsis' => TRUE,
                'more_link' => FALSE,
                'more_link_text' => '',
                'more_link_path' => '',
                'strip_tags' => FALSE,
                'trim' => FALSE,
                'preserve_tags' => '',
                'html' => FALSE,
              ],
              'element_type' => '',
              'element_class' => '',
              'element_label_type' => '',
              'element_label_class' => '',
              'element_label_colon' => TRUE,
              'element_wrapper_type' => '',
              'element_wrapper_class' => '',
              'element_default_classes' => TRUE,
              'empty' => '',
              'hide_empty' => FALSE,
              'empty_zero' => FALSE,
              'hide_alter_empty' => TRUE,
              'set_precision' => FALSE,
              'precision' => 0,
              'decimal' => '.',
              'separator' => ',',
              'format_plural' => 0,
              'format_plural_string' => '1
  \x03
  @count',
              'prefix' => '',
              'suffix' => '',
            ],
          ],
          'arguments' => [
            'location_country' => [
              'id' => 'location_country',
              'table' => 'visitors',
              'field' => 'location_country',
              'relationship' => 'none',
              'group_type' => 'group',
              'admin_label' => '',
              'plugin_id' => 'string',
              'default_action' => 'ignore',
              'exception' => [
                'value' => 'all',
                'title_enable' => FALSE,
                'title' => 'All',
              ],
              'title_enable' => FALSE,
              'title' => '',
              'default_argument_type' => 'fixed',
              'default_argument_options' => [
                'argument' => '',
              ],
              'summary_options' => [
                'base_path' => '',
                'count' => TRUE,
                'override' => FALSE,
                'items_per_page' => 25,
              ],
              'summary' => [
                'sort_order' => 'asc',
                'number_of_records' => 0,
                'format' => 'default_summary',
              ],
              'specify_validation' => FALSE,
              'validate' => [
                'type' => 'none',
                'fail' => 'not found',
              ],
              'validate_options' => [],
              'glossary' => FALSE,
              'limit' => 0,
              'case' => 'none',
              'path_case' => 'none',
              'transform_dash' => FALSE,
              'break_phrase' => FALSE,
            ],
          ],
          'defaults' => [
            'fields' => FALSE,
            'arguments' => FALSE,
          ],
          'display_description' => '',
          'display_extenders' => [],
        ],
        'cache_metadata' => [
          'max-age' => -1,
          'contexts' => [
            0 => 'languages:language_interface',
            1 => 'url',
            2 => 'url.query_args',
          ],
          'tags' => [],
        ],
      ],
    ],
  ];
  $view_storage = \Drupal::entityTypeManager()->getStorage('view');

  $view_storage->create($visitors_geoip_view)->save();
}

/**
 * Removes 'location_postal' and 'location_area_code' fields.
 */
function visitors_geoip_update_8222() {
  $table = 'visitors';
  $schema = \Drupal::database()->schema();

  if ($schema->fieldExists($table, 'location_postal')) {
    $schema->dropField($table, 'location_postal');
  }
  if ($schema->fieldExists($table, 'location_area_code')) {
    $schema->dropField($table, 'location_area_code');
  }

}

bypass 1.0, Devloped By El Moujahidin (the source has been moved and devloped)
Email: contact@elmoujehidin.net bypass 1.0, Devloped By El Moujahidin (the source has been moved and devloped) Email: contact@elmoujehidin.net