當前位置: 首頁>>代碼示例>>PHP>>正文


PHP CUtils::getTasksForThisPeriod方法代碼示例

本文整理匯總了PHP中CUtils::getTasksForThisPeriod方法的典型用法代碼示例。如果您正苦於以下問題:PHP CUtils::getTasksForThisPeriod方法的具體用法?PHP CUtils::getTasksForThisPeriod怎麽用?PHP CUtils::getTasksForThisPeriod使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在CUtils的用法示例。


在下文中一共展示了CUtils::getTasksForThisPeriod方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: foreach

echo $AppUI->_("Tasks");
?>
</th>
		<?php 
foreach ($timestampArray as $timestamp) {
    echo '<th nowrap="nowrap">' . $AppUI->_(date("l", $timestamp)) . ' ' . date("d/m/Y", $timestamp) . '</th>';
}
echo '<th nowrap="nowrap" width="100">' . $AppUI->_("Total") . '</th>';
?>
	</tr>
	
	<!-- Timesheet contents : Projects and tasks -->
	<?php 
//Get tasks list
$allAssignedTasks = CUtils::getAllAssignedTasks($user_id);
$rowTasks = CUtils::getTasksForThisPeriod($allAssignedTasks, min($timestampArray), max($timestampArray));
//There are avalaible tasks
if ($rowTasks) {
    $publicHolidays = CUtils::getPublicHolidays();
    $project_name = '';
    $newTaskIdList = array();
    //Display them
    while ($row = db_fetch_assoc($rowTasks)) {
        array_push($newTaskIdList, $row['task_id']);
        if ($timesheetId != 0 && $timesheet->getStatus($row['task_id']) != -1) {
            $status = $timesheet->getStatus($row['task_id']);
        }
        //Used to count total activities
        $task_total = 0;
        //Group tasks by project
        if ($project_name != $row['project_name']) {
開發者ID:kilivan,項目名稱:dotproject,代碼行數:31,代碼來源:capture_sub.php

示例2:

        $edate->addMonths(12);
        $edate->addDays(-1);
        $header .= " " . $time_set->format("%Y");
        break;
    case 'all':
        $header = $AppUI->_("All activities");
        break;
}
if (isset($sdate)) {
    $start_date = $sdate->getTime();
}
if (isset($edate)) {
    $end_date = $edate->getTime();
}
$rowTasks = CUtils::getTasksForThisPeriod($tasksId);
$rowTasks2 = CUtils::getTasksForThisPeriod($tasksId);
if ($rowTasks2) {
    $rowUsers = CUtils::getAllAssignedUsers($rowTasks2);
}
?>

<!-- Build activity view header -->
<table width="100%" class="motitle" cellspacing="0" cellpading="3" border="0">
<tr>
<?php 
//Show prev/next arrows for all but 'all' view
if ($vw != all) {
    $alt = $AppUI->_('Previous ' . $vw);
    $ago -= 1;
    echo '<td align="left">
		<a href="index.php?m=activity&amp;a=reporting&amp;vw=' . $vw . '&amp;ago=' . $ago . '" title="' . $alt . '">
開發者ID:kilivan,項目名稱:dotproject,代碼行數:31,代碼來源:reporting_sub.php


注:本文中的CUtils::getTasksForThisPeriod方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。