当前位置: 首页>>代码示例>>PHP>>正文


PHP CTask::getAllocation方法代码示例

本文整理汇总了PHP中CTask::getAllocation方法的典型用法代码示例。如果您正苦于以下问题:PHP CTask::getAllocation方法的具体用法?PHP CTask::getAllocation怎么用?PHP CTask::getAllocation使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在CTask的用法示例。


在下文中一共展示了CTask::getAllocation方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: count

    $q->addWhere('task_id <> task_parent');
    $row['children'] = $q->loadResult();
    $row['style'] = taskstyle_pd($row);
    $i = count($projects[$row['task_project']]['tasks']) + 1;
    $row['task_number'] = $i;
    $row['node_id'] = 'node_' . $i . '-' . $row['task_id'];
    if (strpos($row['task_duration'], '.') && $row['task_duration_type'] == 1) {
        $row['task_duration'] = floor($row['task_duration']) . ':' . round(60 * ($row['task_duration'] - floor($row['task_duration'])));
    }
    //pull the final task row into array
    $projects[$row['task_project']]['tasks'][] = $row;
}
$showEditCheckbox = isset($canEditTasks) && $canEditTasks || $perms->checkModule('admin', 'view');
$durnTypes = w2PgetSysVal('TaskDurationType');
$tempoTask = new CTask();
$userAlloc = $tempoTask->getAllocation('user_id');
?>
<table width="100%" border="0" cellpadding="1" cellspacing="3" class="prjprint">
<tr class="prjprint">
        <th width="50%"><?php 
echo $AppUI->_('Task Name');
?>
</th>
        <th width="50" nowrap="nowrap"><?php 
echo $AppUI->_('Work');
?>
</th>
        <th nowrap="nowrap"><?php 
echo $AppUI->_('Start');
?>
</th>
开发者ID:joly,项目名称:web2project,代码行数:31,代码来源:vw_projecttask.php

示例2: CTask

    $cols--;
}
if ($showEditCheckbox) {
    echo '<th width="1">&nbsp;</th>';
} else {
    $cols--;
}
?>
	</tr>
	<?php 
reset($projects);
if ($w2Pconfig['direct_edit_assignment']) {
    // get Users with all Allocation info (e.g. their freeCapacity)
    // but do it only when direct_edit_assignment is on and only once.
    $tempoTask = new CTask();
    $userAlloc = $tempoTask->getAllocation('user_id', null, true);
}
foreach ($projects as $k => $p) {
    $tnums = isset($p['tasks']) ? count($p['tasks']) : 0;
    if ($tnums > 0 || $project_id == $p['project_id']) {
        //echo '<pre>'; print_r($p); echo '</pre>';
        if (!$min_view) {
            // not minimal view
            $open_link = w2PtoolTip($m, 'Click to Expand/Collapse the Tasks for this Project.') . '<a href="javascript: void(0);"><img onclick="expand_collapse(\'project_' . $p['project_id'] . '_\', \'tblProjects\',\'collapse\',0,2);" id="project_' . $p['project_id'] . '__collapse" src="' . w2PfindImage('up22.png', $m) . '" border="0" width="22" height="22" align="center" ' . (!$expanded ? 'style="display:none"' : '') . ' alt="" /><img onclick="expand_collapse(\'project_' . $p['project_id'] . '_\', \'tblProjects\',\'expand\',0,2);" id="project_' . $p['project_id'] . '__expand" src="' . w2PfindImage('down22.png', $m) . '" border="0" width="22" height="22" align="center" ' . ($expanded ? 'style="display:none"' : '') . ' alt="" /></a>' . w2PendTip();
            ?>
					<tr>
					  <td>
							<form name="assFrm<?php 
            echo $p['project_id'];
            ?>
" action="index.php?m=<?php 
开发者ID:eureka2,项目名称:web2project,代码行数:31,代码来源:tasks.php

示例3: CTask

	</td>
	<td align="left" nowrap="nowrap">
		<input class="button" type="submit" name="do_report" value="<?php 
echo $AppUI->_('submit');
?>
" />
	</td>
</tr>
</table>
</form>
<?php 
echo $AppUI->_('P') . '&nbsp;=&nbsp;' . $AppUI->_('User specific Task Priority');
if ($do_report) {
    // get Users with all Allocation info (e.g. their freeCapacity)
    $tempoTask = new CTask();
    $userAlloc = $tempoTask->getAllocation("user_id");
    // Let's figure out which users we have
    $sql = new DBQuery();
    $sql->addTable('users');
    $sql->addQuery('user_id, user_username');
    if ($log_userfilter != 0) {
        $sql->addWhere('user_id = ' . $log_userfilter);
    }
    $sql->addOrder('user_username');
    $user_list = $sql->loadHashList('user_id');
    $sql->clear();
    $ss = $start_date->format(FMT_DATETIME_MYSQL);
    $se = $end_date->format(FMT_DATETIME_MYSQL);
    $sql->addTable('tasks', 't');
    $sql->innerJoin('projects', 'p', 'p.project_id = t.task_project');
    if ($log_userfilter != 0) {
开发者ID:srinivasulurao,项目名称:jonel,代码行数:31,代码来源:tasksperuser_sub.php


注:本文中的CTask::getAllocation方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。