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


PHP task::getAllMyProjectTasks方法代码示例

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


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

示例1: elseif

    $template->assign("title", $title);
    $template->assign("redir", $redir);
    $template->assign("user", $user);
    $template->assign("project", $proj);
    $template->assign("members", $members);
    $template->display("deassignuserform.tpl");
} elseif ($action == "deassign") {
    if (!$userpermissions["projects"]["edit"]) {
        $errtxt = $langfile["nopermission"];
        $noperm = $langfile["accessdenied"];
        $template->assign("errortext", "{$errtxt}<br>{$noperm}");
        $template->display("error.tpl");
        die;
    }
    $task = new task();
    $tasks = $task->getAllMyProjectTasks($id, 100, $usr);
    if ($id > 0 and $assignto > 0) {
        if (!empty($tasks)) {
            foreach ($tasks as $mytask) {
                if ($task->deassign($mytask["ID"], $usr)) {
                    $task->assign($mytask["ID"], $assignto);
                }
            }
        }
    } else {
        if (!empty($tasks)) {
            foreach ($tasks as $mytask) {
                $task->del($mytask["ID"]);
            }
        }
    }
开发者ID:Setrino,项目名称:collabtive,代码行数:31,代码来源:manageproject.php

示例2: task

    }
}
if ($action == "rss-tasks") {
    $thetask = new task();
    $tit = $langfile["mytasks"];
    $rss->title = $tit;
    $rss->description = "";
    $rss->descriptionHtmlSyndicated = true;
    $loc = $url . "/manageproject.php?action=showproject&amp;id={$project}";
    $rss->link = $loc;
    $rss->syndicationURL = $loc;
    $project = new project();
    $myprojects = $project->getMyProjects($user);
    $tasks = array();
    foreach ($myprojects as $proj) {
        $task = $thetask->getAllMyProjectTasks($proj["ID"], 10000, $user);
        if (!empty($task)) {
            array_push($tasks, $task);
        }
    }
    $etasks = reduceArray($tasks);
    foreach ($etasks as $mytask) {
        $item = new FeedItem();
        $item->title = $mytask["title"];
        $loc = $url . "managetask.php?action=showtask&tid={$mytask['ID']}&id={$mytask['project']}";
        $item->link = $loc;
        $item->source = $loc;
        $item->description = $mytask["text"];
        // optional
        $item->descriptionTruncSize = 500;
        $item->descriptionHtmlSyndicated = true;
开发者ID:veganaize,项目名称:Collabtive,代码行数:31,代码来源:managerss.php

示例3: project

$project = new project();
$customer = new company();
$milestone = new milestone();
$mtask = new task();
$msg = new message();
// create arrays to hold data
$messages = array();
$milestones = array();
$tasks = array();
// create a counter for the foreach loop
$cou = 0;
// If user has projects, loop through them and get the messages and tasks belonging to those projects
if (!empty($myOpenProjects)) {
    foreach ($myOpenProjects as $proj) {
        // get all the tasks in this project that are assigned to the current user
        $task = $mtask->getAllMyProjectTasks($proj["ID"], 100);
        // get all messages in the project
        $msgs = $msg->getProjectMessages($proj["ID"]);
        // write those to arrays
        if (!empty($msgs)) {
            array_push($messages, $msgs);
        }
        if (!empty($task)) {
            array_push($tasks, $task);
        }
        $cou = $cou + 1;
    }
}
$myClosedProjects = $project->getMyProjects($userid, 0);
// If the user is allowed to add projects, also get all users to assign to those projects
if ($userpermissions["projects"]["add"]) {
开发者ID:veganaize,项目名称:Collabtive,代码行数:31,代码来源:index.php

示例4: header

            header("Location: admin.php?action=users&mode=deleted");
        }
    }
} elseif ($action == "deleteuser") {
    $id = getArrayVal($_POST, "id");
    $uprojects = getArrayVal($_POST, "uprojects");
    $proarr = array();
    foreach ($uprojects as $upro) {
        $dat = explode("#", $upro);
        $todo = array("project" => $dat[0], "user" => $dat[1]);
        array_push($proarr, $todo);
    }
    if (!empty($proarr)) {
        $task = new task();
        foreach ($proarr as $proj) {
            $tasks = $task->getAllMyProjectTasks($proj["project"], 100, $id);
            if ($proj["project"] > 0 and $proj["user"] > 0) {
                if (!empty($tasks)) {
                    foreach ($tasks as $mytask) {
                        if ($task->deassign($mytask["ID"], $id)) {
                            $task->assign($mytask["ID"], $proj["user"]);
                        }
                    }
                }
            } else {
                if (!empty($tasks)) {
                    foreach ($tasks as $mytask) {
                        $task->del($mytask["ID"]);
                    }
                }
            }
开发者ID:veganaize,项目名称:Collabtive,代码行数:31,代码来源:admin.php


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