Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Walter Felipe
submeta
Commits
0d43f2dd
Unverified
Commit
0d43f2dd
authored
Aug 22, 2022
by
GuilhermeGz
Committed by
GitHub
Aug 22, 2022
Browse files
Merge pull request #575 from GuilhermeGz/master
Ajustes nas telas de avaliações e de listagem de avaliadores
parents
38c26e70
b46063fc
Changes
7
Show whitespace changes
Inline
Side-by-side
app/Http/Controllers/AdministradorController.php
View file @
0d43f2dd
...
@@ -652,12 +652,11 @@ class AdministradorController extends Controller
...
@@ -652,12 +652,11 @@ class AdministradorController extends Controller
public
function
projetos
(
Request
$request
){
public
function
projetos
(
Request
$request
){
$evento
=
Evento
::
where
(
'id'
,
$request
->
evento_id
)
->
first
();
$evento
=
Evento
::
where
(
'id'
,
$request
->
evento_id
)
->
first
();
$trabalhos
=
$evento
->
trabalhos
->
where
(
'status'
,
'submetido'
)
;
$trabalhos
=
$evento
->
trabalhos
;
$grandesAreas
=
GrandeArea
::
orderBy
(
'nome'
)
->
get
();
$avaliadores
=
$evento
->
avaliadors
;
$avaliadores
=
$evento
->
avaliadors
;
foreach
(
$trabalhos
as
$key
=>
$trabalho
)
{
foreach
(
$trabalhos
as
$key
=>
$trabalho
)
{
$avalSelecionadosId
=
$trabalho
->
avaliadors
->
pluck
(
'id'
);
$avalSelecionadosId
=
$trabalho
->
avaliadors
->
pluck
(
'id'
);
$avalProjeto
=
Avaliador
::
whereNotIn
(
'id'
,
$avalSelecionadosId
)
->
get
();
$avalProjeto
=
Avaliador
::
whereNotIn
(
'id'
,
$avalSelecionadosId
)
->
get
();
$trabalho
->
aval
=
$avalProjeto
;
$trabalho
->
aval
=
$avalProjeto
;
...
@@ -670,7 +669,8 @@ class AdministradorController extends Controller
...
@@ -670,7 +669,8 @@ class AdministradorController extends Controller
return
view
(
'administrador.selecionarProjetos'
,
[
return
view
(
'administrador.selecionarProjetos'
,
[
'evento'
=>
$evento
,
'evento'
=>
$evento
,
'trabalhos'
=>
$trabalhos
,
'trabalhos'
=>
$trabalhos
,
'avaliadores'
=>
$avaliadores
'avaliadores'
=>
$avaliadores
,
'grandesAreas'
=>
$grandesAreas
]);
]);
}
}
...
...
app/Http/Controllers/AvaliacaoRelatorioController.php
View file @
0d43f2dd
...
@@ -22,21 +22,15 @@ class AvaliacaoRelatorioController extends Controller
...
@@ -22,21 +22,15 @@ class AvaliacaoRelatorioController extends Controller
}
}
public
function
listarUser
(
Request
$request
){
public
function
listarUser
(
$id
){
$planos
=
Arquivo
::
where
(
'trabalhoId'
,
$request
->
trabalho_id
)
->
get
();
$avaliacao
=
AvaliacaoRelatorio
::
find
(
$id
);
$avaliacoes
=
AvaliacaoRelatorio
::
where
(
'user_id'
,
$request
->
user_id
)
->
get
();
$trabalho
=
Trabalho
::
find
(
$avaliacao
->
plano
->
trabalhoId
);
$trabalho
=
Trabalho
::
find
(
$request
->
trabalho_id
);
$evento
=
$trabalho
->
evento
;
$evento
=
$trabalho
->
evento
;
$hoje
=
\
Carbon\Carbon
::
today
(
'America/Recife'
);
$hoje
=
\
Carbon\Carbon
::
today
(
'America/Recife'
);
$hoje
=
$hoje
->
toDateString
();
$hoje
=
$hoje
->
toDateString
();
if
(
$evento
->
dt_fimRelatorioParcial
<
$hoje
&&
$hoje
<
$evento
->
dt_inicioRelatorioFinal
){
$tipoRelatorio
=
"Parcial"
;
}
else
{
$tipoRelatorio
=
"Final"
;
}
return
view
(
'avaliacaoRelatorio.listar'
,
[
"avaliaco
es
"
=>
$avaliaco
es
,
"trabalho"
=>
$trabalho
,
"
planos"
=>
$planos
,
"evento"
=>
$evento
,
"tipoRelatorio"
=>
$tipoRelatori
o
]);
return
view
(
'avaliacaoRelatorio.listar'
,
[
"avaliac
a
o"
=>
$avaliac
a
o
,
"trabalho"
=>
$trabalho
,
"
evento"
=>
$event
o
]);
}
}
public
function
index
(
Request
$request
){
public
function
index
(
Request
$request
){
...
@@ -74,9 +68,9 @@ class AvaliacaoRelatorioController extends Controller
...
@@ -74,9 +68,9 @@ class AvaliacaoRelatorioController extends Controller
]);
]);
$avaliacao
=
AvaliacaoRelatorio
::
find
(
$request
->
avaliacao_id
);
$avaliacao
=
AvaliacaoRelatorio
::
find
(
$request
->
avaliacao_id
);
if
(
$request
->
a
rquivo
!=
null
){
if
(
$request
->
a
valiacaoArq
!=
null
){
$pasta
=
'planoTrabalho/'
.
$request
->
plano_id
.
'avaliacao/'
.
$request
->
avaliacao_id
;
$pasta
=
'planoTrabalho/'
.
$request
->
plano_id
.
'avaliacao/'
.
$request
->
avaliacao_id
;
$avaliacao
->
arquivoAvaliacao
=
Storage
::
putFileAs
(
$pasta
,
$request
->
a
rquivo
,
"AvaliacaoRelatorio.pdf"
);
$avaliacao
->
arquivoAvaliacao
=
Storage
::
putFileAs
(
$pasta
,
$request
->
a
valiacaoArq
,
"AvaliacaoRelatorio.pdf"
);
}
}
$plano
=
Arquivo
::
find
(
$request
->
plano_id
);
$plano
=
Arquivo
::
find
(
$request
->
plano_id
);
...
@@ -84,20 +78,7 @@ class AvaliacaoRelatorioController extends Controller
...
@@ -84,20 +78,7 @@ class AvaliacaoRelatorioController extends Controller
$avaliacao
->
comentario
=
$request
->
comentario
;
$avaliacao
->
comentario
=
$request
->
comentario
;
$avaliacao
->
update
();
$avaliacao
->
update
();
$planos
=
Arquivo
::
where
(
'trabalhoId'
,
$request
->
trabalho_id
)
->
get
();
return
redirect
()
->
back
()
->
with
([
'sucesso'
=>
'Avaliação do relatório '
.
$avaliacao
->
tipo
.
" do plano "
.
$plano
->
titulo
.
' realizada com sucesso.'
]);
$avaliacoes
=
AvaliacaoRelatorio
::
where
(
'user_id'
,
$request
->
user_id
)
->
get
();
$trabalho
=
Trabalho
::
find
(
$request
->
trabalho_id
);
$evento
=
$trabalho
->
evento
;
$hoje
=
\
Carbon\Carbon
::
today
(
'America/Recife'
);
$hoje
=
$hoje
->
toDateString
();
if
(
$evento
->
dt_fimRelatorioParcial
<
$hoje
&&
$hoje
<
$evento
->
dt_inicioRelatorioFinal
){
$tipoRelatorio
=
"Parcial"
;
}
else
{
$tipoRelatorio
=
"Final"
;
}
return
view
(
'avaliacaoRelatorio.listar'
,
[
"avaliacoes"
=>
$avaliacoes
,
"trabalho"
=>
$trabalho
,
"planos"
=>
$planos
,
"evento"
=>
$evento
,
"tipoRelatorio"
=>
$tipoRelatorio
,
'sucesso'
=>
'Avaliação do relatório '
.
$tipoRelatorio
.
" do plano "
.
$plano
->
titulo
.
' realizada com sucesso.'
]);
}
}
public
function
atribuicaoAvaliador
(
Request
$request
){
public
function
atribuicaoAvaliador
(
Request
$request
){
...
...
resources/views/administrador/analisarProposta.blade.php
View file @
0d43f2dd
...
@@ -562,7 +562,7 @@
...
@@ -562,7 +562,7 @@
||
(
$hoje
>
$evento
->
dt_fimRelatorioFinal
))
||
(
$hoje
>
$evento
->
dt_fimRelatorioFinal
))
<
div
class
=
"col-md-1 text-sm-right"
>
<
div
class
=
"col-md-1 text-sm-right"
>
<
a
type
=
"button"
value
=
"{{
$trabalho->id
}}"
id
=
"atribuir1"
data
-
toggle
=
"modal"
<
a
type
=
"button"
value
=
"{{
$trabalho->id
}}"
id
=
"atribuir1"
data
-
toggle
=
"modal"
data
-
target
=
"#avaliacao
ModalCenter
"
>
data
-
target
=
"#avaliacao
RelatorioModal
"
>
<
img
class
=
""
src
=
"
{
{asset('img/icons/add.ico')}
}
"
style
=
"width:30px"
alt
=
""
>
<
img
class
=
""
src
=
"
{
{asset('img/icons/add.ico')}
}
"
style
=
"width:30px"
alt
=
""
>
</
a
>
</
a
>
</
div
>
</
div
>
...
@@ -574,7 +574,7 @@
...
@@ -574,7 +574,7 @@
</
div
>
</
div
>
@
endif
@
endif
<!--
Modal
-->
<!--
Modal
-->
<
div
class
=
"modal fade"
id
=
"avaliacao
ModalCenter
"
data
-
bs
-
backdrop
=
"static"
<
div
class
=
"modal fade"
id
=
"avaliacao
RelatorioModal
"
data
-
bs
-
backdrop
=
"static"
data
-
bs
-
keyboard
=
"false"
tabindex
=
"-1"
aria
-
labelledby
=
"staticBackdropLabel"
data
-
bs
-
keyboard
=
"false"
tabindex
=
"-1"
aria
-
labelledby
=
"staticBackdropLabel"
aria
-
hidden
=
"true"
style
=
"overflow-y: auto"
>
aria
-
hidden
=
"true"
style
=
"overflow-y: auto"
>
<
div
class
=
"modal-dialog modal-dialog-centered modal-xl"
role
=
"document"
>
<
div
class
=
"modal-dialog modal-dialog-centered modal-xl"
role
=
"document"
>
...
@@ -585,6 +585,10 @@
...
@@ -585,6 +585,10 @@
@
if
(
isset
(
$participante
->
planoTrabalho
))
Seleciones
o
(
s
)
avaliador
(
es
)
@
else
Pendências
de
Substituição
@
endif
</
h5
>
@
if
(
isset
(
$participante
->
planoTrabalho
))
Seleciones
o
(
s
)
avaliador
(
es
)
@
else
Pendências
de
Substituição
@
endif
</
h5
>
</
div
>
</
div
>
<
div
class
=
"col-md-4"
style
=
"text-align: right"
>
<
div
class
=
"col-md-4"
style
=
"text-align: right"
>
<
button
type
=
"button"
id
=
"enviarConviteButton"
class
=
"btn btn-info"
data
-
toggle
=
"modal"
onclick
=
"abrirModalConviteRelatorio()"
>
Enviar
Convites
</
button
>
<
button
type
=
"button"
class
=
"close"
aria
-
label
=
"Close"
<
button
type
=
"button"
class
=
"close"
aria
-
label
=
"Close"
data
-
dismiss
=
"modal"
data
-
dismiss
=
"modal"
style
=
"color: rgb(182, 182, 182);padding-right: 0px;"
>
style
=
"color: rgb(182, 182, 182);padding-right: 0px;"
>
...
@@ -871,7 +875,7 @@
...
@@ -871,7 +875,7 @@
@
csrf
@
csrf
<
input
type
=
"hidden"
name
=
"trabalho_id"
value
=
"{{
$trabalho->id
}}"
>
<
input
type
=
"hidden"
name
=
"trabalho_id"
value
=
"{{
$trabalho->id
}}"
>
<
input
type
=
"hidden"
name
=
"evento_id"
value
=
"{{
$evento->id
}}"
>
<
input
type
=
"hidden"
name
=
"evento_id"
value
=
"{{
$evento->id
}}"
>
<
div
class
=
"form-group"
>
<
div
class
=
"form-group
align-items-start
"
>
<
div
class
=
"row"
style
=
"margin-left: 2px;margin-bottom: 1px"
>
<
div
class
=
"row"
style
=
"margin-left: 2px;margin-bottom: 1px"
>
<
div
class
=
"col-md-4"
>
<
div
class
=
"col-md-4"
>
...
@@ -1526,7 +1530,7 @@
...
@@ -1526,7 +1530,7 @@
</
div
>
</
div
>
<
div
class
=
"modal-body"
style
=
"margin-left: 20px; margin-right: 20px;"
>
<
div
class
=
"modal-body"
style
=
"margin-left: 20px; margin-right: 20px;"
>
<
form
action
=
"{{ route('admin.convite.atribuicao.projeto') }}"
method
=
"POST"
class
=
"labels-blue"
>
<
form
action
=
"{{ route('admin.convite.atribuicao.projeto') }}"
method
=
"POST"
class
=
"labels-blue"
id
=
"formConvite"
>
@
csrf
@
csrf
<
input
type
=
"hidden"
name
=
"evento_id"
value
=
"{{
$evento->id
}}"
>
<
input
type
=
"hidden"
name
=
"evento_id"
value
=
"{{
$evento->id
}}"
>
<
input
type
=
"hidden"
name
=
"trabalho_id"
value
=
"{{
$trabalho->id
}}"
>
<
input
type
=
"hidden"
name
=
"trabalho_id"
value
=
"{{
$trabalho->id
}}"
>
...
@@ -1677,6 +1681,8 @@
...
@@ -1677,6 +1681,8 @@
@section('javascript')
@section('javascript')
<script type="
text
/
javascript
" src="
http
://
code
.
jquery
.
com
/
jquery
-
1.7.2.
min
.
js
"></script>
<script type="
text
/
javascript
" src="
http
://
code
.
jquery
.
com
/
jquery
-
1.7.2.
min
.
js
"></script>
<script type="
text
/
javascript
">
<script type="
text
/
javascript
">
var avaliacaoForm;
$(document).ready(function () {
$(document).ready(function () {
$("
#content div:nth-child(1)").show();
$("
#content div:nth-child(1)").show();
$
(
".abas li:first div"
)
.
addClass
(
"selected"
);
$
(
".abas li:first div"
)
.
addClass
(
"selected"
);
...
@@ -1966,6 +1972,7 @@
...
@@ -1966,6 +1972,7 @@
<
script
>
<
script
>
function
abrirModalConvite
()
{
function
abrirModalConvite
()
{
$
(
"#avaliadorModalCenter"
)
.
modal
(
'toggle'
);
$
(
"#avaliadorModalCenter"
)
.
modal
(
'toggle'
);
$
(
"#formConvite"
)
.
attr
(
'action'
,
'{{ route('
admin
.
convite
.
atribuicao
.
projeto
') }}'
);
setTimeout
(()
=>
{
setTimeout
(()
=>
{
$
(
"#exampleModalCenter"
)
.
modal
();
$
(
"#exampleModalCenter"
)
.
modal
();
},
500
);
},
500
);
...
@@ -1974,12 +1981,31 @@
...
@@ -1974,12 +1981,31 @@
function
fecharModalConvite
()
{
function
fecharModalConvite
()
{
$
(
'#exampleModalCenter'
)
.
modal
(
'toggle'
);
$
(
'#exampleModalCenter'
)
.
modal
(
'toggle'
);
if
(
$
(
"#tipo_avaliacao_id"
)
.
val
()
==
1
){
setTimeout
(()
=>
{
setTimeout
(()
=>
{
$
(
"#avaliadorModalCenter"
)
.
modal
();
$
(
"#avaliadorModalCenter"
)
.
modal
();
},
500
);
},
500
);
$
(
'#avaliadorModalCenter'
)
.
focus
();
$
(
'#avaliadorModalCenter'
)
.
focus
();
}
else
{
setTimeout
(()
=>
{
$
(
"#avaliacaoRelatorioModal"
)
.
modal
();
},
500
);
$
(
'#avaliacaoRelatorioModal'
)
.
focus
();
}
}
}
function
abrirModalConviteRelatorio
()
{
$
(
"#avaliacaoRelatorioModal"
)
.
modal
(
'toggle'
);
$
(
"#formConvite"
)
.
attr
(
'action'
,
'{{ route('
admin
.
enviarConvite
') }}'
);
setTimeout
(()
=>
{
$
(
"#exampleModalCenter"
)
.
modal
();
},
500
);
$
(
'#exampleModalCenter'
)
.
focus
();
}
function
areas
()
{
function
areas
()
{
var
grandeArea
=
$
(
'#grandeAreaConvite'
)
.
val
();
var
grandeArea
=
$
(
'#grandeAreaConvite'
)
.
val
();
$
.
ajax
({
$
.
ajax
({
...
...
resources/views/administrador/selecionarProjetos.blade.php
View file @
0d43f2dd
...
@@ -50,7 +50,7 @@
...
@@ -50,7 +50,7 @@
<
tbody
id
=
"projetos"
>
<
tbody
id
=
"projetos"
>
@
foreach
(
$trabalhos
as
$trabalho
)
@
foreach
(
$trabalhos
as
$trabalho
)
<
tr
>
<
tr
>
<
td
style
=
"max-width:100px; overflow-x:
scroll
; text-overflow:ellipsis"
>
{{
$trabalho
->
titulo
}}
</
td
>
<
td
style
=
"max-width:100px; overflow-x:
auto
; text-overflow:ellipsis"
>
{{
$trabalho
->
titulo
}}
</
td
>
<
td
>
{{
App\Area
::
find
(
$trabalho
->
area_id
)
->
nome
}}
</
td
>
<
td
>
{{
App\Area
::
find
(
$trabalho
->
area_id
)
->
nome
}}
</
td
>
<
td
>
{{
$trabalho
->
proponente
->
user
->
name
}}
</
td
>
<
td
>
{{
$trabalho
->
proponente
->
user
->
name
}}
</
td
>
<
td
style
=
"text-align:center"
>
<
td
style
=
"text-align:center"
>
...
@@ -59,7 +59,7 @@
...
@@ -59,7 +59,7 @@
</
button
>
</
button
>
<!--
Modal
-->
<!--
Modal
-->
<
div
class
=
"modal fade"
id
=
"exampleModalCenter{{
$trabalho->id
}}"
tabindex
=
"-1"
role
=
"dialog"
aria
-
labelledby
=
"exampleModalCenterTitle"
aria
-
hidden
=
"true"
>
<
div
class
=
"modal fade"
id
=
"exampleModalCenter{{
$trabalho->id
}}"
tabindex
=
"-1"
role
=
"dialog"
aria
-
labelledby
=
"exampleModalCenterTitle"
aria
-
hidden
=
"true"
>
<
div
class
=
"modal-dialog modal-dialog-centered"
role
=
"document"
>
<
div
class
=
"modal-dialog modal-dialog-centered
modal-xl
"
role
=
"document"
>
<
div
class
=
"modal-content modal-submeta"
>
<
div
class
=
"modal-content modal-submeta"
>
<
div
class
=
"modal-header modal-header-submeta"
>
<
div
class
=
"modal-header modal-header-submeta"
>
<
h5
class
=
"modal-title titulo-table"
id
=
"exampleModalLongTitle"
>
Selecione
o
(
s
)
avaliador
(
es
)
</
h5
>
<
h5
class
=
"modal-title titulo-table"
id
=
"exampleModalLongTitle"
>
Selecione
o
(
s
)
avaliador
(
es
)
</
h5
>
...
@@ -73,18 +73,111 @@
...
@@ -73,18 +73,111 @@
@
csrf
@
csrf
<
input
type
=
"hidden"
name
=
"trabalho_id"
value
=
"{{
$trabalho->id
}}"
>
<
input
type
=
"hidden"
name
=
"trabalho_id"
value
=
"{{
$trabalho->id
}}"
>
<
input
type
=
"hidden"
name
=
"evento_id"
value
=
"{{
$evento->id
}}"
>
<
input
type
=
"hidden"
name
=
"evento_id"
value
=
"{{
$evento->id
}}"
>
<
div
class
=
"form-group"
>
<
div
class
=
"form-group text-left"
>
<
label
for
=
"exampleFormControlSelect2"
>
Selecione
o
(
s
)
avaliador
(
es
)
para
esse
projeto
</
label
>
<
div
class
=
"row"
style
=
"margin-left: 2px;margin-bottom: 1px"
>
<
select
name
=
"avaliadores_id[]"
multiple
class
=
"form-control"
id
=
"exampleFormControlSelect2"
required
>
<
div
class
=
"col-md-4"
>
<
label
for
=
"exampleFormControlSelect2"
style
=
"font-size: 16px;"
>
Selecione
o
(
s
)
avaliador
(
es
)
para
esse
projeto
</
label
>
</
div
>
<
div
class
=
"col-md-3"
style
=
"text-align: center;overflow-y: auto;overflow-x: auto"
>
<
select
class
=
"form-control"
id
=
"grandeArea"
name
=
"grande_area_id"
onchange
=
"areasFiltro()"
>
<
option
value
=
""
disabled
selected
hidden
>--
Grande
Área
--
</
option
>
@
foreach
(
$grandesAreas
as
$grandeArea
)
<
option
title
=
"
{
{$grandeArea->nome}
}
"
value
=
"
{
{$grandeArea->id}}">{{$grandeArea->nome}
}
</option>
@endforeach
</select>
</div>
<div class="
col
-
md
-
2
"
style="
text
-
align
:
center
;
overflow
-
y
:
auto
;
overflow
-
x
:
auto
">
<input type="
hidden
" id="
oldArea
" value="
{{
old
(
'area'
)
}}
">
<select class="
form
-
control
@
error
(
'area'
)
is
-
invalid
@
enderror
"
id="
area
" name="
area_id
"
onchange="
(
consultaExterno
(),
consultaInterno
())
">
<option value="" disabled selected hidden>-- Área --
</option>
</select>
</div>
<div class="
col
-
sm
-
3
" style="
display
:
flex
;
align
-
items
:
end
;
">
<input type="
text
" class="
form
-
control
form
-
control
-
edit
" placeholder="
Nome
do
avaliador
" onkeyup="
buscar
(
this
)
" style="
max
-
width
:
200
px
;
"> <img src="
{{
asset
(
'img/icons/logo_lupa.png'
)}}
" alt="">
</div>
</div>
<div class="
col
-
md
-
6
">
<label style="
font
-
weight
:
bold
;
font
-
size
:
18
px
">Internos</label>
</div>
<input type="
hidden
" id="
oldAvalInterno
"
value="
{{
old
(
'exampleFormControlSelect2'
)
}}
">
<select name="
avaliadores_internos_id
[]
" multiple
class="
form
-
control
" id="
exampleFormControlSelect2
"
style="
height
:
200
px
;
font
-
size
:
15
px
">
@foreach (
$trabalho->avaliadors
as
$avaliador
)
@if((
$avaliador->tipo
== "
Interno
" &&
$avaliador->trabalhos
()->where("
trabalho_id
",
$trabalho->id
)->first()->pivot->acesso == 1) ||
((
$avaliador->user
->instituicao == "
UFAPE
" ||
$avaliador->user
->instituicao == "
Universidade
Federal
do
Agreste
de
Pernambuco
") && (
$avaliador->trabalhos
()->where("
trabalho_id
",
$trabalho->id
)->first()->pivot->acesso == null ||
$avaliador->trabalhos
()->where("
trabalho_id
",
$trabalho->id
)->first()->pivot->acesso == 1) ))
<option value="
{{
$avaliador
->
id
}}
">{{
$avaliador->user
->name }}
> {{$avaliador->user->instituicao ?? 'Instituição Indefinida'}}
> {{$avaliador->area->nome ?? 'Indefinida'}}
>
{
{$avaliador->user->email}
}
</option>
@endif
@endforeach
@foreach (
$trabalho->aval
as
$avaliador
)
@foreach (
$trabalho->aval
as
$avaliador
)
<
option
value
=
"{{
$avaliador->id
}}"
>
{{
$avaliador
->
user
->
name
}}
({{
$avaliador
->
area
->
nome
??
'Indefinida'
}})
</
option
>
@if(
$avaliador->tipo
== "
Interno
" ||
$avaliador->user
->instituicao == "
UFAPE
" ||
$avaliador->user
->instituicao == "
Universidade
Federal
do
Agreste
de
Pernambuco
")
<option value="
{{
$avaliador
->
id
}}
"> {{
$avaliador->user
->name }}
> {{$avaliador->user->instituicao ?? 'Instituição Indefinida'}}
> {{$avaliador->area->nome ?? 'Indefinida'}}
>
{
{$avaliador->user->email}
}
</option>
@endif
@endforeach
@endforeach
</select>
</select>
<
small
id
=
"emailHelp"
class
=
"form-text text-muted"
>
Segure
SHIFT
do
teclado
para
selecionar
mais
de
um
.
</
small
>
<div class="
col
-
md
-
6
">
<label style="
font
-
weight
:
bold
;
font
-
size
:
18
px
"><i>Ad Hoc</i></label>
</div>
<input type="
hidden
" id="
trab
" value="
{{
$trabalho
->
id
}}
">
<input type="
hidden
" id="
oldAvalExterno
"
value="
{{
old
(
'exampleFormControlSelect3'
)
}}
">
<select name="
avaliadores_externos_id
[]
" multiple
class="
form
-
control
" id="
exampleFormControlSelect3
"
style="
height
:
200
px
;
font
-
size
:
15
px
">
@foreach (
$trabalho->avaliadors
as
$avaliador
)
@if(
$avaliador->trabalhos
()->where("
trabalho_id
",
$trabalho->id
)->first()->pivot->acesso == 2 || (
$avaliador->trabalhos
()->where("
trabalho_id
",
$trabalho->id
)->first()->pivot->acesso == null &&
$avaliador->tipo
== "
Interno
"))
<option value="
{{
$avaliador
->
id
}}
">{{
$avaliador->user
->name }}
> {{$avaliador->user->instituicao ?? 'Instituição Indefinida'}}
> {{$avaliador->area->nome ?? 'Indefinida'}}
>
{
{$avaliador->user->email}
}
</option>
@endif
@endforeach
@foreach (
$trabalho->aval
as
$avaliador
)
<option value="
{{
$avaliador
->
id
}}
"> {{
$avaliador->user
->name }}
> {{$avaliador->user->instituicao ?? 'Instituição Indefinida'}}
> {{$avaliador->area->nome ?? 'Indefinida'}}
>
{
{$avaliador->user->email}
}
</option>
@endforeach
</select>
<small id="
emailHelp
" class="
form
-
text
text
-
muted
">Segure SHIFT do
teclado para selecionar mais de um.</small>
</div>
</div>
<div>
<div>
<
button
type
=
"submit"
class
=
"btn btn-info"
style
=
"width: 100%"
>
Atribuir
</
button
>
<button type="
submit
" class="
btn
btn
-
info
" style="
width
:
100
%
">
Atribuir
</button>
</div>
</div>
</form>
</form>
...
@@ -111,7 +204,7 @@
...
@@ -111,7 +204,7 @@
<thead>
<thead>
<tr>
<tr>
<th scope="
col
">Nome do Usuário</th>
<th scope="
col
">Nome do Usuário</th>
<
th
scope
=
"col"
>
Tipo
</
th
>
<th scope="
col
">Tipo
de Avaliação
</th>
<th scope="
col
">E-mail</th>
<th scope="
col
">E-mail</th>
<th scope="
col
">Titulo do projeto</th>
<th scope="
col
">Titulo do projeto</th>
<th scope="
col
">Status avaliação</th>
<th scope="
col
">Status avaliação</th>
...
@@ -119,67 +212,73 @@
...
@@ -119,67 +212,73 @@
</tr>
</tr>
</thead>
</thead>
<tbody>
<tbody>
@
foreach
(
$avaliadores
as
$avaliador
)
@foreach(
$trabalho->avaliadors
as
$avaliador
)
@
php
$contador
=
0
;
@
endphp
{{-- Avaliação Interna --}}
@
foreach
(
$avaliador
->
trabalhos
->
where
(
'evento_id'
,
$evento
->
id
)
as
$trabalho
)
@if((
$avaliador->tipo
== 'Interno' && (
$avaliador->trabalhos
()->where("
trabalho_id
",
$trabalho->id
)->first()->pivot->acesso == null ||
$avaliador->trabalhos
()->where("
trabalho_id
",
$trabalho->id
)->first()->pivot->acesso != 1))
@
if
(
$trabalho
->
pivot
->
status
==
true
)
|| ((
$avaliador->user
->instituicao == "
UFAPE
" ||
$avaliador->user
->instituicao == "
Universidade
Federal
do
Agreste
de
Pernambuco
") &&
$avaliador->tipo
== null && (
$avaliador->trabalhos
()->where("
trabalho_id
",
$trabalho->id
)->first()->pivot->acesso == null ||
$avaliador->trabalhos
()->where("
trabalho_id
",
$trabalho->id
)->first()->pivot->acesso != 1)))
@
php
$contador
++
;
@
endphp
@
endif
<tr>
<tr>
<td>{{
$avaliador->user
->name }}</td>
<td>{{
$avaliador->user
->name }}</td>
<
td
>
{{
$avaliador
->
tipo
}}
</
td
>
<td>
Interno
</td>
<td>{{
$avaliador->user
->email }}</td>
<td>{{
$avaliador->user
->email }}</td>
<td style="
max
-
width
:
100
px
;
overflow
-
x
:
hidden
;
text
-
overflow
:
ellipsis
">{{
$trabalho->titulo
}}</td>
<td style="
max
-
width
:
100
px
;
overflow
-
x
:
hidden
;
text
-
overflow
:
ellipsis
">{{
$trabalho->titulo
}}</td>
{{
--
<
td
>
{{
$contador
}}
/
{{
$avaliador
->
trabalhos
->
where
(
'evento_id'
,
$evento
->
id
)
->
count
()
}}
</
td
>
--
}}
@php
@
if
(
$avaliador
->
tipo
==
"Externo"
||
$avaliador
->
tipo
=
null
)
$parecerInterno
= App\ParecerInterno::where([['avaliador_id',
$avaliador->id
],['trabalho_id',
$trabalho->id
]])->first();
<
td
>@
if
(
$trabalho
->
pivot
->
parecer
==
null
)
Pendente
@
else
Avaliado
@
endif
</
td
>
@endphp
<td>@if(
$parecerInterno
== null) Pendente @else Avaliado @endif</td>
<td>
<td>
<div class="
btn
-
group
dropright
dropdown
-
options
">
<div class="
btn
-
group
dropright
dropdown
-
options
">
<a id="
options
" class="
dropdown
-
toggle
" data-toggle="
dropdown
" aria-haspopup="
true
" aria-expanded="
false
">
<a id="
options
" class="
dropdown
-
toggle
" data-toggle="
dropdown
" aria-haspopup="
true
" aria-expanded="
false
">
<img src="
{{
asset
(
'img/icons/ellipsis-v-solid.svg'
)}}
" style="
width
:
8
px
">
<img src="
{{
asset
(
'img/icons/ellipsis-v-solid.svg'
)}}
" style="
width
:
8
px
">
</a>
</a>
<div class="
dropdown
-
menu
">
<div class="
dropdown
-
menu
">
@
if
(
$trabalho
->
pivot
->
parecer
!=
null
)
@if(
$parecerInterno
!= null)
<
a
href
=
"{{ route('admin.visualizarParecer', ['trabalho_id' =>
$trabalho->id
, 'avaliador_id' =>
$avaliador->id
]) }}"
class
=
"dropdown-item text-center"
>
<a href="
{{
route
(
'admin.visualizarParecer
Interno
'
,
[
'trabalho_id'
=>
$trabalho
->
id
,
'avaliador_id'
=>
$avaliador
->
id
])
}}
" class="
dropdown
-
item
text
-
center
">
Vizualizar Parecer
Vizualizar Parecer
</a>
</a>
@endif
@endif
<
a
href
=
"{{ route('admin.removerProjAval', ['trabalho_id' =>
$trabalho->id
, 'avaliador_id' =>
$avaliador->id
]) }}"
class
=
"dropdown-item text-center"
>
<a href="
{{
route
(
'admin.removerProjAval'
,
[
'trabalho_id'
=>
$trabalho
->
id
,
'avaliador_id'
=>
$avaliador
->
id
,
'flag'
=>
1
])
}}
" class="
dropdown
-
item
text
-
center
">
Desatribuir Avaliador
Desatribuir Avaliador
</a>
</a>
</div>
</div>
</div>
</div>
</td>
</td>
@
else
</tr>
@
php
@endif
$parecer
=
App\ParecerInterno
::
where
([[
'avaliador_id'
,
$avaliador
->
id
],[
'trabalho_id'
,
$trabalho
->
id
]])
->
first
();
@
endphp
{{-- Avaliação Ad Hoc --}}
<
td
>
@if( (
$avaliador->trabalhos
()->where("
trabalho_id
",
$trabalho->id
)->first()->pivot->acesso == null &&
$avaliador->tipo
== "
Externo
") ||
$avaliador->trabalhos
()->where("
trabalho_id
",
$trabalho->id
)->first()->pivot->acesso != 2
@
if
(
$parecer
==
null
)
Pendente
@
else
Avaliado
@
endif
|| ((
$avaliador->user
->instituicao != "
UFAPE
" &&
$avaliador->user
->instituicao != "
Universidade
Federal
do
Agreste
de
Pernambuco
") &&
$avaliador->tipo
== null && (
$avaliador->trabalhos
()->where("
trabalho_id
",
$trabalho->id
)->first()->pivot->acesso == null ||
$avaliador->trabalhos
()->where("
trabalho_id
",
$trabalho->id
)->first()->pivot->acesso != 2)))
</
td
>
<tr>
<td>{{
$avaliador->user
->name }}</td>
<td> Ad Hoc </td>
<td>{{
$avaliador->user
->email }}</td>
<td style="
max
-
width
:
100
px
;
overflow
-
x
:
hidden
;
text
-
overflow
:
ellipsis
">{{
$trabalho->titulo
}}</td>
<td>@if(
$avaliador->trabalhos
->where('id',
$trabalho->id
)->first()->pivot->status == false) Pendente @else Avaliado @endif</td>
<td>
<td>
<div class="
btn
-
group
dropright
dropdown
-
options
">
<div class="
btn
-
group
dropright
dropdown
-
options
">
<a id="
options
" class="
dropdown
-
toggle
" data-toggle="
dropdown
" aria-haspopup="
true
" aria-expanded="
false
">
<a id="
options
" class="
dropdown
-
toggle
" data-toggle="
dropdown
" aria-haspopup="
true
" aria-expanded="
false
">
<img src="
{{
asset
(
'img/icons/ellipsis-v-solid.svg'
)}}
" style="
width
:
8
px
">
<img src="
{{
asset
(
'img/icons/ellipsis-v-solid.svg'
)}}
" style="
width
:
8
px
">
</a>
</a>
<div class="
dropdown
-
menu
">
<div class="
dropdown
-
menu
">
@
if
(
$
parecer
!=
null
)
@if(
$
avaliador->trabalhos
->where('id',
$trabalho->id
)->first()->pivot->status == true
)
<
a
href
=
"{{ route('admin.visualizarParecer
Interno
', ['trabalho_id' =>
$trabalho->id
, 'avaliador_id' =>
$avaliador->id
]) }}"
class
=
"dropdown-item text-center"
>
<a href="
{{
route
(
'admin.visualizarParecer'
,
[
'trabalho_id'
=>
$trabalho
->
id
,
'avaliador_id'
=>
$avaliador
->
id
])
}}
" class="
dropdown
-
item
text
-
center
">
Vizualizar Parecer
Vizualizar Parecer
</a>
</a>
@endif
@endif
<
a
href
=
"{{ route('admin.removerProjAval', ['trabalho_id' =>
$trabalho->id
, 'avaliador_id' =>
$avaliador->id
]) }}"
class
=
"dropdown-item text-center"
>
<a href="
{{
route
(
'admin.removerProjAval'
,
[
'trabalho_id'
=>
$trabalho
->
id
,
'avaliador_id'
=>
$avaliador
->
id
,
'flag'
=>
0
])
}}
" class="
dropdown
-
item
text
-
center
">
Desatribuir Avaliador
Desatribuir Avaliador
</a>
</a>
</div>
</div>
</div>
</div>
</td>
</td>
@
endif
</tr>
</tr>
@endif
@endforeach
@endforeach
@
endforeach
</tbody>
</tbody>
</table>
</table>
...
...
resources/views/avaliacaoRelatorio/index.blade.php
View file @
0d43f2dd
...
@@ -49,6 +49,7 @@
...
@@ -49,6 +49,7 @@
<
th
scope
=
"col"
>
Nome
do
Projeto
</
th
>
<
th
scope
=
"col"
>
Nome
do
Projeto
</
th
>
<
th
scope
=
"col"
>
Nome
do
plano
</
th
>
<
th
scope
=
"col"
>
Nome
do
plano
</
th
>
<
th
scope
=
"col"
>
Discente
</
th
>
<
th
scope
=
"col"
>
Discente
</
th
>
<
th
scope
=
"col"
>
Tipo
do
Relatório
</
th
>
<
th
scope
=
"col"
>
Avaliar
</
th
>
<
th
scope
=
"col"
>
Avaliar
</
th
>
</
tr
>
</
tr
>
...
@@ -60,16 +61,10 @@
...
@@ -60,16 +61,10 @@
<
td
style
=
"max-width:100px; overflow-x:hidden; text-overflow:ellipsis"
>
{{
$avaliacao
->
plano
->
trabalho
->
titulo
}}
</
td
>
<
td
style
=
"max-width:100px; overflow-x:hidden; text-overflow:ellipsis"
>
{{
$avaliacao
->
plano
->
trabalho
->
titulo
}}
</
td
>
<
td
style
=
"max-width:100px; overflow-x:hidden; text-overflow:ellipsis"
>
{{
$avaliacao
->
plano
->
titulo
}}
</
td
>
<
td
style
=
"max-width:100px; overflow-x:hidden; text-overflow:ellipsis"
>
{{
$avaliacao
->
plano
->
titulo
}}
</
td
>
<
td
style
=
"max-width:100px; overflow-x:hidden; text-overflow:ellipsis"
>
{{
$avaliacao
->
plano
->
participante
->
user
->
name
}}
</
td
>
<
td
style
=
"max-width:100px; overflow-x:hidden; text-overflow:ellipsis"
>
{{
$avaliacao
->
plano
->
participante
->
user
->
name
}}
</
td
>
<
td
style
=
"max-width:100px; overflow-x:hidden; text-overflow:ellipsis"
>
{{
$avaliacao
->
tipo
}}
</
td
>
<
td
>
<
td
>
<
div
class
=
"row justify-content-center"
>
<
div
class
=
"row justify-content-center"
>
<
form
action
=
"
{
{route('planos.avaliacoesUser')}
}
"
method
=
"POST"
>
<
a
type
=
"button"
class
=
"btn btn-primary"
href
=
"{{route('planos.avaliacoesUser', ['id'=>
$avaliacao->id
])}}"
>
Avaliar
</
a
>
@
csrf
<
input
type
=
"hidden"
name
=
"trabalho_id"
value
=
"{{
$avaliacao->plano
->trabalho->id }}"
>
<
input
type
=
"hidden"
name
=
"user_id"
value
=
"
{
{Auth::user()->id}
}
"
>
<
button
type
=
"submit"
class
=
"btn btn-primary mr-2 ml-2"
>
Avaliar
</
button
>
</
form
>
</
div
>
</
div
>
</
td
>
</
td
>
...
...
resources/views/avaliacaoRelatorio/listar.blade.php
View file @
0d43f2dd
...
@@ -5,6 +5,11 @@
...
@@ -5,6 +5,11 @@
<
div
class
=
"row justify-content-center"
>
<
div
class
=
"row justify-content-center"
>
<!--
Proponente
Dados
-->
<!--
Proponente
Dados
-->
<
div
class
=
"col-md-10"
style
=
"margin-top:4rem;padding: 0px"
>
<
div
class
=
"col-md-10"
style
=
"margin-top:4rem;padding: 0px"
>
@
if
(
session
(
'sucesso'
))
<
div
class
=
"alert alert-success"
>
<
strong
>
{{
session
(
'sucesso'
)
}}
</
strong
>
</
div
>
@
endif
@
component
(
'projeto.formularioVisualizar.proponente2'
,
[
'projeto'
=>
$trabalho
,
'edital'
=>
$trabalho
->
evento
])
@
component
(
'projeto.formularioVisualizar.proponente2'
,
[
'projeto'
=>
$trabalho
,
'edital'
=>
$trabalho
->
evento
])
@
endcomponent
@
endcomponent
</
div
>
</
div
>
...
@@ -47,34 +52,27 @@
...
@@ -47,34 +52,27 @@
</
div
>
</
div
>
</
div
>
</
div
>
<
div
class
=
"form-row mt-3"
>
<
div
class
=
"form-row mt-3"
>
<
div
class
=
"col-md-12"
><
h5
style
=
"color: #234B8B; font-weight: bold"
>
Plano
s
</
h5
></
div
>
<
div
class
=
"col-md-12"
><
h5
style
=
"color: #234B8B; font-weight: bold"
>
Plano
</
h5
></
div
>
</
div
>
</
div
>
<
hr
style
=
"border-top: 1px solid#1492E6"
>
<
hr
style
=
"border-top: 1px solid#1492E6"
>
{{
--
Anexo
(
s
)
do
Plano
(
s
)
de
Trabalho
--
}}
{{
--
Anexo
(
s
)
do
Plano
(
s
)
de
Trabalho
--
}}
@
foreach
(
$trabalho
->
participantes
as
$participante
)
@
php
$planoTrabalhoTemp
=
App\Arquivo
::
where
(
'participanteId'
,
$participante
->
id
)
->
first
();
$relatorio
=
\
App\AvaliacaoRelatorio
::
where
(
'user_id'
,
auth
()
->
user
()
->
id
)
->
where
(
'arquivo_id'
,
$planoTrabalhoTemp
->
id
)
->
where
(
'tipo'
,
$tipoRelatorio
)
->
first
();
@
endphp
@
if
(
isset
(
$relatorio
))
<
div
class
=
"row"
style
=
"margin-left: 5px"
>
<
div
class
=
"row"
style
=
"margin-left: 5px"
>
<
label
for
=
"anexoProjeto"
class
=
"col-form-label font-tam"
style
=
"font-weight: bold"
<
label
for
=
"anexoProjeto"
class
=
"col-form-label font-tam"
style
=
"font-weight: bold"
title
=
"
{
{$
participante->planoTrabalh
o->titulo}
}
"
>
{{
__
(
'Plano: '
)
}}{{
$
participante
->
planoTrabalh
o
->
titulo
}}
</
label
>
title
=
"
{
{$
avaliacao->plan
o->titulo}
}
"
>
{{
__
(
'Plano: '
)
}}{{
$
avaliacao
->
plan
o
->
titulo
}}
</
label
>
@
if
(
$
planoTrabalhoTemp
!=
null
)
@
if
(
$
avaliacao
->
plano
!=
null
)
<
a
href
=
"{{route('download', ['file' =>
$
planoTrabalhoTemp
])}}"
><
img
<
a
href
=
"{{route('download', ['file' =>
$
avaliacao->plano
->nome
])}}"
><
img
src
=
"
{
{asset('img/icons/pdf.ico')}
}
"
style
=
"width:40px"
alt
=
""
></
a
>
src
=
"
{
{asset('img/icons/pdf.ico')}
}
"
style
=
"width:40px"
alt
=
""
></
a
>
@
endif
@
endif
@
if
(
$
tipoRelatori
o
==
"Parcial"
)
@
if
(
$
avaliacao
->
tip
o
==
"Parcial"
)
<
div
style
=
"margin-left: 25px"
>
<
div
style
=
"margin-left: 25px"
>
<
label
for
=
"anexoProjeto"
class
=
"col-form-label font-tam"
<
label
for
=
"anexoProjeto"
class
=
"col-form-label font-tam"
style
=
"font-weight: bold"
style
=
"font-weight: bold"
>
{{
__
(
'Relatório Parcial: '
)
}}
</
label
>
>
{{
__
(
'Relatório Parcial: '
)
}}
</
label
>
@
if
(
$
participante
->
planoTrabalh
o
->
relatorioParcial
)
@
if
(
$
avaliacao
->
plan
o
->
relatorioParcial
)
<
a
href
=
"{{ route('baixar.documentosParticipante', ['pathDocumento' =>
$
participante->planoTrabalh
o
->relatorioParcial]) }}"
><
i
<
a
href
=
"{{ route('baixar.documentosParticipante', ['pathDocumento' =>
$
avaliacao->plan
o
->relatorioParcial]) }}"
><
i
class
=
"fas fa-file-pdf fa-2x"
></
i
></
a
>
class
=
"fas fa-file-pdf fa-2x"
></
i
></
a
>
@
else
@
else
...
@@ -88,24 +86,21 @@
...
@@ -88,24 +86,21 @@
@
csrf
@
csrf
<
input
type
=
"hidden"
name
=
"tipo"
value
=
"Parcial"
>
<
input
type
=
"hidden"
name
=
"tipo"
value
=
"Parcial"
>
<
input
type
=
"hidden"
name
=
"trabalho_id"
value
=
"
{
{$trabalho->id}
}
"
>
<
input
type
=
"hidden"
name
=
"trabalho_id"
value
=
"
{
{$trabalho->id}
}
"
>
<
input
type
=
"hidden"
name
=
"avaliacao_id"
value
=
"
{
{$
relatori
o->id}
}
"
>
<
input
type
=
"hidden"
name
=
"avaliacao_id"
value
=
"
{
{$
avaliaca
o->id}
}
"
>
<
input
type
=
"hidden"
name
=
"plano_id"
<
input
type
=
"hidden"
name
=
"plano_id"
value
=
"
{
{$
participante->planoTrabalh
o->id}
}
"
>
value
=
"
{
{$
avaliacao->plan
o->id}
}
"
>
<
input
type
=
"hidden"
name
=
"user_id"
value
=
"
{
{Auth::user()->id}
}
"
>
<
input
type
=
"hidden"
name
=
"user_id"
value
=
"
{
{Auth::user()->id}
}
"
>
<
div
class
=
"col-12"
style
=
"padding-left: 0px"
>
<
div
class
=
"col-12"
style
=
"padding-left: 0px"
>
<
div
class
=
"row"
>
<
div
class
=
"row"
>
@
php
$relatParcial
=
App\AvaliacaoRelatorio
::
where
(
'user_id'
,
Auth
::
user
()
->
id
)
->
where
(
'tipo'
,
'Parcial'
)
->
where
(
'arquivo_id'
,
$participante
->
planoTrabalho
->
id
)
->
first
();
@
endphp
<
div
class
=
"col-sm-6 row"
>
<
div
class
=
"col-sm-6 row"
>
<
label
for
=
"lattes"
class
=
"col-form-label font-tam"
<
label
for
=
"lattes"
class
=
"col-form-label font-tam"
style
=
"font-weight: bold;padding-right: 10px"
>
{{
__
(
'Nota: '
)
}}
</
label
>
style
=
"font-weight: bold;padding-right: 10px"
>
{{
__
(
'Nota: '
)
}}
</
label
>
<
input
class
=
"form-control"
name
=
"nota"
type
=
"number"
<
input
class
=
"form-control"
name
=
"nota"
type
=
"number"
style
=
"width: 60px;"
style
=
"width: 60px;"
@
if
(
isset
(
$relatParcial
))
value
=
"
{
{$relatParcial
->nota}
}
"
@
endif
>
@
if
(
$avaliacao
->
nota
!=
null
)
value
=
"
{
{$avaliacao
->nota}
}
"
@
endif
>
</
div
>
</
div
>
</
div
>
</
div
>
<
div
class
=
"row"
style
=
"margin-top: 10px"
>
<
div
class
=
"row"
style
=
"margin-top: 10px"
>
...
@@ -121,16 +116,14 @@
...
@@ -121,16 +116,14 @@
<
div
class
=
"row"
style
=
"margin-top: 10px"
>
<
div
class
=
"row"
style
=
"margin-top: 10px"
>
<
label
for
=
"lattes"
class
=
"col-form-label font-tam"
<
label
for
=
"lattes"
class
=
"col-form-label font-tam"
style
=
"font-weight: bold;margin-right: 5px;"
>
{{
__
(
'Arquivo: '
)
}}
</
label
>
style
=
"font-weight: bold;margin-right: 5px;"
>
{{
__
(
'Arquivo: '
)
}}
</
label
>
@
if
(
isset
(
$relatParcial
))
@
if
(
$avaliacao
->
arquivoAvaliacao
!=
null
)
@
if
(
$relatParcial
->
arquivoAvaliacao
!=
null
)
<
a
href
=
"{{route('download', ['file' =>
$avaliacao->arquivoAvaliacao
])}}"
target
=
"_new"
>
<
a
href
=
"{{route('download', ['file' =>
$relatParcial->arquivoAvaliacao
])}}"
target
=
"_new"
>
<
img
class
=
""
src
=
"
{
{asset('img/icons/pdf.ico')}
}
"
style
=
"width:40px"
>
<
img
class
=
""
src
=
"
{
{asset('img/icons/pdf.ico')}
}
"
style
=
"width:40px"
>
</
a
>
</
a
>
@
endif
@
endif
@
endif
<
input
type
=
"file"
class
=
"input-group-text"
name
=
"avaliacaoArq"
accept
=
".pdf"
id
=
"avaliacaoArq"
required
/>
<
input
type
=
"file"
class
=
"input-group-text"
value
=
""
name
=
"arquivo"
accept
=
".pdf"
id
=
"arquivo"
required
/>
@
error
(
'a
rquivo
'
)
@
error
(
'a
valiacaoArq
'
)
<
span
class
=
"invalid-feedback"
role
=
"alert"
style
=
"overflow: visible; display:block"
>
<
span
class
=
"invalid-feedback"
role
=
"alert"
style
=
"overflow: visible; display:block"
>
<
strong
>
{{
$message
}}
</
strong
>
<
strong
>
{{
$message
}}
</
strong
>
</
span
>
</
span
>
...
@@ -145,14 +138,10 @@
...
@@ -145,14 +138,10 @@
<
textarea
class
=
"col-md-11"
minlength
=
"20"
id
=
"comentario"
<
textarea
class
=
"col-md-11"
minlength
=
"20"
id
=
"comentario"
name
=
"comentario"
name
=
"comentario"
style
=
"border-radius:5px 5px 0 0;height: 71px;"
style
=
"border-radius:5px 5px 0 0;height: 71px;"
required
>@
if
(
isset
(
$relatParcial
)){{
$relatParcial
->
comentario
}}
</
textarea
>@
else
</
textarea
>
@
endif
required
>@
if
(
$avaliacao
->
comentario
!=
null
){{
$avaliacao
->
comentario
}}
@
endif
</
textarea
>
<
div
class
=
"col-md-1"
style
=
"flex: 1;align-self: flex-end;"
>
<
div
class
=
"col-md-1"
style
=
"flex: 1;align-self: flex-end;"
>
<
button
type
=
"submit"
id
=
"id
{
{$participante->user->id}
}
"
<
button
type
=
"submit"
class
=
"btn btn-success"
style
=
"height: 40px"
>
Salvar
</
button
>
name
=
"id
{
{$participante->user->id}
}
"
class
=
"btn btn-success"
style
=
"height: 40px"
>
Salvar
</
button
>
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
...
@@ -162,13 +151,14 @@
...
@@ -162,13 +151,14 @@
{{
--
Relatorio
FInal
--
}}
@
else
@
else
<
div
style
=
"margin-left: 25px"
>
<
div
style
=
"margin-left: 25px"
>
<
label
for
=
"anexoProjeto"
class
=
"col-form-label font-tam"
<
label
for
=
"anexoProjeto"
class
=
"col-form-label font-tam"
style
=
"font-weight: bold"
style
=
"font-weight: bold"
>
{{
__
(
'Relatório Final: '
)
}}
</
label
>
>
{{
__
(
'Relatório Final: '
)
}}
</
label
>
@
if
(
$
participante
->
planoTrabalh
o
->
relatorioFinal
)
@
if
(
$
avaliacao
->
plan
o
->
relatorioFinal
)
<
a
href
=
"{{ route('baixar.documentosParticipante', ['pathDocumento' =>
$
participante->planoTrabalh
o
->relatorioFinal]) }}"
><
i
<
a
href
=
"{{ route('baixar.documentosParticipante', ['pathDocumento' =>
$
avaliacao->plan
o
->relatorioFinal]) }}"
><
i
class
=
"fas fa-file-pdf fa-2x"
></
i
></
a
>
class
=
"fas fa-file-pdf fa-2x"
></
i
></
a
>
@
else
@
else
<
a
><
i
class
=
"fas fa-times-circle fa-2x"
></
i
></
a
>
<
a
><
i
class
=
"fas fa-times-circle fa-2x"
></
i
></
a
>
...
@@ -181,37 +171,34 @@
...
@@ -181,37 +171,34 @@
@
csrf
@
csrf
<
input
type
=
"hidden"
name
=
"tipo"
value
=
"Final"
>
<
input
type
=
"hidden"
name
=
"tipo"
value
=
"Final"
>
<
input
type
=
"hidden"
name
=
"trabalho_id"
value
=
"
{
{$trabalho->id}
}
"
>
<
input
type
=
"hidden"
name
=
"trabalho_id"
value
=
"
{
{$trabalho->id}
}
"
>
<
input
type
=
"hidden"
name
=
"avaliacao_id"
value
=
"
{
{$
relatori
o->id}
}
"
>
<
input
type
=
"hidden"
name
=
"avaliacao_id"
value
=
"
{
{$
avaliaca
o->id}
}
"
>
<
input
type
=
"hidden"
name
=
"plano_id"
<
input
type
=
"hidden"
name
=
"plano_id"
value
=
"
{
{$
participante->planoTrabalh
o->id}
}
"
>
value
=
"
{
{$
avaliacao->plan
o->id}
}
"
>
<
input
type
=
"hidden"
name
=
"user_id"
value
=
"
{
{Auth::user()->id}
}
"
>
<
input
type
=
"hidden"
name
=
"user_id"
value
=
"
{
{Auth::user()->id}
}
"
>
<
div
class
=
"col-12"
style
=
"padding-left: 0px"
>
<
div
class
=
"col-12"
style
=
"padding-left: 0px"
>
<
div
class
=
"row"
>
<
div
class
=
"row"
>
@
php
$relatFinal
=
App\AvaliacaoRelatorio
::
where
(
'user_id'
,
Auth
::
user
()
->
id
)
->
where
(
'tipo'
,
'Final'
)
->
where
(
'arquivo_id'
,
$participante
->
planoTrabalho
->
id
)
->
first
();
@
endphp
<
div
class
=
"col-sm-6 row"
>
<
div
class
=
"col-sm-6 row"
>
<
label
for
=
"lattes"
class
=
"col-form-label font-tam"
<
label
for
=
"lattes"
class
=
"col-form-label font-tam"
style
=
"font-weight: bold;padding-right: 10px"
>
{{
__
(
'Nota: '
)
}}
</
label
>
style
=
"font-weight: bold;padding-right: 10px"
>
{{
__
(
'Nota: '
)
}}
</
label
>
<
input
class
=
"form-control"
name
=
"nota"
type
=
"number"
<
input
class
=
"form-control"
name
=
"nota"
type
=
"number"
style
=
"width: 60px;"
style
=
"width: 60px;"
@
if
(
isset
(
$relatFinal
)
)
value
=
"
{
{$
relatFinal
->nota}
}
"
@
endif
>
@
if
(
$avaliacao
->
nota
!=
null
)
value
=
"
{
{$
avaliacao
->nota}
}
"
@
endif
>
</
div
>
</
div
>
</
div
>
</
div
>
<
div
class
=
"row"
style
=
"margin-top: 10px"
>
<
div
class
=
"row"
style
=
"margin-top: 10px"
>
<
label
for
=
"lattes"
class
=
"col-form-label font-tam"
<
label
for
=
"lattes"
class
=
"col-form-label font-tam"
style
=
"font-weight: bold;margin-right: 5px;"
>
{{
__
(
'Arquivo: '
)
}}
</
label
>
style
=
"font-weight: bold;margin-right: 5px;"
>
{{
__
(
'Arquivo: '
)
}}
</
label
>
@
if
(
isset
(
$relatFinal
))
@
if
(
$
relatFinal
->
arquivoAvaliacao
!=
null
)
@
if
(
$
avaliacao
->
arquivoAvaliacao
!=
null
)
<
a
href
=
"{{route('download', ['file' =>
$
relatFinal
->arquivoAvaliacao
])}}"
target
=
"_new"
>
<
a
href
=
"{{route('download', ['file' =>
$
avaliacao
->arquivoAvaliacao
])}}"
target
=
"_new"
>
<
img
class
=
""
src
=
"
{
{asset('img/icons/pdf.ico')}
}
"
style
=
"width:40px"
>
<
img
class
=
""
src
=
"
{
{asset('img/icons/pdf.ico')}
}
"
style
=
"width:40px"
>
</
a
>
</
a
>
@
endif
@
endif
@
endif
<
input
type
=
"file"
class
=
"input-group-text"
value
=
""
name
=
"avaliacaoArq"
accept
=
".pdf"
id
=
"avaliacaoArq"
required
/>
<
input
type
=
"file"
class
=
"input-group-text"
name
=
"avaliacaoArq"
accept
=
".pdf"
id
=
"avaliacaoArq"
required
/>
@
error
(
'avaliacaoArq'
)
@
error
(
'avaliacaoArq'
)
<
span
class
=
"invalid-feedback"
role
=
"alert"
style
=
"overflow: visible; display:block"
>
<
span
class
=
"invalid-feedback"
role
=
"alert"
style
=
"overflow: visible; display:block"
>
<
strong
>
{{
$message
}}
</
strong
>
<
strong
>
{{
$message
}}
</
strong
>
...
@@ -227,14 +214,10 @@
...
@@ -227,14 +214,10 @@
<
textarea
class
=
"col-md-11"
minlength
=
"20"
id
=
"comentario"
<
textarea
class
=
"col-md-11"
minlength
=
"20"
id
=
"comentario"
name
=
"comentario"
name
=
"comentario"
style
=
"border-radius:5px 5px 0 0;height: 71px;"
style
=
"border-radius:5px 5px 0 0;height: 71px;"
required
>@
if
(
isset
(
$relatFinal
)){{
$relatFinal
->
comentario
}}
</
textarea
>@
else
</
textarea
>
@
endif
required
>@
if
(
$avaliacao
->
comentario
){{
$avaliacao
->
comentario
}}
@
endif
</
textarea
>
<
div
class
=
"col-md-1"
style
=
"flex: 1;align-self: flex-end;"
>
<
div
class
=
"col-md-1"
style
=
"flex: 1;align-self: flex-end;"
>
<
button
type
=
"submit"
id
=
"id
{
{$participante->user->id}
}
"
<
button
type
=
"submit"
class
=
"btn btn-success"
style
=
"height: 40px"
>
Salvar
</
button
>
name
=
"id
{
{$participante->user->id}
}
"
class
=
"btn btn-success"
style
=
"height: 40px"
>
Salvar
</
button
>
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
...
@@ -243,10 +226,9 @@
...
@@ -243,10 +226,9 @@
</
div
>
</
div
>
@
endif
@
endif
</
div
>
</
div
>
@
endif
<
div
class
=
"row"
style
=
"margin-left: 0px"
>
<
div
class
=
"row"
style
=
"margin-left: 0px"
>
</
div
>
</
div
>
@
endforeach
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
...
...
routes/web.php
View file @
0d43f2dd
...
@@ -54,7 +54,7 @@ Route::group(['middleware' => ['isTemp', 'auth', 'verified']], function(){
...
@@ -54,7 +54,7 @@ Route::group(['middleware' => ['isTemp', 'auth', 'verified']], function(){
Route
::
post
(
'/atribuirAvaliadorPlano'
,
'AvaliacaoRelatorioController@atribuicaoAvaliador'
)
->
name
(
'atribuicao.avaliador'
)
->
middleware
(
'checkRoles:coordenador,administrador'
);
Route
::
post
(
'/atribuirAvaliadorPlano'
,
'AvaliacaoRelatorioController@atribuicaoAvaliador'
)
->
name
(
'atribuicao.avaliador'
)
->
middleware
(
'checkRoles:coordenador,administrador'
);
Route
::
get
(
'/removerAvaliadorPlano/{id}'
,
'AvaliacaoRelatorioController@removerAvaliador'
)
->
name
(
'remover.avaliador'
)
->
middleware
(
'checkRoles:coordenador,administrador'
);
Route
::
get
(
'/removerAvaliadorPlano/{id}'
,
'AvaliacaoRelatorioController@removerAvaliador'
)
->
name
(
'remover.avaliador'
)
->
middleware
(
'checkRoles:coordenador,administrador'
);
});
});
Route
::
pos
t
(
'/trabalho/planos/avaliac
oes
'
,
'AvaliacaoRelatorioController@listarUser'
)
->
name
(
'planos.avaliacoesUser'
);
Route
::
ge
t
(
'/trabalho/planos/avaliac
ao/{id}
'
,
'AvaliacaoRelatorioController@listarUser'
)
->
name
(
'planos.avaliacoesUser'
);
Route
::
get
(
'/trabalho/planos/avaliacoes/index'
,
'AvaliacaoRelatorioController@index'
)
->
name
(
'planos.avaliacoes.index'
);
Route
::
get
(
'/trabalho/planos/avaliacoes/index'
,
'AvaliacaoRelatorioController@index'
)
->
name
(
'planos.avaliacoes.index'
);
Route
::
post
(
'/trabalho/planos/avaliacoes/criar'
,
'AvaliacaoRelatorioController@criar'
)
->
name
(
'planos.avaliacoesUser.criar'
);
Route
::
post
(
'/trabalho/planos/avaliacoes/criar'
,
'AvaliacaoRelatorioController@criar'
)
->
name
(
'planos.avaliacoesUser.criar'
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment