<!--
-- UsuarioNivel --
1: 
2: 
3: 
4: 
5:
6: operadores(operario)
?>

<!-- Navigation -->
<nav class="navbar navbar-default navbar-static-top" role="navigation" style="margin-bottom: 0">
    <div class="navbar-header">
        <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse" >
            <span class="sr-only">Toggle navigation</span>
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
        </button>
        <a class="navbar-brand" href="javascript:void(0)" onclick="fLoadOptionScriptLeitura('Leitura', '<?php echo $_SESSION['pais'] ?>')" ><img class="hidden-xs" src="css/logo.png" width="47px">Gerenciamento de Tablets</a>
    </div>
    <!-- /.navbar-header -->

    <ul class="nav navbar-top-links navbar-right">
        <li class="dropdown">
            <a class="dropdown-toggle" data-toggle="dropdown" href="#"> <i class="fa fa-info-circle fa-fw"></i>  <i class="fa fa-caret-down"></i></a>        
            <ul class="dropdown-menu dropdown-messages">
                <li>
                    <a href="#">
                        <div><strong>Sistema de Gerenciamento Tablets</strong><span class="pull-right text-muted"><em>VS 2.0</em></span></div>
                        <div>Direitos Reservados</div>
                    </a>
                </li>
            </ul>
            <!-- /.dropdown-messages -->    
        </li>
        <!-- /.dropdown -->    
        <li class="dropdown">
            <a class="dropdown-toggle" data-toggle="dropdown" href="#"><i class="fa fa-user fa-fw"></i>&nbsp;<?php echo $_SESSION['UsuarioNome'] ?>&nbsp;<i class="fa fa-caret-down"></i>        </a>        
            <ul class="dropdown-menu dropdown-user">
                <li>
                    <a data-toggle="modal" data-target="#alterarsenhamodal" href="javascript:void(0);" ><i class="fa fa-lock fa-fw"></i> Alterar senha</a>
                </li>
                <li><a href="logout.php"><i class="fa fa-sign-out fa-fw"></i> Logout</a></li>
            </ul>
            <!-- /.dropdown-user -->    
        </li>
        <!-- /.dropdown -->
    </ul>
    <!-- /.navbar-top-links -->


    <div class="navbar-default sidebar" role="navigation">
        <div class="sidebar-nav navbar-collapse collapse">

            <ul class="nav page-sidebar-menu page-header-fixed " id="side-menu" data-keep-expanded="false" data-auto-scroll="true" data-slide-speed="200" style="padding-top: 20px">
                <?php if ($_SESSION['UsuarioNivel'] < 5) { ?>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Home')"><i class="fa fa-align-justify fa-fw"></i> Página Inicial</a></li>
                    <?php
                }

                if ($_SESSION['UsuarioNivel'] == 1) {
                    ?>

                    <li><a href="javascript:void(0)" onclick="fLoadOptionScriptLeitura('Leitura', '<?php echo $_SESSION['pais'] ?>')" ><i class='fa fa-dashboard fa-fw'></i> Painel Administrativo</a></li>
                    <li>
                        <a href='javascript:void(0)'><i class='fa fa-file-o fa-fw'></i> Leituras<span class='fa arrow'></span></a>
                        <ul class='nav nav-second-level'>
                            <li>
                                <a href="javascript:void(0)" onclick="fLoadOptionScript('ConsultarFaturas')" >Consultar Leitura</a>
                            </li>
                            <li><a href="javascript:void(0)" onclick="fLoadOptionScript('ConsultarFaturasPeriodo')" >Leitura por Período</a></li>
                        </ul>
                    </li>
                    <li>
                        <a href='javascript:void(0)'><i class="fa fa-barcode" aria-hidden="true"></i> Financeiro<span class='fa arrow'></span></a>
                        <ul class='nav nav-second-level'>
                            <li>
                                <a href="javascript:void(0)" onclick="fLoadOptionScript('ContasReceber')" >Contas a Receber</a>
                            </li>
                        </ul>
                    </li>
                    <li>
                        <a href='javascript:void(0)'><i class='fa fa-money fa-fw'></i> Transações<span class='fa arrow'></span></a>
                        <ul class='nav nav-second-level'>
                            <li><a href="javascript:void(0)" onclick="fLoadOptionScript('TransacaoPeriodo')" >Entradas e Saidas</a></li>
                            <li><a href="javascript:void(0)" onclick="fLoadOptionScript('MovimentacaoPeriodo')" >Movimentação por Periodo</a></li>					
                            <li><a href="javascript:void(0)" onclick="fLoadOptionScript('AcumuladosPagos')" >Acumulados Pagos</a></li>					
                        </ul>
                    </li>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('GerenciarAdministradores')" ><i class='fa fa-cogs fa-fw'></i> Gerenciar Administradores</a></li>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Clientes')" ><i class='fa fa-users fa-fw'></i> Gerenciar Clientes</a></li>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Socios')" ><i class='fa fa-briefcase fa-fw'></i> Gerenciar Sócios</a></li>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Operadores')" ><i class='fa fa-users fa-fw'></i> Gerenciar Operadores</a></li>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Funcionarios')" ><i class='fa fa-users fa-fw'></i> Gerenciar Funcionários</a></li>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Pontos')" ><i class='fa fa-home fa-fw'></i> Gerenciar Pontos</a></li>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Tablets')"><i class='fa fa-tablet fa-fw'></i> Gerenciar Tablets</a></li>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('CrashLogs')"><i class='fa fa-exclamation-triangle fa-fw'></i> Crash Logs</a></li>

                <?php } elseif ($_SESSION['UsuarioNivel'] == 2) {
                    ?>

                    <li><a href="javascript:void(0)" onclick="fLoadOptionScriptLeitura('Leitura', '<?php echo $_SESSION['pais'] ?>')" ><i class='fa fa-dashboard fa-fw'></i> Painel Administrativo</a></li>
                    <li>
                        <a href='#'><i class='fa fa-file-o fa-fw'></i> Leituras<span class='fa arrow'></span></a>
                        <ul class='nav nav-second-level'>
                            <li><a href="javascript:void(0)" onclick="fLoadOptionScript('ConsultarFaturasPeriodo')" >Leituras por Período</a></li>
                            <li>
                                <a href="javascript:void(0)" onclick="fLoadOptionScript('GerenciarFaturas')" >Gerenciar Leituras</a>
                            </li>
                        </ul>
                    </li>
                    <li>
                        <a href='#'><i class='fa fa-money fa-fw'></i> Transações<span class='fa arrow'></span></a>
                        <ul class='nav nav-second-level'>
                            <li><a href="javascript:void(0)" onclick="fLoadOptionScript('TransacaoPeriodo')" >Entradas e Saidas</a></li>
                            <li><a href="javascript:void(0)" onclick="fLoadOptionScript('MovimentacaoPeriodo')" >Movimentação por Periodo</a></li>

                        </ul>
                    </li>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Clientes')" ><i class='fa fa-users fa-fw'></i> Gerenciar Clientes</a></li>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Socios')"><i class='fa fa-briefcase fa-fw'></i> Gerenciar Sócios</a></li>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Operadores')" ><i class='fa fa-users fa-fw'></i> Gerenciar Operadores</a></li>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Funcionarios')" ><i class='fa fa-users fa-fw'></i> Gerenciar Funcionários</a></li>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Pontos')" ><i class='fa fa-home fa-fw'></i> Gerenciar Pontos</a></li>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Tablets')"><i class='fa fa-tablet fa-fw'></i> Gerenciar Tablets</a></li>

                <?php } elseif ($_SESSION['UsuarioNivel'] == 3 || $_SESSION['UsuarioNivel'] == 4) {
                    ?>

                    <li><a href="javascript:void(0)" onclick="fLoadOptionScriptLeitura('Leitura', '<?php echo $_SESSION['pais'] ?>')" ><i class='fa fa-dashboard fa-fw'></i> Painel Administrativo</a></li>
                    <li>
                        <a href='#'><i class='fa fa-file-o fa-fw'></i> Leituras<span class='fa arrow'></span></a>
                        <ul class='nav nav-second-level'>
                            <li>
                                <a href="javascript:void(0)" onclick="fLoadOptionScript('ConsultarFaturas')" >Consultar Leituras</a>
                            </li>
                            <li><a href="javascript:void(0)" onclick="fLoadOptionScript('ConsultarFaturasPeriodo')" >Leituras por Período</a></li>
                        </ul>
                    </li>
                    <li>
                        <a href='javascript:void(0)'><i class="fa fa-barcode" aria-hidden="true"></i> Financeiro<span class='fa arrow'></span></a>
                        <ul class='nav nav-second-level'>
                            <?php if ($_SESSION['UsuarioNivel'] == 3) { ?>
                            <li>
                                <a href="javascript:void(0)" onclick="fLoadOptionScript('ContasReceber')" >Contas a Receber</a>
                            </li>
                            <?php }?>
                            <li><a href="javascript:void(0)" onclick="fLoadOptionScript('ContasPagar')" >Contas a Pagar</a></li>
                        </ul>
                    </li>
                    <li>
                        <a href='#'><i class='fa fa-money fa-fw'></i> Transações<span class='fa arrow'></span></a>
                        <ul class='nav nav-second-level'>
                            <li><a href="javascript:void(0)" onclick="fLoadOptionScript('TransacaoPeriodo')" >Entradas e Saidas</a></li>
                            <li><a href="javascript:void(0)" onclick="fLoadOptionScript('MovimentacaoPeriodo')" >Movimentação por Periodo</a></li>	
                            <li><a href="javascript:void(0)" onclick="fLoadOptionScript('AcumuladosPagos')" >Acumulados Pagos</a></li>	
                        </ul>
                    </li>
    <?php if ($_SESSION['UsuarioNivel'] == 3) { ?>
                        <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Socios')"><i class='fa fa-briefcase fa-fw'></i> Gerenciar Sócios</a></li>
                    <?php } ?>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Operadores')" ><i class='fa fa-users fa-fw'></i> Gerenciar Operadores</a></li>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Funcionarios')" ><i class='fa fa-users fa-fw'></i> Gerenciar Funcionários</a></li>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Pontos')" ><i class='fa fa-home fa-fw'></i> Gerenciar Pontos</a></li>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Tablets')"><i class='fa fa-tablet fa-fw'></i> Gerenciar Tablets</a></li>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('PrePagos')"><i class='fa fa-credit-card fa-fw'></i> Gerenciar Pré-pagos</a></li>

