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
a3626e5e
Commit
a3626e5e
authored
Jun 01, 2021
by
Danillo Bion
Browse files
Merge branch 'master' of
https://github.com/lmts-ufape/submeta
into modificacoes_layout_minha_conta
parents
4685346c
a1caf480
Changes
5
Hide whitespace changes
Inline
Side-by-side
app/Http/Controllers/TrabalhoController.php
View file @
a3626e5e
...
@@ -834,6 +834,7 @@ class TrabalhoController extends Controller
...
@@ -834,6 +834,7 @@ class TrabalhoController extends Controller
}
}
public
function
salvar
(
Request
$request
)
{
public
function
salvar
(
Request
$request
)
{
// dd($request->all());
$edital
=
Evento
::
find
(
$request
->
editalId
);
$edital
=
Evento
::
find
(
$request
->
editalId
);
$hoje
=
now
();
$hoje
=
now
();
// dd($request->all());
// dd($request->all());
...
...
resources/views/evento/formulario/anexos.blade.php
View file @
a3626e5e
...
@@ -22,7 +22,7 @@
...
@@ -22,7 +22,7 @@
@endcomponent
@endcomponent
</div>
</div>
<div
class=
"form-group col-md-6"
>
<div
class=
"form-group col-md-6"
>
@component('componentes.input', ['label' => '
Anexo
da Planilha de Pontuação(.xlsx,.xls,.ods)'])
@component('componentes.input', ['label' => '
Valor
da Planilha de Pontuação(.xlsx,.xls,.ods)'])
<input
type=
"file"
class=
"input-group-text"
name=
"anexoPlanilha"
placeholder=
"anexoPlanoTrabalho"
accept=
".xlsx, .xls, .ods"
required
/>
<input
type=
"file"
class=
"input-group-text"
name=
"anexoPlanilha"
placeholder=
"anexoPlanoTrabalho"
accept=
".xlsx, .xls, .ods"
required
/>
@endcomponent
@endcomponent
</div>
</div>
...
...
resources/views/evento/formulario/participantes.blade.php
View file @
a3626e5e
...
@@ -18,6 +18,166 @@
...
@@ -18,6 +18,166 @@
<li
id=
"item"
>
<li
id=
"item"
>
<div
style=
"margin-bottom:15px"
>
<div
style=
"margin-bottom:15px"
>
<div
id=
"participante"
>
<div
id=
"participante"
>
{{--
<div
class=
"form-row"
style=
"display: none"
id=
"participantePrimeiro"
>
<button
type=
"button"
class=
"btn btn-danger"
id=
"buttonRemover"
onclick=
"removerPart(this)"
>
Remover participante
</button>
<div
class=
"col-md-12"
>
<a
class=
"btn btn-light"
data-toggle=
"collapse"
id=
"idCollapseParticipante"
href=
"#collapseParticipante"
role=
"button"
aria-expanded=
"false"
aria-controls=
"collapseParticipante"
style=
"width: 100%; text-align:left"
>
<div
class=
"d-flex justify-content-between align-items-center"
>
<h4
id=
"tituloParticipante"
style=
"color: #01487E; font-size:17px; margin-top:5px"
>
Participante
<span
id=
"pontos"
style=
"display: none;"
>
:
</span>
<span
style=
"display: none;"
id=
"display"
></span>
</h4>
</div>
</a>
</div>
<div
class=
"col-md-12"
>
<div
class=
"collapse"
id=
"collapseParticipante"
>
<div
class=
"container"
>
<div
class=
"row"
>
<input
type=
"hidden"
name=
"funcaoParticipante[]"
value=
"4"
>
<div
class=
"col-md-12 mt-3"
><h5>
Dados do participante
</h5></div>
<div
class=
"col-6"
>
@component('componentes.input', ['label' => 'Nome completo'])
<input
type=
"text"
class=
"form-control "
id=
"nomeParticipante"
name=
"nomeParticipante[]"
placeholder=
"Nome Completo"
required
/>
@endcomponent
</div>
<div
class=
"col-6"
>
@component('componentes.input', ['label' => 'E-mail'])
<input
type=
"email"
class=
"form-control"
name=
"emailParticipante[]"
placeholder=
"E-mail"
required
/>
@endcomponent
</div>
<div
class=
"col-6"
>
@component('componentes.input', ['label' => 'Data de nascimento'])
<input
type=
"date"
class=
"form-control"
name=
"data_de_nascimento[]"
placeholder=
"Data de nascimento"
required
/>
@endcomponent
</div>
<div
class=
"col-6"
>
@component('componentes.input', ['label' => 'CPF'])
<input
type=
"text"
class=
"form-control cpf"
name=
"cpf[]"
placeholder=
"CPF"
required
/>
@endcomponent
</div>
<div
class=
"col-6"
>
@component('componentes.input', ['label' => 'RG'])
<input
type=
"number"
class=
"form-control"
min=
"1"
maxlength=
"8"
name=
"rg[]"
placeholder=
"RG"
required
/>
@endcomponent
</div>
<div
class=
"col-6"
>
@component('componentes.input', ['label' => 'Celular'])
<input
type=
"tel"
class=
"form-control celular"
name=
"celular[]"
placeholder=
"Celular"
required
/>
@endcomponent
</div>
<div
class=
"col-md-12"
><h5>
Endereço
</h5></div>
<div
class=
"col-6"
>
@component('componentes.input', ['label' => 'CEP'])
<input
type=
"number"
class=
"form-control"
name=
"cep[]"
placeholder=
"CEP"
required
/>
@endcomponent
</div>
<div
class=
"col-6"
>
@component('componentes.select', ['label' => 'Estado'])
<select
name=
"uf[]"
id=
"estado"
class=
"form-control"
style=
"visibility: visible"
required
>
<option
value=
""
disabled
selected
>
-- Selecione uma opção --
</option>
@foreach ($estados as $sigla => $nome)
<option
@
if
(
old
('
uf
'
) =
=
$
sigla
)
selected
@
endif
value=
"{{ $sigla }}"
>
{{ $nome }}
</option>
@endforeach
</select>
@endcomponent
</div>
<div
class=
"col-6"
>
@component('componentes.input', ['label' => 'Cidade'])
<input
type=
"text"
class=
"form-control"
name=
"cidade[]"
placeholder=
"Cidade"
required
/>
@endcomponent
</div>
<div
class=
"col-6"
>
@component('componentes.input', ['label' => 'Bairro'])
<input
type=
"text"
class=
"form-control"
name=
"bairro[]"
placeholder=
"Bairro"
required
/>
@endcomponent
</div>
<div
class=
"col-6"
>
@component('componentes.input', ['label' => 'Rua'])
<input
type=
"text"
class=
"form-control"
name=
"rua[]"
placeholder=
"Rua"
required
/>
@endcomponent
</div>
<div
class=
"col-6"
>
@component('componentes.input', ['label' => 'Número'])
<input
type=
"text"
class=
"form-control"
name=
"numero[]"
placeholder=
"Número"
required
/>
@endcomponent
</div>
<div
class=
"col-12"
>
@component('componentes.input', ['label' => 'Complemento'])
<input
type=
"text"
id=
"complemento"
class=
"form-control"
name=
"complemento[]"
pattern=
"[A-Za-z]+"
placeholder=
"Complemento"
required
/>
@endcomponent
</div>
<div
class=
"col-md-12"
><h5>
Dados do curso
</h5></div>
<div
class=
"col-6"
>
@component('componentes.input', ['label' => 'Universidade'])
<input
type=
"text"
class=
"form-control"
name=
"universidade[]"
placeholder=
"Universidade"
required
/>
@endcomponent
</div>
<div
class=
"col-6"
>
@component('componentes.input', ['label' => 'Curso'])
<input
type=
"text"
class=
"form-control"
name=
"curso[]"
placeholder=
"Curso"
required
/>
@endcomponent
</div>
<div
class=
"col-6"
>
@component('componentes.select', ['label' => 'Turno'])
<select
name=
"turno[]"
class=
"form-control"
required
>
<option
value=
""
disabled
selected
>
-- Selecione uma opção --
</option>
@foreach ($enum_turno as $key => $value)
<option
@
if
(
old
('
turno
'
) =
=
$
value
)
selected
@
endif
value=
"{{ $value }}"
>
{{ $value }}
</option>
@endforeach
</select>
@endcomponent
</div>
@php
$options = array('6' => 6, '7' => 7,'8' => 8,'9' => 9,'10' => 10,'11' => 11,'12' => 12);
@endphp
<div
class=
"col-6"
>
@component('componentes.select', ['label' => 'Total de períodos do curso'])
<select
name=
"total_periodos[]"
class=
"form-control"
onchange=
"gerarPeriodo(this)"
required
>
<option
value=
""
disabled
selected
>
-- Selecione uma opção --
</option>
@foreach ($options as $key => $value)
<option
@
if
(
old
('
total_periodos
'
) =
=
$
key
)
selected
@
endif
value=
"{{ $key }}"
>
{{ $value }}
</option>
@endforeach
</select>
@endcomponent
</div>
<div
class=
"col-6"
>
@component('componentes.select', ['label' => 'Período atual'])
<select
name=
"periodo_atual[]"
class=
"form-control"
required
>
<option
value=
""
disabled
selected
>
-- Selecione uma opção --
</option>
</select>
@endcomponent
</div>
<div
class=
"col-6"
>
@component('componentes.select', ['label' => 'Ordem de prioridade'])
<select
name=
"ordem_prioridade[]"
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>
</select>
@endcomponent
</div>
<div
class=
"col-6"
>
@component('componentes.input', ['label' => 'Coeficiente de rendimento'])
<input
type=
"number"
class=
"form-control media"
name=
"media_geral_curso[]"
min=
"0"
max=
"10"
step=
"0.01"
required
>
@endcomponent
</div>
<div
class=
"col-md-12"
><h5>
Plano de trabalho
</h5></div>
<div
class=
"col-6"
>
@component('componentes.input', ['label' => 'Título'])
<input
type=
"text"
class=
"form-control"
name=
"nomePlanoTrabalho[]"
placeholder=
"Digite o título do plano de trabalho"
required
>
@endcomponent
</div>
<div
class=
"col-6"
>
@component('componentes.input', ['label' => 'Anexo(.pdf)'])
<input
type=
"file"
class=
"input-group-text"
name=
"anexoPlanoTrabalho[]"
accept=
".pdf"
placeholder=
"Anexo do Plano de Trabalho"
required
/>
@endcomponent
</div>
</div>
</div>
</div>
</div>
</div>
--}}
<div
class=
"form-row"
>
<div
class=
"form-row"
>
{{--
<button
type=
"button"
onload=
"myScript(this)"
onclick=
"subir(this)"
>
Subir
</button>
{{--
<button
type=
"button"
onload=
"myScript(this)"
onclick=
"subir(this)"
>
Subir
</button>
<button
type=
"button"
onload=
"myScript(this)"
onclick=
"descer(this)"
>
Descer
</button>
--}}
<button
type=
"button"
onload=
"myScript(this)"
onclick=
"descer(this)"
>
Descer
</button>
--}}
...
@@ -37,7 +197,7 @@
...
@@ -37,7 +197,7 @@
<div
class=
"col-md-12 mt-3"
><h5>
Dados do participante
</h5></div>
<div
class=
"col-md-12 mt-3"
><h5>
Dados do participante
</h5></div>
<div
class=
"col-6"
>
<div
class=
"col-6"
>
@component('componentes.input', ['label' => 'Nome completo'])
@component('componentes.input', ['label' => 'Nome completo'])
<input
type=
"text"
class=
"form-control "
id=
"nomeParticipante"
name=
"nomeParticipante[]"
placeholder=
"Nome Completo"
required
/>
<input
type=
"text"
class=
"form-control "
name=
"nomeParticipante[]"
placeholder=
"Nome Completo"
required
/>
@endcomponent
@endcomponent
</div>
</div>
<div
class=
"col-6"
>
<div
class=
"col-6"
>
...
@@ -104,7 +264,7 @@
...
@@ -104,7 +264,7 @@
</div>
</div>
<div
class=
"col-12"
>
<div
class=
"col-12"
>
@component('componentes.input', ['label' => 'Complemento'])
@component('componentes.input', ['label' => 'Complemento'])
<input
type=
"text"
id=
"complemento"
class=
"form-control"
name=
"complemento[]"
pattern=
"[A-Za-z]+"
placeholder=
"Complemento"
required
/>
<input
type=
"text"
class=
"form-control"
name=
"complemento[]"
pattern=
"[A-Za-z]+"
placeholder=
"Complemento"
required
/>
@endcomponent
@endcomponent
</div>
</div>
<div
class=
"col-md-12"
><h5>
Dados do curso
</h5></div>
<div
class=
"col-md-12"
><h5>
Dados do curso
</h5></div>
...
...
resources/views/evento/formulario/proponente.blade.php
View file @
a3626e5e
...
@@ -32,7 +32,7 @@
...
@@ -32,7 +32,7 @@
</div>
</div>
<div
class=
"form-group col-md-6"
>
<div
class=
"form-group col-md-6"
>
<label
for=
"linkGrupo"
>
Link do grupo de pesquisa
<
span
style=
"color: red; font-weight:bold"
>
*
</span><
/label>
<label
for=
"linkGrupo"
>
Link do grupo de pesquisa
</label>
<input
class=
"form-control @error('linkGrupo') is-invalid @enderror"
type=
"url"
name=
"linkGrupo"
<input
class=
"form-control @error('linkGrupo') is-invalid @enderror"
type=
"url"
name=
"linkGrupo"
value=
"{{old('linkGrupo') !== null ? old('linkGrupo') : (isset($rascunho) ? $rascunho->linkGrupoPesquisa : '')}}"
required
>
value=
"{{old('linkGrupo') !== null ? old('linkGrupo') : (isset($rascunho) ? $rascunho->linkGrupoPesquisa : '')}}"
required
>
...
...
resources/views/evento/submeterTrabalho.blade.php
View file @
a3626e5e
...
@@ -29,6 +29,330 @@
...
@@ -29,6 +29,330 @@
</
div
>
</
div
>
</
div
>
</
div
>
</
form
>
</
form
>
<
div
id
=
"participanteFirst"
>
<
div
class
=
"form-row"
style
=
"display: none"
id
=
"participantePrimeiro"
>
<
button
type
=
"button"
class
=
"btn btn-danger"
id
=
"buttonRemover"
onclick
=
"removerPart(this)"
>
Remover
participante
</
button
>
<
div
class
=
"col-md-12"
>
<
a
class
=
"btn btn-light"
data
-
toggle
=
"collapse"
id
=
"idCollapseParticipante"
href
=
"#collapseParticipante"
role
=
"button"
aria
-
expanded
=
"false"
aria
-
controls
=
"collapseParticipante"
style
=
"width: 100%; text-align:left"
>
<
div
class
=
"d-flex justify-content-between align-items-center"
>
<
h4
id
=
"tituloParticipante"
style
=
"color: #01487E; font-size:17px; margin-top:5px"
>
Participante
<
span
id
=
"pontos"
style
=
"display: none;"
>:</
span
>
<
span
style
=
"display: none;"
id
=
"display"
></
span
>
</
h4
>
</
div
>
</
a
>
</
div
>
<
div
class
=
"col-md-12"
>
<
div
class
=
"collapse"
id
=
"collapseParticipante"
>
<
div
class
=
"container"
>
<
div
class
=
"row"
>
<
input
type
=
"hidden"
name
=
"funcaoParticipante[]"
value
=
"4"
>
<
div
class
=
"col-md-12 mt-3"
><
h5
>
Dados
do
participante
</
h5
></
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Nome completo'
])
<
input
type
=
"text"
class
=
"form-control "
id
=
"nomeParticipante"
name
=
"nomeParticipante[]"
placeholder
=
"Nome Completo"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'E-mail'
])
<
input
type
=
"email"
class
=
"form-control"
name
=
"emailParticipante[]"
placeholder
=
"E-mail"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Data de nascimento'
])
<
input
type
=
"date"
class
=
"form-control"
name
=
"data_de_nascimento[]"
placeholder
=
"Data de nascimento"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'CPF'
])
<
input
type
=
"text"
class
=
"form-control cpf"
name
=
"cpf[]"
placeholder
=
"CPF"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'RG'
])
<
input
type
=
"number"
class
=
"form-control"
min
=
"1"
maxlength
=
"8"
name
=
"rg[]"
placeholder
=
"RG"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Celular'
])
<
input
type
=
"tel"
class
=
"form-control celular"
name
=
"celular[]"
placeholder
=
"Celular"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-md-12"
><
h5
>
Endereço
</
h5
></
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'CEP'
])
<
input
type
=
"number"
class
=
"form-control"
name
=
"cep[]"
placeholder
=
"CEP"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.select'
,
[
'label'
=>
'Estado'
])
<
select
name
=
"uf[]"
id
=
"estado"
class
=
"form-control"
style
=
"visibility: visible"
required
>
<
option
value
=
""
disabled
selected
>--
Selecione
uma
opção
--</
option
>
@
foreach
(
$estados
as
$sigla
=>
$nome
)
<
option
@
if
(
old
(
'uf'
)
==
$sigla
)
selected
@
endif
value
=
"{{
$sigla
}}"
>
{{
$nome
}}
</
option
>
@
endforeach
</
select
>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Cidade'
])
<
input
type
=
"text"
class
=
"form-control"
name
=
"cidade[]"
placeholder
=
"Cidade"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Bairro'
])
<
input
type
=
"text"
class
=
"form-control"
name
=
"bairro[]"
placeholder
=
"Bairro"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Rua'
])
<
input
type
=
"text"
class
=
"form-control"
name
=
"rua[]"
placeholder
=
"Rua"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Número'
])
<
input
type
=
"text"
class
=
"form-control"
name
=
"numero[]"
placeholder
=
"Número"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-12"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Complemento'
])
<
input
type
=
"text"
id
=
"complemento"
class
=
"form-control"
name
=
"complemento[]"
pattern
=
"[A-Za-z]+"
placeholder
=
"Complemento"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-md-12"
><
h5
>
Dados
do
curso
</
h5
></
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Universidade'
])
<
input
type
=
"text"
class
=
"form-control"
name
=
"universidade[]"
placeholder
=
"Universidade"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Curso'
])
<
input
type
=
"text"
class
=
"form-control"
name
=
"curso[]"
placeholder
=
"Curso"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.select'
,
[
'label'
=>
'Turno'
])
<
select
name
=
"turno[]"
class
=
"form-control"
required
>
<
option
value
=
""
disabled
selected
>--
Selecione
uma
opção
--</
option
>
@
foreach
(
$enum_turno
as
$key
=>
$value
)
<
option
@
if
(
old
(
'turno'
)
==
$value
)
selected
@
endif
value
=
"{{
$value
}}"
>
{{
$value
}}
</
option
>
@
endforeach
</
select
>
@
endcomponent
</
div
>
@
php
$options
=
array
(
'6'
=>
6
,
'7'
=>
7
,
'8'
=>
8
,
'9'
=>
9
,
'10'
=>
10
,
'11'
=>
11
,
'12'
=>
12
);
@
endphp
<
div
class
=
"col-6"
>
@
component
(
'componentes.select'
,
[
'label'
=>
'Total de períodos do curso'
])
<
select
name
=
"total_periodos[]"
class
=
"form-control"
onchange
=
"gerarPeriodo(this)"
required
>
<
option
value
=
""
disabled
selected
>--
Selecione
uma
opção
--</
option
>
@
foreach
(
$options
as
$key
=>
$value
)
<
option
@
if
(
old
(
'total_periodos'
)
==
$key
)
selected
@
endif
value
=
"{{
$key
}}"
>
{{
$value
}}
</
option
>
@
endforeach
</
select
>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.select'
,
[
'label'
=>
'Período atual'
])
<
select
name
=
"periodo_atual[]"
class
=
"form-control"
required
>
<
option
value
=
""
disabled
selected
>--
Selecione
uma
opção
--</
option
>
</
select
>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.select'
,
[
'label'
=>
'Ordem de prioridade'
])
<
select
name
=
"ordem_prioridade[]"
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
>
</
select
>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Coeficiente de rendimento'
])
<
input
type
=
"number"
class
=
"form-control media"
name
=
"media_geral_curso[]"
min
=
"0"
max
=
"10"
step
=
"0.01"
required
>
@
endcomponent
</
div
>
<
div
class
=
"col-md-12"
><
h5
>
Plano
de
trabalho
</
h5
></
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Título'
])
<
input
type
=
"text"
class
=
"form-control"
name
=
"nomePlanoTrabalho[]"
placeholder
=
"Digite o título do plano de trabalho"
required
>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Anexo(.pdf)'
])
<
input
type
=
"file"
class
=
"input-group-text"
name
=
"anexoPlanoTrabalho[]"
accept
=
".pdf"
placeholder
=
"Anexo do Plano de Trabalho"
required
/>
@
endcomponent
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
<
div
class
=
"form-row"
style
=
"display: none"
>
{{
--
<
button
type
=
"button"
onload
=
"myScript(this)"
onclick
=
"subir(this)"
>
Subir
</
button
>
<
button
type
=
"button"
onload
=
"myScript(this)"
onclick
=
"descer(this)"
>
Descer
</
button
>
--
}}
<
button
type
=
"button"
class
=
"btn btn-danger"
id
=
"buttonRemover"
onclick
=
"removerPart(this)"
>
Remover
participante
</
button
>
<
div
class
=
"col-md-12"
>
<
a
class
=
"btn btn-light"
data
-
toggle
=
"collapse"
id
=
"idCollapseParticipante"
href
=
"#collapseParticipante"
role
=
"button"
aria
-
expanded
=
"false"
aria
-
controls
=
"collapseParticipante"
style
=
"width: 100%; text-align:left"
>
<
div
class
=
"d-flex justify-content-between align-items-center"
>
<
h4
id
=
"tituloParticipante"
style
=
"color: #01487E; font-size:17px; margin-top:5px"
>
Participante
<
span
id
=
"pontos"
style
=
"display: none;"
>:</
span
>
<
span
style
=
"display: none;"
id
=
"display"
></
span
>
</
h4
>
</
div
>
</
a
>
</
div
>
<
div
class
=
"col-md-12"
>
<
div
class
=
"collapse"
id
=
"collapseParticipante"
>
<
div
class
=
"container"
>
<
div
class
=
"row"
>
<
input
type
=
"hidden"
name
=
"funcaoParticipante[]"
value
=
"4"
>
<
div
class
=
"col-md-12 mt-3"
><
h5
>
Dados
do
participante
</
h5
></
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Nome completo'
])
<
input
type
=
"text"
class
=
"form-control "
name
=
"nomeParticipante[]"
placeholder
=
"Nome Completo"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'E-mail'
])
<
input
type
=
"email"
class
=
"form-control"
name
=
"emailParticipante[]"
placeholder
=
"E-mail"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Data de nascimento'
])
<
input
type
=
"date"
class
=
"form-control"
name
=
"data_de_nascimento[]"
placeholder
=
"Data de nascimento"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'CPF'
])
<
input
type
=
"text"
class
=
"form-control cpf"
name
=
"cpf[]"
placeholder
=
"CPF"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'RG'
])
<
input
type
=
"number"
class
=
"form-control"
min
=
"1"
maxlength
=
"8"
name
=
"rg[]"
placeholder
=
"RG"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Celular'
])
<
input
type
=
"tel"
class
=
"form-control celular"
name
=
"celular[]"
placeholder
=
"Celular"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-md-12"
><
h5
>
Endereço
</
h5
></
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'CEP'
])
<
input
type
=
"number"
class
=
"form-control"
name
=
"cep[]"
placeholder
=
"CEP"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.select'
,
[
'label'
=>
'Estado'
])
<
select
name
=
"uf[]"
id
=
"estado"
class
=
"form-control"
style
=
"visibility: visible"
required
>
<
option
value
=
""
disabled
selected
>--
Selecione
uma
opção
--</
option
>
@
foreach
(
$estados
as
$sigla
=>
$nome
)
<
option
@
if
(
old
(
'uf'
)
==
$sigla
)
selected
@
endif
value
=
"{{
$sigla
}}"
>
{{
$nome
}}
</
option
>
@
endforeach
</
select
>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Cidade'
])
<
input
type
=
"text"
class
=
"form-control"
name
=
"cidade[]"
placeholder
=
"Cidade"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Bairro'
])
<
input
type
=
"text"
class
=
"form-control"
name
=
"bairro[]"
placeholder
=
"Bairro"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Rua'
])
<
input
type
=
"text"
class
=
"form-control"
name
=
"rua[]"
placeholder
=
"Rua"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Número'
])
<
input
type
=
"text"
class
=
"form-control"
name
=
"numero[]"
placeholder
=
"Número"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-12"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Complemento'
])
<
input
type
=
"text"
class
=
"form-control"
name
=
"complemento[]"
pattern
=
"[A-Za-z]+"
placeholder
=
"Complemento"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-md-12"
><
h5
>
Dados
do
curso
</
h5
></
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Universidade'
])
<
input
type
=
"text"
class
=
"form-control"
name
=
"universidade[]"
placeholder
=
"Universidade"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Curso'
])
<
input
type
=
"text"
class
=
"form-control"
name
=
"curso[]"
placeholder
=
"Curso"
required
/>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.select'
,
[
'label'
=>
'Turno'
])
<
select
name
=
"turno[]"
class
=
"form-control"
required
>
<
option
value
=
""
disabled
selected
>--
Selecione
uma
opção
--</
option
>
@
foreach
(
$enum_turno
as
$key
=>
$value
)
<
option
@
if
(
old
(
'turno'
)
==
$value
)
selected
@
endif
value
=
"{{
$value
}}"
>
{{
$value
}}
</
option
>
@
endforeach
</
select
>
@
endcomponent
</
div
>
@
php
$options
=
array
(
'6'
=>
6
,
'7'
=>
7
,
'8'
=>
8
,
'9'
=>
9
,
'10'
=>
10
,
'11'
=>
11
,
'12'
=>
12
);
@
endphp
<
div
class
=
"col-6"
>
@
component
(
'componentes.select'
,
[
'label'
=>
'Total de períodos do curso'
])
<
select
name
=
"total_periodos[]"
class
=
"form-control"
onchange
=
"gerarPeriodo(this)"
required
>
<
option
value
=
""
disabled
selected
>--
Selecione
uma
opção
--</
option
>
@
foreach
(
$options
as
$key
=>
$value
)
<
option
@
if
(
old
(
'total_periodos'
)
==
$key
)
selected
@
endif
value
=
"{{
$key
}}"
>
{{
$value
}}
</
option
>
@
endforeach
</
select
>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.select'
,
[
'label'
=>
'Período atual'
])
<
select
name
=
"periodo_atual[]"
class
=
"form-control"
required
>
<
option
value
=
""
disabled
selected
>--
Selecione
uma
opção
--</
option
>
</
select
>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.select'
,
[
'label'
=>
'Ordem de prioridade'
])
<
select
name
=
"ordem_prioridade[]"
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
>
</
select
>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Coeficiente de rendimento'
])
<
input
type
=
"number"
class
=
"form-control media"
name
=
"media_geral_curso[]"
min
=
"0"
max
=
"10"
step
=
"0.01"
required
>
@
endcomponent
</
div
>
<
div
class
=
"col-md-12"
><
h5
>
Plano
de
trabalho
</
h5
></
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Título'
])
<
input
type
=
"text"
class
=
"form-control"
name
=
"nomePlanoTrabalho[]"
placeholder
=
"Digite o título do plano de trabalho"
required
>
@
endcomponent
</
div
>
<
div
class
=
"col-6"
>
@
component
(
'componentes.input'
,
[
'label'
=>
'Anexo(.pdf)'
])
<
input
type
=
"file"
class
=
"input-group-text"
name
=
"anexoPlanoTrabalho[]"
accept
=
".pdf"
placeholder
=
"Anexo do Plano de Trabalho"
required
/>
@
endcomponent
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
<!--
Modal
de
Aviso
Edit
-->
<!--
Modal
de
Aviso
Edit
-->
<
div
class
=
"modal fade"
id
=
"exampleModalAnexarDocumento"
tabindex
=
"-1"
role
=
"dialog"
aria
-
labelledby
=
"exampleModalLabel2"
aria
-
hidden
=
"true"
>
<
div
class
=
"modal fade"
id
=
"exampleModalAnexarDocumento"
tabindex
=
"-1"
role
=
"dialog"
aria
-
labelledby
=
"exampleModalLabel2"
aria
-
hidden
=
"true"
>
<
div
class
=
"modal-dialog modal-dialog-centered"
role
=
"document"
>
<
div
class
=
"modal-dialog modal-dialog-centered"
role
=
"document"
>
...
@@ -68,8 +392,12 @@
...
@@ -68,8 +392,12 @@
let
buttonForm
=
document
.
getElementById
(
'buttonForm'
);
let
buttonForm
=
document
.
getElementById
(
'buttonForm'
);
let
buttonSubmit
=
document
.
getElementById
(
'idButtonSubmitProjeto'
);
let
buttonSubmit
=
document
.
getElementById
(
'idButtonSubmitProjeto'
);
let
parts
=
document
.
getElementById
(
'participante'
);
let
parts
=
document
.
getElementById
(
'participante'
);
let
partsFirst
=
document
.
getElementById
(
'participanteFirst'
);
// let buttonRemover = document.getElementById('buttonRemover');
// let buttonRemover = document.getElementById('buttonRemover');
const
participante
=
parts
.
firstElementChild
;
// var item1 = $( "#participante" )[ 0 ];
// var participante $( "#participante" ).find( item1 )
const
participante
=
partsFirst
.
firstElementChild
;
// const participante = document.getElementById('participantePrimeiro');
let
contador
=
2
;
let
contador
=
2
;
// var validator = $( "#formPart" ).validate();
// var validator = $( "#formPart" ).validate();
...
@@ -122,16 +450,18 @@
...
@@ -122,16 +450,18 @@
buttonMais
.
addEventListener
(
"click"
,
(
e
)
=>
{
buttonMais
.
addEventListener
(
"click"
,
(
e
)
=>
{
// console.log("{{ $edital->numParticipantes }}")
// console.log("{{ $edital->numParticipantes }}")
if
(
parts
.
children
.
length
>=
"{{
$edital->numParticipantes
}}"
){
if
(
parts
.
children
.
length
-
1
>=
"{{
$edital->numParticipantes
}}"
){
alert
(
'Limite de participante.'
)
alert
(
'Limite de participante.'
)
}
else
{
}
else
{
var
cln
=
participante
.
cloneNode
(
true
);
var
cln
=
participante
.
cloneNode
(
true
);
cln
.
style
.
display
=
'block'
;
// console.log(cln.style.display = 'block')
for
(
i
=
0
;
i
<
cln
.
children
.
length
;
i
++
)
{
for
(
i
=
0
;
i
<
cln
.
children
.
length
;
i
++
)
{
for
(
let
index
=
0
;
index
<
cln
.
children
[
i
]
.
querySelectorAll
(
'input'
)
.
length
;
index
++
)
{
for
(
let
index
=
0
;
index
<
cln
.
children
[
i
]
.
querySelectorAll
(
'input'
)
.
length
;
index
++
)
{
let
input
=
cln
.
children
[
i
]
.
querySelectorAll
(
'input'
)[
index
];
let
input
=
cln
.
children
[
i
]
.
querySelectorAll
(
'input'
)[
index
];
let
name
=
input
.
getAttributeNode
(
"name"
)
.
value
;
let
name
=
input
.
getAttributeNode
(
"name"
)
.
value
;
input
.
getAttributeNode
(
"name"
)
.
value
=
name
+
'['
+
contador
+
']'
;
input
.
getAttributeNode
(
"name"
)
.
value
=
name
+
'['
+
contador
+
']'
;
input
.
getAttributeNode
(
"disabled"
)
.
value
=
" "
;
let
select
=
cln
.
children
[
i
]
.
querySelectorAll
(
'select'
)[
index
];
let
select
=
cln
.
children
[
i
]
.
querySelectorAll
(
'select'
)[
index
];
if
(
select
){
if
(
select
){
let
selectName
=
select
.
getAttributeNode
(
"name"
)
.
value
;
let
selectName
=
select
.
getAttributeNode
(
"name"
)
.
value
;
...
@@ -149,25 +479,6 @@
...
@@ -149,25 +479,6 @@
});
});
// buttonMenos.addEventListener("click", (e) => {
// contador--;
// if(parts.lastElementChild){
// parts.removeChild(parts.lastElementChild);
// }
// });
// $(document).ready(function() {
// buttonForm.addEventListener('click', (e)=>{
// e.preventDefault();
// // console.log(e)
// validator.form();
// $( "#formPart" ).submit();
// });
// });
</
script
>
</
script
>
...
@@ -226,7 +537,6 @@
...
@@ -226,7 +537,6 @@
$
(
"#criarProjetoForm"
)
.
validate
(
{
$
(
"#criarProjetoForm"
)
.
validate
(
{
rules
:
{
rules
:
{
firstname
:
"required"
,
firstname
:
"required"
,
lastname
:
"required"
,
username
:
{
username
:
{
required
:
true
,
required
:
true
,
minlength
:
2
minlength
:
2
...
@@ -247,7 +557,7 @@
...
@@ -247,7 +557,7 @@
},
},
"complemento[]"
:
{
"complemento[]"
:
{
alpha
:
true
,
},
},
"nomeParticipante[]"
:
{
"nomeParticipante[]"
:
{
required
:
true
,
required
:
true
,
...
@@ -258,14 +568,42 @@
...
@@ -258,14 +568,42 @@
},
},
messages
:
{
messages
:
{
nomeProjeto
:
"O nome do projeto é obrigatório."
,
nomeProjeto
:
"O nome do projeto é obrigatório."
,
'emailParticipante[]'
:
"Este campo é obrigatório."
,
'data_de_nascimento[]'
:
"Este campo é obrigatório."
,
'cpf[]'
:
"Este campo é obrigatório."
,
'rg[]'
:
"Este campo é obrigatório."
,
'celular[]'
:
"Este campo é obrigatório."
,
'cep[]'
:
"Este campo é obrigatório."
,
'uf[]'
:
"Este campo é obrigatório."
,
'cidade[]'
:
"Este campo é obrigatório."
,
'bairro[]'
:
"Este campo é obrigatório."
,
'rua[]'
:
"Este campo é obrigatório."
,
'numero[]'
:
"Este campo é obrigatório."
,
'complemento[]'
:
"Este campo é obrigatório."
,
'universidade[]'
:
"Este campo é obrigatório."
,
'curso[]'
:
"Este campo é obrigatório."
,
'turno[]'
:
"Este campo é obrigatório."
,
'total_periodos[]'
:
"Este campo é obrigatório."
,
'periodo_atual[]'
:
"Este campo é obrigatório."
,
'ordem_prioridade[]'
:
"Este campo é obrigatório."
,
'media_geral_curso[]'
:
"Este campo é obrigatório."
,
'nomePlanoTrabalho[]'
:
"Este campo é obrigatório."
,
'anexoPlanoTrabalho[]'
:
"Este campo é obrigatório."
,
grandeArea
:
"Escolha uma grande área."
,
grandeArea
:
"Escolha uma grande área."
,
area
:
"Escolha uma área."
,
area
:
"Escolha uma área."
,
"complemento[]"
:
"Não é permitido números."
,
linkGrupo
:
"Este campo é obrigatório."
,
pontuacaoPlanilha
:
"Este campo é obrigatório."
,
anexoProjeto
:
"Este campo é obrigatório."
,
anexoLattesCoordenador
:
"Este campo é obrigatório."
,
anexoConsuPreenchido
:
"Este campo é obrigatório."
,
anexoGrupoPesquisa
:
"Este campo é obrigatório."
,
anexoPlanilha
:
"Este campo é obrigatório."
,
anexoComiteEtica
:
"Este campo é obrigatório."
,
inputJustificativa
:
"Este campo é obrigatório."
,
"nomeParticipante[]"
:
{
"nomeParticipante[]"
:
{
required
:
"O nome do p
rojeto
é obrigatório."
,
required
:
"O nome do p
articipante
é obrigatório."
,
alpha
:
"Não é permitido números."
alpha
:
"Não é permitido números."
},
},
anexoProjeto
:
"O campo anexo do projeto é obrigatório."
,
username
:
{
username
:
{
required
:
"Please enter a username"
,
required
:
"Please enter a username"
,
minlength
:
"Your username must consist of at least 2 characters"
minlength
:
"Your username must consist of at least 2 characters"
...
...
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