本文整理汇总了PHP中Stats::getCategory方法的典型用法代码示例。如果您正苦于以下问题:PHP Stats::getCategory方法的具体用法?PHP Stats::getCategory怎么用?PHP Stats::getCategory使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Stats
的用法示例。
在下文中一共展示了Stats::getCategory方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: array
}
$tpl->assign('hide_closed', $hide_closed);
if ($role_id == User::getRoleID('customer')) {
$crm = CRM::getInstance($prj_id);
// need the activity dashboard here
$contact_id = User::getCustomerContactID($usr_id);
$customer_id = Auth::getCurrentCustomerID();
$tpl->assign(array('contact' => $crm->getContact($contact_id), 'customer' => $crm->getCustomer($customer_id)));
} else {
if (Auth::getCurrentRole() <= User::getRoleID('Reporter') && Project::getSegregateReporters($prj_id)) {
$tpl->assign('hide_stats', true);
} else {
$tpl->assign('hide_stats', false);
$tpl->assign('status', Stats::getStatus());
$tpl->assign('releases', Stats::getRelease($hide_closed));
$tpl->assign('categories', Stats::getCategory($hide_closed));
$tpl->assign('priorities', Stats::getPriority($hide_closed));
$tpl->assign('users', Stats::getUser($hide_closed));
$tpl->assign('emails', Stats::getEmailStatus($hide_closed));
$tpl->assign('pie_chart', Stats::getPieChart($hide_closed));
}
}
if (@$_REQUEST['hide_closed'] == '') {
$Stats_Search_Profile = Search_Profile::getProfile($usr_id, $prj_id, 'stats');
if (!empty($Stats_Search_Profile)) {
$tpl->assign('hide_closed', $Stats_Search_Profile['hide_closed']);
}
} else {
$tpl->assign('hide_closed', @$_REQUEST['hide_closed']);
Search_Profile::save($usr_id, $prj_id, 'stats', array('hide_closed' => @$_REQUEST['hide_closed']));
}
示例2: Template_API
include_once APP_INC_PATH . "class.auth.php";
include_once APP_INC_PATH . "class.user.php";
include_once APP_INC_PATH . "class.stats.php";
include_once APP_INC_PATH . "class.misc.php";
include_once APP_INC_PATH . "class.news.php";
include_once APP_INC_PATH . "db_access.php";
$tpl = new Template_API();
$tpl->setTemplate("main.tpl.html");
Auth::checkAuthentication(APP_COOKIE);
$prj_id = Auth::getCurrentProject();
$role_id = Auth::getCurrentRole();
if ($role_id == User::getRoleID('customer')) {
// need the activity dashboard here
$usr_id = Auth::getUserID();
$customer_id = User::getCustomerID($usr_id);
$tpl->assign("customer_stats", Customer::getOverallStats($prj_id, $customer_id));
$tpl->assign("profile", Customer::getProfile($prj_id, $usr_id));
} else {
$tpl->assign("status", Stats::getStatus());
$tpl->assign("releases", Stats::getRelease());
$tpl->assign("categories", Stats::getCategory());
$tpl->assign("priorities", Stats::getPriority());
$tpl->assign("users", Stats::getUser());
$tpl->assign("emails", Stats::getEmailStatus());
$tpl->assign("pie_chart", Stats::getPieChart());
if ($_GET['tips']) {
$tpl->assign("random_tip", Misc::getRandomTip($tpl));
}
}
$tpl->assign("news", News::getListByProject($prj_id));
$tpl->displayTemplate();