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
2bec30d5
Commit
2bec30d5
authored
Apr 12, 2023
by
Yuri Resende
Browse files
Resolvendo conflitos
parent
ac403a6d
Changes
3
Hide whitespace changes
Inline
Side-by-side
app/Http/Controllers/AdministradorController.php
View file @
2bec30d5
...
...
@@ -112,88 +112,87 @@ class AdministradorController extends Controller
return
view
(
'administrador.analisar'
)
->
with
([
'trabalhos'
=>
$trabalhos
,
'evento'
=>
$evento
,
'funcaoParticipantes'
=>
$funcaoParticipantes
,
'column'
=>
$request
->
column
,
'grandesAreas'
=>
$grandesAreas
,
'areas'
=>
$areas
]);
}
// Utilizado para paginação de Collection
public
function
analisarProposta
(
Request
$request
)
{
$trabalho
=
Trabalho
::
where
(
'id'
,
$request
->
id
)
->
first
();
$evento
=
Evento
::
where
(
'id'
,
$trabalho
->
evento_id
)
->
first
();
$funcaoParticipantes
=
FuncaoParticipantes
::
all
();
$substituicoesProjeto
=
Substituicao
::
where
(
'trabalho_id'
,
$trabalho
->
id
)
->
orderBy
(
'created_at'
,
'DESC'
)
->
get
();
$substituicoesPendentes
=
Substituicao
::
where
(
'trabalho_id'
,
$trabalho
->
id
)
->
where
(
'status'
,
'Em Aguardo'
)
->
orderBy
(
'created_at'
,
'DESC'
)
->
get
();
$avalSelecionadosId
=
$trabalho
->
avaliadors
->
pluck
(
'id'
);
$avalProjeto
=
Avaliador
::
whereNotIn
(
'id'
,
$avalSelecionadosId
)
->
get
();
$trabalho
->
aval
=
$avalProjeto
;
// Usuarios que possuem avaliações de relatório
//$avaliacoesRelatorio = [];->join('users','users.id','=','candidatos.user_id')
//retorna a média das avaliações dos relatórios e apresentações,
//o número de avaliações pendentes e duas listas com as avaliações parciais
//e finais respectivamente
protected
function
get_info_avaliacoes
(
$avals
){
$AvalRelatParcial
=
[];
$AvalRelatFinal
=
[];
$MediaAvalRelatParcial
=
0
;
$MediaApresentacaoParcial
=
0
;
$AvalRelatParcialPendentes
=
0
;
$MediaAvalRelatFinal
=
0
;
$MediaApresentacaoFinal
=
0
;
$AvalRelatFinalPendentes
=
0
;
if
(
$evento
->
numParticipantes
==
0
)
{
$arquivo
=
Arquivo
::
where
(
"trabalhoId"
,
$trabalho
->
id
)
->
first
();
if
(
isset
(
$arquivo
))
{
$avals
=
AvaliacaoRelatorio
::
where
(
'arquivo_id'
,
$arquivo
->
id
)
->
get
();
}
else
{
$avals
=
[];
}
foreach
(
$avals
as
$aval
)
{
if
(
$aval
->
tipo
==
'Parcial'
)
{
array_push
(
$AvalRelatParcial
,
$aval
);
$MediaAvalRelatParcial
+=
$aval
->
nota
;
foreach
(
$avals
as
$aval
)
{
if
(
$aval
->
tipo
==
'Parcial'
)
{
array_push
(
$AvalRelatParcial
,
$aval
);
$MediaAvalRelatParcial
+=
$aval
->
nota
;
$MediaApresentacaoParcial
+=
$aval
->
nota_apresentacao
;
if
(
$aval
->
nota
==
null
){
$AvalRelatParcialPendentes
+=
1
;
}
}
else
{
array_push
(
$AvalRelatFinal
,
$aval
);
$MediaAvalRelatFinal
+=
$aval
->
nota
;
if
(
$aval
->
nota
==
null
){
$AvalRelatFinalPendentes
+=
1
;
}
if
(
$aval
->
nota
==
null
){
$AvalRelatParcialPendentes
+=
1
;
}
}
}
foreach
(
$trabalho
->
participantes
as
$participante
)
{
if
(
isset
(
$participante
->
planoTrabalho
))
{
$avals
=
AvaliacaoRelatorio
::
where
(
'arquivo_id'
,
$participante
->
planoTrabalho
->
id
)
->
get
();
}
else
{
$avals
=
[];
}
foreach
(
$avals
as
$aval
)
{
if
(
$aval
->
tipo
==
'Parcial'
)
{
array_push
(
$AvalRelatParcial
,
$aval
);
$MediaAvalRelatParcial
+=
$aval
->
nota
;
array_push
(
$AvalRelatFinal
,
$aval
);
$MediaAvalRelatFinal
+=
$aval
->
nota
;
$MediaApresentacaoFinal
+=
$aval
->
nota_apresentacao
;
if
(
$aval
->
nota
==
null
){
$AvalRelatParcialPendentes
+=
1
;
}
}
else
{
array_push
(
$AvalRelatFinal
,
$aval
);
$MediaAvalRelatFinal
+=
$aval
->
nota
;
if
(
$aval
->
nota
==
null
){
$AvalRelatFinalPendentes
+=
1
;
}
if
(
$aval
->
nota
==
null
){
$AvalRelatFinalPendentes
+=
1
;
}
}
}
if
(
count
(
$AvalRelatParcial
)
>
0
){
$MediaAvalRelatParcial
=
$MediaAvalRelatParcial
/
count
(
$AvalRelatParcial
);
$MediaApresentacaoParcial
=
$MediaApresentacaoParcial
/
count
(
$AvalRelatParcial
);
}
if
(
count
(
$AvalRelatFinal
)
>
0
){
$MediaAvalRelatFinal
=
$MediaAvalRelatFinal
/
count
(
$AvalRelatFinal
);
$MediaApresentacaoFinal
=
$MediaApresentacaoFinal
/
count
(
$AvalRelatFinal
);
}
return
[
'relatorio_parcial'
=>
number_format
(
$MediaAvalRelatParcial
,
2
,
'.'
,
''
),
'apresentacao_parcial'
=>
number_format
(
$MediaApresentacaoParcial
,
2
,
'.'
,
''
),
'pendentes_parcial'
=>
$AvalRelatParcialPendentes
,
'relatorio_final'
=>
number_format
(
$MediaAvalRelatFinal
,
2
,
'.'
,
''
),
'apresentacao_final'
=>
number_format
(
$MediaApresentacaoFinal
,
2
,
'.'
,
''
),
'pendentes_final'
=>
$AvalRelatFinalPendentes
,
'avaliacoes_parciais'
=>
$AvalRelatParcial
,
'avaliacoes_finais'
=>
$AvalRelatFinal
];
}
// Utilizado para paginação de Collection
public
function
analisarProposta
(
Request
$request
)
{
$trabalho
=
Trabalho
::
where
(
'id'
,
$request
->
id
)
->
first
();
$evento
=
Evento
::
where
(
'id'
,
$trabalho
->
evento_id
)
->
first
();
$funcaoParticipantes
=
FuncaoParticipantes
::
all
();
$substituicoesProjeto
=
Substituicao
::
where
(
'trabalho_id'
,
$trabalho
->
id
)
->
orderBy
(
'created_at'
,
'DESC'
)
->
get
();
$substituicoesPendentes
=
Substituicao
::
where
(
'trabalho_id'
,
$trabalho
->
id
)
->
where
(
'status'
,
'Em Aguardo'
)
->
orderBy
(
'created_at'
,
'DESC'
)
->
get
();
$avalSelecionadosId
=
$trabalho
->
avaliadors
->
pluck
(
'id'
);
$avalProjeto
=
Avaliador
::
whereNotIn
(
'id'
,
$avalSelecionadosId
)
->
get
();
$trabalho
->
aval
=
$avalProjeto
;
// Usuarios que possuem avaliações de relatório
//$avaliacoesRelatorio = [];->join('users','users.id','=','candidatos.user_id')
$arquivos
=
Arquivo
::
where
(
"trabalhoId"
,
$trabalho
->
id
)
->
get
();
$avals_projeto
=
[];
$media_avaliacoes
=
[];
if
(
isset
(
$arquivos
))
{
foreach
(
$arquivos
as
$arquivo
)
{
array_push
(
$avals_projeto
,
AvaliacaoRelatorio
::
where
(
'arquivo_id'
,
$arquivo
->
id
)
->
get
());
}
}
foreach
(
$avals_projeto
as
$avals
)
{
array_push
(
$media_avaliacoes
,
$this
->
get_info_avaliacoes
(
$avals
));
}
// Verficação de pendencia de substituição
...
...
@@ -209,7 +208,7 @@ class AdministradorController extends Controller
$hoje
=
Carbon
::
today
(
'America/Recife'
);
$hoje
=
$hoje
->
toDateString
();
//dd($media_avaliacoes, $arquivos);
return
view
(
'administrador.analisarProposta'
)
->
with
(
[
'trabalho'
=>
$trabalho
,
'funcaoParticipantes'
=>
$funcaoParticipantes
,
...
...
@@ -217,15 +216,11 @@ class AdministradorController extends Controller
'substituicoesPendentes'
=>
$substituicoesPendentes
,
'substituicoesProjeto'
=>
$substituicoesProjeto
,
'grandeAreas'
=>
$grandeAreas
,
'AvalRelatParcial'
=>
$AvalRelatParcial
,
'AvalRelatFinal'
=>
$AvalRelatFinal
,
'hoje'
=>
$hoje
,
'flagSubstituicao'
=>
$flagSubstituicao
,
'areasTematicas'
=>
$areasTematicas
,
'MediaAvalRelatParcial'
=>
$MediaAvalRelatParcial
,
'AvalRelatParcialPendentes'
=>
$AvalRelatParcialPendentes
,
'MediaAvalRelatFinal'
=>
$MediaAvalRelatFinal
,
'AvalRelatFinalPendentes'
=>
$AvalRelatFinalPendentes
,
'areasTematicas'
=>
$areasTematicas
,
'mediaAval'
=>
$media_avaliacoes
,
'arquivos'
=>
$arquivos
,
]);
}
...
...
@@ -1302,4 +1297,4 @@ class AdministradorController extends Controller
return
$pdf
->
setPaper
(
'a4'
)
->
stream
(
'Resultados.pdf'
);
}
}
\ No newline at end of file
}
resources/views/administrador/analisarProposta.blade.php
View file @
2bec30d5
...
...
@@ -738,153 +738,171 @@
</
div
>
<
hr
style
=
"border-top: 1px solid#1492E6"
>
@
if
(
count
(
$AvalRelatParcial
)
>
0
)
<
div
class
=
"row justify-content-start"
style
=
"alignment: center"
>
<
div
class
=
"col-md-11"
><
h6
style
=
"color: #234B8B; font-weight: bold"
>
Avaliações
de
Relatórios
Parciais
</
h6
></
div
>
</
div
>
<
div
class
=
'row justify-content-start'
>
<
h6
class
=
'col-9'
style
=
"color: black; font-weight: bold"
>
Media
das
avaliações
:<
span
style
=
"font-weight: normal"
>
{{
$MediaAvalRelatParcial
}}
</
span
><
h6
>
<
h6
class
=
'col-3'
style
=
"color: black; font-weight: bold"
>
Avaliações
pendentes
:
<
span
style
=
"font-weight: normal"
>
{{
$AvalRelatParcialPendentes
}}
</
span
><
h6
>
<
br
><
br
>
</
div
>
<
div
class
=
"row justify-content-start"
style
=
"alignment: center"
>
@
foreach
(
$AvalRelatParcial
as
$aval
)
<
div
class
=
"col-sm-1"
style
=
"margin-bottom: 7px"
>
<
img
src
=
"
{
{asset('img/icons/usuario.svg')}
}
"
style
=
"width:60px"
alt
=
""
>
</
div
>
<
div
class
=
"col-sm-3"
>
<
h5
>
{{
\
App\User
::
find
(
$aval
->
user_id
)
->
name
}}
</
h5
>
<
h6
><
a
href
=
""
data
-
toggle
=
"modal"
data
-
target
=
"#modalVizuRelatParcial
{
{$aval->id}
}
"
class
=
"button"
>
@
if
(
$aval
->
nota
==
null
)
Pendente
</
a
>@
else
Avaliação
</
a
>
@
endif
</
h6
>
@
if
(
$aval
->
nota
==
null
)
<
h6
><
a
href
=
""
data
-
toggle
=
"modal"
data
-
target
=
"#removerAvaliadorReltorioParcial
{
{$aval->id}
}
"
class
=
"button"
><
b
style
=
"color: red"
>
Remover
</
b
></
a
></
h6
>
@
endif
@
if
(
count
(
$arquivos
)
>
0
)
<
div
class
=
"row justify-content-start"
style
=
"alignment: center"
>
<
div
class
=
"col-md-11"
><
h6
style
=
"color: #234B8B; font-weight: bold"
>
Avaliações
de
Relatórios
Parciais
</
h6
></
div
>
</
div
>
@
for
(
$i
=
0
;
$i
<
count
(
$arquivos
);
$i
++
)
<
div
class
=
'row justify-content-start'
style
=
'margin-top:40px;'
>
<
h6
class
=
'col-4'
style
=
"color: black; font-weight: bold"
>
Título
:<
span
style
=
"font-weight: normal"
>
{{
$arquivos
[
$i
]
->
titulo
}}
</
span
><
h6
>
<
h6
class
=
'col-9'
style
=
"color: black; font-weight: bold"
>
Média
das
avaliações
:<
span
style
=
"font-weight: normal"
>
{{
$mediaAval
[
$i
][
'relatorio_parcial'
]}}
</
span
><
h6
>
<
h6
class
=
'col-4'
style
=
"color: black; font-weight: bold"
>
Média
da
apresentação
:<
span
style
=
"font-weight: normal"
>
{{
$mediaAval
[
$i
][
'apresentacao_parcial'
]}}
</
span
><
h6
>
<
h6
class
=
'col-3'
style
=
"color: black; font-weight: bold"
>
Avaliações
pendentes
:
<
span
style
=
"font-weight: normal"
>
{{
$mediaAval
[
$i
][
'pendentes_parcial'
]}}
</
span
><
h6
>
<
br
><
br
>
</
div
>
<
div
class
=
"row justify-content-start"
style
=
"alignment: center"
>
@
foreach
(
$mediaAval
[
$i
][
'avaliacoes_parciais'
]
as
$aval
)
<
div
class
=
"col-sm-1"
style
=
"margin-bottom: 7px"
>
<
img
src
=
"
{
{asset('img/icons/usuario.svg')}
}
"
style
=
"width:60px"
alt
=
""
>
</
div
>
<
div
class
=
"col-sm-3"
>
<
h5
>
{{
\
App\User
::
find
(
$aval
->
user_id
)
->
name
}}
</
h5
>
<
h6
><
a
href
=
""
data
-
toggle
=
"modal"
data
-
target
=
"#modalVizuRelatParcial
{
{$aval->id}
}
"
class
=
"button"
>
@
if
(
$aval
->
nota
==
null
)
Pendente
</
a
>@
else
Avaliação
</
a
>
@
endif
</
h6
>
@
if
(
$aval
->
nota
==
null
)
<
h6
><
a
href
=
""
data
-
toggle
=
"modal"
data
-
target
=
"#removerAvaliadorReltorioParcial
{
{$aval->id}
}
"
class
=
"button"
><
b
style
=
"color: red"
>
Remover
</
b
></
a
></
h6
>
@
endif
</
div
>
<!--
Modal
Remover
-->
<
div
class
=
"modal fade"
id
=
"removerAvaliadorReltorioParcial{{
$aval->id
}}"
tabindex
=
"-1"
role
=
"dialog"
aria
-
labelledby
=
"exampleModalLabel"
aria
-
hidden
=
"true"
>
<
div
class
=
"modal-dialog modal-lg"
>
<
div
class
=
"modal-content"
>
<
div
class
=
"modal-header"
>
<
h5
class
=
"modal-title"
id
=
"exampleModalLabel"
>
Remover
Avaliador
Do
Relatório
Parcial
</
h5
>
<
button
type
=
"button"
class
=
"close"
data
-
dismiss
=
"modal"
aria
-
label
=
"Close"
>
<
span
aria
-
hidden
=
"true"
>&
times
;
</
span
>
</
button
>
</
div
>
<
div
class
=
"modal-body"
>
<
p
>
Você
tem
certeza
que
deseja
remover
o
avaliador
:
{{
$aval
->
user
->
name
}}
?</
p
>
</
div
>
<
div
class
=
"modal-footer"
>
<
button
type
=
"button"
class
=
"btn btn-secondary"
data
-
dismiss
=
"modal"
>
Cancelar
</
button
>
<
a
type
=
"button"
class
=
"btn btn-danger"
href
=
"
{
{route('avaliacaoRelatorio.remover.avaliador',$aval->id)}
}
"
>
Remover
</
a
>
<!--
Modal
Remover
-->
<
div
class
=
"modal fade"
id
=
"removerAvaliadorReltorioParcial{{
$aval->id
}}"
tabindex
=
"-1"
role
=
"dialog"
aria
-
labelledby
=
"exampleModalLabel"
aria
-
hidden
=
"true"
>
<
div
class
=
"modal-dialog modal-lg"
>
<
div
class
=
"modal-content"
>
<
div
class
=
"modal-header"
>
<
h5
class
=
"modal-title"
id
=
"exampleModalLabel"
>
Remover
Avaliador
Do
Relatório
Parcial
</
h5
>
<
button
type
=
"button"
class
=
"close"
data
-
dismiss
=
"modal"
aria
-
label
=
"Close"
>
<
span
aria
-
hidden
=
"true"
>&
times
;
</
span
>
</
button
>
</
div
>
<
div
class
=
"modal-body"
>
<
p
>
Você
tem
certeza
que
deseja
remover
o
avaliador
:
{{
$aval
->
user
->
name
}}
?</
p
>
</
div
>
<
div
class
=
"modal-footer"
>
<
button
type
=
"button"
class
=
"btn btn-secondary"
data
-
dismiss
=
"modal"
>
Cancelar
</
button
>
<
a
type
=
"button"
class
=
"btn btn-danger"
href
=
"
{
{route('avaliacaoRelatorio.remover.avaliador',$aval->id)}
}
"
>
Remover
</
a
>
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
<!--
Modal
visualizar
informações
participante
-->
<
div
class
=
"modal fade"
id
=
"modalVizuRelatParcial
{
{$aval->id}
}
"
tabindex
=
"-1"
role
=
"dialog"
aria
-
labelledby
=
"exampleModalLabel"
aria
-
hidden
=
"true"
>
<
div
class
=
"modal-dialog modal-dialog-centered modal-lg"
>
<
div
class
=
"modal-content"
>
<!--
Modal
visualizar
informações
participante
-->
<
div
class
=
"modal fade"
id
=
"modalVizuRelatParcial
{
{$aval->id}
}
"
tabindex
=
"-1"
role
=
"dialog"
aria
-
labelledby
=
"exampleModalLabel"
aria
-
hidden
=
"true"
>
<
div
class
=
"modal-dialog modal-dialog-centered modal-lg"
>
<
div
class
=
"modal-content"
>
<
div
class
=
"modal-header"
style
=
"overflow-x:auto; padding-left: 31px"
>
<
h5
class
=
"modal-title"
id
=
"exampleModalLabel"
style
=
"color:#1492E6"
>
Avaliação
do
relatório
parcial
@
if
(
$aval
->
nota
==
null
)
<
b
style
=
"color: red"
>
Pendente
</
b
>@
endif
</
h5
>
<
div
class
=
"modal-header"
style
=
"overflow-x:auto; padding-left: 31px"
>
<
h5
class
=
"modal-title"
id
=
"exampleModalLabel"
style
=
"color:#1492E6"
>
Avaliação
do
relatório
parcial
@
if
(
$aval
->
nota
==
null
)
<
b
style
=
"color: red"
>
Pendente
</
b
>@
endif
</
h5
>
<
button
type
=
"button"
class
=
"close"
data
-
dismiss
=
"modal"
aria
-
label
=
"Close"
style
=
"padding-top: 8px; color:#1492E6"
>
<
span
aria
-
hidden
=
"true"
>&
times
;
</
span
>
</
button
>
</
div
>
<
button
type
=
"button"
class
=
"close"
data
-
dismiss
=
"modal"
aria
-
label
=
"Close"
style
=
"padding-top: 8px; color:#1492E6"
>
<
span
aria
-
hidden
=
"true"
>&
times
;
</
span
>
</
button
>
</
div
>
<
div
class
=
"modal-body"
style
=
"padding-right: 32px;padding-left: 32px;padding-top: 20px;padding-bottom: 32px;"
>
@
include
(
'avaliacaoRelatorio.avaliacao'
,
[
'avaliacao'
=>
$aval
])
<
div
class
=
"modal-body"
style
=
"padding-right: 32px;padding-left: 32px;padding-top: 20px;padding-bottom: 32px;"
>
@
include
(
'avaliacaoRelatorio.avaliacao'
,
[
'avaliacao'
=>
$aval
])
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
@
endforeach
</
div
>
@
endforeach
</
div
>
@
endfor
@
endif
@
if
(
count
(
$AvalRelatFinal
)
>
0
)
<
div
class
=
"row justify-content-start"
style
=
"alignment: center"
>
<
div
class
=
"col-md-11"
><
h6
style
=
"color: #234B8B; font-weight: bold"
>
Avaliações
de
Relatórios
Finais
</
h6
></
div
>
</
div
>
<
div
class
=
'row justify-content-start'
>
<
h6
class
=
'col-9'
style
=
"color: black; font-weight: bold"
>
Media
das
avaliações
:<
span
style
=
"font-weight: normal"
>
{{
$MediaAvalRelatFinal
}}
</
span
><
h6
>
<
h6
class
=
'col-3'
style
=
"color: black; font-weight: bold"
>
Avaliações
pendentes
:
<
span
style
=
"font-weight: normal"
>
{{
$AvalRelatFinalPendentes
}}
</
span
><
h6
>
<
br
><
br
>
</
div
>
<
div
class
=
"row justify-content-start"
style
=
"alignment: center"
>
@
foreach
(
$AvalRelatFinal
as
$aval
)
<
div
class
=
"col-sm-1"
style
=
"margin-bottom: 7px"
>
<
img
src
=
"
{
{asset('img/icons/usuario.svg')}
}
"
style
=
"width:60px"
alt
=
""
>
</
div
>
<
div
class
=
"col-sm-3"
>
<
h5
>
{{
\
App\User
::
find
(
$aval
->
user_id
)
->
name
}}
</
h5
>
<
h6
><
a
href
=
""
data
-
toggle
=
"modal"
data
-
target
=
"#modalVizuRelatFinal
{
{$aval->id}
}
"
class
=
"button"
>
@
if
(
$aval
->
nota
==
null
)
Pendente
</
a
>@
else
Avaliação
</
a
>
@
endif
</
h6
>
@
if
(
$aval
->
nota
==
null
)
<
h6
><
a
href
=
""
data
-
toggle
=
"modal"
data
-
target
=
"#removerAvaliadorReltorioFinal
{
{$aval->id}
}
"
class
=
"button"
><
b
style
=
"color: red"
>
Remover
</
b
></
a
></
h6
>
@
endif
@
if
(
count
(
$arquivos
)
>
0
)
@
foreach
(
$mediaAval
as
$aval
)
@
if
(
count
(
$aval
[
'avaliacoes_finais'
])
>
0
)
<
br
><
hr
style
=
"border-top: 1px solid#1492E6"
>
<
div
class
=
"row justify-content-start"
style
=
"alignment: center"
>
<
div
class
=
"col-md-11"
><
h6
style
=
"color: #234B8B; font-weight: bold"
>
Avaliações
de
Relatórios
Finais
</
h6
></
div
>
</
div
>
@
for
(
$i
=
0
;
$i
<
count
(
$arquivos
);
$i
++
)
<
div
class
=
'row justify-content-start'
style
=
'margin-top:40px;'
>
<
h6
class
=
'col-4'
style
=
"color: black; font-weight: bold"
>
Título
:<
span
style
=
"font-weight: normal"
>
{{
$arquivos
[
$i
]
->
titulo
}}
</
span
><
h6
>
</
div
>
<
div
class
=
'row justify-content-start'
>
<
h6
class
=
'col-4'
style
=
"color: black; font-weight: bold"
>
Média
das
avaliações
:<
span
style
=
"font-weight: normal"
>
{{
$mediaAval
[
$i
][
'relatorio_final'
]}}
</
span
><
h6
>
<
h6
class
=
'col-4'
style
=
"color: black; font-weight: bold"
>
Média
da
apresentação
:<
span
style
=
"font-weight: normal"
>
{{
$mediaAval
[
$i
][
'apresentacao_final'
]}}
</
span
><
h6
>
<
h6
class
=
'col-3'
style
=
"color: black; font-weight: bold"
>
Avaliações
pendentes
:
<
span
style
=
"font-weight: normal"
>
{{
$mediaAval
[
$i
][
'pendentes_final'
]}}
</
span
><
h6
>
<
br
><
br
>
</
div
>
<
div
class
=
"row justify-content-start"
style
=
"alignment: center"
>
@
foreach
(
$mediaAval
[
$i
][
'avaliacoes_finais'
]
as
$aval
)
<
div
class
=
"col-sm-1"
style
=
"margin-bottom: 7px"
>
<
img
src
=
"
{
{asset('img/icons/usuario.svg')}
}
"
style
=
"width:60px"
alt
=
""
>
</
div
>
<
div
class
=
"col-sm-3"
>
<
h5
>
{{
\
App\User
::
find
(
$aval
->
user_id
)
->
name
}}
</
h5
>
<
h6
><
a
href
=
""
data
-
toggle
=
"modal"
data
-
target
=
"#modalVizuRelatFinal
{
{$aval->id}
}
"
class
=
"button"
>
@
if
(
$aval
->
nota
==
null
)
Pendente
</
a
>@
else
Avaliação
</
a
>
@
endif
</
h6
>
@
if
(
$aval
->
nota
==
null
)
<
h6
><
a
href
=
""
data
-
toggle
=
"modal"
data
-
target
=
"#removerAvaliadorReltorioFinal
{
{$aval->id}
}
"
class
=
"button"
><
b
style
=
"color: red"
>
Remover
</
b
></
a
></
h6
>
@
endif
<!--
Modal
Remover
-->
<
div
class
=
"modal fade"
id
=
"removerAvaliadorReltorioFinal{{
$aval->id
}}"
tabindex
=
"-1"
role
=
"dialog"
aria
-
labelledby
=
"exampleModalLabel"
aria
-
hidden
=
"true"
>
<
div
class
=
"modal-dialog modal-lg"
>
<
div
class
=
"modal-content"
>
<
div
class
=
"modal-header"
>
<
h5
class
=
"modal-title"
id
=
"exampleModalLabel"
>
Remover
Avaliador
Do
Relatório
Final
</
h5
>
<
button
type
=
"button"
class
=
"close"
data
-
dismiss
=
"modal"
aria
-
label
=
"Close"
>
<
span
aria
-
hidden
=
"true"
>&
times
;
</
span
>
</
button
>
</
div
>
<
div
class
=
"modal-body"
>
<
p
>
Você
tem
certeza
que
deseja
remover
o
avaliador
:
{{
$aval
->
user
->
name
}}
?</
p
>
</
div
>
<
div
class
=
"modal-footer"
>
<
button
type
=
"button"
class
=
"btn btn-secondary"
data
-
dismiss
=
"modal"
>
Cancelar
</
button
>
<
a
type
=
"button"
class
=
"btn btn-danger"
href
=
"
{
{route('avaliacaoRelatorio.remover.avaliador',$aval->id)}
}
"
>
Remover
</
a
>
</
div
>
<!--
Modal
Remover
-->
<
div
class
=
"modal fade"
id
=
"removerAvaliadorReltorioFinal{{
$aval->id
}}"
tabindex
=
"-1"
role
=
"dialog"
aria
-
labelledby
=
"exampleModalLabel"
aria
-
hidden
=
"true"
>
<
div
class
=
"modal-dialog modal-lg"
>
<
div
class
=
"modal-content"
>
<
div
class
=
"modal-header"
>
<
h5
class
=
"modal-title"
id
=
"exampleModalLabel"
>
Remover
Avaliador
Do
Relatório
Final
</
h5
>
<
button
type
=
"button"
class
=
"close"
data
-
dismiss
=
"modal"
aria
-
label
=
"Close"
>
<
span
aria
-
hidden
=
"true"
>&
times
;
</
span
>
</
button
>
</
div
>
<
div
class
=
"modal-body"
>
<
p
>
Você
tem
certeza
que
deseja
remover
o
avaliador
:
{{
$aval
->
user
->
name
}}
?</
p
>
</
div
>
<
div
class
=
"modal-footer"
>
<
button
type
=
"button"
class
=
"btn btn-secondary"
data
-
dismiss
=
"modal"
>
Cancelar
</
button
>
<
a
type
=
"button"
class
=
"btn btn-danger"
href
=
"
{
{route('avaliacaoRelatorio.remover.avaliador',$aval->id)}
}
"
>
Remover
</
a
>
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
<!--
Modal
visualizar
informações
participante
-->
<
div
class
=
"modal fade"
id
=
"modalVizuRelatFinal
{
{$aval->id}
}
"
tabindex
=
"-1"
role
=
"dialog"
aria
-
labelledby
=
"exampleModalLabel"
aria
-
hidden
=
"true"
>
<
div
class
=
"modal-dialog modal-dialog-centered modal-lg"
>
<
div
class
=
"modal-content"
>
<!--
Modal
visualizar
informações
participante
-->
<
div
class
=
"modal fade"
id
=
"modalVizuRelatFinal
{
{$aval->id}
}
"
tabindex
=
"-1"
role
=
"dialog"
aria
-
labelledby
=
"exampleModalLabel"
aria
-
hidden
=
"true"
>
<
div
class
=
"modal-dialog modal-dialog-centered modal-lg"
>
<
div
class
=
"modal-content"
>
<
div
class
=
"modal-header"
style
=
"overflow-x:auto; padding-left: 31px"
>
<
h5
class
=
"modal-title"
id
=
"exampleModalLabel"
style
=
"color:#1492E6"
>
Avaliação
do
relatório
final
@
if
(
$aval
->
nota
==
null
)
<
b
style
=
"color: red"
>
Pendente
</
b
>@
endif
</
h5
>
<
div
class
=
"modal-header"
style
=
"overflow-x:auto; padding-left: 31px"
>
<
h5
class
=
"modal-title"
id
=
"exampleModalLabel"
style
=
"color:#1492E6"
>
Avaliação
do
relatório
final
@
if
(
$aval
->
nota
==
null
)
<
b
style
=
"color: red"
>
Pendente
</
b
>@
endif
</
h5
>
<
button
type
=
"button"
class
=
"close"
data
-
dismiss
=
"modal"
aria
-
label
=
"Close"
style
=
"padding-top: 8px; color:#1492E6"
>
<
span
aria
-
hidden
=
"true"
>&
times
;
</
span
>
</
button
>
</
div
>
<
button
type
=
"button"
class
=
"close"
data
-
dismiss
=
"modal"
aria
-
label
=
"Close"
style
=
"padding-top: 8px; color:#1492E6"
>
<
span
aria
-
hidden
=
"true"
>&
times
;
</
span
>
</
button
>
</
div
>
<
div
class
=
"modal-body"
style
=
"padding-right: 32px;padding-left: 32px;padding-top: 20px;padding-bottom: 32px;"
>
@
include
(
'avaliacaoRelatorio.avaliacao'
,
[
'avaliacao'
=>
$aval
])
<
div
class
=
"modal-body"
style
=
"padding-right: 32px;padding-left: 32px;padding-top: 20px;padding-bottom: 32px;"
>
@
include
(
'avaliacaoRelatorio.avaliacao'
,
[
'avaliacao'
=>
$aval
])
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
@
endforeach
</
div
>
@
endforeach
</
div
>
@
endfor
@
break
@
endif
@
endforeach
@
endif
</
div
>
...
...
@@ -2282,4 +2300,4 @@
}
}
</
script
>
@
endsection
\ No newline at end of file
@
endsection
resources/views/projeto/formularioVisualizar/relatorio.blade.php
View file @
2bec30d5
...
...
@@ -52,17 +52,24 @@
<thead>
<tr>
<th
style=
"color: black;"
>
Avaliador
</th>
<th
style=
"color: black;"
>
Discente
</th>
<th
style=
"color: black;"
>
Relatório
</th>
<th
style=
"color: black;"
>
Nota
</th>
<th
style=
"color: black;"
>
Apresentação
</th>
<th
style=
"color: black;"
>
Visualizar
</th>
</tr>
</thead>
<tbody>
@foreach($AvalRelatParcial as $aval)
@php $arquivo = \App\Arquivo::find($aval->arquivo_id);@endphp
<tr>
<th
style=
"color: black;"
>
{{$cont += 1}}
</th>
<td>
@if($arquivo->participanteId != null) {{\App\Participante::find($arquivo->participanteId)->user->name}}@endif
</td>
<td>
Parcial
</td>
<td>
@if($aval->nota == null) Pendente @else {{$aval->nota}} @endif
</td>
<td>
@if($aval->nota_apresentacao == null) Pendente @else {{$aval->nota}} @endif
</td>
<td><a
href=
""
data-toggle=
"modal"
data-target=
"#modalVizuRelatParcial{{$aval->id}}"
class=
"button"
>
Visualizar
</a></td>
</tr>
...
...
@@ -87,10 +94,15 @@
</div>
@endforeach
@foreach($AvalRelatFinal as $aval)
@php $arquivo = \App\Arquivo::find($aval->arquivo_id);@endphp
<tr>
<th
style=
"color: black;"
>
{{$cont += 1}}
</th>
<td>
@if($arquivo->participanteId != null) {{\App\Participante::find($arquivo->participanteId)->user->name}}@endif
</td>
<td>
Final
</td>
<td>
@if($aval->nota == null) Pendente @else {{$aval->nota}} @endif
</td>
<td>
@if($aval->nota_apresentacao == null) Pendente @else {{$aval->nota}} @endif
</td>
<td><a
href=
""
data-toggle=
"modal"
data-target=
"#modalVizuRelatFinal{{$aval->id}}"
class=
"button"
>
Visualizar
</a></td>
</tr>
<!-- Modal visualizar informações participante -->
...
...
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