X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=WEB-INF%2Flib%2FttProjectHelper.class.php;h=06605c76a8a06f567a881e6b63d17dd0a6bdc633;hb=ae00c14ac2999773e17a761542932cb95420430a;hp=59f202232b640f98adff20ac6f053b55d09e50a8;hpb=993450e17195b87dc406c3135ee22dafe9b825fb;p=timetracker.git diff --git a/WEB-INF/lib/ttProjectHelper.class.php b/WEB-INF/lib/ttProjectHelper.class.php index 59f20223..06605c76 100644 --- a/WEB-INF/lib/ttProjectHelper.class.php +++ b/WEB-INF/lib/ttProjectHelper.class.php @@ -67,6 +67,7 @@ class ttProjectHelper { $res = $mdb2->query($sql); if (!is_a($res, 'PEAR_Error')) { while ($val = $res->fetchRow()) { + $val['rate'] = str_replace('.', $user->decimal_mark, $val['rate']); $result[] = $val; } } @@ -76,9 +77,9 @@ class ttProjectHelper { // getProjects - returns an array of active and inactive projects in a team. static function getProjects() { - global $user; - - $result = array(); + global $user; + + $result = array(); $mdb2 = getConnection(); $sql = "select id, name, tasks from tt_projects @@ -255,9 +256,9 @@ class ttProjectHelper { if(!in_array($row['user_id'], $users_to_bind)) { // Delete tt_user_project_binds record (safely). ttUserHelper::deleteBind($row['user_id'], $project_id); - } else if (!$row['status']) { + } elseif (!$row['status']) { // If we are here, status of the bind is not active. Memorize such users to update their bind status. - $users_to_update[] = $row['user_id']; // Users we need to update in tt_user_project_binds. + $users_to_update[] = $row['user_id']; // Users we need to update in tt_user_project_binds. } $all_users[] = $row['user_id']; // All users from tt_user_project_binds for project. }