Skip to main content
added 96 characters in body
Source Link
Dominic Woodman
  • 2.2k
  • 4
  • 36
  • 60

Problem

I'm trying to pull data from the entity objects on a views page that is rendered using Search API. I'm trying to pull the data from hook_views_post_render.

Views appears to sometimes load the entire entity in the path:

$view->result[x]->_entity_properties['entity object']

However it doesn't always. Sometimes the objects are just missing and I can't pull data from them. (They appear on flushing the cache and then disappear a couple normal browser refreshes after.)

Does anyone know why this happens? I was wondering if they were cached, but they don't appear in $cache or $view i.e.:

hook_views_post_render ($view, $output, $cache)

Problem

I'm trying to pull data from the entity objects on a views page that is rendered using Search API. I'm trying to pull the data from hook_views_post_render.

Views appears to sometimes load the entire entity in the path:

$view->result[x]->_entity_properties['entity object']

However it doesn't always. Sometimes the objects are just missing and I can't pull data from them.

Does anyone know why this happens? I was wondering if they were cached, but they don't appear in $cache or $view i.e.:

hook_views_post_render ($view, $output, $cache)

Problem

I'm trying to pull data from the entity objects on a views page that is rendered using Search API. I'm trying to pull the data from hook_views_post_render.

Views appears to sometimes load the entire entity in the path:

$view->result[x]->_entity_properties['entity object']

However it doesn't always. Sometimes the objects are just missing and I can't pull data from them. (They appear on flushing the cache and then disappear a couple normal browser refreshes after.)

Does anyone know why this happens? I was wondering if they were cached, but they don't appear in $cache or $view i.e.:

hook_views_post_render ($view, $output, $cache)

Source Link
Dominic Woodman
  • 2.2k
  • 4
  • 36
  • 60

Views entity object sometimes missing

Problem

I'm trying to pull data from the entity objects on a views page that is rendered using Search API. I'm trying to pull the data from hook_views_post_render.

Views appears to sometimes load the entire entity in the path:

$view->result[x]->_entity_properties['entity object']

However it doesn't always. Sometimes the objects are just missing and I can't pull data from them.

Does anyone know why this happens? I was wondering if they were cached, but they don't appear in $cache or $view i.e.:

hook_views_post_render ($view, $output, $cache)