| Server IP : 20.75.53.88 / Your IP : 216.73.217.138 [ 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/juridico/horizonte/modulos/solicitacao/ |
Upload File : |
<?php
$id = $_GET['id'];
$varg = $_GET['varg'];
$solicita = $conn->query("select * from v_lista_solicita where solicita_id='$id'");
$p = $solicita->fetch(PDO::FETCH_OBJ);
$set_soli = $conn->query("select * from setor_solicitante order by setor");
$arq_stat = $conn->query("select * from solicita_status");
$arq_file = $conn->query("select * from v_lista_solicita_arq where solicita_id=$id order by arquivo_id DESC");
?>
<head>
<script src="js/mascara.js" type="text/javascript"></script>
<script>
function combo(id, acao, valor) {
$.ajax({
type: "GET",
url: 'modulos/parecer/ajax.php?a=' + acao + '&valor=' + valor,
dataType: "html",
success: function (resultado) {
//alert(resultado);
$('#' + id).html(resultado);
//$('#resposta').html(resultado);
}
});
}
</script>
</head>
<div class="container">
<div class='row'>
<div class='panel-body label'>
<a href='?page=solicitacao/solicita&varg=<?php echo $varg ?>' title="voltar"><i aling='center' class='fa fa-arrow-circle-o-left fa-2x' title='Voltar'></i></a>
<span style="font-size:20px; color: #060606"> Solicitações | Edição</span>
<a class="j90" href='index2.php?page=parecer/auxiliar' target="_blank">
<i aling='center' class='fa fa-plus-circle fa-2x pull-right' title='Tabelas auxiliares'></i>
</a>
</div>
</div>
</div>
<div class="container-fluid">
<div class="row">
<div class="panel-body">
<form id="form1" name="form1" OnSubmit="showCarga()" id="formulario" method="post" action="?page=solicitacao/solicita_crud&var=editar">
<div class='panel panel-primary filterable panel-body'>
<input type="hidden" value="<?php echo $idusu ?>" name="usu_id">
<input type="hidden" value="<?php echo $p->solicita_id ?>" name="solicita_id">
<input type="hidden" value="<?php echo $varg ?>" name="varg">
<div class="col-md-6">
<label>Setor solicitante
<i class='fa fa-refresh' onclick="combo('cod_setor_sol','sel_setor_sol','0')" style="cursor: hand;"></i>
</label>
<select id="cod_setor_sol" name="setor_solicitante_id" class="form-control select2">
<?php while ($sol = $set_soli->fetch(PDO::FETCH_OBJ)) {
if ($p->setor_solicitante_id==$sol->setor_solicitante_id) {
$selected = 'selected';
} else {
$selected = '';
} ?>
<option value="<?php echo $sol->setor_solicitante_id ?>"<?php echo $selected; ?>><?php echo $sol->setor ?></option>
<?php } ?>
</select>
</div>
<div class='col-md-2'>
<label>Data solicitação</label>
<input type='text' class='form-control' name='data_solictacao' value="<?php echo date('d/m/Y', strtotime($p->data_solicitacao)) ?>"/>
</div>
<div class='col-md-2'>
<label>Prazo</label>
<input type='text' class='form-control' name='data_prazo' value="<?php echo date('d/m/Y', strtotime($p->data_prazo)) ?>"/>
</div>
<div class="col-md-2">
<label>Status
<!-- <i class='fa fa-refresh' onclick="combo('cod_status','sel_status','0')" style="cursor: hand;"></i>-->
</label>
<select id="cod_status" name="status" class="form-control select2">
<?php while ($sta = $arq_stat->fetch(PDO::FETCH_OBJ)) {
if ($p->status==$sta->status_id) {
$selected = 'selected';
} else {
$selected = '';
} ?>
<option value="<?php echo $sta->status_id ?>"<?php echo $selected; ?>><?php echo $sta->status ?></option>
<?php } ?>
</select>
</div>
<div class='col-md-12'>
<label>Pedido</label>
<textarea id="allTextAreas" class="form-control" rows="7" name="pedido"><?php echo $p->pedido ?></textarea>
</div>
<div class='col-md-2 pull-right'>
<label> </label>
<br>
<button type="submit" name="bt_novo" title="Salvar registro" class="btn btn-primary form-control"><i class="glyphicon glyphicon-ok"></i></button>
</div>
</div>
</form>
</div>
</div>
</div>
<!--ADICIONAR ARQUIVO-->
<div class="container-fluid">
<div class="row">
<div class="panel-body">
<div class='panel panel-primary filterable panel-body'>
<span style="font-size:15px; color: #060606"><b> Adicionar arquivo</b></span>
<form id="f_files" name="f_files" enctype="multipart/form-data" OnSubmit="showCarga()" method="post" action="?page=solicitacao/solicita_crud&var=solicita_arq">
<a name="peticao">
<input type='hidden' name='id' value="<?php echo $p->solicita_id ?>"/>
<input type="hidden" value="<?php echo $varg ?>" name="varg">
<div class='col-md-12'>
<label for='descri'>Descrição</label>
<input type='text' class='form-control upper' name='descricao'/>
</div>
<div class='col-md-10'>
<label for='caminho'>Adicionar arquivo</label>
<input id="file-0a" class="file" name="caminho" type="file" multiple data-min-file-count="1" accept=".pdf, .doc, .docx, .jpg, .jpeg, .xls, .xlsx">
</div>
<div class='col-md-2'>
<label for='bt_novo'> </label>
<br>
<button type="submit" onclick="validaPeticoes();" name="bt_novo" class="btn btn-primary form-control">
<i class="glyphicon glyphicon-ok"></i></button>
</div>
</a>
</form>
</div>
</div>
<div class="container-fluid">
<div class='panel panel-primary filterable panel-body'>
<span style="font-size:15px; color: #060606"><b> Arquivos anexados</b></span>
<form id='frm_pesq' method='post' class="search-form">
<table class='table dtabelas table-striped table-hover dt-responsive' cellspacing='0' width='100%' border='0'>
<thead>
<tr class="success">
<th width="2%">ID</th>
<th>Data</th>
<th>Descrição</th>
<th>Tipo</th>
<th width="2%"></th>
</tr>
</thead>
<tbody>
<?php
while ($d = $arq_file->fetch(PDO::FETCH_OBJ)) {
echo "<tr>";
echo "<td>" . $d->arquivo_id . "</td>";
echo "<td>" . date('d/m/Y', strtotime($d->data)) . "</td>";
echo "<td>" . $d->descricao . "</td>";
echo "<td>" . $d->tipo . "</td>";
$id = $d->arquivo_id;
echo "<td><a href='$d->caminho' target='_blank'><i aling='center' class='fa fa-eye text-orange' title='Visualizar arquivo' style='font-size: 20px;'></i></a></td>";
echo "</tr>";
}
?>
</tbody>
</table>
</form>
</div>
</div>
</div>
</div>
<!--FIM ADICIONAR ARQUIVO-->
</div>
</div>