projects
/
timetracker.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Optimized a bit more for uncompleted indicators option.
[timetracker.git]
/
WEB-INF
/
lib
/
ttFavReportHelper.class.php
diff --git
a/WEB-INF/lib/ttFavReportHelper.class.php
b/WEB-INF/lib/ttFavReportHelper.class.php
index
ab9fa0e
..
36600e2
100644
(file)
--- a/
WEB-INF/lib/ttFavReportHelper.class.php
+++ b/
WEB-INF/lib/ttFavReportHelper.class.php
@@
-80,7
+80,7
@@
class ttFavReportHelper {
global $user;
$mdb2 = getConnection();
global $user;
$mdb2 = getConnection();
- $group_id = $user->get
Active
Group();
+ $group_id = $user->getGroup();
$org_id = $user->org_id;
$sql = "insert into tt_fav_reports".
$org_id = $user->org_id;
$sql = "insert into tt_fav_reports".
@@
-107,13
+107,8
@@
class ttFavReportHelper {
if (is_a($affected, 'PEAR_Error'))
return false;
if (is_a($affected, 'PEAR_Error'))
return false;
- $sql = "select last_insert_id() as last_id";
- $res = $mdb2->query($sql);
- if (is_a($res, 'PEAR_Error'))
- return false;
-
- $val = $res->fetchRow();
- return $val['last_id'];
+ $last_id = $mdb2->lastInsertID('tt_fav_reports', 'id');
+ return $last_id;
}
// updateReport - updates report options in the database.
}
// updateReport - updates report options in the database.