Added commenting on the list page
This commit is contained in:
@@ -116,6 +116,32 @@ $filter->render();
|
||||
|
||||
<br/>
|
||||
|
||||
<?php
|
||||
$signature_id = (int)$_REQUEST["signature_id"];
|
||||
if ($signature_id):
|
||||
CrashStats::getSignature($signature_id);
|
||||
?>
|
||||
|
||||
<table class="ui-widget ui-widget-content ui-corner-all" style="width: 100%">
|
||||
<thead>
|
||||
<tr class="ui-widget-header">
|
||||
<th style="width: 40%">Signature</th>
|
||||
<th style="width: 60%">Notes</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr class="ui-helper-reset">
|
||||
<td><?php echo CrashStats::renderSignature($signature_id) ?></td>
|
||||
<td><?php echo Comments::renderCommentPanel($signature_id) ?></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<br/>
|
||||
|
||||
<?php endif ?>
|
||||
|
||||
|
||||
<table width="100%" class="jtable">
|
||||
<tr>
|
||||
<th>ID</th>
|
||||
|
||||
@@ -76,14 +76,17 @@ tr.rowhighlight a {
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
table {
|
||||
border-spacing: 0px;
|
||||
/*border-collapse:collapse;*/
|
||||
}
|
||||
|
||||
table.jtable tr:hover, table.jtable th {
|
||||
background: #2b3233 url(images/ui-bg_highlight-hard_20_2b3233_1x100.png) 50% 50% repeat-x;
|
||||
color: #ffffff;
|
||||
}
|
||||
|
||||
table.jtable {
|
||||
border-spacing: 0px;
|
||||
/*border-collapse:collapse;*/
|
||||
border: 1px solid #555555;
|
||||
background: #1e1e1e url(images/ui-bg_flat_25_1e1e1e_40x100.png) 50% 50% repeat-x;
|
||||
color: #c5c5c5;
|
||||
|
||||
@@ -45,7 +45,7 @@ class CrashStats
|
||||
return $ret;
|
||||
}
|
||||
|
||||
function getSignature($id)
|
||||
static function getSignature($id)
|
||||
{
|
||||
$ret = new stdClass;
|
||||
$q = kl_str_sql("select * from signature where id=!i", $id);
|
||||
@@ -64,6 +64,22 @@ class CrashStats
|
||||
return false;
|
||||
}
|
||||
|
||||
static function renderSignature($id)
|
||||
{
|
||||
if (!$r = self::getSignature($id)) return "";
|
||||
|
||||
$parts = explode("|", $r->signature);
|
||||
$txt = "";
|
||||
if ($parts[1]) $txt .= preg_replace("/((::|<|>|,|\\(|\\)))/", "<wbr/>\\1<wbr/>", htmlentities($parts[1]));
|
||||
if ($txt) $txt .= "<br/><br/>";
|
||||
if ($parts[2]) $txt .= preg_replace("/((::|<|>|,|\\(|\\)))/", "<wbr/>\\1<wbr/>", htmlentities($parts[2]));
|
||||
|
||||
$ret = "<p>Module: " . $parts[0];
|
||||
if ($txt) $ret .= "<br/><br/>" . $txt . "</p>";
|
||||
|
||||
return $ret;
|
||||
}
|
||||
|
||||
function getGPUStats()
|
||||
{
|
||||
$ret = array();
|
||||
|
||||
@@ -158,7 +158,7 @@ class SearchFilter
|
||||
|
||||
<form id="filter_form" method="get">
|
||||
<div class="ui-widget ui-widget-content ui-corner-all">
|
||||
<div class="ui-widget-header" style="padding: 5px">Filter</div>
|
||||
<div class="ui-widget-header" style="padding: 0.5em;">Filter</div>
|
||||
|
||||
<div class="filterelem">
|
||||
<div class="radio">
|
||||
|
||||
@@ -123,6 +123,10 @@ $(function() {
|
||||
<th>Crash Reason</th>
|
||||
<td><?php echo htmlentities($report->crash_reason . " at " . $report->crash_address . " thread " . $report->crash_thread) ?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Crash Type</th>
|
||||
<td><a href="crashes.php?signature_id=<?php echo $report->signature_id ?>"><?php echo $report->signature_id ?></a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Minidump</th>
|
||||
<td><a href="download.php/singularity<?php echo (int)$report->id ?>.dmp?report_id=<?php echo (int)$report->id ?>">Download</a></td>
|
||||
|
||||
@@ -4,18 +4,4 @@ define("SITE_ROOT", realpath(dirname(__file__)));
|
||||
require_once SITE_ROOT . "/lib/init.php";
|
||||
$S->requireUser();
|
||||
|
||||
$stats = new CrashStats($filter);
|
||||
|
||||
if (false === $r = $stats->getSignature((int)$_GET["signature_id"]))
|
||||
{
|
||||
print "<p>No such signature</p>";
|
||||
}
|
||||
|
||||
$parts = explode("|", $r->signature);
|
||||
$txt = "";
|
||||
if ($parts[1]) $txt .= preg_replace("/((::|<|>|,|\\(|\\)))/", "<wbr/>\\1<wbr/>", htmlentities($parts[1]));
|
||||
if ($txt) $txt .= "<br/><br/>";
|
||||
if ($parts[2]) $txt .= preg_replace("/((::|<|>|,|\\(|\\)))/", "<wbr/>\\1<wbr/>", htmlentities($parts[2]));
|
||||
|
||||
print "<p>Module: " . $parts[0];
|
||||
if ($txt) print "<br/><br/>" . $txt . "</p>";
|
||||
print CrashStats::renderSignature((int)$_GET["signature_id"]);
|
||||
Reference in New Issue
Block a user