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
b5365fd8
Commit
b5365fd8
authored
Mar 18, 2022
by
Guilherme Silva
Browse files
Ajuste do recebimento da documentação complementar
parent
ec1f7916
Changes
3
Show whitespace changes
Inline
Side-by-side
app/Http/Controllers/ParticipanteController.php
View file @
b5365fd8
...
...
@@ -117,4 +117,16 @@ class ParticipanteController extends Controller
$participante
->
save
();
return
redirect
()
->
back
()
->
with
([
'mensagem'
=>
'Alteração da bolsa realizada com sucesso!'
]);
}
public
function
atualizarDocComplementar
(
Request
$request
){
$participante
=
Participante
::
find
(
$request
->
partcipanteId
);
$pasta
=
'participantes/'
.
$participante
->
id
;
$participante
->
anexoTermoCompromisso
=
Storage
::
putFileAs
(
$pasta
,
$request
->
termoCompromisso
,
"Termo_de_Compromisso.pdf"
);
$participante
->
anexoComprovanteMatricula
=
Storage
::
putFileAs
(
$pasta
,
$request
->
comprovanteMatricula
,
"Comprovante_de_Matricula.pdf"
);
$participante
->
anexoLattes
=
Storage
::
putFileAs
(
$pasta
,
$request
->
pdfLattes
,
"Curriculo_Lattes.pdf"
);
$participante
->
linkLattes
=
$request
->
linkLattes
;
$participante
->
update
();
return
redirect
()
->
back
()
->
with
([
'sucesso'
=>
"Documentação complementar enviada com sucesso"
]);
}
}
resources/views/documentacaoComplementar/listar.blade.php
View file @
b5365fd8
...
...
@@ -34,7 +34,9 @@
<td style="
text
-
align
:
center
;
" title="
{{
$participante
->
user
->
name
}}
">
{
{$participante->user->name}
}
</td>
<td style="
text
-
align
:
center
;
">
<button type="
button
" class="
btn
btn
-
primary
" data-toggle="
modal
" data-target="
#modalConfirm{{$participante->id}}" @if($trabalho->status!="aprovado")disabled="disabled" @endif>
@
if
(
$participante
->
documentacaoComplementar
==
null
)
@
if
(
$participante
->
anexoComprovanteMatricula
==
null
||
$participante
->
anexoTermoCompromisso
==
null
||
$participante
->
anexoLattes
==
null
||
$participante
->
linkLattes
==
null
)
Pendente
@
else
Visualizar
...
...
@@ -43,7 +45,7 @@
</
td
>
</
tbody
>
<
div
class
=
"modal fade"
id
=
"modalConfirm
{
{$participante->id}
}
"
tabindex
=
"-1"
role
=
"dial
o
g"
<
div
class
=
"modal fade"
id
=
"modalConfirm
{
{$participante->id}
}
"
tabindex
=
"-1"
role
=
"
o
dialg"
aria
-
labelledby
=
"modalConfirmLabel"
aria
-
hidden
=
"true"
>
<
div
class
=
"modal-dialog modal-lg"
role
=
"document"
>
<
div
class
=
"modal-content"
>
...
...
@@ -57,7 +59,11 @@
<
input
type
=
"hidden"
value
=
"
{
{$participante->id}
}
"
name
=
"partcipanteId"
>
<
div
class
=
"row col-md-12"
>
<
div
class
=
"col-md-6"
>
<
label
class
=
"control-label "
>
Termo
de
Compromisso
</
label
>
<
label
class
=
"control-label "
>
Termo
de
Compromisso
@
if
(
$participante
->
anexoTermoCompromisso
)
:
<
a
id
=
"modeloDocumentoTemp"
href
=
"{{ route('baixar.documentosParticipante', ['pathDocumento' =>
$participante->anexoTermoCompromisso
]) }}"
>
Arquivo
atual
</
a
>
@
endif
</
label
>
<
br
>
<
input
type
=
"file"
class
=
"input-group-text"
value
=
""
name
=
"termoCompromisso"
accept
=
".pdf"
id
=
"termoCompromisso
{
{$participante->id}
}
"
required
/>
...
...
@@ -69,7 +75,11 @@
<
br
>
</
div
>
<
div
class
=
"col-md-6"
>
<
label
class
=
"control-label "
>
Comprovante
de
Matricula
</
label
>
<
label
class
=
"control-label "
>
Comprovante
de
Matricula
@
if
(
$participante
->
anexoComprovanteMatricula
)
:
<
a
id
=
"modeloDocumentoTemp"
href
=
"{{ route('baixar.documentosParticipante', ['pathDocumento' =>
$participante->anexoComprovanteMatricula
]) }}"
>
Arquivo
atual
</
a
>
@
endif
</
label
>
<
br
>
<
input
type
=
"file"
class
=
"input-group-text"
value
=
""
name
=
"comprovanteMatricula"
accept
=
".pdf"
id
=
"comprovanteMatricula
{
{$participante->id}
}
"
required
/>
@
error
(
'comprovanteMatricula'
)
...
...
@@ -81,7 +91,10 @@
</
div
>
<
div
class
=
"col-md-6"
>
<
label
class
=
"control-label "
>
PDF
Lattes
</
label
>
<
label
class
=
"control-label "
>
PDF
Lattes
@
if
(
$participante
->
anexoLattes
)
:
<
a
id
=
"modeloDocumentoTemp"
href
=
"{{ route('baixar.documentosParticipante', ['pathDocumento' =>
$participante->anexoLattes
]) }}"
>
Arquivo
atual
</
a
>
@
endif
</
label
>
<
br
>
<
input
type
=
"file"
class
=
"input-group-text"
value
=
""
name
=
"pdfLattes"
accept
=
".pdf"
id
=
"pdfLattes
{
{$participante->id}
}
"
required
/>
...
...
@@ -92,10 +105,10 @@
@
enderror
</
div
>
<
div
class
=
"col-md-6"
>
<
label
class
=
"control-label "
>
Link
Lattes
</
label
>
<
label
class
=
"control-label "
>
Link
Lattes
</
label
>
<
br
>
<
input
type
=
"text"
class
=
"input-group-text col-md-12"
name
=
"linkLattes"
placeholder
=
"Link Lattes"
id
=
"linkLattes
{
{$participante->id}
}
"
required
/>
required
@
if
(
$participante
->
linkLattes
)
value
=
"
{
{$participante->linkLattes}
}
"
@
endif
/>
@
error
(
'linkLattes'
)
<
span
class
=
"invalid-feedback"
role
=
"alert"
style
=
"overflow: visible; display:block"
>
<
strong
>
{{
$message
}}
</
strong
>
...
...
routes/web.php
View file @
b5365fd8
...
...
@@ -152,7 +152,7 @@ Route::group(['middleware' => ['isTemp', 'auth', 'verified']], function(){
//########## Documentação Complementar
Route
::
get
(
'/documentacaoComplementar'
,
'ParticipanteController@listarParticipanteProjeto'
)
->
name
(
'docComplementar.listar'
);
Route
::
post
(
'/documentacaoComplementar/enviar'
,
'
DocumentacaoComplementarController@cri
ar'
)
->
name
(
'docComplementar.enviar'
);
Route
::
post
(
'/documentacaoComplementar/enviar'
,
'
ParticipanteController@atualizarDocComplement
ar'
)
->
name
(
'docComplementar.enviar'
);
//######### Atribuição #######################################
Route
::
get
(
'/atribuir'
,
'AtribuicaoController@distribuicaoAutomatica'
)
->
name
(
'distribuicao'
);
...
...
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