本文整理汇总了PHP中sbr_meta::getUserRatings方法的典型用法代码示例。如果您正苦于以下问题:PHP sbr_meta::getUserRatings方法的具体用法?PHP sbr_meta::getUserRatings怎么用?PHP sbr_meta::getUserRatings使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类sbr_meta
的用法示例。
在下文中一共展示了sbr_meta::getUserRatings方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: GetMoreSBR
function GetMoreSBR($uid, $i)
{
session_start();
$objResponse = new xajaxResponse();
$html = '';
$user = new users();
$user->GetUserByUID($uid);
require_once $_SERVER['DOCUMENT_ROOT'] . '/classes/sbr.php';
$MONTHA = $GLOBALS['MONTHA'];
if ($i > 5 || $i <= 0) {
$i = 5;
}
$sbr_ratings = sbr_meta::getUserRatings($user->uid, is_emp($user->role), 'ALL', 5);
ob_start();
include $_SERVER['DOCUMENT_ROOT'] . '/user/tpl.rating-sbr.php';
$html = ob_get_contents();
ob_end_clean();
$objResponse->assign('more_sbr_content', 'innerHTML', $html);
return $objResponse;
}
示例2: rating
}
require_once $_SERVER['DOCUMENT_ROOT'] . "/xajax/rating.common.php";
$xajax->printJavascript('/xajax/');
require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/rating.php";
require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/projects_offers.php";
require_once $_SERVER['DOCUMENT_ROOT'] . "/classes/sbr.php";
if (!$rating || !$rating instanceof rating || $rating->data['user_id'] != $user->uid) {
$rating = new rating($user->uid, $user->is_pro, $user->is_verify, $user->is_profi);
}
$r_data = $rating->data;
$r_data['kis'] = projects_offers::GetFrlOffersSummary($r_data['user_id']);
$r_data['kis']['refused_3'] = (int) $r_data['kis']['refused'] - (int) $r_data['kis']['refused_1'] - (int) $r_data['kis']['refused_0'] - (int) $r_data['kis']['refused_2'] - (int) $r_data['kis']['refused_4'];
if (!$r_data['max']) {
$r_data['max'] = $rating->get_max_of('total', false);
}
$sbr_ratings = sbr_meta::getUserRatings($user->uid, is_emp($user->role), 5, 0, $sbr_info['success_cnt']);
//$sbr_info['success_cnt'] = sbr_meta::getCountSuccessRatingSbr($user->uid, is_emp($user->role));
if (!($prjs = projects_offers::GetFrlOffers($r_data['user_id'], 'marked', NULL))) {
$prjs = array();
}
$kis_per_refused = round($r_data['kis']['total'] ? 100 * $r_data['kis']['refused'] / $r_data['kis']['total'] : 0, 2);
$kis_per_frl_refused = round($r_data['kis']['total'] ? 100 * $r_data['kis']['frl_refused'] / $r_data['kis']['total'] : 0, 2);
$kis_per_selected = round($r_data['kis']['total'] ? 100 * $r_data['kis']['selected'] / $r_data['kis']['total'] : 0, 2);
$kis_per_executor = round($r_data['kis']['total'] ? 100 * $r_data['kis']['executor'] / $r_data['kis']['total'] : 0, 2);
$kis_unknown = (int) $r_data['kis']['total'] - ((int) $r_data['kis']['refused'] + (int) $r_data['kis']['selected'] + (int) $r_data['kis']['executor']) - (int) $r_data['kis']['frl_refused'];
$kis_per_unknown = 100 - ($kis_per_refused + $kis_per_selected + $kis_per_executor + $kis_per_frl_refused);
$o_contest_rating = round($r_data['o_contest_1'] + $r_data['o_contest_2'] + $r_data['o_contest_3']);
$o_contest_ban_rating = round($r_data['o_contest_ban']);
$is_owner = $user->uid == $_SESSION['uid'];
?>