summaryrefslogtreecommitdiff
path: root/httemplate/elements
diff options
context:
space:
mode:
Diffstat (limited to 'httemplate/elements')
-rw-r--r--httemplate/elements/menu.html1
-rw-r--r--httemplate/elements/select-otaker.html27
-rw-r--r--httemplate/elements/tr-select-otaker.html10
3 files changed, 38 insertions, 0 deletions
diff --git a/httemplate/elements/menu.html b/httemplate/elements/menu.html
index da8f58054..b40b01986 100644
--- a/httemplate/elements/menu.html
+++ b/httemplate/elements/menu.html
@@ -162,6 +162,7 @@ $report_packages{'Advanced package reports'} = [ $fsurl.'search/report_cust_pkg
tie my %report_rating, 'Tie::IxHash',
'RADIUS sessions' => [ $fsurl.'search/sqlradius.html', '' ],
'Call Detail Records (CDRs)' => [ $fsurl.'search/report_cdr.html', '' ],
+ 'Time worked' => [ $fsurl.'search/report_rt_transaction.html', '' ],
;
tie my %report_bill_event, 'Tie::IxHash',
diff --git a/httemplate/elements/select-otaker.html b/httemplate/elements/select-otaker.html
new file mode 100644
index 000000000..2a689f39d
--- /dev/null
+++ b/httemplate/elements/select-otaker.html
@@ -0,0 +1,27 @@
+<SELECT NAME="otaker">
+
+% unless ( $opt{'multiple'} || $opt{'disable_empty'} ) {
+ <OPTION VALUE="">all</OPTION>
+% }
+
+% foreach my $otaker ( @{ $opt{'otakers'} } ) {
+ <OPTION VALUE="<% $otaker %>"><% $otaker %></OPTION>
+% }
+
+</SELECT>
+
+<%init>
+
+my %opt = @_;
+
+unless ( $opt{'otakers'} ) {
+
+ my $sth = dbh->prepare("SELECT username FROM access_user".
+ " WHERE disabled = '' or disabled IS NULL")
+ or die dbh->errstr;
+ $sth->execute or die $sth->errstr;
+ $opt{'otakers'} = [ map { $_->[0] } @{$sth->fetchall_arrayref} ];
+
+}
+
+</%init>
diff --git a/httemplate/elements/tr-select-otaker.html b/httemplate/elements/tr-select-otaker.html
new file mode 100644
index 000000000..edf62dceb
--- /dev/null
+++ b/httemplate/elements/tr-select-otaker.html
@@ -0,0 +1,10 @@
+<TR>
+ <TD ALIGN="right"><% $opt{'label'} || 'Employee: ' %></TD>
+ <TD><% include('select-otaker.html', %opt) %></TD>
+</TR>
+
+<%init>
+
+my %opt = @_;
+
+</%init>