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


PHP VTTaskManager::getTasks方法代码示例

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


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

示例1: vtDisplayTaskList

function vtDisplayTaskList($adb, $requestUrl, $current_language)
{
    global $theme, $app_strings;
    $image_path = "themes/{$theme}/images/";
    $util = new VTWorkflowUtils();
    $module = new VTWorkflowApplication("tasklist");
    $mod = return_module_language($current_language, $module->name);
    if (!$util->checkAdminAccess()) {
        $errorUrl = $module->errorPageUrl($mod['LBL_ERROR_NOT_ADMIN']);
        $util->redirectTo($errorUrl, $mod['LBL_ERROR_NOT_ADMIN']);
        return;
    }
    $smarty = new vtigerCRM_Smarty();
    $tm = new VTTaskManager($adb);
    $smarty->assign("tasks", $tm->getTasks());
    $smarty->assign("moduleNames", array("Contacts", "Applications"));
    $smarty->assign("taskTypes", array("VTEmailTask", "VTDummyTask"));
    $smarty->assign("returnUrl", $requestUrl);
    $smarty->assign("MOD", return_module_language($current_language, 'Settings'));
    $smarty->assign("APP", $app_strings);
    $smarty->assign("THEME", $theme);
    $smarty->assign("IMAGE_PATH", $image_path);
    $smarty->assign("MODULE_NAME", $module->label);
    $smarty->assign("PAGE_NAME", 'Task List');
    $smarty->assign("PAGE_TITLE", 'List available tasks');
    $smarty->assign("moduleName", $moduleName);
    $smarty->display("{$module->name}/ListTasks.tpl");
}
开发者ID:sacredwebsite,项目名称:vtigercrm,代码行数:28,代码来源:tasklist.php

示例2: getActiveCount

 /**
  * Function to get the count of active workflows
  * @return <Integer> count of acive workflows
  */
 public static function getActiveCount()
 {
     $db = PearDatabase::getInstance();
     vimport('~~/modules/com_vtiger_workflow/VTTaskManager.inc');
     $taskManager = new VTTaskManager($db);
     $taskList = $taskManager->getTasks();
     $examinedIdList = array();
     foreach ($taskList as $taskDetails) {
         $workFlowId = $taskDetails->workflowId;
         if (in_array($workFlowId, $examinedIdList)) {
             continue;
         }
         if ($taskDetails->active) {
             array_push($examinedIdList, $workFlowId);
         }
     }
     return count($examinedIdList);
 }
开发者ID:artisan4710,项目名称:YetiForceCRM,代码行数:22,代码来源:Record.php


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