2 $this->
data[
'header'] =
'SimpleSAMLphp Statistics';
4 $this->
data[
'jquery'] =
array(
'core' =>
true,
'ui' =>
true,
'css' =>
true);
9 $this->includeAtTemplateBase(
'includes/header.php');
11 echo
'<h1>'. $this->
data[
'available.rules'][$this->
data[
'selected.rule']][
'name'] .
'</h1>';
12 echo
'<p>' . $this->
data[
'available.rules'][$this->
data[
'selected.rule']][
'descr'] .
'</p>';
15 echo
'<table class="selecttime">';
16 echo
'<tr><td class="selecttime_icon"><img src="' . SimpleSAML\Utils\HTTP::getBaseUrl() .
'resources/icons/crystal_project/kchart.32x32.png" alt="Report settings" /></td>';
20 echo
'<form action="#">';
21 echo $this->
data[
'post_rule'];
22 echo
'<select onchange="submit();" name="rule">';
24 if (
$key === $this->
data[
'selected.rule']) {
25 echo
'<option selected="selected" value="' .
$key .
'">' .
$rule[
'name'] .
'</option>';
27 echo
'<option value="' .
$key .
'">' .
$rule[
'name'] .
'</option>';
30 echo
'</select></form>';
34 echo
'<td class="td_right">';
35 echo
'<form action="#">';
36 echo $this->
data[
'post_d'];
37 echo
'<select onchange="submit();" name="d">';
38 foreach ($this->data[
'availdelimiters'] as
$key => $delim) {
40 if (array_key_exists($delim, $this->data[
'delimiterPresentation'])) {
41 $delimName = $this->data[
'delimiterPresentation'][$delim];
45 echo
'<option value="_">Total</option>';
46 } elseif (isset($_REQUEST[
'd']) && $delim == $_REQUEST[
'd']) {
47 echo
'<option selected="selected" value="' . htmlspecialchars($delim) .
'">' . htmlspecialchars($delimName) .
'</option>';
49 echo
'<option value="' . htmlspecialchars($delim) .
'">' . htmlspecialchars($delimName) .
'</option>';
52 echo
'</select></form>';
61 echo
'<table class="selecttime">';
62 echo
'<tr><td class="selecttime_icon"><img src="' . SimpleSAML\Utils\HTTP::getBaseUrl() .
'resources/icons/crystal_project/date.32x32.png" alt="Select date and time" /></td>';
64 if (isset($this->data[
'available.times.prev'])) {
65 echo
'<td><a href="' . $this->data[
'get_times_prev'] .
'">« Previous</a></td>';
67 echo
'<td class="selecttime_link_grey">« Previous</td>';
70 echo
'<td class="td_right">';
71 echo
'<form action="#">';
72 echo $this->data[
'post_res'];
73 echo
'<select onchange="submit();" name="res">';
74 foreach ($this->data[
'available.timeres'] as
$key => $timeresname) {
75 if (
$key == $this->data[
'selected.timeres']) {
76 echo
'<option selected="selected" value="' .
$key .
'">' . $timeresname .
'</option>';
78 echo
'<option value="' .
$key .
'">' . $timeresname .
'</option>';
81 echo
'</select></form>';
84 echo
'<td class="td_left">';
85 echo
'<form action="#">';
86 echo $this->data[
'post_time'];
87 echo
'<select onchange="submit();" name="time">';
88 foreach ($this->data[
'available.times'] as
$key => $timedescr) {
89 if (
$key == $this->data[
'selected.time']) {
90 echo
'<option selected="selected" value="' .
$key .
'">' . $timedescr .
'</option>';
92 echo
'<option value="' .
$key .
'">' . $timedescr .
'</option>';
95 echo
'</select></form>';
98 if (isset($this->data[
'available.times.next'])) {
99 echo
'<td class="td_right td_next_right"><a href="' . $this->data[
'get_times_next'] .
'">Next »</a></td>';
101 echo
'<td class="td_right selecttime_link_grey td_next_right">Next »</td>';
104 echo
'</tr></table>';
107 echo
'<div id="tabdiv"><ul class="tabset_tabs"> 108 <li><a href="#graph">Graph</a></li> 109 <li><a href="#table">Summary table</a></li> 110 <li><a href="#debug">Time serie</a></li> 114 <div id="graph" class="tabset_content">';
116 echo
'<img src="' . htmlspecialchars($this->data[
'imgurl']) .
'" alt="Graph" />';
118 echo
'<form action="#">';
119 echo
'<p class="p_right">Compare with total from this dataset ';
120 echo $this->data[
'post_rule2'];
121 echo
'<select onchange="submit();" name="rule2">';
122 echo
' <option value="_">None</option>';
123 foreach ($this->data[
'available.rules'] as
$key =>
$rule) {
124 if (
$key === $this->data[
'selected.rule2']) {
125 echo
'<option selected="selected" value="' .
$key .
'">' .
$rule[
'name'] .
'</option>';
127 echo
'<option value="' .
$key .
'">' .
$rule[
'name'] .
'</option>';
130 echo
'</select></p></form>';
139 echo
'<div id="table" class="tabset_content">';
141 if (isset($this->data[
'pieimgurl'])) {
142 echo
'<img src="' . $this->data[
'pieimgurl'] .
'" alt="Pie chart" />';
144 echo
'<table class="tableview"><tr><th class="value">Value</th><th class="category">Data range</th></tr>';
146 foreach ($this->data[
'summaryDataset'] as
$key => $value) {
150 if (array_key_exists(
$key, $this->data[
'delimiterPresentation'])) {
151 $keyName = $this->data[
'delimiterPresentation'][
$key];
155 echo
'<tr class="total ' . $clint .
'"><td class="value">' . $value .
'</td><td class="category">' . $keyName .
'</td></tr>';
157 echo
'<tr class="' . $clint .
'"><td class="value">' . $value .
'</td><td class="category">' . $keyName .
'</td></tr>';
161 echo
'</table></div>';
164 echo
'<div id="debug" >';
165 echo
'<table class="timeseries">';
166 echo
'<tr><th>Time</th><th>Total</th>';
167 foreach ($this->data[
'topdelimiters'] as
$key) {
169 if (array_key_exists($key, $this->data[
'delimiterPresentation'])) {
170 $keyName = $this->data[
'delimiterPresentation'][
$key];
172 echo
'<th>' . $keyName .
'</th>';
178 foreach ($this->data[
'debugdata'] as $slot => $dd) {
179 echo
'<tr class="' . ((++
$i % 2) == 0 ?
'odd' :
'even') .
'">';
180 echo
'<td>' . $dd[0] .
'</td>';
181 echo
'<td class="datacontent">' . $dd[1] .
'</td>';
183 foreach ($this->data[
'topdelimiters'] as $key) {
184 echo
'<td class="datacontent">' . (array_key_exists($key, $this->data[
'results'][$slot]) ?
185 $this->data[
'results'][$slot][
$key] :
' ') .
'</td>';
195 $this->includeAtTemplateBase(
'includes/footer.php');
$classint
Handle table view - - - - - -.
static getModuleURL($resource, array $parameters=array())
Get absolute URL to a specified module resource.
Create styles array
The data for the language used.