本文整理汇总了PHP中CProject::canCreate方法的典型用法代码示例。如果您正苦于以下问题:PHP CProject::canCreate方法的具体用法?PHP CProject::canCreate怎么用?PHP CProject::canCreate使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CProject
的用法示例。
在下文中一共展示了CProject::canCreate方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: die
<?php
if (!defined('W2P_BASE_DIR')) {
die('You should not access this file directly.');
}
$tab = $AppUI->processIntState('ProjIdxTab', $_GET, 'tab', 5);
$project = new CProject();
$structprojs = $project->getProjects();
$search_string = w2PgetParam($_POST, 'search_string', '');
$AppUI->setState($m . '_search_string', $search_string);
$search_string = w2PformSafe($search_string, true);
$canCreate = $project->canCreate();
$company_id = w2PgetConfig('company_filter_default', 'user') == 'user' ? $AppUI->user_company : '-1';
$orderby = isset($_GET['orderby']) && property_exists('CProject', $_GET['orderby']) ? $_GET['orderby'] : 'project_name';
$project_type = $AppUI->processIntState('ProjIdxType', $_POST, 'project_type', -1);
$owner = $AppUI->processIntState('ProjIdxowner', $_POST, 'project_owner', -1);
$orderdir = $AppUI->getState('ProjIdxOrderDir') ? $AppUI->getState('ProjIdxOrderDir') : 'asc';
if (isset($_GET['orderby'])) {
if ($AppUI->getState('ProjIdxOrderDir') == 'asc') {
$orderdir = 'desc';
} else {
$orderdir = 'asc';
}
}
$AppUI->setState('ProjIdxOrderDir', $orderdir);
// collect the full projects list data via function in projects.class.php
$search_text = $search_string;
// @note this is only because the projects_list_data function takes a bunch of globals
//$projects = projects_list_data();
$oCompany = new CCompany();
$allowedCompanies[-1] = $AppUI->_('all');