Commit 0b3bd513 authored by Carlos André's avatar Carlos André
Browse files

tabela editais

parent b4d041c9
......@@ -349,4 +349,71 @@ section {
.btn-success {
border-radius: 5px;
font-weight: bolder;
}
.dropdown-item {
color: rgb(0, 140, 255);
}
.dropdown-item:hover {
color: rgb(0, 140, 255);
}
.dropdown-item-delete {
background-color: red;
width: 155px;
border-radius: 5px;
margin-left: 10px;
margin-right: 10px;
color: white;
}
.dropdown-item-delete:hover {
background-color: rgb(207, 0, 0);
color: white;
}
.dropdown-options a:hover {
text-decoration: none;
}
.dropdown-hr {
margin-top: 0px;
margin-bottom: 0px;
width: 80%;
}
.titulo-table {
color: rgb(0, 140, 255);
}
.table th {
color: rgb(0, 140, 255);
}
.form-control-edit {
border-top: none;
border-left: none;
border-right: none;
border-radius: 0px;
border-color: rgb(0, 140, 255);
}
.form-control-edit:focus {
border-color: none;
box-shadow: none;
border-top: none;
border-left: none;
border-right: none;
border-radius: 0px;
}
.form-control-edit:hover {
border-color: none;
box-shadow: none;
border-top: none;
border-left: none;
border-right: none;
border-radius: 0px;
border-color: rgb(0, 140, 255);
}
\ No newline at end of file
......@@ -6,8 +6,22 @@
<div class="container" >
<div class="row" >
<div class="col-sm-10">
<h3>Meus Editais</h3>
<div class="col-sm-4">
<div class="row">
<div class="col-sm-2">
<button class="btn" onclick="buscarEdital(this.parentElement.parentElement.children[1].children[0])">
<img src="{{asset('img/icons/logo_lupa.png')}}" alt="">
</button>
</div>
<div class="col-sm-10">
<input type="text" class="form-control form-control-edit" placeholder="Digite o nome do edital" onkeyup="buscarEdital(this)">
</div>
</div>
</div>
<div class="col-sm-1">
</div>
<div class="col-sm-5" style="float: center;">
<h4 class="titulo-table">Editais</h4>
</div>
<div class="col-sm-2">
<a href="{{route('evento.criar')}}" class="btn btn-info" style="float: right;">Criar Edital</a>
......@@ -22,7 +36,7 @@
<th scope="col">Opção</th>
</tr>
</thead>
<tbody>
<tbody id="eventos">
@foreach ($eventos as $evento)
<tr>
<td>
......@@ -39,25 +53,25 @@
</a>
<div class="dropdown-menu">
<a href="{{ route('evento.editar', ['id' => $evento->id]) }}" class="dropdown-item text-center">
Editar Edital
Editar Edital
</a>
<hr class="dropdown-hr">
<a href="{{route('admin.atribuir', ['evento_id' => $evento->id])}}" class="dropdown-item text-center">
Atribuir Avaliadores
</a>
<hr class="dropdown-hr">
<a href="{{route('admin.pareceres', ['evento_id' => $evento->id])}}" class="dropdown-item text-center">
Visualizar Pareceres
</a>
<hr class="dropdown-hr">
<a href="{{route('admin.analisar', ['evento_id' => $evento->id])}}" class="dropdown-item text-center">
Analisar projetos
</a>
<hr class="dropdown-hr">
<!-- Button trigger modal -->
<button type="button" class="dropdown-item text-center" data-toggle="modal" data-target="#exampleModal{{ $evento->id }}">
Deletar
</button>
<button type="button" class="dropdown-item dropdown-item-delete text-center" data-toggle="modal" data-target="#exampleModal{{ $evento->id }}">
<img src="{{asset('img/icons/logo_lixeira.png')}}" alt=""> Deletar
</button>
</div>
......@@ -104,6 +118,22 @@
@section('javascript')
<script>
function buscarEdital(input) {
var editais = document.getElementById('eventos').children;
if(input.value.length > 2) {
for(var i = 0; i < editais.length; i++) {
var nomeEvento = editais[i].children[0].children[0].textContent;
if(nomeEvento.substr(0).indexOf(input.value) >= 0) {
editais[i].style.display = "";
} else {
editais[i].style.display = "none";
}
}
} else {
for(var i = 0; i < editais.length; i++) {
editais[i].style.display = "";
}
}
}
</script>
@endsection
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment