Update to Drupal 8.1.9. For more information, see https://www.drupal.org/project/drupal/releases/8.1.9

This commit is contained in:
Pantheon Automation 2016-09-07 13:26:21 -07:00 committed by Greg Anderson
parent f9f23cdf38
commit 09b113657a
125 changed files with 2307 additions and 385 deletions

View file

@ -64,6 +64,7 @@ class FieldApiDataTest extends FieldTestBase {
$this->assertTrue(isset($data[$revision_table]['table']['join']['node_field_revision']));
$expected_join = array(
'table' => $current_table,
'left_field' => 'nid',
'field' => 'entity_id',
'extra' => array(
@ -73,6 +74,7 @@ class FieldApiDataTest extends FieldTestBase {
);
$this->assertEqual($expected_join, $data[$current_table]['table']['join']['node_field_data']);
$expected_join = array(
'table' => $revision_table,
'left_field' => 'vid',
'field' => 'revision_id',
'extra' => array(

View file

@ -701,7 +701,7 @@ function hook_views_pre_view(ViewExecutable $view, $display_id, array &$args) {
// Modify contextual filters for my_special_view if user has 'my special permission'.
$account = \Drupal::currentUser();
if ($view->name == 'my_special_view' && $account->hasPermission('my special permission') && $display_id == 'public_display') {
if ($view->id() == 'my_special_view' && $account->hasPermission('my special permission') && $display_id == 'public_display') {
$args[0] = 'custom value';
}
}
@ -744,7 +744,7 @@ function hook_views_post_build(ViewExecutable $view) {
// assumptions about both exposed filter settings and the fields in the view.
// Also note that this alter could be done at any point before the view being
// rendered.)
if ($view->name == 'my_view' && isset($view->exposed_raw_input['type']) && $view->exposed_raw_input['type'] != 'All') {
if ($view->id() == 'my_view' && isset($view->exposed_raw_input['type']) && $view->exposed_raw_input['type'] != 'All') {
// 'Type' should be interpreted as content type.
if (isset($view->field['type'])) {
$view->field['type']->options['exclude'] = TRUE;
@ -771,7 +771,7 @@ function hook_views_pre_execute(ViewExecutable $view) {
$account = \Drupal::currentUser();
if (count($view->query->tables) > 2 && $account->hasPermission('administer views')) {
drupal_set_message(t('The view %view may be heavy to execute.', array('%view' => $view->name)), 'warning');
drupal_set_message(t('The view %view may be heavy to execute.', array('%view' => $view->id())), 'warning');
}
}

View file

@ -357,6 +357,7 @@ function views_field_default_views_data(FieldStorageConfigInterface $field_stora
if ($data_table) {
// Tell Views how to join to the base table, via the data table.
$data[$table_alias]['table']['join'][$data_table] = array(
'table' => $table_mapping->getDedicatedDataTableName($field_storage),
'left_field' => $entity_type->getKey('id'),
'field' => 'entity_id',
'extra' => array(
@ -368,6 +369,7 @@ function views_field_default_views_data(FieldStorageConfigInterface $field_stora
else {
// If there is no data table, just join directly.
$data[$table_alias]['table']['join'][$base_table] = array(
'table' => $table_mapping->getDedicatedDataTableName($field_storage),
'left_field' => $entity_type->getKey('id'),
'field' => 'entity_id',
'extra' => array(
@ -381,6 +383,7 @@ function views_field_default_views_data(FieldStorageConfigInterface $field_stora
if ($entity_revision_data_table) {
// Tell Views how to join to the revision table, via the data table.
$data[$table_alias]['table']['join'][$entity_revision_data_table] = array(
'table' => $table_mapping->getDedicatedRevisionTableName($field_storage),
'left_field' => $entity_type->getKey('revision'),
'field' => 'revision_id',
'extra' => array(
@ -392,6 +395,7 @@ function views_field_default_views_data(FieldStorageConfigInterface $field_stora
else {
// If there is no data table, just join directly.
$data[$table_alias]['table']['join'][$entity_revision_table] = array(
'table' => $table_mapping->getDedicatedRevisionTableName($field_storage),
'left_field' => $entity_type->getKey('revision'),
'field' => 'revision_id',
'extra' => array(