Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions content/content.profile.php
Original file line number Diff line number Diff line change
Expand Up @@ -123,15 +123,15 @@ public function buildContent(XMLElement $wrapper) {
foreach ($this->_records['data-sources'] as $data) $ds_total += $data[1];

$this->_records = array(
array(__('Total Database Queries'), $this->_dbstats['queries'], NULL, NULL, false),
array(__('Slow Queries (> 0.09s)'), (string)count($this->_dbstats['slow-queries']), NULL, NULL, false),
array(__('Total Database Queries'), $this->_dbstats['queries'], null, null, false),
array(__('Slow Queries (> 0.09s)'), (string)count($this->_dbstats['slow-queries']), null, null, false),
array(__('Total Time Spent on Queries'), $this->_dbstats['total-query-time']),
array(__('Time Triggering All Events'), $event_total),
array(__('Time Running All Data Sources'), $ds_total),
array(__('XML Generation'), $xml_generation[1]),
array(__('XSLT Transformation'), $xsl_transformation[1]),
array(__('Output Creation Time'), Symphony::Profiler()->retrieveTotalRunningTime()),
array(__('Total Memory Usage'), General::formatFilesize(Symphony::Profiler()->retrieveTotalMemoryUsage()), NULL, NULL, false),
array(__('Total Memory Usage'), General::formatFilesize(Symphony::Profiler()->retrieveTotalMemoryUsage()), null, null, false),
);

foreach ($this->_records as $data) {
Expand Down Expand Up @@ -240,19 +240,19 @@ public function buildContent(XMLElement $wrapper) {

}
elseif ($this->_view == 'slow-queries') {

$value = $data[1];
if(!isset($data[4]) || $data[4] !== false){
$data[1] = number_format($data[1], 4) . ' s';
$value = number_format($data[1], 4) . ' s';
}

$row->appendChild(new XMLElement('td', $data[1]));
$row->appendChild(new XMLElement('td', $value));

}
else {
$row->appendChild(new XMLElement('td', number_format($data[1], 4) . ' s from ' . $data[4] . ' ' . ($data[4] == 1 ? 'query' : 'queries')));
}

$ds_total += $data[1];
$ds_total += intval($data[1]);
$table->appendChild($row);
}
}
Expand Down
4 changes: 4 additions & 0 deletions extension.meta.xml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,10 @@
</author>
</authors>
<releases>
<release version="2.0.0" date="TBA" min="4.0.0" max="4.x.x" php-min="5.6.x" php-max="7.x.x">
- Update for Symphony 4.x
- PHP7 Compatibility
</release>
<release version="1.5.2" date="2014-03-11" min="2.4" max="2.x.x">
- Mark compatibility with Symphony 2.6+
</release>
Expand Down