| Server IP : 20.75.53.88 / Your IP : 216.73.217.72 [ Web Server : Apache System : Linux VMRALP-3 4.4.0-256-generic #290~14.04.1-Ubuntu SMP Thu Jun 20 09:24:50 UTC 2024 x86_64 User : www-data ( 33) PHP Version : 5.5.9-1ubuntu4.29+esm15 Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority, Domains : 3 Domains MySQL : ON | cURL : OFF | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /var/www/html/merenda/mnova19/modulos/movimento/ |
Upload File : |
<?php
/**
* Criado por PhpStorm.
* Projeto: SGAE.
* Arquivo: ordcompra.php.
* Usuário: RalpAlves
* Data: 15/09/2015
* Hora: 08:28
*/
ini_set('display_errors', 'off');
mysql_select_db($banco, $conexao);
$rsResult = mysql_query("SELECT * FROM v_lista_ordem_compra WHERE odc_tipo='1'");
$mesatu = date('m');
$rsSaldo = mysql_query("SELECT sigla, valor, sum(oci_vrusado) as oci_vrusado, valor-sum(oci_vrusado) as oci_vrsaldo FROM v_lista_ordem_compra_valor_real where mes=$mesatu and SUBSTRING(odc_data,4,2) = $mesatu");
$saldo = mysql_fetch_array($rsSaldo);
?>
<head>
<script type="text/javascript">
$(document).ready(function () {
$('#tabela').DataTable({
stateSave: true, "oLanguage": {
"sProcessing": "Processando. Aguarde...",
"sLengthMenu": "Mostrar _MENU_ registros",
"sZeroRecords": "NENHUM REGISTRO ENCONTRADO!",
"sInfo": "Mostrando _START_ até _END_ de _TOTAL_ registros",
"sInfoEmpty": "Mostrando 0 até 0 de 0 registros",
"sInfoFiltered": "(de _MAX_ registros no total)",
"sInfoPostFix": "",
"sSearch": "<em class='fa fa-search' title='pesquisar'></em>",
"sUrl": "",
"oPaginate": {
"sFirst": "<em class='fa fa-angle-double-left' title='primeiro registro'>",
"sPrevious": "<em class='fa fa-arrow-circle-left' title='registro anterior'></em>",
"sNext": "<em class='fa fa-arrow-circle-right' title='próximo registro'></em>",
"sLast": "<em class='fa fa-angle-double-right ' title='último registro'>"
}
}
});
});
</script>
<script type="text/javascript">
function excluir_registro(e) {
if (!confirm('Deseja realmente excluir este registro?')) {
if (window.event)
window.event.returnValue = false; else
e.preventDefault();
}
}
</script>
<script>
$('#sign-up').click(function () {
var btn = $(this);
btn.button('loading');
$.ajax(...
).
always(function () {
btn.button('reset');
});
});
</script>
</head>
<!--GRID DA DADOS-->
<body style="padding-top: 70px;"/>
<div id='id_grid' class='container'>
<div class='row'>
<p style='font-size: 20px;'>Ordem compra | Listagem
<button type='submit' id="#sign-up" name='bt_cad_prod' class='btn'
onclick=location.href='?page=./movimento/ordcompra_cad'><i class="fa fa-plus"></i>
</button>
<a href="modulos/movimento/rel_ordcompralista.php?id=<?=$cod_id?>"
target='_blank'>
<i class="glyphicon glyphicon-print text-print navbar-right" title="Relatório de ordens"></i>
</a>
<a href="?page=movimento/ordem_compra_geral" target='_blank' class="pull-right">
<i class="glyphicon glyphicon-list-alt text-print-left-1" title="Emissao das Ordens de compra"></i>
</a>
<b><span style="font-size:14px;color: black;">Disponível <?php echo '<b><span style="color: #8a6d3b"> ' . utf8_encode($saldo['sigla']) . '</span></b>:' ?>
</span>R$ <?=number_format($saldo['valor'], 2, ',', '.')?></b> |
<b><span style="font-size:15px;color: #843534;">utilizado: </span>R$ <?=number_format($saldo['oci_vrusado'], 2, ',', '.')?></b> |
<b><span style="font-size:15px;color: #008000;">Saldo: </span>R$ <?=number_format($saldo['oci_vrsaldo'], 2, ',', '.')?></b>
</p>
<div class='panel panel-body panel-primary filterable'>
<form id='frm_pesq' method='post'>
<table class='tabe1 table table-striped table-hover dt-responsive' cellspacing='0' width='100%' border='0'>
<thead>
<tr>
<th>ID</th>
<th width="10%">Nº O.C.</th>
<th width="25%">Cardápio</th>
<th>Programa</th>
<th>Período</th>
<th>Fornecedor</th>
<th></th>
<th></th>
</tr>
</thead>
<tbody>
<?php
while ($row = mysql_fetch_array($rsResult)) {
echo "<tr>";
echo "<td>" . $row['odc_id'] . "</td>";
echo "<td>" . $row['odc_numordcomp'] . "</td>";
echo "<td>" . $row['cdp_nmcardapio'] . "</td>";
echo "<td>" . $row['prg_programa'] . "</td>";
echo "<td>" . $row['odc_dtinic'] .' '.$row['odc_dtfim'] . "</td>";
echo "<td>" . utf8_encode($row['pes_pessoa']) . "</td>";
$cod_id = $row['odc_id'];
echo "<td><a href='?page=movimento/ordcompra_edt&cod_id=$cod_id'> <em class='fa fa-eye' title='visualizar itens'/></a></td>";
echo "<td><a href='?page=movimento/ordcompra_crud&cod_id=$cod_id&var_acao=exc_ordem'>
<em class='fa fa-trash text-red' title='Excluir registro' onclick='excluir_registro(event);'/></a></td>";
}
?>
</tbody>
</table>
</form>
</div>
</div>
</div>
</html>