employeehours report

This commit is contained in:
2018-02-21 21:27:23 +01:00
parent 4fbcc6a52a
commit 327f81ea97
3290 changed files with 17984 additions and 747234 deletions
@@ -35,4 +35,13 @@ class Projectcost extends BaseModel {
return $projectID;
}
public static function getCostsPerPerProject( $projectID )
{
$projectCosts = Projectcost::selectraw( 'ROUND(COALESCE(SUM(costs), 0), 0) AS costs')
->whereProjectId($projectID)
->first();
return $projectCosts->costs;
}
}