本文整理汇总了PHP中GetAuthorizationLevel函数的典型用法代码示例。如果您正苦于以下问题:PHP GetAuthorizationLevel函数的具体用法?PHP GetAuthorizationLevel怎么用?PHP GetAuthorizationLevel使用的例子?那么, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了GetAuthorizationLevel函数的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: DataConnector
include_once "../DataTransferObjects/ContractBonusDTO.php";
include_once "../DataAccessObjects/ContractBonusDAO.php";
include_once "../DataTransferObjects/CounterDTO.php";
include_once "../DataAccessObjects/CounterDAO.php";
$subContractId = 0;
if (isset($_REQUEST["subContractId"]) && $_REQUEST["subContractId"] != 0) {
$subContractId = $_REQUEST["subContractId"];
}
// Abre a conexao com o banco de dados
$dataConnector = new DataConnector('mySql');
$dataConnector->OpenConnection();
if ($dataConnector->mysqlConnection == null) {
echo 'Não foi possível se connectar ao bando de dados!';
exit;
}
$nivelAutorizacao = GetAuthorizationLevel($dataConnector->mysqlConnection, $functionalities["gerenciamentoContratos"]);
if ($nivelAutorizacao <= 1) {
DisplayNotAuthorizedWarning();
exit;
}
// Cria os objetos de mapeamento objeto-relacional
$contractBonusDAO = new ContractBonusDAO($dataConnector->mysqlConnection);
$contractBonusDAO->showErrors = 1;
$counterDAO = new CounterDAO($dataConnector->mysqlConnection);
$counterDAO->showErrors = 1;
// Busca os bonus associados ao subContrato
$bonusArray = $contractBonusDAO->RetrieveRecordArray("subcontrato_id = " . $subContractId . " ORDER BY de, ate");
if (sizeof($bonusArray) == 0) {
echo '<tr><td colspan="5" align="center" >Nenhum registro encontrado!</td></tr>';
}
foreach ($bonusArray as $contractBonus) {
示例2: DataConnector
include_once "../../check.php";
include_once "../../defines.php";
include_once "../../ClassLibrary/Text.php";
include_once "../../ClassLibrary/DataConnector.php";
include_once "../../DataAccessObjects/MailingDAO.php";
include_once "../../DataTransferObjects/MailingDTO.php";
include_once "../../DataAccessObjects/BusinessPartnerDAO.php";
include_once "../../DataTransferObjects/BusinessPartnerDTO.php";
// Abre a conexao com o banco de dados
$dataConnector = new DataConnector('both');
$dataConnector->OpenConnection();
if ($dataConnector->mysqlConnection == null || $dataConnector->sqlserverConnection == null) {
echo 'Não foi possível se connectar ao bando de dados!';
exit;
}
$nivelAutorizacao = GetAuthorizationLevel($dataConnector->mysqlConnection, $functionalities["envioFaturamento"]);
if ($nivelAutorizacao <= 1) {
DisplayNotAuthorizedWarning();
exit;
}
// Cria o objeto de mapeamento objeto-relacional
$mailingDAO = new MailingDAO($dataConnector->mysqlConnection);
$mailingDAO->showErrors = 1;
$id = 0;
$mailing = new MailingDTO();
if (isset($_REQUEST["id"]) && $_REQUEST["id"] != 0) {
$id = $_REQUEST["id"];
$mailing = $mailingDAO->RetrieveRecord($id);
}
?>
示例3: session_start
<?php
session_start();
include_once "../../check.php";
include_once "../../defines.php";
include_once "../../ClassLibrary/DataConnector.php";
include_once "../../DataAccessObjects/SmtpServerDAO.php";
include_once "../../DataTransferObjects/SmtpServerDTO.php";
// Abre a conexao com o banco de dados
$dataConnector = new DataConnector('mySql');
$dataConnector->OpenConnection();
if ($dataConnector->mysqlConnection == null) {
echo 'Não foi possível se connectar ao bando de dados!';
exit;
}
$nivelAutorizacao = GetAuthorizationLevel($dataConnector->mysqlConnection, $functionalities["administracaoSistema"]);
if ($nivelAutorizacao <= 1) {
DisplayNotAuthorizedWarning();
exit;
}
// Cria o objeto de mapeamento objeto-relacional
$smtpServerDAO = new SmtpServerDAO($dataConnector->mysqlConnection);
$smtpServerDAO->showErrors = 1;
$id = 0;
$smtpServer = new SmtpServerDTO();
if (isset($_REQUEST["id"]) && $_REQUEST["id"] != 0) {
$id = $_REQUEST["id"];
$smtpServer = $smtpServerDAO->RetrieveRecord($id);
}
?>
示例4: DataConnector
$supplyRequestId = 0;
if (isset($_REQUEST["supplyRequestId"]) && $_REQUEST["supplyRequestId"] != 0) {
$supplyRequestId = $_REQUEST["supplyRequestId"];
}
$partRequestId = 0;
if (isset($_REQUEST["partRequestId"]) && $_REQUEST["partRequestId"] != 0) {
$partRequestId = $_REQUEST["partRequestId"];
}
// Abre a conexao com o banco de dados
$dataConnector = new DataConnector('both');
$dataConnector->OpenConnection();
if ($dataConnector->mysqlConnection == null || $dataConnector->sqlserverConnection == null) {
echo 'Não foi possível se connectar ao bando de dados!';
exit;
}
$nivelAutorizacao = GetAuthorizationLevel($dataConnector->mysqlConnection, $functionalities["solicitacaoConsumiveis"]);
if ($nivelAutorizacao <= 1) {
DisplayNotAuthorizedWarning();
exit;
}
// Cria os objetos de mapeamento objeto-relacional
$requestItemDAO = new RequestItemDAO($dataConnector->mysqlConnection);
$requestItemDAO->showErrors = 1;
// Busca os itens da solicitação
$firstCondition = 'pedidoConsumivel_id IS NULL';
if ($supplyRequestId != 0) {
$firstCondition = 'pedidoConsumivel_id=' . $supplyRequestId;
}
$secondCondition = 'pedidoPecaReposicao_id IS NULL';
if ($partRequestId != 0) {
$secondCondition = 'pedidoPecaReposicao_id=' . $partRequestId;
示例5: session_start
session_start();
include_once "../../check.php";
include_once "../../defines.php";
include_once "../../ClassLibrary/DataConnector.php";
// Abre a conexao com o banco de dados
$dataConnector = new DataConnector('both');
$dataConnector->OpenConnection();
if ($dataConnector->mysqlConnection == null || $dataConnector->sqlserverConnection == null) {
echo 'Não foi possível se connectar ao bando de dados!';
exit;
}
$nivelAutorizacaoEquipmts = GetAuthorizationLevel($dataConnector->mysqlConnection, $functionalities["gerenciamentoEquipmtPecas"]);
$nivelAutorizacaoChamados = GetAuthorizationLevel($dataConnector->mysqlConnection, $functionalities["gerenciamentoChamados"]);
$nivelAutorizacaoContratos = GetAuthorizationLevel($dataConnector->mysqlConnection, $functionalities["gerenciamentoContratos"]);
$nivelAutorizacaoFaturamentos = GetAuthorizationLevel($dataConnector->mysqlConnection, $functionalities["sinteseFaturamento"]);
$nivelAutorizacaoLeituras = GetAuthorizationLevel($dataConnector->mysqlConnection, $functionalities["gerenciamentoLeituras"]);
// Fecha a conexão com o banco de dados
$dataConnector->CloseConnection();
?>
<h1>Relatórios</h1><br/>
<h1><?php
echo str_pad('_', 64, '_', STR_PAD_LEFT);
?>
</h1>
<div style="clear:both;">
<br/><br/>
</div>
<script type="text/javascript" >
$(document).ready(function() {