Commit 2c402a9b authored by Guilherme Silva's avatar Guilherme Silva
Browse files

Merge branch 'master' of https://github.com/antonioDurval/submeta

parents 9ed13ca2 a50ee9e7
......@@ -39,6 +39,10 @@
</div>
</div>
<div class="col-sm-12">
<h4 class="titulo-table" style="text-align: center">Projetos Recomendados</h4>
</div>
<div class="row justify-content-center">
<div class="col-md-12">
<table class="table table-bordered" style="display: block; white-space: nowrap; border-radius:10px; margin-bottom:0px">
......@@ -111,6 +115,161 @@
</table>
</div>
</div>
<br>
<div class="col-sm-12">
<h4 class="titulo-table" style="text-align: center">Projetos não recomendados</h4>
</div>
<div class="row justify-content-center">
<div class="col-md-12">
<table class="table table-bordered" style="display: block; white-space: nowrap; border-radius:10px; margin-bottom:0px">
<thead>
<tr>
<th scope="col">Posição</th>
<th scope="col">Pontuação</th>
<th scope="col" style="width: 100%;">Nome do projeto</th>
<th scope="col">Proponente</th>
<th scope="col">Área</th>
<th scope="col">N. Planos</th>
<th scope="col">Avaliador</th>
<th scope="col">Status</th>
<th scope="col">Bolsas</th>
</tr>
</thead>
<tbody id="projetos">
@php $cont=1;@endphp
@foreach($trabalhos as $trabalho)
@if($trabalho->status == 'reprovado')
<tr>
<td>{{$cont}}</td>
<td>{{$trabalho->pontuacao}}</td>
<td style="max-width:100px; overflow-x:hidden; text-overflow:ellipsis">
{{$trabalho->titulo}}
</td>
<td>
{{$trabalho->proponente->user->name}}
</td>
<td>
{{$trabalho->area->nome}}
</td>
<td>
{{$trabalho->participantes->count()}}
</td>
<td>
@if($trabalho->avaliadors->count() > 0)
@foreach($trabalho->avaliadors as $avaliador)
{{$avaliador->user->name}}<br>
@endforeach
@else
Sem Atribuição
@endif
</td>
@if($trabalho->avaliadors->count() > 0)
<td>
@foreach($trabalho->avaliadors as $avaliador)
@if($avaliador->tipo == "Externo")
{{$avaliador->pivot->recomendacao}}<br>
@php
$parecer = App\ParecerInterno::where([['avaliador_id',$avaliador->id],['trabalho_id',$trabalho->id]])->first();
@endphp
@if($parecer != null && $parecer->statusParecer !=null){{$parecer->statusParecer}} @else Pendente @endif
@endif
@endforeach
</td>
@else
<td>Pendente</td>
@endif
<td>
<button type="button" class="btn btn-primary" data-toggle="modal" data-target="#modalConfirmTrab{{$trabalho->id}}" >
Definir
</button>
</td>
</tr>
@php $cont+=1;@endphp
@endif
@endforeach
</tbody>
</table>
</div>
</div>
<!-- TODOS OS PROJETOS SUBMETIDOS -->
<br>
<div class="col-sm-12">
<h4 class="titulo-table" style="text-align: center">Projetos Submetidos</h4>
</div>
<div class="row justify-content-center">
<div class="col-md-12">
<table class="table table-bordered" style="display: block; white-space: nowrap; border-radius:10px; margin-bottom:0px">
<thead>
<tr>
<th scope="col">Posição</th>
<th scope="col">Pontuação</th>
<th scope="col" style="width: 100%;">Nome do projeto</th>
<th scope="col">Proponente</th>
<th scope="col">Área</th>
<th scope="col">N. Planos</th>
<th scope="col">Avaliador</th>
<th scope="col">Status</th>
<th scope="col">Bolsas</th>
</tr>
</thead>
<tbody id="projetos">
@php $cont=1;@endphp
@foreach($trabalhos as $trabalho)
@if($trabalho->status == 'submetido')
<tr>
<td>{{$cont}}</td>
<td>{{$trabalho->pontuacao}}</td>
<td style="max-width:100px; overflow-x:hidden; text-overflow:ellipsis">
{{$trabalho->titulo}}
</td>
<td>
{{$trabalho->proponente->user->name}}
</td>
<td>
{{$trabalho->area->nome}}
</td>
<td>
{{$trabalho->participantes->count()}}
</td>
<td>
@if($trabalho->avaliadors->count() > 0)
@foreach($trabalho->avaliadors as $avaliador)
{{$avaliador->user->name}}<br>
@endforeach
@else
Sem Atribuição
@endif
</td>
@if($trabalho->avaliadors->count() > 0)
<td>
@foreach($trabalho->avaliadors as $avaliador)
@if($avaliador->tipo == "Externo")
{{$avaliador->pivot->recomendacao}}<br>
@php
$parecer = App\ParecerInterno::where([['avaliador_id',$avaliador->id],['trabalho_id',$trabalho->id]])->first();
@endphp
@if($parecer != null && $parecer->statusParecer !=null){{$parecer->statusParecer}} @else Pendente @endif
@endif
@endforeach
</td>
@else
<td>Pendente</td>
@endif
<td>
<button type="button" class="btn btn-primary" data-toggle="modal" data-target="#modalConfirmTrab{{$trabalho->id}}" >
Definir
</button>
</td>
</tr>
@php $cont+=1;@endphp
@endif
@endforeach
</tbody>
</table>
</div>
</div>
</div>
{{--Janelas--}}
@foreach($trabalhos as $trabalho)
......
......@@ -68,6 +68,7 @@
</thead>
<tbody id="projetos">
@php $cont=1;@endphp
@foreach($trabalhosDoutor as $trabalho)
@if($trabalho->status == 'aprovado')
<tr>
......@@ -204,6 +205,275 @@
</table>
</div>
</div>
<!-- AKI -->
<br>
<div class="col-sm-12">
<h4 class="titulo-table" style="text-align: center">Projetos não recomendados</h4>
</div>
<div class="row justify-content-center">
<div class="col-md-12">
<table class="table table-bordered" style="display: block; white-space: nowrap; border-radius:10px; margin-bottom:0px">
<thead>
<tr>
<th scope="col">Posição</th>
<th scope="col">Pontuação</th>
<th scope="col" style="width: 100%;">Nome do projeto</th>
<th scope="col">Proponente</th>
<th scope="col">Área</th>
<th scope="col">N. Planos</th>
<th scope="col">Avaliador</th>
<th scope="col">Status</th>
<th scope="col">Bolsas</th>
</tr>
</thead>
<tbody id="projetos">
@php $cont=1;@endphp
@foreach($trabalhosAmpla as $trabalho)
@if($trabalho->status == 'reprovado')
<tr>
<td>{{$cont}}</td>
<td>{{$trabalho->pontuacao}}</td>
<td style="max-width:100px; overflow-x:hidden; text-overflow:ellipsis">
{{$trabalho->titulo}}
</td>
<td>
{{$trabalho->proponente->user->name}}
</td>
<td>
{{$trabalho->area->nome}}
</td>
<td>
{{$trabalho->participantes->count()}}
</td>
<td>
@if($trabalho->avaliadors->count() > 0)
@foreach($trabalho->avaliadors as $avaliador)
{{$avaliador->user->name}}<br>
@endforeach
@else
Sem Atribuição
@endif
</td>
@if($trabalho->avaliadors->count() > 0)
<td>
@foreach($trabalho->avaliadors as $avaliador)
@if($avaliador->tipo == "Externo")
@if($avaliador->pivot->recomendacao != null ){{$avaliador->pivot->recomendacao}} @else Pendente @endif
<br>
@else
@php
$parecer = App\ParecerInterno::where([['avaliador_id',$avaliador->id],['trabalho_id',$trabalho->id]])->first();
@endphp
@if($parecer != null && $parecer->statusParecer !=null){{$parecer->statusParecer}} @else Pendente @endif
@endif
@endforeach
</td>
@else
<td>Pendente</td>
@endif
<td>
<button type="button" class="btn btn-primary" data-toggle="modal" data-target="#modalConfirmTrab{{$trabalho->id}}" >
Definir
</button>
</td>
</tr>
@php $cont+=1;@endphp
@endif
@endforeach
@foreach($trabalhosDoutor as $trabalho)
@if($trabalho->status == 'reprovado')
<tr>
<td>{{$cont}}</td>
<td>{{$trabalho->pontuacao}}</td>
<td style="max-width:100px; overflow-x:hidden; text-overflow:ellipsis">
{{$trabalho->titulo}}
</td>
<td>
{{$trabalho->proponente->user->name}}
</td>
<td>
{{$trabalho->area->nome}}
</td>
<td>
{{$trabalho->participantes->count()}}
</td>
<td>
@if($trabalho->avaliadors->count() > 0)
@foreach($trabalho->avaliadors as $avaliador)
{{$avaliador->user->name}}<br>
@endforeach
@else
Sem Atribuição
@endif
</td>
@if($trabalho->avaliadors->count() > 0)
<td>
@foreach($trabalho->avaliadors as $avaliador)
@if($avaliador->tipo == "Externo")
@if($avaliador->pivot->recomendacao != null ){{$avaliador->pivot->recomendacao}} @else Pendente @endif
<br>
@else
@php
$parecer = App\ParecerInterno::where([['avaliador_id',$avaliador->id],['trabalho_id',$trabalho->id]])->first();
@endphp
@if($parecer != null && $parecer->statusParecer !=null){{$parecer->statusParecer}} @else Pendente @endif
@endif
@endforeach
</td>
@else
<td>Pendente</td>
@endif
<td>
<button type="button" class="btn btn-primary" data-toggle="modal" data-target="#modalConfirmTrab{{$trabalho->id}}" >
Definir
</button>
</td>
</tr>
@php $cont+=1;@endphp
@endif
@endforeach
</tbody>
</table>
</div>
</div>
<br>
<div class="col-sm-12">
<h4 class="titulo-table" style="text-align: center">Projetos Submetidos</h4>
</div>
<div class="row justify-content-center">
<div class="col-md-12">
<table class="table table-bordered" style="display: block; white-space: nowrap; border-radius:10px; margin-bottom:0px">
<thead>
<tr>
<th scope="col">Posição</th>
<th scope="col">Pontuação</th>
<th scope="col" style="width: 100%;">Nome do projeto</th>
<th scope="col">Proponente</th>
<th scope="col">Área</th>
<th scope="col">N. Planos</th>
<th scope="col">Avaliador</th>
<th scope="col">Status</th>
<th scope="col">Bolsas</th>
</tr>
</thead>
<tbody id="projetos">
@php $cont=1;@endphp
@foreach($trabalhosAmpla as $trabalho)
@if($trabalho->status == 'submetido')
<tr>
<td>{{$cont}}</td>
<td>{{$trabalho->pontuacao}}</td>
<td style="max-width:100px; overflow-x:hidden; text-overflow:ellipsis">
{{$trabalho->titulo}}
</td>
<td>
{{$trabalho->proponente->user->name}}
</td>
<td>
{{$trabalho->area->nome}}
</td>
<td>
{{$trabalho->participantes->count()}}
</td>
<td>
@if($trabalho->avaliadors->count() > 0)
@foreach($trabalho->avaliadors as $avaliador)
{{$avaliador->user->name}}<br>
@endforeach
@else
Sem Atribuição
@endif
</td>
@if($trabalho->avaliadors->count() > 0)
<td>
@foreach($trabalho->avaliadors as $avaliador)
@if($avaliador->tipo == "Externo")
@if($avaliador->pivot->recomendacao != null ){{$avaliador->pivot->recomendacao}} @else Pendente @endif
<br>
@else
@php
$parecer = App\ParecerInterno::where([['avaliador_id',$avaliador->id],['trabalho_id',$trabalho->id]])->first();
@endphp
@if($parecer != null && $parecer->statusParecer !=null){{$parecer->statusParecer}} @else Pendente @endif
@endif
@endforeach
</td>
@else
<td>Pendente</td>
@endif
<td>
<button type="button" class="btn btn-primary" data-toggle="modal" data-target="#modalConfirmTrab{{$trabalho->id}}" >
Definir
</button>
</td>
</tr>
@php $cont+=1;@endphp
@endif
@endforeach
@foreach($trabalhosDoutor as $trabalho)
@if($trabalho->status == 'submetido')
<tr>
<td>{{$cont}}</td>
<td>{{$trabalho->pontuacao}}</td>
<td style="max-width:100px; overflow-x:hidden; text-overflow:ellipsis">
{{$trabalho->titulo}}
</td>
<td>
{{$trabalho->proponente->user->name}}
</td>
<td>
{{$trabalho->area->nome}}
</td>
<td>
{{$trabalho->participantes->count()}}
</td>
<td>
@if($trabalho->avaliadors->count() > 0)
@foreach($trabalho->avaliadors as $avaliador)
{{$avaliador->user->name}}<br>
@endforeach
@else
Sem Atribuição
@endif
</td>
@if($trabalho->avaliadors->count() > 0)
<td>
@foreach($trabalho->avaliadors as $avaliador)
@if($avaliador->tipo == "Externo")
@if($avaliador->pivot->recomendacao != null ){{$avaliador->pivot->recomendacao}} @else Pendente @endif
<br>
@else
@php
$parecer = App\ParecerInterno::where([['avaliador_id',$avaliador->id],['trabalho_id',$trabalho->id]])->first();
@endphp
@if($parecer != null && $parecer->statusParecer !=null){{$parecer->statusParecer}} @else Pendente @endif
@endif
@endforeach
</td>
@else
<td>Pendente</td>
@endif
<td>
<button type="button" class="btn btn-primary" data-toggle="modal" data-target="#modalConfirmTrab{{$trabalho->id}}" >
Definir
</button>
</td>
</tr>
@php $cont+=1;@endphp
@endif
@endforeach
</tbody>
</table>
</div>
</div>
</div>
{{--Janelas Cotas--}}
@foreach($trabalhosDoutor as $trabalho)
......
......@@ -14,6 +14,7 @@
<option value="todos" selected>Todos</option>
<option value="aberto">Aberto(s)</option>
<option value="encerrado">Encerrado(s)</option>
<option value="abrira">Abrirão</option>
</select>
</div>
<div class="col-sm" style="margin-bottom: 10px">
......@@ -43,25 +44,26 @@
<hr>
</div>
</div>
@php
$hoje = now();
@endphp
<div class="row justify-content-center">
@if(count($eventos)>0)
@foreach ($eventos as $evento)
@if (Auth::check())
@if($evento->fimSubmissao >= $hoje)
@if($evento->fimSubmissao >= $hoje && $hoje >= $evento->inicioSubmissao)
<a href="{{ route('evento.visualizar',['id'=> $evento->id]) }}" style="text-decoration: none" class="aberto">
@else
@elseif($hoje > $evento->fimSubmissao)
<a href="{{ route('evento.visualizar',['id'=> $evento->id]) }}" style="text-decoration: none" class="encerrado">
@else
<a href="{{ route('evento.visualizar',['id'=> $evento->id]) }}" style="text-decoration: none" class="vaiAbrir">
@endif
@else
@if($evento->fimSubmissao >= $hoje)
@if($evento->fimSubmissao >= $hoje && $hoje >= $evento->inicioSubmissao)
<a href="{{ route('evento.visualizarNaoLogado', ['id'=>$evento->id]) }}" style="text-decoration: none" class="aberto">
@else
@elseif($hoje > $evento->fimSubmissao)
<a href="{{ route('evento.visualizarNaoLogado', ['id'=>$evento->id]) }}" style="text-decoration: none" class="encerrado">
@else
<a href="{{ route('evento.visualizar',['id'=> $evento->id]) }}" style="text-decoration: none" class="vaiAbrir">
@endif
@endif
<div class="card" style="width: 18rem; border-radius:12px; border-width:0px; margin:10px">
......@@ -202,7 +204,9 @@
function exibirEditais(select) {
let abertos = document.getElementsByClassName("aberto");
let encerrados = document.getElementsByClassName("encerrado");
let vaiAbrir = document.getElementsByClassName("vaiAbrir");
if(select.value == "todos"){
for(let i = 0; i < abertos.length; i++ ){
abertos[i].style.display = "";
......@@ -211,6 +215,10 @@
for(let j = 0; j < encerrados.length; j++ ){
encerrados[j].style.display = "";
}
for(let l = 0; l < vaiAbrir.length; l++ ){
vaiAbrir[l].style.display = "";
}
}else if(select.value == "aberto") {
for(let i = 0; i < abertos.length; i++){
abertos[i].style.display = "";
......@@ -219,11 +227,31 @@
for(let j = 0; j < encerrados.length; j++ ){
encerrados[j].style.display = "none";
}
for(let l = 0; l < vaiAbrir.length; l++ ){
vaiAbrir[l].style.display = "none";
}
}else if(select.value == "abrira"){
for(let i = 0; i < abertos.length; i++){
abertos[i].style.display = "none";
}
for(let j = 0; j < encerrados.length; j++ ){
encerrados[j].style.display = "none";
}
for(let l = 0; l < vaiAbrir.length; l++ ){
vaiAbrir[l].style.display = "";
}
}else {
for(let i = 0; i < abertos.length; i++){
abertos[i].style.display = "none";
}
for(let l = 0; l < vaiAbrir.length; l++ ){
vaiAbrir[l].style.display = "none";
}
for(let j = 0; j < encerrados.length; j++ ){
encerrados[j].style.display = "";
}
......
......@@ -16,7 +16,7 @@
</div>
@if($errors->any())
<div class="alert alert-danger">
Verifique se todos os campos obrigatórios foram preenchidos!
Verifique se todos os campos obrigatórios/Dados do discente foram preenchidos!
</div>
@endif
</div>
......
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