X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fsearch%2Ftimeworked.html;h=d07cd4f591b7d8f82f3d15547bdf7ab9ec2df042;hb=e168ca3db2702bd9a540316cd9bd840238dd19ce;hp=b72dd0ea998040f31654e57947177f740763ee37;hpb=5e05724a635a22776f1b973f5d7e77989da4e048;p=freeside.git diff --git a/httemplate/search/timeworked.html b/httemplate/search/timeworked.html index b72dd0ea9..d07cd4f59 100644 --- a/httemplate/search/timeworked.html +++ b/httemplate/search/timeworked.html @@ -32,19 +32,7 @@ '', '', ], - 'html_foot' => sub { - '
'. - ''. - '

'. - ''; - }, + 'html_foot' => $html_foot, ) %> @@ -62,7 +50,7 @@ my $transactiontime = " END "; -push @groupby, qw( transactions.type newvalue oldvalue timetaken ); +push @groupby, qw( Transactions.Type NewValue OldValue TimeTaken ); my $appliedtimeclause = "COALESCE (SUM(acct_rt_transaction.seconds), 0)"; @@ -96,6 +84,13 @@ my $where = " "; #AND $wheretimeleft +my $str2time_sql = str2time_sql; +my $closing = str2time_sql_closing; + +my($begin, $end) = FS::UI::Web::parse_beginning_ending($cgi); +$where .= " AND $str2time_sql Transactions.Created $closing >= $begin ". + " AND $str2time_sql Transactions.Created $closing <= $end "; + my $query = " SELECT Tickets.id, Tickets.Subject, TO_CHAR(Transactions.Created, 'Dy Mon DD HH24:MI:SS YYYY'), @@ -114,4 +109,22 @@ my $count_query = "SELECT COUNT(*) FROM Transactions $where"; my $link = [ "${p}rt/Ticket/Display.html?id=", sub { shift->[0]; } ]; +my $html_foot = qq' + + +
+ + +
+
+ +'; +