示例#1
0
/**
 * Implements the {atkmoduledir} plugin for use in templates.
 *
 * The atkmoduledir plugin return module path
 * Useful for including custom templates  into other teplate.
 *
 * Params:
 * modulename   module name
 *
 * Example:
 * {atkmoduledir modulename="project"}
 *
 * @author Yury Golovnya <*****@*****.**>
 *
 */
function smarty_function_atkmoduledir($params, &$smarty)
{
    return $smarty->assign("atkmoduledir", moduleDir($params['modulename']));
}
示例#2
0
/**
 * Module Resource planning
 * Ganttchart resource planning
 *
 * This file generates the ganttchart. .
 *
 * @author Ludo M. Beumer  <*****@*****.**>
 * @version $Revision$
 *
 * $Id$
 */
chdir("../..");
$config_atkroot = "./";
include_once $config_atkroot . "atk.inc";
include_once moduleDir("graph") . "jpgraph/jpgraph.php";
include_once moduleDir("graph") . "jpgraph/jpgraph_gantt.php";
include_once atkconfig("atkroot") . "atk/utils/adodb-time.inc.php";
atkimport("module.utils.dateutil");
include_once "achievotools.inc";
atksession();
atksecure();
global $g_securityManager;
if ($g_securityManager->allowed("project.project", "any_project")) {
    $coordinator = $_REQUEST["coordinator"];
} else {
    $user = getUser();
    $coordinator = $user["id"];
}
function dashDate($undasheddate)
{
    return substr($undasheddate, 0, 4) . "-" . substr($undasheddate, 4, 2) . "-" . substr($undasheddate, 6, 2);