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
b7d2533c
Unverified
Commit
b7d2533c
authored
May 22, 2021
by
Gabriel Antônio da Silva
Committed by
GitHub
May 22, 2021
Browse files
Merge branch 'master' into modificacoes_layout_2
parents
8de6a88e
18615797
Changes
23
Hide whitespace changes
Inline
Side-by-side
resources/views/projeto/editar.blade.php
View file @
b7d2533c
...
@@ -262,131 +262,274 @@
...
@@ -262,131 +262,274 @@
@enderror
@enderror
</div>
</div>
@endif
@endif
</div>
</div>
<hr>
<hr>
<h3>Participantes</h3>
<h3>Participantes</h3>
<input type="
hidden
" value="
{{
sizeof
(
$participantes
)}}
" id="
qtd
Participante
s
">
<input type="
hidden
" value="
{{
sizeof
(
$participantes
)}}
" id="
count
Participante
">
{{-- Participantes --}}
{{-- Participantes --}}
<div class="
row
" style="
margin
-
top
:
20
px
">
<div class="
row
" style="
margin
-
top
:
20
px
">
<div class="
col
-
sm
-
12
">
<div class="
col
-
sm
-
12
">
<div id="
participantes
">
<div id="
participantes
">
@foreach(
$participantes
as
$participante
)
@foreach(
$participantes
as
$participante
)
@foreach(
$users
as
$user
)
<div id="
novoParticipante
" style="
display
:
block
;
">
@if(
$participante->user_id
===
$user->id
)
<br>
<div id="
novoParticipante
">
<h4>Dados do participante</h4>
<br>
<h6>Dados pessoais</h6>
<h4>Dados do participante</h4>
<input type="
hidden
" name="
participante_id
[]
" value="
{{
$participante
->
id
}}
">
<div class="
row
">
<div class="
row
">
<div class="
col
-
sm
-
5
">
<div class="
col
-
sm
-
5
">
<label>Nome Completo</label>
<label>Nome Completo*</label>
<input value="
{{
$user
->
name
}}
" type="
text
" style="
margin
-
bottom
:
10
px
" class="
form
-
control
@
error
(
'nomeParticipante'
)
is
-
invalid
@
enderror
" name="
nomeParticipante
[]
" placeholder="
Nome
" required>
<input type="
text
" style="
margin
-
bottom
:
10
px
" class="
form
-
control
@
error
(
'nomeParticipante'
)
is
-
invalid
@
enderror
" name="
nomeParticipante
[]
" placeholder="
Nome
" value="
{{
$participante
->
user
->
name
}}
" required>
@error('nomeParticipante')
@error('nomeParticipante.'.
$projeto->id
)
<span class="
invalid
-
feedback
" role="
alert
" style="
overflow
:
visible
;
display
:
block
">
<strong>{{
$message
}}</strong>
</span>
@enderror
</div>
<div class="
col
-
sm
-
4
">
<label>E-mail*</label>
<input type="
email
" style="
margin
-
bottom
:
10
px
" class="
form
-
control
@
error
(
'emailParticipante'
)
is
-
invalid
@
enderror
" name="
emailParticipante
[]
" placeholder="
email
" value="
{{
$participante
->
user
->
email
}}
" required>
@error('emailParticipante.'.
$projeto->id
)
<span class="
invalid
-
feedback
" role="
alert
" style="
overflow
:
visible
;
display
:
block
">
<strong>{{
$message
}}</strong>
</span>
@enderror
</div>
<div class="
col
-
sm
-
3
">
<label>Função*:</label>
<select class="
form
-
control
@
error
(
'funcaoParticipante'
)
is
-
invalid
@
enderror
" name="
funcaoParticipante
[]
" id="
funcaoParticipante
" required>
<option value="" disabled selected hidden>-- Função --</option>
@foreach(
$funcaoParticipantes
as
$funcaoParticipante
)
<option @if(
$participante->funcao_participante_id
==
$funcaoParticipante->id
) selected @endif value="
{{
$funcaoParticipante
->
id
}}
">
{
{$funcaoParticipante->nome}
}
</option>
@endforeach
</select>
@error('funcaoParticipante')
<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>
@enderror
@enderror
</div>
</div>
<div id="
dados_complemento_1
">
<div class="
form
-
group
">
<div class="
row
">
<div class="
col
-
sm
-
4
">
<label for="">{{ __('CPF*') }}</label>
<input type="
text
" class="
form
-
control
cpf
" name="
cpf
[]
" required value="
{{
$participante
->
user
->
cpf
}}
">
</div>
<div class="
col
-
sm
-
4
">
<label for="">{{ __('RG*') }}</label>
<input type="
text
" class="
form
-
control
rg
" name="
rg
[]
" required value="
{{
$participante
->
rg
}}
">
</div>
<div class="
col
-
sm
-
4
">
<label for="">{{ __('Celular*') }}</label>
<input type="
text
" class="
form
-
control
celular
" name="
celular
[]
" required value="
{{
$participante
->
user
->
celular
}}
">
</div>
</div>
</div>
<div class="
col
-
sm
-
4
">
</div>
<label>E-mail</label>
<div class="
form
-
group
">
<input value="
{{
$user
->
email
}}
" type="
email
" style="
margin
-
bottom
:
10
px
" class="
form
-
control
@
error
(
'emailParticipante'
)
is
-
invalid
@
enderror
" name="
emailParticipante
[]
" placeholder="
email
" required>
<div class="
row
">
@error('emailParticipante')
<div class="
col
-
sm
-
4
">
<span class="
invalid
-
feedback
" role="
alert
" style="
overflow
:
visible
;
display
:
block
">
<label for="">{{ __('Data de nascimento*') }}</label>
<strong>{{
$message
}}</strong>
<input type="
date
" class="
form
-
control
" name="
data_de_nascimento
[]
" required value="
{{
$participante
->
data_de_nascimento
}}
">
</span>
</div>
@enderror
</div>
</div>
<div class="
form
-
group
">
<div class="
row
">
<div class="
container
">
<h6>Endereço do participante</h6>
</div>
</div>
</div>
<div class="
col
-
sm
-
3
">
<div class="
row
">
<label>Função:</label>
<div class="
col
-
sm
-
3
">
<select class="
form
-
control
@
error
(
'funcaoParticipante'
)
is
-
invalid
@
enderror
" name="
funcaoParticipante
[]
" id="
funcaoParticipante
">
<label for="">{{ __('CEP*') }}</label>
<option value="" disabled selected hidden>-- Função --</option>
<input type="
text
" class="
form
-
control
" name="
cep
[]
" required value="
{{
$participante
->
user
->
endereco
->
cep
}}
">
@foreach(
$funcaoParticipantes
as
$funcaoParticipante
)
</div>
@if(
$funcaoParticipante->id
===
$participante->funcao_participante_id
)
<option value="
{{
$funcaoParticipante
->
id
}}
" selected>
{
{$funcaoParticipante->nome}
}
</option>
@else
<option value="
{{
$funcaoParticipante
->
id
}}
">
{
{$funcaoParticipante->nome}
}
</option>
@endif
@endforeach
@error('funcaoParticipante')
<span class="
invalid
-
feedback
" role="
alert
" style="
overflow
:
visible
;
display
:
block
">
<strong>{{
$message
}}</strong>
</span>
@enderror
</select>
</div>
</div>
</div>
</div>
<div class="
row
">
<div class="
form
-
group
">
<div class='col-sm-11'>
<div class="
row
">
<h6 class="
mb
-
1
">Possui plano de trabalho?</h6>
<div class="
col
-
sm
-
6
">
<button class="
btn
btn
-
primary
mt
-
2
mb
-
2
simPlano
" id="
simPlano
">Sim</button>
<label for="">{{ __('Rua*') }}</label>
<button class="
btn
btn
-
primary
mt
-
2
mb
-
2
naoPlano
">Não</button>
<input type="
text
" class="
form
-
control
" name="
rua
[]
" required value="
{{
$participante
->
user
->
endereco
->
rua
}}
">
<input type="
hidden
" name="
semPlano
[]
" value="">
</div>
<div class="
col
-
sm
-
3
">
<label for="">{{ __('Número*') }}</label>
<input type="
text
" class="
form
-
control
" name="
numero
[]
" required value="
{{
$participante
->
user
->
endereco
->
numero
}}
">
</div>
<div class="
col
-
sm
-
3
">
<label for="">{{ __('Bairro*') }}</label>
<input type="
text
" class="
form
-
control
" name="
bairro
[]
" required value="
{{
$participante
->
user
->
endereco
->
bairro
}}
">
</div>
</div>
</div>
<div class="
col
-
sm
-
1
deletarSemPlano
" >
</div>
<a class="
delete
">
<div class="
form
-
group
">
<img src="
/
img
/
icons
/
user
-
times
-
solid
.
svg
" style="
width
:
25
px
;
margin
-
top
:
35
px
">
<div class="
row
">
</a>
<div class="
col
-
sm
-
4
">
<label for="">{{ __('Cidade*') }}</label>
<input type="
text
" class="
form
-
control
" name="
cidade
[]
" required value="
{{
$participante
->
user
->
endereco
->
cidade
}}
">
</div>
<div class="
col
-
sm
-
4
">
<label for="">{{ __('Complemento*') }}</label>
<input type="
text
" class="
form
-
control
" name="
complemento
[]
" required value="
{{
$participante
->
user
->
endereco
->
complemento
}}
">
</div>
<div class="
col
-
sm
-
4
">
<label for="">{{ __('Estado*') }}</label>
<select name="
uf
[]
" id="" class="
form
-
control
" required>
<option value="" disabled selected>-- UF --</option>
<option @if(
$participante->user
->endereco->uf == 'AC') selected @endif value="
AC
">Acre</option>
<option @if(
$participante->user
->endereco->uf == 'AL') selected @endif value="
AL
">Alagoas</option>
<option @if(
$participante->user
->endereco->uf == 'AP') selected @endif value="
AP
">Amapá</option>
<option @if(
$participante->user
->endereco->uf == 'AM') selected @endif value="
AM
">Amazonas</option>
<option @if(
$participante->user
->endereco->uf == 'BA') selected @endif value="
BA
">Bahia</option>
<option @if(
$participante->user
->endereco->uf == 'CE') selected @endif value="
CE
">Ceará</option>
<option @if(
$participante->user
->endereco->uf == 'DF') selected @endif value="
DF
">Distrito Federal</option>
<option @if(
$participante->user
->endereco->uf == 'ES') selected @endif value="
ES
">Espírito Santo</option>
<option @if(
$participante->user
->endereco->uf == 'GO') selected @endif value="
GO
">Goiás</option>
<option @if(
$participante->user
->endereco->uf == 'MA') selected @endif value="
MA
">Maranhão</option>
<option @if(
$participante->user
->endereco->uf == 'MT') selected @endif value="
MT
">Mato Grosso</option>
<option @if(
$participante->user
->endereco->uf == 'MS') selected @endif value="
MS
">Mato Grosso do Sul</option>
<option @if(
$participante->user
->endereco->uf == 'MG') selected @endif value="
MG
">Minas Gerais</option>
<option @if(
$participante->user
->endereco->uf == 'PA') selected @endif value="
PA
">Pará</option>
<option @if(
$participante->user
->endereco->uf == 'PB') selected @endif value="
PB
">Paraíba</option>
<option @if(
$participante->user
->endereco->uf == 'PR') selected @endif value="
PR
">Paraná</option>
<option @if(
$participante->user
->endereco->uf == 'PE') selected @endif value="
PE
">Pernambuco</option>
<option @if(
$participante->user
->endereco->uf == 'PI') selected @endif value="
PI
">Piauí</option>
<option @if(
$participante->user
->endereco->uf == 'RJ') selected @endif value="
RJ
">Rio de Janeiro</option>
<option @if(
$participante->user
->endereco->uf == 'RN') selected @endif value="
RN
">Rio Grande do Norte</option>
<option @if(
$participante->user
->endereco->uf == 'RS') selected @endif value="
RS
">Rio Grande do Sul</option>
<option @if(
$participante->user
->endereco->uf == 'RO') selected @endif value="
RO
">Rondônia</option>
<option @if(
$participante->user
->endereco->uf == 'RR') selected @endif value="
RR
">Roraima</option>
<option @if(
$participante->user
->endereco->uf == 'SC') selected @endif value="
SC
">Santa Catarina</option>
<option @if(
$participante->user
->endereco->uf == 'SP') selected @endif value="
SP
">São Paulo</option>
<option @if(
$participante->user
->endereco->uf == 'SE') selected @endif value="
SE
">Sergipe</option>
<option @if(
$participante->user
->endereco->uf == 'TO') selected @endif value="
TO
">Tocantins</option>
</select>
</div>
</div>
</div>
</div>
</div>
<div id="
planoHabilitado
" >
<div class="
form
-
group
">
@foreach (
$arquivos
as
$arquivo
)
@if(
$arquivo->participanteId
===
$participante->id
)
<input type="
hidden
" class="
exibirPlano
">
<h5>Dados do plano de trabalho</h5>
<a href="
{{
route
(
'baixar.plano'
,
[
'id'
=>
$arquivo
->
id
])
}}
">Plano de trabalho atual</a>
<div class="
row
">
<div class="
row
">
<div class="
col
-
sm
-
12
">
<div class="
container
">
<div id="
planoTrabalho
">
<h6>Dados do curso do participante</h6>
<div class="
row
">
</div>
<div class="
col
-
sm
-
4
">
</div>
<label>Titulo </label>
<div class="
row
">
<input type="
text
" value="
{{
$arquivo
->
titulo
}}
" style="
margin
-
bottom
:
10
px
" class="
form
-
control
@
error
(
'nomePlanoTrabalho'
)
is
-
invalid
@
enderror
" name="
nomePlanoTrabalho
[]
" placeholder="
Nome
">
<div class="
col
-
sm
-
6
">
<label for="">{{ __('Universidade*') }}</label>
@error('nomePlanoTrabalho')
<input type="
text
" class="
form
-
control
" name="
universidade
[]
" required value="
{{
$participante
->
user
->
instituicao
}}
">
<span class="
invalid
-
feedback
" role="
alert
" style="
overflow
:
visible
;
display
:
block
">
</div>
<strong>{{
$message
}}</strong>
<div class="
col
-
sm
-
6
">
</span>
<label for="">{{ __('Curso*') }}</label>
@enderror
<input type="
text
" class="
form
-
control
" name="
curso
[]
" required value="
{{
$participante
->
curso
}}
">
</div>
</div>
{{-- Arquivo --}}
</div>
<div class="
col
-
sm
-
7
">
</div>
<label for="
nomeTrabalho
">Anexo</label>
<div class="
form
-
group
">
<div class="
input
-
group
">
<div class="
row
">
<div class="
input
-
group
-
prepend
">
<div class="
col
-
sm
-
2
">
<span class="
input
-
group
-
text
" id="
anexoPlanoTrabalho
">Selecione um arquivo:</span>
<label for="">{{ __('Turno*') }}</label>
</div>
<select id="" class="
form
-
control
" name="
turno
[]
" required>
<div class="
custom
-
file
">
<option value="" disabled selected>-- TURNO --</option>
<input type="
file
" class="
custom
-
file
-
input
@
error
(
'anexoPlanoTrabalho'
)
is
-
invalid
@
enderror
" id="
anexoPlanoTrabalho
" aria-describedby="
anexoPlanoTrabalho
" name="
anexoPlanoTrabalho
[]
">
@foreach (
$enum_turno
as
$turno
)
<label class="
custom
-
file
-
label
" id="
custom
-
file
-
label
" for="
inputGroupFile01
">O arquivo deve ser no formato PDF de até 2mb.</label>
<option @if(
$participante->turno
==
$turno
) selected @endif value="
{{
$turno
}}
">
{
{$turno}
}
</option>
</div>
@endforeach
</div>
</select>
@error('anexoPlanoTrabalho')
</div>
<span class="
invalid
-
feedback
" role="
alert
" style="
overflow
:
visible
;
display
:
block
">
<div class="
col
-
sm
-
3
">
<strong>{{
$message
}}</strong>
<label for="">{{ __('Total de periodos do curso*') }}</label>
</span>
<select name="
total_periodos
[]
" id="" class="
form
-
control
" onchange="
gerarPeriodos
(
this
)
" required>
@enderror
<option value="" disabled selected>-- TOTAL DE PERIODOS --</option>
<option @if(
$participante->total_periodos
== "
6
") selected @endif value="
6
">6</option>
<option @if(
$participante->total_periodos
== "
7
") selected @endif value="
7
">7</option>
<option @if(
$participante->total_periodos
== "
8
") selected @endif value="
8
">8</option>
<option @if(
$participante->total_periodos
== "
9
") selected @endif value="
9
">9</option>
<option @if(
$participante->total_periodos
== "
10
") selected @endif value="
10
">10</option>
<option @if(
$participante->total_periodos
== "
11
") selected @endif value="
11
">11</option>
<option @if(
$participante->total_periodos
== "
12
") selected @endif value="
12
">12</option>
</select>
</div>
<div class="
col
-
sm
-
2
">
<label for="">{{ __('Periodo atual*') }}</label>
<select name="
periodo_cursado
[]
" id="" class="
form
-
control
" required>
<option value="" disabled selected>-- PERÍODO ATUAL --</option>
@for(
$i
= 1;
$i
<=
$participante->total_periodos
;
$i
++)
<option @if(
$participante->periodo_atual
==
$i
) selected @endif value="
{{
$i
}}
">
{
{$i}
}
</option>
@endfor
</select>
</div>
<div class="
col
-
sm
-
2
">
<label for="">{{ __('Ordem de prioridade*') }}</label>
<select name="
ordem_prioridade
[]
" id="" class="
form
-
control
" required>
<option value="" disabled selected>-- ORDEM --</option>
<option @if(
$participante->ordem_prioridade
== "
1
") selected @endif value="
1
">1º</option>
<option @if(
$participante->ordem_prioridade
== "
2
") selected @endif value="
2
">2º</option>
<option @if(
$participante->ordem_prioridade
== "
3
") selected @endif value="
3
">3º</option>
<option @if(
$participante->ordem_prioridade
== "
4
") selected @endif value="
4
">4º</option>
</select>
</div>
<div class="
col
-
sm
-
3
">
<label for="">{{ __('Média geral do curso*') }}</label>
<input type="
number
" class="
form
-
control
media
" min="
0
" max="
10
" step="
0.01
" value="
{{
$participante
->
media_do_curso
}}
" name="
media_geral_curso
[]
" required>
</div>
</div>
</div>
</div>
<h6 class="
mb
-
1
">Possui plano de trabalho?</h6>
<button class="
btn
btn
-
primary
mt
-
2
mb
-
2
simPlano
">Sim</button>
<button class="
btn
btn
-
primary
mt
-
2
mb
-
2
naoPlano
">Não</button>
{{--
{
{dd($participantes)}
}
--}}
<div id="
planoHabilitado
" style="
display
:@
if
(
$participante
->
planoTrabalho
!=
null
)
block
;
@
else
none
;
@
endif
">
<h5>Dados do plano de trabalho</h5>
<div class="
row
">
<div class="
col
-
sm
-
12
">
<div id="
planoTrabalho
">
<div class="
row
">
<div class="
col
-
sm
-
4
">
<label>Titulo* </label>
<input type="
text
" style="
margin
-
bottom
:
10
px
" class="
form
-
control
@
error
(
'nomePlanoTrabalho'
)
is
-
invalid
@
enderror
" name="
nomePlanoTrabalho
[]
" placeholder="
Nome
" value="
{{
$participante
->
planoTrabalho
->
titulo
}}
">
@error('nomePlanoTrabalho')
<span class="
invalid
-
feedback
" role="
alert
" style="
overflow
:
visible
;
display
:
block
">
<strong>{{
$message
}}</strong>
</span>
@enderror
</div>
{{-- Arquivo --}}
<div class="
col
-
sm
-
7
">
<label for="
nomeTrabalho
">Anexo*</label> <a href="
{{
route
(
'baixar.plano'
,
[
'id'
=>
$participante
->
planoTrabalho
->
id
])
}}
">plano de trabalho atual</a>
<div class="
input
-
group
">
<div class="
input
-
group
-
prepend
">
<span class="
input
-
group
-
text
" id="
anexoPlanoTrabalho
">Selecione um arquivo:</span>
</div>
</div>
<div class="
col
-
sm
-
1
">
<div class="
custom
-
file
">
<a class="
delete
">
<input type="
file
" class="
custom
-
file
-
input
@
error
(
'anexoPlanoTrabalho'
)
is
-
invalid
@
enderror
" id="
anexoPlanoTrabalho
" aria-describedby="
anexoPlanoTrabalho
" name="
anexoPlanoTrabalho
[]
">
<img src="
/
img
/
icons
/
user
-
times
-
solid
.
svg
" style="
width
:
25
px
;
margin
-
top
:
35
px
">
<label class="
custom
-
file
-
label
" id="
custom
-
file
-
label
" for="
inputGroupFile01
">O arquivo deve ser no formato PDF de até 2MB.</label>
</a>
</div>
</div>
</div>
</div>
@error('anexoPlanoTrabalho')
<span class="
invalid
-
feedback
" role="
alert
" style="
overflow
:
visible
;
display
:
block
">
<strong>{{
$message
}}</strong>
</span>
@enderror
</div>
</div>
</div>
</div>
</div>
</div>
@endif
</div>
@endforeach
</div>
</div>
</div>
<button class="
btn
btn
-
danger
mt
-
2
mb
-
2
delete
" style='width:100%;margin-top:10px' @if(sizeof(
$participantes
) == 1) disabled @endif>@if(sizeof(
$participantes
) == 1)Limite minimo de participantes @else Remover @endif</button>
</div>
</div>
@endif
@endforeach
@endforeach
@endforeach
</div>
</div>
<
a href="
#"
class="btn btn-primary" id="addCoautor" style="width:100%;margin-top:10px">Participantes +</
a
>
<
button
class="
btn
btn
-
primary
" id="
addCoautor
" style="
width
:
100
%
;
margin
-
top
:
10
px
">Participantes +</
button
>
</div>
</div>
</div>
</div>
...
@@ -418,18 +561,38 @@
...
@@ -418,18 +561,38 @@
<script type="
text
/
javascript
">
<script type="
text
/
javascript
">
$(function() {
$(function() {
var qtdLinhas = 1;
var qtdLinhas = 1;
var
qtdParticipantes
=
$
(
'#qtdParticipantes'
)
.
val
();
const limiteMaxParticipantes = 3;
const limiteMinParticipantes = 1;
// Coautores
// Coautores
$('#addCoautor').click(function(e) {
$('#addCoautor').click(function(e) {
if
(
qtdParticipantes
<
100
)
{
var countParticipante = document.getElementById('countParticipante');
if (countParticipante.value < limiteMaxParticipantes) {
e.preventDefault();
e.preventDefault();
linha = montarLinhaInput();
linha = montarLinhaInput();
$('#participantes').append(linha);
$('#participantes').append(linha);
qtdParticipantes
++
setParticipanteDiv(parseInt(countParticipante.value) + 1);
}
var btnsDeletar = document.getElementsByClassName("
delete
");
for(var i = 0; i < btnsDeletar.length; i++) {
btnsDeletar[i].disabled = "";
$(btnsDeletar[i]).text("
Remover
participantes
");
}
if (countParticipante.value >= limiteMaxParticipantes) {
var btn = document.getElementById('addCoautor');
btn.disabled = "
true
";
$('#addCoautor').text("
Limite
de
participantes
atingido
");
}
// aplicarMascaras();
}
});
});
function setParticipanteDiv(qtdParticipante) {
var countParticipante = document.getElementById('countParticipante');
countParticipante.value = qtdParticipante;
}
// $('#addPlanoTrabalho').click(function(e) {
// $('#addPlanoTrabalho').click(function(e) {
// e.preventDefault();
// e.preventDefault();
// if (qtdLinhas < 4) {
// if (qtdLinhas < 4) {
...
@@ -446,11 +609,21 @@
...
@@ -446,11 +609,21 @@
// });
// });
$
(
document
)
.
on
(
'click'
,
'.delete'
,
function
()
{
$
(
document
)
.
on
(
'click'
,
'.delete'
,
function
()
{
if
(
qtdParticipantes
>
1
)
{
var
countParticipante
=
document
.
getElementById
(
'countParticipante'
);
qtdParticipantes
--
;
if
(
countParticipante
.
value
>=
limiteMinParticipantes
)
{
setParticipanteDiv
(
parseInt
(
countParticipante
.
value
)
-
1
);
$
(
this
)
.
closest
(
'#novoParticipante'
)
.
remove
();
$
(
this
)
.
closest
(
'#novoParticipante'
)
.
remove
();
document
.
getElementById
(
"addCoautor"
)
.
disabled
=
""
;
$
(
'#addCoautor'
)
.
text
(
"Adicionar participante"
);
if
(
countParticipante
.
value
==
limiteMinParticipantes
)
{
var
btnsDeletar
=
document
.
getElementsByClassName
(
"delete"
);
for
(
var
i
=
0
;
i
<
btnsDeletar
.
length
;
i
++
)
{
btnsDeletar
[
i
]
.
disabled
=
true
;
$
(
btnsDeletar
)
.
text
(
"Limite minimo de participantes"
);
}
}
return
false
;
return
false
;
}
}
});
});
$
(
document
)
.
on
(
'click'
,
'.deletePlano'
,
function
()
{
$
(
document
)
.
on
(
'click'
,
'.deletePlano'
,
function
()
{
if
(
qtdLinhas
>
1
)
{
if
(
qtdLinhas
>
1
)
{
...
@@ -515,93 +688,230 @@
...
@@ -515,93 +688,230 @@
function
montarLinhaInput
()
{
function
montarLinhaInput
()
{
return
"<div id="
+
"novoParticipante"
+
">"
+
return
`<div id="novoParticipante" style="display: block;">
"<div class='row'>"
+
<br>
"<div class='col-sm-9'>"
+
<h4>Dados do participante</h4>
"<br><h4>Dados do participante</h4>"
+
<h6>Dados pessoais</h6>
"</div>"
+
<input type="hidden" name="participante_id[]" value="0">
"<div class='col-sm-3'>"
+
<div class="row">
<div class="col-sm-5">
"</div>"
+
<label>Nome Completo*</label>
"</div>"
+
<input type="text" style="margin-bottom:10px" class="form-control @error('nomeParticipante') is-invalid @enderror" name="nomeParticipante[]" placeholder="Nome" value="" required>
"<div class="
+
"row"
+
">"
+
</div>
"<div class="
+
"col-sm-5"
+
">"
+
<div class="col-sm-4">
"<label>Nome Completo*</label>"
+
<label>E-mail*</label>
"<input"
+
" type="
+
'text'
+
" style="
+
"margin-bottom:10px"
+
" class="
+
'form-control'
+
" @error('nomeParticipante') is-invalid @enderror"
+
"name="
+
'nomeParticipante[]'
+
" placeholder="
+
"Nome"
+
">"
+
<input type="email" style="margin-bottom:10px" class="form-control @error('emailParticipante') is-invalid @enderror" name="emailParticipante[]" placeholder="email" value="" required>
"@error('nomeParticipante')"
+
</div>
"<span class='invalid-feedback'"
+
"role='alert'"
+
"style='overflow: visible; display:block'>"
+
<div class="col-sm-3">
"<strong>{{
$message
}}</strong>"
+
<label>Função*:</label>
"</span>"
+
<select class="form-control @error('funcaoParticipante') is-invalid @enderror" name="funcaoParticipante[]" id="funcaoParticipante" required>
"@enderror"
+
<option value="" disabled selected hidden>-- Função --</option>
"</div>"
+
@foreach($funcaoParticipantes as $funcaoParticipante)
"<div class="
+
"col-sm-4"
+
">"
+
<option value="{{$funcaoParticipante->id}}">{{$funcaoParticipante->nome}}</option>
"<label>E-mail*</label>"
+
@endforeach
"<input type='email'"
+
"style='margin-bottom:10px'"
+
"class="
+
"form-control @error('emailParticipante') is-invalid @enderror"
+
"name='emailParticipante[]'"
+
"placeholder='email' >"
+
</select>
"@error('emailParticipante')"
+
</div>
"<span class='invalid-feedback'"
+
"role='alert'"
+
"style='overflow: visible; display:block'>"
+
</div>
"<strong>{{
$message
}}</strong>"
+
<div id="dados_complemento_1">
"</span>"
+
<div class="form-group">
"@enderror"
+
<div class="row">
"</div>"
+
<div class="col-sm-4">
"<div class='col-sm-3'>"
+
<label for="">{{ __('CPF*') }}</label>
"<label>Função*:</label>"
+
<input type="text" class="form-control cpf" name="cpf[]" required>
"<select class="
+
"form-control @error('funcaoParticipante') is-invalid @enderror"
+
"name='funcaoParticipante[]'"
+
"id='funcaoParticipante'> "
+
</div>
"<option value='' disabled selected hidden> Função </option>"
+
<div class="col-sm-4">
"@foreach(
$funcaoParticipantes
as
$funcaoParticipante
)"
+
<label for="">{{ __('RG*') }}</label>
"<option value='
{
{$funcaoParticipante->id}}'>{{$funcaoParticipante->nome}
}
</option>"
+
<input type="text" class="form-control rg" name="rg[]" required>
"@endforeach"
+
</div>
"@error('funcaoParticipante')"
+
<div class="col-sm-4">
"<span class='invalid-feedback'"
+
"role='alert'"
+
"style='overflow: visible; display:block'>"
+
<label for="">{{ __('Celular*') }}</label>
"<strong>{{
$message
}}</strong>"
+
<input type="text" class="form-control celular" name="celular[]" required>
"</span>"
+
</div>
"@enderror"
+
</div>
"</select>"
+
</div>
"</div>"
+
<div class="form-group">
"</div>"
+
<div class="row">
"<h6 class='mb-1'>Possui plano de trabalho?</h6>"
+
<div class="col-sm-4">
"<button class="
+
"'btn btn-primary mt-2 mb-2 mr-1 simPlano'"
+
">Sim</button>"
+
<label for="">{{ __('Data de nascimento*') }}</label>
"<button class="
+
"'btn btn-primary mt-2 mb-2 mr-1 naoPlano'"
+
">Não</button>"
+
<input type="date" class="form-control" name="data_de_nascimento[]" required>
"<div id="
+
"planoHabilitado"
+
" style="
+
"'display:none;'"
+
">"
+
</div>
"<h5>Dados do plano de trabalho</h5>"
+
</div>
"<div class="
+
"row"
+
">"
+
</div>
"<div class="
+
"col-sm-4"
+
">"
+
<div class="form-group">
"<label>Titulo*</label>"
+
<div class="row">
"<input"
+
" type="
+
'text'
+
" style="
+
"margin-bottom:10px"
+
" class="
+
"form-control @error('nomePlanoTrabalho') is-invalid @enderror"
+
" name="
+
'nomePlanoTrabalho[]'
+
" placeholder="
+
"Nome"
+
">"
+
<div class="container">
"@error('nomePlanoTrabalho')"
+
<h6>Endereço do participante</h6>
"<span class='invalid-feedback'"
+
"role='alert'"
+
"style='overflow: visible; display:block'>"
+
</div>
"<strong>{{
$message
}}</strong>"
+
</div>
"</span>"
+
<div class="row">
"@enderror"
+
<div class="col-sm-3">
"</div>"
+
<label for="">{{ __('CEP*') }}</label>
"<div class="
+
"col-sm-7"
+
">"
+
<input type="text" class="form-control" name="cep[]" required>
"<label for="
+
"nomeTrabalho"
+
">Anexo* </label>"
+
</div>
</div>
"<div class="
+
"input-group"
+
">"
+
</div>
"<div class='input-group-prepend'>"
+
<div class="form-group">
"<span class='input-group-text' id='anexoPlanoTrabalho'>Selecione um arquivo:</span>"
+
<div class="row">
"</div>"
+
<div class="col-sm-6">
"<div class='custom-file'>"
+
<label for="">{{ __('Rua*') }}</label>
"<input type='file' class='custom-file-input @error('anexoPlanoTrabalho') is-invalid @enderror"
+
"id='anexoPlanoTrabalho'"
+
<input type="text" class="form-control" name="rua[]" required>
" aria-describedby='anexoPlanoTrabalho' name='anexoPlanoTrabalho[]'>"
+
</div>
"<label class='custom-file-label' id='custom-file-label' for='inputGroupFile01'>O arquivo deve ser no formato PDF de até 2mb.</label>"
+
<div class="col-sm-3">
"</div>"
+
<label for="">{{ __('Número*') }}</label>
"</div>"
+
<input type="text" class="form-control" name="numero[]" required>
"@error('anexoPlanoTrabalho')"
+
</div>
"<span class='invalid-feedback' role='alert' style='overflow: visible; display:block'>"
+
<div class="col-sm-3">
"<strong>{{
$message
}}</strong>"
+
<label for="">{{ __('Bairro*') }}</label>
"</span>"
+
<input type="text" class="form-control" name="bairro[]" required>
"@enderror"
+
</div>
"</div>"
+
</div>
"<div class="
+
"col-sm-1"
+
">"
+
</div>
"<a class="
+
"delete"
+
">"
+
<div class="form-group">
"<img src="
+
"{{ asset('/img/icons/user-times-solid.svg') }}"
+
" style="
+
"width:25px;margin-top:35px"
+
">"
+
<div class="row">
"</a>"
+
<div class="col-sm-4">
"</div>"
+
<label for="">{{ __('Cidade*') }}</label>
"</div>"
+
<input type="text" class="form-control " name="cidade[]" required>
"</div>"
+
</div>
<div class="col-sm-4">
<label for="">{{ __('Complemento*') }}</label>
<input type="text" class="form-control" name="complemento[]" required>
</div>
<div class="col-sm-4">
<label for="">{{ __('Estado*') }}</label>
<select name="uf[]" id="" class="form-control" required>
<option value="" disabled selected>-- UF --</option>
<option @if(old('uf') == 'AC') selected @endif value="AC">Acre</option>
<option @if(old('uf') == 'AL') selected @endif value="AL">Alagoas</option>
<option @if(old('uf') == 'AP') selected @endif value="AP">Amapá</option>
<option @if(old('uf') == 'AM') selected @endif value="AM">Amazonas</option>
<option @if(old('uf') == 'BA') selected @endif value="BA">Bahia</option>
<option @if(old('uf') == 'CE') selected @endif value="CE">Ceará</option>
<option @if(old('uf') == 'DF') selected @endif value="DF">Distrito Federal</option>
<option @if(old('uf') == 'ES') selected @endif value="ES">Espírito Santo</option>
<option @if(old('uf') == 'GO') selected @endif value="GO">Goiás</option>
<option @if(old('uf') == 'MA') selected @endif value="MA">Maranhão</option>
<option @if(old('uf') == 'MT') selected @endif value="MT">Mato Grosso</option>
<option @if(old('uf') == 'MS') selected @endif value="MS">Mato Grosso do Sul</option>
<option @if(old('uf') == 'MG') selected @endif value="MG">Minas Gerais</option>
<option @if(old('uf') == 'PA') selected @endif value="PA">Pará</option>
<option @if(old('uf') == 'PB') selected @endif value="PB">Paraíba</option>
<option @if(old('uf') == 'PR') selected @endif value="PR">Paraná</option>
<option @if(old('uf') == 'PE') selected @endif value="PE">Pernambuco</option>
<option @if(old('uf') == 'PI') selected @endif value="PI">Piauí</option>
<option @if(old('uf') == 'RJ') selected @endif value="RJ">Rio de Janeiro</option>
<option @if(old('uf') == 'RN') selected @endif value="RN">Rio Grande do Norte</option>
<option @if(old('uf') == 'RS') selected @endif value="RS">Rio Grande do Sul</option>
<option @if(old('uf') == 'RO') selected @endif value="RO">Rondônia</option>
<option @if(old('uf') == 'RR') selected @endif value="RR">Roraima</option>
<option @if(old('uf') == 'SC') selected @endif value="SC">Santa Catarina</option>
<option @if(old('uf') == 'SP') selected @endif value="SP">São Paulo</option>
<option @if(old('uf') == 'SE') selected @endif value="SE">Sergipe</option>
<option @if(old('uf') == 'TO') selected @endif value="TO">Tocantins</option>
</select>
</div>
</div>
</div>
<div class="form-group">
<div class="row">
<div class="container">
<h6>Dados do curso do participante</h6>
</div>
</div>
<div class="row">
<div class="col-sm-6">
<label for="">{{ __('Universidade*') }}</label>
<input type="text" class="form-control" name="universidade[]" required>
</div>
<div class="col-sm-6">
<label for="">{{ __('Curso*') }}</label>
<input type="text" class="form-control" name="curso[]" required>
</div>
</div>
</div>
<div class="form-group">
<div class="row">
<div class="col-sm-2">
<label for="">{{ __('Turno*') }}</label>
<select id="" class="form-control" name="turno[]" required>
<option value="" disabled selected>-- TURNO --</option>
@foreach ($enum_turno as $turno)
<option value="{{$turno}}">{{$turno}}</option>
@endforeach
</select>
</div>
<div class="col-sm-3">
<label for="">{{ __('Total de periodos do curso*') }}</label>
<select name="total_periodos[]" id="" class="form-control" onchange="gerarPeriodos(this)" required>
<option value="" disabled selected>-- TOTAL DE PERIODOS --</option>
<option value="6">6</option>
<option value="7">7</option>
<option value="8">8</option>
<option value="9">9</option>
<option value="10">10</option>
<option value="11">11</option>
<option value="12">12</option>
</select>
</div>
<div class="col-sm-2">
<label for="">{{ __('Periodo atual*') }}</label>
<select name="periodo_cursado[]" id="" class="form-control" required>
<option value="" disabled selected>-- PERÍODO ATUAL --</option>
</select>
</div>
<div class="col-sm-2">
<label for="">{{ __('Ordem de prioridade*') }}</label>
<select name="ordem_prioridade[]" id="" class="form-control" required>
<option value="" disabled selected>-- ORDEM --</option>
<option value="1">1º</option>
<option value="2">2º</option>
<option value="3">3º</option>
<option value="4">4º</option>
</select>
</div>
<div class="col-sm-3">
<label for="">{{ __('Média geral do curso*') }}</label>
<input type="number" class="form-control media" min="0" max="10" step="0.01" value="00.00" name="media_geral_curso[]" required>
</div>
</div>
</div>
</div>
<h6 class="mb-1">Possui plano de trabalho?</h6>
<button class="btn btn-primary mt-2 mb-2 simPlano">Sim</button>
<button class="btn btn-primary mt-2 mb-2 naoPlano">Não</button>
<div id="planoHabilitado" style="display:none;">
<h5>Dados do plano de trabalho</h5>
<div class="row">
<div class="col-sm-12">
<div id="planoTrabalho">
<div class="row">
<div class="col-sm-4">
<label>Titulo* </label>
<input type="text" style="margin-bottom:10px" class="form-control" name="nomePlanoTrabalho[]" placeholder="Nome" value="">
</div>
{{-- Arquivo --}}
<div class="col-sm-7">
<label for="nomeTrabalho">Anexo*</label>
<div class="input-group">
<div class="input-group-prepend">
<span class="input-group-text" id="anexoPlanoTrabalho">Selecione um arquivo:</span>
</div>
<div class="custom-file">
<input type="file" class="custom-file-input" id="anexoPlanoTrabalho" aria-describedby="anexoPlanoTrabalho" name="anexoPlanoTrabalho[]">
<label class="custom-file-label" id="custom-file-label" for="inputGroupFile01">O arquivo deve ser no formato PDF de até 2MB.</label>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
"<a href='#' class="
+
"'btn btn-danger mt-2 mb-2 delete'"
+
" style='width:100%;margin-top:10px'"
+
">Remover participante</a>"
+
</div>
"</div>"
;
<button class="btn btn-danger mt-2 mb-2 delete" style='width:100%;margin-top:10px' disabled>Limite minimo de participantes</button>
</div>`
;
}
}
// function montarLinhaInputPlanoTrabalho(){
// function montarLinhaInputPlanoTrabalho(){
...
@@ -747,5 +1057,35 @@
...
@@ -747,5 +1057,35 @@
})
})
}
}
$
(
document
)
.
ready
(
aplicarMascaras
());
function
aplicarMascaras
()
{
$
(
'.cpf'
)
.
mask
(
'000.000.000-00'
);
var
SPMaskBehavior
=
function
(
val
)
{
return
val
.
replace
(
/
\
D
/
g
,
''
)
.
length
===
11
?
'(00) 00000-0000'
:
'(00) 0000-00009'
;
},
spOptions
=
{
onKeyPress
:
function
(
val
,
e
,
field
,
options
)
{
field
.
mask
(
SPMaskBehavior
.
apply
({},
arguments
),
options
);
}
};
$
(
'.celular'
)
.
mask
(
SPMaskBehavior
,
spOptions
);
$
(
'.rg'
)
.
mask
(
'99.999.999-9'
);
$
(
'.media'
)
.
mask
(
'00.00'
);
}
function
gerarPeriodos
(
select
)
{
var
div
=
select
.
parentElement
.
parentElement
;
var
selectPeriodos
=
div
.
children
[
2
]
.
children
[
1
];
var
html
=
`<option value="" disabled selected>-- TOTAL DE PERIODOS --</option>`
;
for
(
var
i
=
0
;
i
<
parseInt
(
select
.
value
);
i
++
)
{
html
+=
`<option value="${i+1}">${i+1}º</option>`
;
}
$
(
selectPeriodos
)
.
html
(
''
);
$
(
selectPeriodos
)
.
append
(
html
);
}
</
script
>
</
script
>
@
endsection
@
endsection
resources/views/proponente/projetos.blade.php
View file @
b7d2533c
...
@@ -3,14 +3,15 @@
...
@@ -3,14 +3,15 @@
@
section
(
'content'
)
@
section
(
'content'
)
<
div
class
=
"container"
style
=
"margin-top: 100px;"
>
<
div
class
=
"container"
style
=
"margin-top: 100px;"
>
@
if
(
isset
(
$mensagem
))
{{
--
@
if
(
isset
(
$mensagem
))
<
div
class
=
"col-sm-12"
>
<
div
class
=
"col-sm-12"
>
<
br
>
<
br
>
<
div
class
=
"alert alert-success"
>
<
div
class
=
"alert alert-success"
>
<
p
>
{{
$mensagem
}}
</
p
>
<
p
>
{{
$mensagem
}}
</
p
>
</
div
>
</
div
>
</
div
>
</
div
>
@
endif
@
endif
--
}}
<
div
class
=
"container"
>
<
div
class
=
"container"
>
<
div
class
=
"row"
>
<
div
class
=
"row"
>
<
div
class
=
"col-sm-1"
>
<
div
class
=
"col-sm-1"
>
...
@@ -39,91 +40,105 @@
...
@@ -39,91 +40,105 @@
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
@
if
(
session
(
'mensagem'
))
<
div
class
=
"row"
>
<
div
class
=
"col-sm-12"
>
<
br
>
<
div
class
=
"alert alert-success"
>
<
p
>
{{
session
(
'mensagem'
)}}
</
p
>
</
div
>
</
div
>
</
div
>
@
endif
<
hr
>
<
hr
>
<
table
class
=
"table table-bordered"
>
<
div
class
=
"row"
>
<
thead
>
<
div
class
=
"col-md-12"
>
<
tr
>
<
table
class
=
"table table-bordered"
>
<
th
scope
=
"col"
>
Projeto
</
th
>
<
thead
>
<
th
scope
=
"col"
>
Status
</
th
>
<
tr
>
<
th
scope
=
"col"
>
Data
de
Criação
</
th
>
<
th
scope
=
"col"
>
Projeto
</
th
>
<
th
scope
=
"col"
>
Opção
</
th
>
<
th
scope
=
"col"
>
Status
</
th
>
</
tr
>
<
th
scope
=
"col"
>
Data
de
Criação
</
th
>
</
thead
>
<
th
scope
=
"col"
>
Opção
</
th
>
<
tbody
>
</
tr
>
@
foreach
(
$projetos
as
$projeto
)
</
thead
>
<
tbody
>
<
tr
>
@
foreach
(
$projetos
as
$projeto
)
<
td
>
{{
$projeto
->
titulo
}}
<
tr
>
</
td
>
<
td
>
@
if
(
$projeto
->
status
==
'Avaliado'
)
{{
$projeto
->
titulo
}}
<
td
style
=
"color: rgb(6, 85, 6)"
>
Avaliado
</
td
>
</
td
>
@
elseif
(
$projeto
->
status
==
'Submetido'
)
@
if
(
$projeto
->
status
==
'Avaliado'
)
<
td
style
=
"color: rgb(0, 0, 0)"
>
Submetido
</
td
>
<
td
style
=
"color: rgb(6, 85, 6)"
>
Avaliado
</
td
>
@
elseif
(
$projeto
->
status
==
'Rascunho'
)
@
elseif
(
$projeto
->
status
==
'Submetido'
)
<
td
style
=
"color: rgb(0, 0, 0)"
>
Rascunho
</
td
>
<
td
style
=
"color: rgb(0, 0, 0)"
>
Submetido
</
td
>
@
endif
@
elseif
(
$projeto
->
status
==
'Rascunho'
)
<
td
>
{{
date
(
'd/m/Y'
,
strtotime
(
$projeto
->
updated_at
))
}}
</
td
>
<
td
style
=
"color: rgb(0, 0, 0)"
>
Rascunho
</
td
>
<
td
>
@
endif
<
div
class
=
"btn-group dropright dropdown-options"
>
<
td
>
{{
date
(
'd/m/Y'
,
strtotime
(
$projeto
->
updated_at
))
}}
</
td
>
<
a
id
=
"options"
class
=
"dropdown-toggle "
data
-
toggle
=
"dropdown"
aria
-
haspopup
=
"true"
aria
-
expanded
=
"false"
>
<
td
>
<
img
src
=
"
{
{asset('img/icons/ellipsis-v-solid.svg')}
}
"
style
=
"width:8px"
>
<
div
class
=
"btn-group dropright dropdown-options"
>
</
a
>
<
a
id
=
"options"
class
=
"dropdown-toggle "
data
-
toggle
=
"dropdown"
aria
-
haspopup
=
"true"
aria
-
expanded
=
"false"
>
<
div
class
=
"dropdown-menu"
>
<
img
src
=
"
{
{asset('img/icons/ellipsis-v-solid.svg')}
}
"
style
=
"width:8px"
>
@
if
(
$projeto
->
evento
->
inicioSubmissao
<=
$hoje
&&
$hoje
<=
$projeto
->
evento
->
fimSubmissao
)
</
a
>
<
a
href
=
"{{ route('trabalho.editar', ['id' =>
$projeto->id
]) }}"
class
=
"dropdown-item"
style
=
"text-align: center;"
>
<
div
class
=
"dropdown-menu"
>
Editar
@
if
(
$projeto
->
evento
->
inicioSubmissao
<=
$hoje
&&
$hoje
<=
$projeto
->
evento
->
fimSubmissao
)
</
a
>
<
a
href
=
"{{ route('trabalho.editar', ['id' =>
$projeto->id
]) }}"
class
=
"dropdown-item"
style
=
"text-align: center;"
>
<
hr
class
=
"dropdown-hr"
>
Editar
@
else
</
a
>
@
endif
<
a
href
=
"{{ route('trabalho.show', ['id' =>
$projeto->id
]) }}"
class
=
"dropdown-item"
style
=
"text-align: center"
>
Visualizar
</
a
>
{{
--
<
a
href
=
""
class
=
"dropdown-item"
style
=
"text-align: center"
>
Recorrer
</
a
>
<
a
href
=
""
class
=
"dropdown-item"
style
=
"text-align: center"
>
Resultado
</
a
>
--
}}
@
if
(
$projeto
->
status
==
'Submetido'
)
<
hr
class
=
"dropdown-hr"
>
<
hr
class
=
"dropdown-hr"
>
<!--
Button
trigger
modal
-->
@
else
<
button
type
=
"button"
class
=
"dropdown-item dropdown-item-delete"
style
=
"text-align: center"
data
-
toggle
=
"modal"
data
-
target
=
"#modal
{
{$projeto->id}
}
"
>
<
img
src
=
"
{
{asset('img/icons/logo_lixeira.png')}
}
"
alt
=
""
>
Deletar
</
button
>
@
endif
@
endif
<
a
href
=
"{{ route('trabalho.show', ['id' =>
$projeto->id
]) }}"
class
=
"dropdown-item"
style
=
"text-align: center"
>
</
div
>
Visualizar
</
div
>
</
a
>
</
td
>
{{
--
<
a
href
=
""
class
=
"dropdown-item"
style
=
"text-align: center"
>
</
tr
>
Recorrer
</
a
>
<!--
Modal
-->
<
a
href
=
""
class
=
"dropdown-item"
style
=
"text-align: center"
>
<
div
class
=
"modal fade"
id
=
"modal
{
{$projeto->id}
}
"
tabindex
=
"-1"
role
=
"dialog"
aria
-
labelledby
=
"exampleModalLabel"
aria
-
hidden
=
"true"
>
Resultado
<
div
class
=
"modal-dialog"
>
</
a
>
--
}}
<
div
class
=
"modal-content"
>
@
if
(
$projeto
->
status
==
'Submetido'
)
<
div
class
=
"modal-header"
>
<
hr
class
=
"dropdown-hr"
>
<
h5
class
=
"modal-title"
id
=
"exampleModalLabel"
>
Deletar
o
projeto
:
{{
$projeto
->
titulo
}}
</
h5
>
<!--
Button
trigger
modal
-->
<
button
type
=
"button"
class
=
"close"
data
-
dismiss
=
"modal"
aria
-
label
=
"Close"
>
<
button
type
=
"button"
class
=
"dropdown-item dropdown-item-delete"
style
=
"text-align: center"
data
-
toggle
=
"modal"
data
-
target
=
"#modal
{
{$projeto->id}
}
"
>
<
span
aria
-
hidden
=
"true"
>&
times
;
</
span
>
<
img
src
=
"
{
{asset('img/icons/logo_lixeira.png')}
}
"
alt
=
""
>
Deletar
</
button
>
</
button
>
</
div
>
@
endif
<
div
class
=
"modal-body"
>
<
p
>
Você
tem
certeza
que
deseja
deletar
o
projeto
:
{{
$projeto
->
titulo
}}
?</
p
>
</
div
>
</
div
>
</
div
>
<
div
class
=
"modal-footer"
>
</
td
>
<
button
type
=
"button"
class
=
"btn btn-secondary"
data
-
dismiss
=
"modal"
>
Cancelar
</
button
>
</
tr
>
<
a
href
=
"{{ route('trabalho.destroy', ['id' =>
$projeto->id
]) }}"
class
=
"btn btn-primary"
>
Deletar
<!--
Modal
-->
</
a
>
<
div
class
=
"modal fade"
id
=
"modal
{
{$projeto->id}
}
"
tabindex
=
"-1"
role
=
"dialog"
aria
-
labelledby
=
"exampleModalLabel"
aria
-
hidden
=
"true"
>
<
div
class
=
"modal-dialog"
>
<
div
class
=
"modal-content"
>
<
div
class
=
"modal-header"
>
<
h5
class
=
"modal-title"
id
=
"exampleModalLabel"
>
Deletar
o
projeto
:
{{
$projeto
->
titulo
}}
</
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
deletar
o
projeto
:
{{
$projeto
->
titulo
}}
?</
p
>
</
div
>
<
div
class
=
"modal-footer"
>
<
button
type
=
"button"
class
=
"btn btn-secondary"
data
-
dismiss
=
"modal"
>
Cancelar
</
button
>
<
a
href
=
"{{ route('trabalho.destroy', ['id' =>
$projeto->id
]) }}"
class
=
"btn btn-primary"
>
Deletar
</
a
>
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
@
endforeach
@
endforeach
</
tbody
>
</
tbody
>
</
table
>
</
table
>
</
div
>
</
div
>
</
div
>
</
div
>
@
endsection
@
endsection
...
...
routes/web.php
View file @
b7d2533c
...
@@ -41,12 +41,15 @@ Route::group(['middleware' => ['isTemp', 'auth', 'verified']], function(){
...
@@ -41,12 +41,15 @@ Route::group(['middleware' => ['isTemp', 'auth', 'verified']], function(){
//######## Rotas Avaliador ####################################
//######## Rotas Avaliador ####################################
Route
::
prefix
(
'avaliador'
)
->
name
(
'avaliador.'
)
->
group
(
function
(){
Route
::
prefix
(
'avaliador'
)
->
name
(
'avaliador.'
)
->
group
(
function
(){
Route
::
get
(
'/index'
,
'AvaliadorController@index'
)
->
name
(
'index'
)
->
middleware
(
'auth'
);
Route
::
get
(
'/index'
,
'AvaliadorController@index'
)
->
name
(
'index'
)
->
middleware
(
'auth'
);
Route
::
get
(
'/trabalhos'
,
'AvaliadorController@visualizarTrabalhos'
)
->
name
(
'visualizarTrabalho'
)
->
middleware
(
'auth'
);
Route
::
get
(
'/trabalhos'
,
'AvaliadorController@visualizarTrabalhos'
)
->
name
(
'visualizarTrabalho'
)
->
middleware
(
'auth'
);
Route
::
post
(
'/parecer'
,
'AvaliadorController@parecer'
)
->
name
(
'parecer'
)
->
middleware
(
'auth'
);
Route
::
get
(
'/planos'
,
'AvaliadorController@listarPlanos'
)
->
name
(
'listarPlanos'
)
->
middleware
(
'auth'
);
Route
::
get
(
'/editais'
,
'AvaliadorController@editais'
)
->
name
(
'editais'
)
->
middleware
(
'auth'
);
Route
::
post
(
'/parecer'
,
'AvaliadorController@parecer'
)
->
name
(
'parecer'
)
->
middleware
(
'auth'
);
Route
::
post
(
'/Enviarparecer'
,
'AvaliadorController@enviarParecer'
)
->
name
(
'enviarParecer'
)
->
middleware
(
'auth'
);
Route
::
post
(
'/parecer/plano'
,
'AvaliadorController@parecerPlano'
)
->
name
(
'parecer.plano'
)
->
middleware
(
'auth'
);
Route
::
get
(
'/Resposta'
,
'AvaliadorController@conviteResposta'
)
->
name
(
'conviteResposta'
)
->
middleware
(
'auth'
);
Route
::
get
(
'/editais'
,
'AvaliadorController@editais'
)
->
name
(
'editais'
)
->
middleware
(
'auth'
);
Route
::
post
(
'/Enviarparecer'
,
'AvaliadorController@enviarParecer'
)
->
name
(
'enviarParecer'
)
->
middleware
(
'auth'
);
Route
::
post
(
'/Enviarparecer'
,
'AvaliadorController@enviarParecerPlano'
)
->
name
(
'enviarParecerPlano'
)
->
middleware
(
'auth'
);
Route
::
get
(
'/Resposta'
,
'AvaliadorController@conviteResposta'
)
->
name
(
'conviteResposta'
)
->
middleware
(
'auth'
);
});
});
...
@@ -73,6 +76,14 @@ Route::prefix('avaliador')->name('avaliador.')->group(function(){
...
@@ -73,6 +76,14 @@ Route::prefix('avaliador')->name('avaliador.')->group(function(){
Route
::
get
(
'/participante/index'
,
'ParticipanteController@index'
)
->
name
(
'participante.index'
);
Route
::
get
(
'/participante/index'
,
'ParticipanteController@index'
)
->
name
(
'participante.index'
);
Route
::
get
(
'/participante/edital/{id}'
,
'ParticipanteController@edital'
)
->
name
(
'participante.edital'
);
Route
::
get
(
'/participante/edital/{id}'
,
'ParticipanteController@edital'
)
->
name
(
'participante.edital'
);
//######### Plano de Trablho ########################################
Route
::
prefix
(
'/plano/trabalho'
)
->
name
(
'plano.trabalho.'
)
->
group
(
function
(){
Route
::
get
(
'/index/{evento_id}'
,
'PlanoTrabalhoController@index'
)
->
name
(
'index'
);
Route
::
get
(
'/selecionar/{evento_id}'
,
'PlanoTrabalhoController@selecionarPlanos'
)
->
name
(
'selecionarPlanos'
);
Route
::
post
(
'/atribuicao'
,
'PlanoTrabalhoController@atribuicao'
)
->
name
(
'atribuicao'
);
});
//########## Area da comissao ###################################
//########## Area da comissao ###################################
Route
::
get
(
'/comissoes'
,
'EventoController@listComissao'
)
->
name
(
'comissoes'
);
Route
::
get
(
'/comissoes'
,
'EventoController@listComissao'
)
->
name
(
'comissoes'
);
Route
::
get
(
'/area/comissao'
,
'EventoController@listComissaoTrabalhos'
)
->
name
(
'area.comissao'
);
Route
::
get
(
'/area/comissao'
,
'EventoController@listComissaoTrabalhos'
)
->
name
(
'area.comissao'
);
...
@@ -102,7 +113,7 @@ Route::prefix('avaliador')->name('avaliador.')->group(function(){
...
@@ -102,7 +113,7 @@ Route::prefix('avaliador')->name('avaliador.')->group(function(){
Route
::
get
(
'/edital/{id}/projetos'
,
'TrabalhoController@projetosDoEdital'
)
->
name
(
'projetos.edital'
);
Route
::
get
(
'/edital/{id}/projetos'
,
'TrabalhoController@projetosDoEdital'
)
->
name
(
'projetos.edital'
);
Route
::
get
(
'/projeto/{id}/visualizar'
,
'TrabalhoController@show'
)
->
name
(
'trabalho.show'
);
Route
::
get
(
'/projeto/{id}/visualizar'
,
'TrabalhoController@show'
)
->
name
(
'trabalho.show'
);
Route
::
get
(
'/projeto/{id}/editar'
,
'TrabalhoController@edit'
)
->
name
(
'trabalho.editar'
);
Route
::
get
(
'/projeto/{id}/editar'
,
'TrabalhoController@edit'
)
->
name
(
'trabalho.editar'
);
Route
::
post
(
'/projeto/{id}/atualizar'
,
'TrabalhoController@
update'
)
->
name
(
'trabalho.update'
);
Route
::
post
(
'/projeto/{id}/atualizar'
,
'TrabalhoController@
atualizar'
)
->
name
(
'trabalho.update'
);
Route
::
get
(
'/projeto/{id}/excluir'
,
'TrabalhoController@destroy'
)
->
name
(
'trabalho.destroy'
);
Route
::
get
(
'/projeto/{id}/excluir'
,
'TrabalhoController@destroy'
)
->
name
(
'trabalho.destroy'
);
Route
::
get
(
'/projeto/{id}/excluirParticipante'
,
'TrabalhoController@excluirParticipante'
)
->
name
(
'trabalho.excluirParticipante'
);
Route
::
get
(
'/projeto/{id}/excluirParticipante'
,
'TrabalhoController@excluirParticipante'
)
->
name
(
'trabalho.excluirParticipante'
);
...
...
Prev
1
2
Next
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