HelpSpot Help Desk Software | HelpSpot Blog | HelpSpot Support

Last Public Update in Portal Request History

Hello,
I’m trying to customize request.history.tpl.php to show the date of the last public update for each request. To do this, I’m trying something like this…

// $row is from requestHistoryData
$accessKey = $row['accesskey'];
$latestPublicUpdate = "0";

foreach ($this->splugin('Request_Check', 'getPublicUpdates', $accessKey) as $update) {
	if ($update["dtGMTChange"] > $latestPublicUpdate) {
		$latestPublicUpdate = $update["dtGMTChange"];
	}
}

However, it seems getPublicUpdates is cached and repeatedly returns the first result when called multiple times.

Does anyone know how I might accomplish this customization?

Thanks,
Andy