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
838d399b
"database/seeders/ProponenteSeeder.php" did not exist on "b3f3f53aaee90e7923e7581e94049110a2bcc1be"
Commit
838d399b
authored
Aug 22, 2022
by
GuilhermeGz
Browse files
Merge branch 'master' of
https://github.com/GuilhermeGz/submeta
parents
6b5e5824
38c26e70
Changes
5
Hide whitespace changes
Inline
Side-by-side
app/Http/Controllers/AvaliadorController.php
View file @
838d399b
...
@@ -109,6 +109,8 @@ class AvaliadorController extends Controller
...
@@ -109,6 +109,8 @@ class AvaliadorController extends Controller
$avaliador
=
$user
->
avaliadors
->
where
(
'user_id'
,
$user
->
id
)
->
first
();
$avaliador
=
$user
->
avaliadors
->
where
(
'user_id'
,
$user
->
id
)
->
first
();
$trabalho
=
$avaliador
->
trabalhos
->
find
(
$request
->
trabalho_id
);
$trabalho
=
$avaliador
->
trabalhos
->
find
(
$request
->
trabalho_id
);
$evento
=
Evento
::
find
(
$request
->
evento
);
$evento
=
Evento
::
find
(
$request
->
evento
);
$hoje
=
Carbon
::
today
(
'America/Recife'
);
$hoje
=
$hoje
->
toDateString
();
// Verficação de pendencia de substituição
// Verficação de pendencia de substituição
$aux
=
count
(
Substituicao
::
where
(
'status'
,
'Em Aguardo'
)
->
whereIn
(
'participanteSubstituido_id'
,
$trabalho
->
participantes
->
pluck
(
'id'
))
->
get
());
$aux
=
count
(
Substituicao
::
where
(
'status'
,
'Em Aguardo'
)
->
whereIn
(
'participanteSubstituido_id'
,
$trabalho
->
participantes
->
pluck
(
'id'
))
->
get
());
...
@@ -116,7 +118,7 @@ class AvaliadorController extends Controller
...
@@ -116,7 +118,7 @@ class AvaliadorController extends Controller
return
redirect
()
->
back
()
->
withErrors
(
"A proposta "
.
$trabalho
->
titulo
.
" possui substituições pendentes"
);
return
redirect
()
->
back
()
->
withErrors
(
"A proposta "
.
$trabalho
->
titulo
.
" possui substituições pendentes"
);
}
}
return
view
(
'avaliador.parecer'
,
[
'trabalho'
=>
$trabalho
,
'evento'
=>
$evento
]);
return
view
(
'avaliador.parecer'
,
[
'trabalho'
=>
$trabalho
,
'evento'
=>
$evento
,
'hoje'
=>
$hoje
]);
}
}
public
function
parecerInterno
(
Request
$request
){
public
function
parecerInterno
(
Request
$request
){
...
...
app/Http/Requests/StoreTrabalho.php
View file @
838d399b
...
@@ -30,6 +30,10 @@ class StoreTrabalho extends FormRequest
...
@@ -30,6 +30,10 @@ class StoreTrabalho extends FormRequest
//dd($this->all());
//dd($this->all());
$evento
=
Evento
::
find
(
$this
->
editalId
);
$evento
=
Evento
::
find
(
$this
->
editalId
);
$rules
=
[];
$rules
=
[];
if
(
!
(
$this
->
has
(
'marcado'
))){
$rules
[
'erro'
]
=
[
'required'
];
}
if
(
$this
->
has
(
'marcado'
)){
if
(
$this
->
has
(
'marcado'
)){
foreach
(
$this
->
get
(
'marcado'
)
as
$key
=>
$value
)
{
foreach
(
$this
->
get
(
'marcado'
)
as
$key
=>
$value
)
{
if
(
intval
(
$value
)
==
$key
){
if
(
intval
(
$value
)
==
$key
){
...
@@ -65,7 +69,7 @@ class StoreTrabalho extends FormRequest
...
@@ -65,7 +69,7 @@ class StoreTrabalho extends FormRequest
}
}
if
(
$this
->
has
(
'rascunho'
))
{
if
(
$this
->
has
(
'rascunho'
))
{
$rules
=
[];
$rules
=
[];
return
$rules
;
return
$rules
;
}
else
{
}
else
{
...
...
app/Http/Requests/UpdateTrabalho.php
View file @
838d399b
...
@@ -32,6 +32,9 @@ class UpdateTrabalho extends FormRequest
...
@@ -32,6 +32,9 @@ class UpdateTrabalho extends FormRequest
$projeto
=
Trabalho
::
find
(
$this
->
id
);
$projeto
=
Trabalho
::
find
(
$this
->
id
);
$evento
=
Evento
::
find
(
$this
->
editalId
);
$evento
=
Evento
::
find
(
$this
->
editalId
);
if
(
!
(
$this
->
has
(
'marcado'
))){
$rules
[
'erro'
]
=
[
'required'
];
}
if
(
$this
->
has
(
'marcado'
)){
if
(
$this
->
has
(
'marcado'
)){
foreach
(
$this
->
get
(
'marcado'
)
as
$key
=>
$value
)
{
foreach
(
$this
->
get
(
'marcado'
)
as
$key
=>
$value
)
{
if
(
intval
(
$value
)
==
$key
){
if
(
intval
(
$value
)
==
$key
){
...
...
resources/views/avaliador/editais.blade.php
View file @
838d399b
...
@@ -67,23 +67,11 @@
...
@@ -67,23 +67,11 @@
</
a
>
</
a
>
<
div
class
=
"dropdown-menu"
>
<
div
class
=
"dropdown-menu"
>
@
if
(
!
is_null
(
Auth
::
user
()
->
avaliadors
->
eventos
->
where
(
'id'
,
$evento
->
id
)
->
first
()
->
pivot
->
convite
)
&&
Auth
::
user
()
->
avaliadors
->
eventos
->
where
(
'id'
,
$evento
->
id
)
->
first
()
->
pivot
->
convite
==
true
)
@
if
(
!
is_null
(
Auth
::
user
()
->
avaliadors
->
eventos
->
where
(
'id'
,
$evento
->
id
)
->
first
()
->
pivot
->
convite
)
&&
Auth
::
user
()
->
avaliadors
->
eventos
->
where
(
'id'
,
$evento
->
id
)
->
first
()
->
pivot
->
convite
==
true
)
@
if
(
$hoje
>=
$evento
->
inicioRevisao
&&
$hoje
<=
$evento
->
fimRevisao
)
@
if
(
$evento
->
flag
==
0
)
<
a
href
=
"{{ route('avaliador.visualizarTrabalho', ['evento_id' =>
$evento->id
]) }}"
class
=
"dropdown-item"
>
<
button
disabled
=
"disabled"
class
=
"dropdown-item"
>
<
img
src
=
"
{
{asset('img/icons/eye-regular.svg')}
}
"
class
=
"icon-card"
alt
=
""
>
Não
há
ainda
avaliação
atribuída
para
você
neste
edital
.
Avaliar
Propostas
</
button
>
</
a
>
@
else
<
a
href
=
"{{ route('avaliador.visualizarTrabalho', ['evento_id' =>
$evento->id
]) }}"
class
=
"dropdown-item"
>
<
img
src
=
"
{
{asset('img/icons/eye-regular.svg')}
}
"
class
=
"icon-card"
alt
=
""
>
Avaliar
Propostas
</
a
>
@
endif
@
else
<
button
disabled
=
"disabled"
class
=
"dropdown-item"
>
Hoje
({{
date
(
'd/m/Y'
,
strtotime
(
$hoje
))
}})
não
faz
parte
do
período
de
revisão
(
avaliação
)
</
button
>
@
endif
@
elseif
(
!
is_null
(
Auth
::
user
()
->
avaliadors
->
eventos
->
where
(
'id'
,
$evento
->
id
)
->
first
()
->
pivot
->
convite
)
&&
Auth
::
user
()
->
avaliadors
->
eventos
->
where
(
'id'
,
$evento
->
id
)
->
first
()
->
pivot
->
convite
==
false
)
@
elseif
(
!
is_null
(
Auth
::
user
()
->
avaliadors
->
eventos
->
where
(
'id'
,
$evento
->
id
)
->
first
()
->
pivot
->
convite
)
&&
Auth
::
user
()
->
avaliadors
->
eventos
->
where
(
'id'
,
$evento
->
id
)
->
first
()
->
pivot
->
convite
==
false
)
<
button
disabled
=
"disabled"
class
=
"dropdown-item"
>
<
button
disabled
=
"disabled"
class
=
"dropdown-item"
>
Convite
recusado
Convite
recusado
...
...
resources/views/avaliador/parecer.blade.php
View file @
838d399b
...
@@ -151,7 +151,8 @@
...
@@ -151,7 +151,8 @@
<
hr
style
=
"border-top: 1px solid#1492E6"
>
<
hr
style
=
"border-top: 1px solid#1492E6"
>
<
div
class
=
"d-flex justify-content-end"
>
<
div
class
=
"d-flex justify-content-end"
>
<
div
style
=
"margin-right: 15px"
><
a
href
=
"{{ route('avaliador.visualizarTrabalho', ['evento_id' =>
$evento->id
])}}"
class
=
"btn btn-light"
style
=
"color: red;"
>
Cancelar
</
a
></
div
>
<
div
style
=
"margin-right: 15px"
><
a
href
=
"{{ route('avaliador.visualizarTrabalho', ['evento_id' =>
$evento->id
])}}"
class
=
"btn btn-light"
style
=
"color: red;"
>
Cancelar
</
a
></
div
>
<
div
><
button
type
=
"submit"
class
=
"btn btn-success"
>
Enviar
meu
parecer
</
button
></
div
>
<
div
><
button
type
=
"submit"
class
=
"btn btn-success"
@
if
(
$evento
->
inicioRevisao
>
$hoje
||
$evento
->
fimRevisao
<
$hoje
)
disabled
@
endif
>
Enviar
meu
parecer
</
button
></
div
>
</
div
>
</
div
>
</
form
>
</
form
>
...
...
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