RTx-Statistics in 2.1 / 3.8, RT#10046
authorivan <ivan>
Sun, 5 Dec 2010 02:59:38 +0000 (02:59 +0000)
committerivan <ivan>
Sun, 5 Dec 2010 02:59:38 +0000 (02:59 +0000)
rt/share/html/RTx/Statistics/CallsMultiQueue/index.html
rt/share/html/RTx/Statistics/CallsQueueDay/index.html
rt/share/html/RTx/Statistics/DayOfWeek/index.html
rt/share/html/RTx/Statistics/OpenStalled/index.html
rt/share/html/RTx/Statistics/Resolution/index.html
rt/share/html/RTx/Statistics/TimeToResolve/index.html

index abf8aa7..1b7a659 100755 (executable)
@@ -99,11 +99,6 @@ The line chart below shows the same information in a graphical form.
 </table>
 <& /Elements/TitleBoxEnd&>
 
-<hr>
-
-<BR />
-<BR />
-
 <!--    <td>Show:</td>
     <td COLSPAN=2><SELECT NAME="status">
 % for (qw(resolved new deleted stalled rejected open)) {
index 06fc484..5a4fe52 100755 (executable)
@@ -81,11 +81,6 @@ for a spreadsheet, use this <a href="<%$RT::WebPath%>/RTx/Statistics/CallsQueueD
 </table>
 </&>
 
-<hr>
-
-<BR />
-<BR />
-
 <%perl>
 # Create the graph URL
 my $url= 'Elements/Chart?x_labels=';
index 2e82b9c..6353abb 100755 (executable)
@@ -46,11 +46,6 @@ selected queue for each day. It also hows how many of those created tickets were
 </table>
 </&>
 
-<hr>
-
-<BR />
-<BR />
-
 <%perl>
 my $url = 'Elements/Chart?&x_labels=';
 for (0..$#days) {
index d0cd9f1..4a1badb 100755 (executable)
@@ -65,11 +65,6 @@ viewed once (Open) and how many have had their status changed to stalled.</p>
 </table>
 <& /Elements/TitleBoxEnd&>
 
-<hr>
-
-<BR />
-<BR />
-
 % use Data::Dumper;
 % Statistics::DebugLog("Dump of data array is " . Dumper(@data) . "\n");
 %  my $url = 'Elements/Chart?x_labels=';
index d9885b0..838d273 100644 (file)
@@ -72,11 +72,6 @@ resolve.</p>
 </table>
 </&>
 
-<hr>
-
-<BR />
-<BR />
-
 <%perl>
 # Create the graph URL
 
index 2124b53..ad3e23a 100755 (executable)
@@ -5,19 +5,9 @@
 <p>This page displays the same information as the Time to Resolve chart, but in a scattergraph format and only for the previous 7 calendar
 days. It only displays data for tickets which have been resolved. Each division on the Days axis is one day and the granularity of this chart
 is 30 minutes.</p>
-<form method="POST">
 
-<table>
-  <tr>
-  <td>Show Queue:</td>
-  <td COLSPAN=3><& /Elements/SelectQueue, Name=>"queue", Default=>$queue ,ShowNullOption=>0, 
-            CheckQueueRight=>'SeeQueue' &></td>
-  </tr>
-</table>
-<INPUT TYPE="submit" VALUE="Update Page"</INPUT>
-</form>
+<form method="POST">
 
-<BR>
 % my $url = 'Elements/Chart?x_labels=';
 % my $i;
 % $url .= join ",", (map {(int($_/2) == $_/2 && (++$i)%2) ? $_/2 : ""} grep {$counts[$_]} 0..($#counts-1)), "longer";
@@ -25,14 +15,19 @@ is 30 minutes.</p>
 % $url .= "marker_size=1&";
 % $url .= "data1=".(join ",", map { $_ || () } @counts)."&";
 % chop $url;
-<IMG SRC="<% $url %>">
+<& /RTx/Statistics/Elements/GraphBox, GraphURL => $url &>
 
-<BR>
+<& /RTx/Statistics/Elements/ControlsAsTable/ControlBox, 
+        Title => "Change Queue",
+        ShowSingleQueue => 1, Queue=>$Queue,
+&>
+
+</form>
 
 %Statistics::DebugInit($m);
 
 <%ARGS>
-$queue => undef
+$Queue => undef
 </%ARGS>
 
 <%INIT>
@@ -51,16 +46,16 @@ for my $key (keys %ARGS) {
 }
 
 my $QueueObj = new RT::Queue($session{'CurrentUser'});
-if (!defined $queue) {
-  $QueueObj->Load($Statistics::TimeToResolveGraphQueue);
-  $queue = $QueueObj->Id();
-} else {
-  $QueueObj->Load($queue);
-}
+#if (!defined $queue) {
+#  $QueueObj->Load($Statistics::TimeToResolveGraphQueue);
+#  $queue = $QueueObj->Id();
+#} else {
+  $QueueObj->Load($Queue);
+#}
 
 
 my $tix = new RT::Tickets($session{'CurrentUser'});
-$tix->LimitQueue (VALUE => $queue) if $queue;
+$tix->LimitQueue (VALUE => $Queue) if $Queue;
 $tix->LimitStatus(VALUE => "resolved");
 $tix->UnLimit;
 if ($tix->Count) {