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
1fddb235
Unverified
Commit
1fddb235
authored
Jul 02, 2021
by
Gabriel Antônio da Silva
Committed by
GitHub
Jul 02, 2021
Browse files
Merge pull request #141 from Gabriel-31415/master
ajuste justificatica etica e download headers
parents
d46ee73f
6538730d
Changes
2
Show whitespace changes
Inline
Side-by-side
app/Http/Controllers/TrabalhoController.php
View file @
1fddb235
...
@@ -615,7 +615,12 @@ class TrabalhoController extends Controller
...
@@ -615,7 +615,12 @@ class TrabalhoController extends Controller
if
(
Storage
::
disk
()
->
exists
(
$projeto
->
anexoPlanilhaPontuacao
))
{
if
(
Storage
::
disk
()
->
exists
(
$projeto
->
anexoPlanilhaPontuacao
))
{
ob_end_clean
();
ob_end_clean
();
return
Storage
::
download
(
$projeto
->
anexoPlanilhaPontuacao
);
$headers
=
array
(
'Content-type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'
,
);
return
Storage
::
download
(
$projeto
->
anexoPlanilhaPontuacao
,
null
,
$headers
);
}
}
return
abort
(
404
);
return
abort
(
404
);
}
}
...
@@ -679,11 +684,25 @@ class TrabalhoController extends Controller
...
@@ -679,11 +684,25 @@ class TrabalhoController extends Controller
DB
::
beginTransaction
();
DB
::
beginTransaction
();
$trabalho
=
Auth
::
user
()
->
proponentes
->
trabalhos
()
->
where
(
'id'
,
$id
)
->
first
();
$trabalho
=
Auth
::
user
()
->
proponentes
->
trabalhos
()
->
where
(
'id'
,
$id
)
->
first
();
$pasta
=
'trabalhos/'
.
$evento
->
id
.
'/'
.
$trabalho
->
id
;
$trabalho
=
$this
->
armazenarAnexosFinais
(
$request
,
$pasta
,
$trabalho
,
$evento
);
$trabalho
->
save
();
// dd($request->all());
// dd($request->has('justificativaAutorizacaoEtica') && ($request->justificativaAutorizacaoEtica == null));
if
(
$request
->
has
(
'anexoAutorizacaoComiteEtica'
)){
$trabalho
->
justificativaAutorizacaoEtica
=
null
;
$trabalho
->
save
();
}
else
{
$trabalho
->
anexoAutorizacaoComiteEtica
=
null
;
$trabalho
->
save
();
}
$trabalho
->
update
(
$request
->
except
([
$trabalho
->
update
(
$request
->
except
([
'anexoProjeto'
,
'anexoDecisaoCONSU'
,
'anexoPlanilhaPontuacao'
,
'anexoProjeto'
,
'anexoDecisaoCONSU'
,
'anexoPlanilhaPontuacao'
,
'anexoLattesCoordenador'
,
'anexoGrupoPesquisa'
,
'anexoAutorizacaoComiteEtica'
,
'anexoLattesCoordenador'
,
'anexoGrupoPesquisa'
,
'justificativaAutorizacaoEtica'
,
'justificativaAutorizacaoEtica'
'anexoAutorizacaoComiteEtica'
]));
]));
// dd($trabalho);
if
(
$request
->
marcado
==
null
)
{
if
(
$request
->
marcado
==
null
)
{
$idExcluido
=
$trabalho
->
participantes
->
pluck
(
'id'
);
$idExcluido
=
$trabalho
->
participantes
->
pluck
(
'id'
);
...
@@ -801,9 +820,7 @@ class TrabalhoController extends Controller
...
@@ -801,9 +820,7 @@ class TrabalhoController extends Controller
}
}
$pasta
=
'trabalhos/'
.
$evento
->
id
.
'/'
.
$trabalho
->
id
;
$trabalho
=
$this
->
armazenarAnexosFinais
(
$request
,
$pasta
,
$trabalho
,
$evento
);
$trabalho
->
save
();
DB
::
commit
();
DB
::
commit
();
...
...
resources/views/projeto/formularioVisualizar/anexos.blade.php
View file @
1fddb235
...
@@ -119,9 +119,9 @@
...
@@ -119,9 +119,9 @@
<label
for=
"botao"
class=
"col-form-label @error('botao') is-invalid @enderror"
data-toggle=
"tooltip"
data-placement=
"bottom"
title=
"Se possuir, coloque todas em único arquivo pdf."
style=
"margin-right: 15px;"
>
{{ __('Possui autorizações especiais?') }}
<span
style=
"color: red; font-weight:bold"
>
*
</span></label>
<label
for=
"botao"
class=
"col-form-label @error('botao') is-invalid @enderror"
data-toggle=
"tooltip"
data-placement=
"bottom"
title=
"Se possuir, coloque todas em único arquivo pdf."
style=
"margin-right: 15px;"
>
{{ __('Possui autorizações especiais?') }}
<span
style=
"color: red; font-weight:bold"
>
*
</span></label>
</div>
</div>
<div
class=
"col-12"
>
<div
class=
"col-12"
>
<input
type=
"radio"
checked
id=
"radioSim"
onchange=
"displayAutorizacoesEspeciais('sim')"
>
<input
type=
"radio"
@
if
($
projeto-
>
anexoAutorizacaoComiteEtica) checked @endif
id="radioSim" onchange="displayAutorizacoesEspeciais('sim')">
<label
for=
"radioSim"
style=
"margin-right: 5px"
>
Sim
</label>
<label
for=
"radioSim"
style=
"margin-right: 5px"
>
Sim
</label>
<input
type=
"radio"
id=
"radioNao"
onchange=
"displayAutorizacoesEspeciais('nao')"
>
<input
type=
"radio"
id=
"radioNao"
@
if
($
projeto-
>
justificativaAutorizacaoEtica) checked @endif
onchange="displayAutorizacoesEspeciais('nao')">
<label
for=
"radioNao"
style=
"margin-right: 5px"
>
Não
</label><br>
<label
for=
"radioNao"
style=
"margin-right: 5px"
>
Não
</label><br>
</div>
</div>
</div>
</div>
...
...
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