<?php } elseif ($_SESSION['UsuarioNivel'] == 4) {
    ?>

                    <li><a href="javascript:void(0)" onclick="fLoadOptionScriptLeitura('Leitura', '<?php echo $_SESSION['pais'] ?>')" ><i class='fa fa-dashboard fa-fw'></i> Painel Administrativo</a></li>
                    <li>
                        <a href='#'><i class='fa fa-file-o fa-fw'></i> Leituras<span class='fa arrow'></span></a>
                        <ul class='nav nav-second-level'>
                            <li>
                                <a href="javascript:void(0)" onclick="fLoadOptionScript('ConsultarFaturas')" >Consultar Leituras</a>
                            </li>
                            <li><a href="javascript:void(0)" onclick="fLoadOptionScript('ConsultarFaturasPeriodo')" >Leituras por Período</a></li>
                        </ul>
                    </li>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Funcionarios')" ><i class='fa fa-users fa-fw'></i> Gerenciar Funcionários</a></li>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Pontos')" ><i class='fa fa-home fa-fw'></i> Gerenciar Pontos</a></li>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Tablets')"><i class='fa fa-tablet fa-fw'></i> Gerenciar Tablets</a></li>

<?php } elseif ($_SESSION['UsuarioNivel'] == 5) {
    ?>

                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Tablets')"><i class='fa fa-tablet fa-fw'></i> Gerenciar Tablets</a></li>

<?php } elseif ($_SESSION['UsuarioNivel'] == 6) {
    ?>


                    <li><a href="javascript:void(0)" onclick="fLoadOptionScriptLeitura('Leitura', '<?php echo $_SESSION['pais'] ?>')" ><i class='fa fa-dashboard fa-fw'></i> Painel Administrativo</a></li>

                    <li>
                        <a href='#'><i class='fa fa-file-o fa-fw'></i> Leituras<span class='fa arrow'></span></a>
                        <ul class='nav nav-second-level'>
                            <li>
                                <a href="javascript:void(0)" onclick="fLoadOptionScript('ConsultarFaturas')" >Consultar Leituras</a>
                            </li>
                            <li><a href="javascript:void(0)" onclick="fLoadOptionScript('ConsultarFaturasPeriodo')" >Leituras por Período</a></li>
                            
                        </ul>
                    </li>
                    <li>
                        <a href='#'><i class='fa fa-money fa-fw'></i> Transações<span class='fa arrow'></span></a>
                        <ul class='nav nav-second-level'>
                            <li><a href="javascript:void(0)" onclick="fLoadOptionScript('TransacaoPeriodo')" >Entradas e Saidas</a></li>
                            <li><a href="javascript:void(0)" onclick="fLoadOptionScript('MovimentacaoPeriodo')" >Movimentação por Periodo</a></li>	
                            <li><a href="javascript:void(0)" onclick="fLoadOptionScript('AcumuladosPagos')" >Acumulados Pagos</a></li>	
                        </ul>
                    </li>
                    <!--
                    //verificar se operador possui permissão de fechamanto de faturas do ponto
                    -->
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Pontos')" ><i class='fa fa-home fa-fw'></i> Gerenciar Pontos</a></li>
                    <li><a href="javascript:void(0)" onclick="fLoadOptionScript('Tablets')"><i class='fa fa-tablet fa-fw'></i> Gerenciar Tablets</a></li>
    <?php
}
?>
            </ul>

        </div> <!-- /#side-menu -->
    </div>   <!-- /.sidebar-collapse -->
    <!-- /.navbar-static-side -->
</nav>
<?php include('alterar_senha_modal.php'); ?>