function ShowBillComms($bill_id, $uid = 0, $mode = 1) { global $session; session_start(); $objResponse = new xajaxResponse(); if ($uid && !hasPermissions('payments')) { return $objResponse; } elseif (!$uid) { $uid = $_SESSION['uid']; } $account = new account(); if ($account->checkOperationOwner((int) $bill_id, (int) $uid)) { $info = $account->GetHistoryInfo($bill_id, $uid, $mode); } if (isset($info) && $info) { $objResponse->assign("bil" . $bill_id, "innerHTML", ($mode == 2 ? '<br/>' : '') . $info); } return $objResponse; }
/* switch ($opinfo['op_code']){ case 16: $pr_txt = "Аккаунт ПРО"; break; case 17: $pr_txt = "Первая страница – 1 неделя"; break; case 18: $pr_txt = "Первая страница – 1 месяц"; break; case 23: $pr_txt = $opinfo['ammount']." FM"; break; case 26: $pr_txt = "Аккаунт ПРО"; break; case 27: $pr_txt = "Первая страница – 1 неделя"; break; case 34: $pr_txt = "Первая страница – новогодний подарок – 1 неделя"; break; case 35: $pr_txt = "Аккаунт ПРО – новогодний подарок"; break; case 42: $pr_txt = "Аккаунт ПРО – подарок на 8 марта"; break; default: $pr_txt = ""; } */ if ($pr_txt && $opinfo['billing_id'] == $acc->id) { $info = $acc->GetHistoryInfo($opinfo['id'], $_SESSION['uid'], 3); $user = new users(); $user->GetUser($opinfo['login']); $cnt_role = !is_emp($user->role) ? 'frl' : 'emp'; present::SetGiftResv($id, $_SESSION['uid']); require_once $_SERVER['DOCUMENT_ROOT'] . '/classes/payed.php'; $is_pro = payed::CheckPro($user->login); $_SESSION['pro_last'] = payed::ProLast($_SESSION['login']); $_SESSION['pro_last'] = $_SESSION['pro_last']['freeze_to'] ? false : $_SESSION['pro_last']['cnt']; } } if (!$user) { header('Location: /404.php'); exit; } $css_file[] = '/css/styles/present.css';