X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/timetracker.git/blobdiff_plain/f0e54f23029d8b109c0ab554ab2b49195d204391..101cdfe54c97350fc65b140f3f27c5bdd466844e:/WEB-INF/lib/ttReportHelper.class.php
diff --git a/WEB-INF/lib/ttReportHelper.class.php b/WEB-INF/lib/ttReportHelper.class.php
index b5208bc7..bd882559 100644
--- a/WEB-INF/lib/ttReportHelper.class.php
+++ b/WEB-INF/lib/ttReportHelper.class.php
@@ -370,10 +370,10 @@ class ttReportHelper {
array_push($fields, 'ei.paid as paid');
// Add IP address. NULL for now for expenses.
if ($canViewReports && $bean->getAttribute('chip')) {
- array_push($fields, 'null as created');
- array_push($fields, 'null as created_ip');
- array_push($fields, 'null as modified');
- array_push($fields, 'null as modified_ip');
+ array_push($fields, 'ei.created as created');
+ array_push($fields, 'ei.created_ip as created_ip');
+ array_push($fields, 'ei.modified as modified');
+ array_push($fields, 'ei.modified_ip as modified_ip');
}
// Add invoice name if it is selected.
@@ -1254,6 +1254,8 @@ class ttReportHelper {
$body .= '
'.$i18n->getKey('label.cost').' | ';
if ($bean->getAttribute('chpaid'))
$body .= ''.$i18n->getKey('label.paid').' | ';
+ if ($bean->getAttribute('chip'))
+ $body .= ''.$i18n->getKey('label.ip').' | ';
if ($bean->getAttribute('chinvoice'))
$body .= ''.$i18n->getKey('label.invoice').' | ';
$body .= '';
@@ -1296,6 +1298,7 @@ class ttReportHelper {
$body .= '';
}
if ($bean->getAttribute('chpaid')) $body .= ' | ';
+ if ($bean->getAttribute('chip')) $body .= ' | ';
if ($bean->getAttribute('chinvoice')) $body .= ' | ';
$body .= '';
$body .= '| |
';
@@ -1333,6 +1336,11 @@ class ttReportHelper {
$body .= $record['paid'] == 1 ? $i18n->getKey('label.yes') : $i18n->getKey('label.no');
$body .= '';
}
+ if ($bean->getAttribute('chip')) {
+ $body .= '';
+ $body .= $record['modified'] ? $record['modified_ip'].' '.$record['modified'] : $record['created_ip'].' '.$record['created'];
+ $body .= ' | ';
+ }
if ($bean->getAttribute('chinvoice'))
$body .= ''.htmlspecialchars($record['invoice']).' | ';
$body .= '';
@@ -1363,6 +1371,7 @@ class ttReportHelper {
$body .= '';
}
if ($bean->getAttribute('chpaid')) $body .= ' | ';
+ if ($bean->getAttribute('chip')) $body .= ' | ';
if ($bean->getAttribute('chinvoice')) $body .= ' | ';
$body .= '';
}
@@ -1386,6 +1395,7 @@ class ttReportHelper {
$body .= '';
}
if ($bean->getAttribute('chpaid')) $body .= ' | ';
+ if ($bean->getAttribute('chip')) $body .= ' | ';
if ($bean->getAttribute('chinvoice')) $body .= ' | ';
$body .= '';