comparison core/modules/views_ui/src/ViewUI.php @ 14:1fec387a4317

Update Drupal core to 8.5.2 via Composer
author Chris Cannam
date Mon, 23 Apr 2018 09:46:53 +0100
parents 4c8ae668cc8c
children 129ea1e6d783
comparison
equal deleted inserted replaced
13:5fb285c0d0e3 14:1fec387a4317
46 46
47 /** 47 /**
48 * If this view is locked for editing. 48 * If this view is locked for editing.
49 * 49 *
50 * If this view is locked it will contain the result of 50 * If this view is locked it will contain the result of
51 * \Drupal\user\SharedTempStore::getMetadata(). Which can be a stdClass or 51 * \Drupal\Core\TempStore\SharedTempStore::getMetadata(). Which can be a stdClass or
52 * NULL. 52 * NULL.
53 * 53 *
54 * @var stdClass 54 * @var stdClass
55 */ 55 */
56 public $lock; 56 public $lock;
853 } 853 }
854 return $progress; 854 return $progress;
855 } 855 }
856 856
857 /** 857 /**
858 * Sets a cached view object in the user tempstore. 858 * Sets a cached view object in the shared tempstore.
859 */ 859 */
860 public function cacheSet() { 860 public function cacheSet() {
861 if ($this->isLocked()) { 861 if ($this->isLocked()) {
862 drupal_set_message(t('Changes cannot be made to a locked view.'), 'error'); 862 drupal_set_message(t('Changes cannot be made to a locked view.'), 'error');
863 return; 863 return;
876 // Unset handlers. We don't want to write these into the cache. 876 // Unset handlers. We don't want to write these into the cache.
877 $executable->display_handler = NULL; 877 $executable->display_handler = NULL;
878 $executable->default_display = NULL; 878 $executable->default_display = NULL;
879 $executable->query = NULL; 879 $executable->query = NULL;
880 $executable->displayHandlers = NULL; 880 $executable->displayHandlers = NULL;
881 \Drupal::service('user.shared_tempstore')->get('views')->set($this->id(), $this); 881 \Drupal::service('tempstore.shared')->get('views')->set($this->id(), $this);
882 } 882 }
883 883
884 /** 884 /**
885 * Returns whether the current view is locked. 885 * Returns whether the current view is locked.
886 * 886 *