Commit 1a0ca124 authored by aspilicious's avatar aspilicious Committed by tim.plunkett

Issue #1712456 by aspilicious: Convert old cache api in groupwise_maximum handler.

parent e9b6395e
......@@ -178,7 +178,7 @@ function get_temporary_view() {
*/
function options_form_submit(&$form, &$form_state) {
$cid = 'views_relationship_groupwise_max:' . $this->view->name . ':' . $this->view->current_display . ':' . $this->options['id'];
cache_clear_all($cid, 'cache_views_data');
cache('views_data')->delete($cid);
}
/**
......@@ -365,13 +365,13 @@ function query() {
else {
// Get the stored subquery SQL string.
$cid = 'views_relationship_groupwise_max:' . $this->view->name . ':' . $this->view->current_display . ':' . $this->options['id'];
$cache = cache_get($cid, 'cache_views_data');
$cache = cache('views_data')->get($cid);
if (isset($cache->data)) {
$def['left_query'] = $cache->data;
}
else {
$def['left_query'] = $this->left_query($this->options);
cache_set($cid, $def['left_query'], 'cache_views_data');
cache('views_data')->set($cid, $def['left_query']);
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment