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
b8e96d8a
Unverified
Commit
b8e96d8a
authored
May 14, 2021
by
carlos1270
Committed by
GitHub
May 14, 2021
Browse files
Merge pull request #76 from carlos1270/master
Modificando banco e controller para ajuste na submissão do projeto
parents
c6fe4274
ec18d6fc
Changes
17
Hide whitespace changes
Inline
Side-by-side
app/Http/Controllers/EventoController.php
View file @
b8e96d8a
...
@@ -343,7 +343,7 @@ class EventoController extends Controller
...
@@ -343,7 +343,7 @@ class EventoController extends Controller
'natureza'
=>
[
'required'
],
'natureza'
=>
[
'required'
],
'inicioSubmissao'
=>
[
'required'
,
'date'
],
'inicioSubmissao'
=>
[
'required'
,
'date'
],
'fimSubmissao'
=>
[
'required'
,
'date'
],
'fimSubmissao'
=>
[
'required'
,
'date'
],
'inicioRevisao'
=>
[
'required'
,
'date'
,
'after:
yesterday
'
],
'inicioRevisao'
=>
[
'required'
,
'date'
,
'after:
fimSubmissao
'
],
'fimRevisao'
=>
[
'required'
,
'date'
],
'fimRevisao'
=>
[
'required'
,
'date'
],
'resultado_preliminar'
=>
[
'required'
,
'date'
],
'resultado_preliminar'
=>
[
'required'
,
'date'
],
'inicio_recurso'
=>
[
'required'
,
'date'
],
'inicio_recurso'
=>
[
'required'
,
'date'
],
...
@@ -359,10 +359,10 @@ class EventoController extends Controller
...
@@ -359,10 +359,10 @@ class EventoController extends Controller
'descricao'
=>
[
'required'
,
'string'
,
'max:1500'
],
'descricao'
=>
[
'required'
,
'string'
,
'max:1500'
],
'tipo'
=>
[
'required'
,
'string'
],
'tipo'
=>
[
'required'
,
'string'
],
'natureza'
=>
[
'required'
],
'natureza'
=>
[
'required'
],
'inicioSubmissao'
=>
[
'required'
,
'date'
,
'after
:yesterday
'
],
'inicioSubmissao'
=>
[
'required'
,
'date'
,
'after
_or_equal:inicioSubmissao
'
],
'fimSubmissao'
=>
[
'required'
,
'date'
,
'after_or_equal:inicioSubmissao'
],
'fimSubmissao'
=>
[
'required'
,
'date'
,
'after_or_equal:inicioSubmissao'
],
'inicioRevisao'
=>
[
'required'
,
'date'
,
'after:
yesterday
'
],
'inicioRevisao'
=>
[
'required'
,
'date'
,
'after:
fimSubmissao
'
],
'fimRevisao'
=>
[
'required'
,
'date'
,
'after:inicioRevisao'
,
'after:fimSubmissao'
],
'fimRevisao'
=>
[
'required'
,
'date'
,
'after:inicioRevisao'
],
'resultado_preliminar'
=>
[
'required'
,
'date'
,
'after_or_equal:fimRevisao'
],
'resultado_preliminar'
=>
[
'required'
,
'date'
,
'after_or_equal:fimRevisao'
],
'inicio_recurso'
=>
[
'required'
,
'date'
,
'after_or_equal:resultado_preliminar'
],
'inicio_recurso'
=>
[
'required'
,
'date'
,
'after_or_equal:resultado_preliminar'
],
'fim_recurso'
=>
[
'required'
,
'date'
,
'after:inicio_recurso'
],
'fim_recurso'
=>
[
'required'
,
'date'
,
'after:inicio_recurso'
],
...
@@ -402,8 +402,8 @@ class EventoController extends Controller
...
@@ -402,8 +402,8 @@ class EventoController extends Controller
$evento
->
update
();
$evento
->
update
();
$eventos
=
Evento
::
all
();
$eventos
=
Evento
::
orderBy
(
'nome'
)
->
get
();
return
view
(
'
coordenador.home
'
,[
'eventos'
=>
$eventos
]);
return
view
(
'
administrador.editais
'
,[
'eventos'
=>
$eventos
]);
}
}
/**
/**
...
...
app/Http/Controllers/TrabalhoController.php
View file @
b8e96d8a
...
@@ -21,6 +21,7 @@ use App\FuncaoParticipantes;
...
@@ -21,6 +21,7 @@ use App\FuncaoParticipantes;
use
App\Participante
;
use
App\Participante
;
use
App\Avaliador
;
use
App\Avaliador
;
use
Carbon\Carbon
;
use
Carbon\Carbon
;
use
App\Endereco
;
use
Auth
;
use
Auth
;
use
Illuminate\Http\Request
;
use
Illuminate\Http\Request
;
use
Illuminate\Http\File
;
use
Illuminate\Http\File
;
...
@@ -63,7 +64,7 @@ class TrabalhoController extends Controller
...
@@ -63,7 +64,7 @@ class TrabalhoController extends Controller
'grandeAreas'
=>
$grandeAreas
,
'grandeAreas'
=>
$grandeAreas
,
'funcaoParticipantes'
=>
$funcaoParticipantes
,
'funcaoParticipantes'
=>
$funcaoParticipantes
,
'rascunho'
=>
$rascunho
,
'rascunho'
=>
$rascunho
,
'enum_turno'
=>
OutrasInfo
Participante
::
ENUM_TURNO
'enum_turno'
=>
Participante
::
ENUM_TURNO
]);
]);
}
}
...
@@ -84,7 +85,7 @@ class TrabalhoController extends Controller
...
@@ -84,7 +85,7 @@ class TrabalhoController extends Controller
* @return \Illuminate\Http\Response
* @return \Illuminate\Http\Response
*/
*/
public
function
store
(
Request
$request
){
public
function
store
(
Request
$request
){
dd
(
$request
);
$mytime
=
Carbon
::
now
(
'America/Recife'
);
$mytime
=
Carbon
::
now
(
'America/Recife'
);
$mytime
=
$mytime
->
toDateString
();
$mytime
=
$mytime
->
toDateString
();
$evento
=
Evento
::
find
(
$request
->
editalId
);
$evento
=
Evento
::
find
(
$request
->
editalId
);
...
@@ -971,4 +972,157 @@ class TrabalhoController extends Controller
...
@@ -971,4 +972,157 @@ class TrabalhoController extends Controller
}
}
return
abort
(
404
);
return
abort
(
404
);
}
}
public
function
salvar
(
Request
$request
)
{
$edital
=
Evento
::
find
(
$request
->
editalId
);
$hoje
=
now
();
if
(
!
(
$edital
->
inicioSubmissao
<
$hoje
&&
$edital
->
fimSubmissao
>=
$hoje
))
{
return
redirect
()
->
route
(
'inicial'
)
->
with
([
'error'
=>
0
,
'mensagem'
=>
'As submissões para o edital '
.
$edital
->
titulo
.
' foram encerradas.'
]);
}
$projeto
=
$this
->
atribuirDados
(
$request
,
$edital
);
$projeto
->
save
();
// Salvando anexos no storage
$pasta
=
'trabalhos/'
.
$edital
->
id
.
'/'
.
$projeto
->
id
;
$projeto
=
$this
->
armazenarAnexosFinais
(
$request
,
$pasta
,
$projeto
,
$edital
);
$subject
=
"Submissão de Trabalho"
;
$proponente
=
Auth
()
->
user
();
Mail
::
to
(
$proponente
->
email
)
->
send
(
new
SubmissaoTrabalho
(
$proponente
,
$subject
,
$edital
,
$projeto
));
// Salvando participantes
$this
->
salvarParticipantes
(
$request
,
$edital
,
$projeto
);
dd
(
"foi"
);
}
public
function
atribuirDados
(
Request
$request
,
$edital
)
{
$projeto
=
new
Trabalho
();
$proponente
=
User
::
find
(
auth
()
->
user
()
->
id
)
->
proponentes
;
$hoje
=
now
();
$projeto
->
titulo
=
$request
->
nomeProjeto
;
$projeto
->
coordenador_id
=
$edital
->
coordenadorComissao
->
id
;
$projeto
->
grande_area_id
=
$request
->
grandeArea
;
$projeto
->
area_id
=
$request
->
area
;
$projeto
->
sub_area_id
=
$request
->
subArea
;
$projeto
->
pontuacaoPlanilha
=
$request
->
pontuacaoPlanilha
;
$projeto
->
linkGrupoPesquisa
=
$request
->
linkGrupo
;
$projeto
->
linkLattesEstudante
=
$request
->
linkLattesEstudante
;
$projeto
->
data
=
$hoje
;
$projeto
->
evento_id
=
$request
->
editalId
;
$projeto
->
status
=
'Submetido'
;
$projeto
->
proponente_id
=
$proponente
->
id
;
//Anexos
$projeto
->
anexoProjeto
=
$request
->
anexoProjeto
;
$projeto
->
anexoAutorizacaoComiteEtica
=
$request
->
anexoComiteEtica
;
$projeto
->
justificativaAutorizacaoEtica
=
$request
->
justificativaAutorizacaoEtica
;
$projeto
->
anexoLattesCoordenador
=
$request
->
anexoLattesCoordenador
;
$projeto
->
anexoPlanilhaPontuacao
=
$request
->
anexoPlanilha
;
if
(
$edital
->
tipo
==
'PIBIC'
||
$edital
->
tipo
==
'PIBIC-EM'
){
$projeto
->
anexoDecisaoCONSU
=
$request
->
anexoCONSU
;
}
return
$projeto
;
}
public
function
salvarParticipantes
(
Request
$request
,
$edital
,
$projeto
)
{
if
(
$request
->
emailParticipante
!=
null
)
{
foreach
(
$request
->
emailParticipante
as
$key
=>
$email
)
{
$userParticipante
=
User
::
where
(
'email'
,
$email
)
->
first
();
$participante
=
new
Participante
();
if
(
$userParticipante
==
null
){
$passwordTemporario
=
Str
::
random
(
8
);
$usuario
=
new
User
();
$usuario
->
email
=
$email
;
$usuario
->
password
=
bcrypt
(
$passwordTemporario
);
$usuario
->
usuarioTemp
=
false
;
$usuario
->
name
=
$request
->
nomeParticipante
[
$key
];
$usuario
->
tipo
=
'participante'
;
$usuario
->
instituicao
=
$request
->
universidade
[
$key
];
$usuario
->
cpf
=
$request
->
cpf
[
$key
];
$usuario
->
celular
=
$request
->
celular
[
$key
];
$endereco
=
new
Endereco
();
$endereco
->
rua
=
$request
->
rua
[
$key
];
$endereco
->
numero
=
$request
->
numero
[
$key
];
$endereco
->
bairro
=
$request
->
bairro
[
$key
];
$endereco
->
cidade
=
$request
->
cidade
[
$key
];
$endereco
->
uf
=
$request
->
uf
[
$key
];
$endereco
->
cep
=
$request
->
cep
[
$key
];
$endereco
->
complemento
=
$request
->
complemento
[
$key
];
$endereco
->
save
();
$usuario
->
enderecoId
=
$endereco
->
id
;
$usuario
->
save
();
$participante
->
user_id
=
$usuario
->
id
;
$participante
->
trabalho_id
=
$projeto
->
id
;
$participante
->
funcao_participante_id
=
$request
->
funcaoParticipante
[
$key
];
$participante
->
confirmacao_convite
=
true
;
$participante
->
rg
=
$request
->
rg
[
$key
];
$participante
->
data_de_nascimento
=
$request
->
data_de_nascimento
[
$key
];
$participante
->
curso
=
$request
->
curso
[
$key
];
$participante
->
turno
=
$request
->
turno
[
$key
];
$participante
->
ordem_prioridade
=
$request
->
ordem_prioridade
[
$key
];
$participante
->
periodo_atual
=
$request
->
periodo_cursado
[
$key
];
$participante
->
total_periodos
=
$request
->
total_periodos
[
$key
];
$participante
->
media_do_curso
=
$request
->
media_geral_curso
[
$key
];
$participante
->
save
();
$subject
=
"Participante de Projeto"
;
Mail
::
to
(
$email
)
->
send
(
new
EmailParaUsuarioNaoCadastrado
(
Auth
()
->
user
()
->
name
,
$projeto
->
titulo
,
'Participante'
,
$edital
->
nome
,
$passwordTemporario
,
$subject
));
}
else
{
$participante
->
user_id
=
$userParticipante
->
id
;
$participante
->
trabalho_id
=
$projeto
->
id
;
$participante
->
funcao_participante_id
=
$request
->
funcaoParticipante
[
$key
];
$participante
->
confirmacao_convite
=
true
;
$participante
->
rg
=
$request
->
rg
[
$key
];
$participante
->
data_de_nascimento
=
$request
->
data_de_nascimento
[
$key
];
$participante
->
curso
=
$request
->
curso
[
$key
];
$participante
->
turno
=
$request
->
turno
[
$key
];
$participante
->
ordem_prioridade
=
$request
->
ordem_prioridade
[
$key
];
$participante
->
periodo_atual
=
$request
->
periodo_cursado
[
$key
];
$participante
->
total_periodos
=
$request
->
total_periodos
[
$key
];
$participante
->
media_do_curso
=
$request
->
media_geral_curso
[
$key
];
$participante
->
save
();
$subject
=
"Participante de Projeto"
;
Mail
::
to
(
$email
)
->
send
(
new
SubmissaoTrabalho
(
$userParticipante
,
$subject
,
$edital
,
$projeto
));
}
if
(
$request
->
nomePlanoTrabalho
[
$key
]
!=
null
){
$usuario
=
User
::
where
(
'email'
,
$email
)
->
first
();
$participante
=
Participante
::
where
([[
'user_id'
,
'='
,
$usuario
->
id
],
[
'trabalho_id'
,
'='
,
$projeto
->
id
]])
->
first
();
$path
=
'trabalhos/'
.
$edital
->
id
.
'/'
.
$projeto
->
id
.
'/'
;
$nome
=
$request
->
nomePlanoTrabalho
[
$key
]
.
".pdf"
;
$file
=
$request
->
anexoPlanoTrabalho
[
$key
];
Storage
::
putFileAs
(
$path
,
$file
,
$nome
);
$agora
=
now
();
$arquivo
=
new
Arquivo
();
$arquivo
->
titulo
=
$request
->
nomePlanoTrabalho
[
$key
];
$arquivo
->
nome
=
$path
.
$nome
;
$arquivo
->
trabalhoId
=
$projeto
->
id
;
$arquivo
->
data
=
$agora
;
$arquivo
->
participanteId
=
$participante
->
id
;
$arquivo
->
versaoFinal
=
true
;
$arquivo
->
save
();
}
}
}
}
}
}
\ No newline at end of file
app/Http/Controllers/UserController.php
View file @
b8e96d8a
...
@@ -24,7 +24,8 @@ class UserController extends Controller
...
@@ -24,7 +24,8 @@ class UserController extends Controller
public
function
index
()
public
function
index
()
{
{
$eventos
=
Evento
::
all
();
$eventos
=
Evento
::
orderBy
(
'created_at'
,
'desc'
)
->
get
();
dd
(
$eventos
);
if
(
Auth
::
check
()){
if
(
Auth
::
check
()){
Log
::
debug
(
'UserController check'
);
Log
::
debug
(
'UserController check'
);
return
redirect
()
->
route
(
'home'
);
return
redirect
()
->
route
(
'home'
);
...
@@ -37,8 +38,7 @@ class UserController extends Controller
...
@@ -37,8 +38,7 @@ class UserController extends Controller
}
}
public
function
inicial
()
public
function
inicial
()
{
{
$eventos
=
Evento
::
all
();
$eventos
=
Evento
::
orderBy
(
'created_at'
,
'desc'
)
->
get
();
$hoje
=
Carbon
::
today
(
'America/Recife'
);
$hoje
=
Carbon
::
today
(
'America/Recife'
);
$hoje
=
$hoje
->
toDateString
();
$hoje
=
$hoje
->
toDateString
();
return
view
(
'index'
,
[
'eventos'
=>
$eventos
,
'hoje'
=>
$hoje
]);
return
view
(
'index'
,
[
'eventos'
=>
$eventos
,
'hoje'
=>
$hoje
]);
...
...
app/OutrasInfoParticipante.php
deleted
100644 → 0
View file @
c6fe4274
<?php
namespace
App
;
use
Illuminate\Database\Eloquent\Model
;
class
OutrasInfoParticipante
extends
Model
{
protected
$fillable
=
[
'name'
,
'user_id'
,
'trabalho_id'
,
'participante_id'
];
public
const
ENUM_TURNO
=
[
'Matutino'
,
'Vespertino'
,
'Noturno'
,
'Integral'
];
}
app/Participante.php
View file @
b8e96d8a
...
@@ -8,6 +8,7 @@ use Illuminate\Database\Eloquent\SoftDeletes;
...
@@ -8,6 +8,7 @@ use Illuminate\Database\Eloquent\SoftDeletes;
class
Participante
extends
Model
class
Participante
extends
Model
{
{
use
SoftDeletes
;
use
SoftDeletes
;
public
const
ENUM_TURNO
=
[
'Matutino'
,
'Vespertino'
,
'Noturno'
,
'Integral'
];
protected
$fillable
=
[
'name'
,
'user_id'
,
'trabalho_id'
,
'participante_id'
];
protected
$fillable
=
[
'name'
,
'user_id'
,
'trabalho_id'
,
'participante_id'
];
...
...
database/migrations/2020_02_05_123217_create_enderecos_table.php
View file @
b8e96d8a
...
@@ -22,6 +22,7 @@ class CreateEnderecosTable extends Migration
...
@@ -22,6 +22,7 @@ class CreateEnderecosTable extends Migration
$table
->
string
(
'cidade'
);
$table
->
string
(
'cidade'
);
$table
->
string
(
'uf'
);
$table
->
string
(
'uf'
);
$table
->
string
(
'cep'
);
$table
->
string
(
'cep'
);
$table
->
string
(
'complemento'
)
->
nullable
(
true
);
});
});
}
}
...
...
database/migrations/2020_05_23_054945_create_participantes_table.php
View file @
b8e96d8a
...
@@ -3,6 +3,7 @@
...
@@ -3,6 +3,7 @@
use
Illuminate\Database\Migrations\Migration
;
use
Illuminate\Database\Migrations\Migration
;
use
Illuminate\Database\Schema\Blueprint
;
use
Illuminate\Database\Schema\Blueprint
;
use
Illuminate\Support\Facades\Schema
;
use
Illuminate\Support\Facades\Schema
;
use
App\Participante
;
class
CreateParticipantesTable
extends
Migration
class
CreateParticipantesTable
extends
Migration
{
{
...
@@ -15,11 +16,21 @@ class CreateParticipantesTable extends Migration
...
@@ -15,11 +16,21 @@ class CreateParticipantesTable extends Migration
{
{
Schema
::
create
(
'participantes'
,
function
(
Blueprint
$table
)
{
Schema
::
create
(
'participantes'
,
function
(
Blueprint
$table
)
{
$table
->
bigIncrements
(
'id'
);
$table
->
bigIncrements
(
'id'
);
$table
->
boolean
(
'confirmacao_convite'
)
->
nullable
();
$table
->
boolean
(
'confirmacao_convite'
)
->
nullable
()
->
nullable
(
true
);
$table
->
string
(
"rg"
)
->
nullable
(
true
);
$table
->
date
(
"data_de_nascimento"
)
->
nullable
(
true
);
$table
->
string
(
"curso"
)
->
nullable
(
true
);
$table
->
enum
(
"turno"
,
Participante
::
ENUM_TURNO
)
->
nullable
(
true
);
$table
->
integer
(
"ordem_prioridade"
)
->
nullable
(
true
);
$table
->
string
(
"periodo_atual"
)
->
nullable
(
true
);
$table
->
string
(
"total_periodos"
)
->
nullable
(
true
);
$table
->
double
(
"media_do_curso"
,
3
,
2
)
->
nullable
(
true
);
$table
->
timestamps
();
$table
->
timestamps
();
$table
->
unsignedBigInteger
(
'user_id'
)
->
nullable
();
$table
->
unsignedBigInteger
(
'user_id'
)
->
nullable
();
$table
->
foreign
(
'user_id'
)
->
references
(
'id'
)
->
on
(
'users'
);
$table
->
foreign
(
'user_id'
)
->
references
(
'id'
)
->
on
(
'users'
);
$table
->
unsignedBigInteger
(
'trabalho_id'
)
->
nullable
();
$table
->
unsignedBigInteger
(
'trabalho_id'
)
->
nullable
();
$table
->
foreign
(
'trabalho_id'
)
->
references
(
'id'
)
->
on
(
'trabalhos'
);
$table
->
foreign
(
'trabalho_id'
)
->
references
(
'id'
)
->
on
(
'trabalhos'
);
...
...
database/migrations/2021_05_05_161225_create_outras_info_participantes_table.php
deleted
100644 → 0
View file @
c6fe4274
<?php
use
Illuminate\Database\Migrations\Migration
;
use
Illuminate\Database\Schema\Blueprint
;
use
Illuminate\Support\Facades\Schema
;
use
App\OutrasInfoParticipante
;
class
CreateOutrasInfoParticipantesTable
extends
Migration
{
/**
* Run the migrations.
*
* @return void
*/
public
function
up
()
{
Schema
::
create
(
'outras_info_participantes'
,
function
(
Blueprint
$table
)
{
$table
->
bigIncrements
(
'id'
);
$table
->
string
(
"rg"
);
$table
->
date
(
"data_de_nascimento"
);
$table
->
string
(
"curso"
);
$table
->
enum
(
"turno"
,
OutrasInfoParticipante
::
ENUM_TURNO
)
->
nullable
(
true
);
$table
->
integer
(
"ordem_prioridade"
)
->
nullable
(
true
);
$table
->
string
(
"periodo_atual"
)
->
nullable
(
true
);
$table
->
string
(
"total_periodos"
)
->
nullable
(
true
);
$table
->
double
(
"media_do_curso"
,
3
,
2
)
->
nullable
(
true
);
$table
->
timestamps
();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public
function
down
()
{
Schema
::
dropIfExists
(
'outras_info_participantes'
);
}
}
database/migrations/2021_05_05_163601_add_column_participante.php
deleted
100644 → 0
View file @
c6fe4274
<?php
use
Illuminate\Database\Migrations\Migration
;
use
Illuminate\Database\Schema\Blueprint
;
use
Illuminate\Support\Facades\Schema
;
class
AddColumnParticipante
extends
Migration
{
/**
* Run the migrations.
*
* @return void
*/
public
function
up
()
{
Schema
::
table
(
'participantes'
,
function
(
Blueprint
$table
)
{
$table
->
unsignedBigInteger
(
'outras_info_participante_id'
)
->
nullable
(
true
);
$table
->
foreign
(
'outras_info_participante_id'
)
->
references
(
'id'
)
->
on
(
'outras_info_participantes'
);
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public
function
down
()
{
//
}
}
public/css/layout.css
View file @
b8e96d8a
...
@@ -461,3 +461,15 @@ button.close {
...
@@ -461,3 +461,15 @@ button.close {
border
:
none
;
border
:
none
;
}
}
.select-submeta
{
border-radius
:
5px
;
border
:
1px
solid
rgb
(
172
,
172
,
172
);
}
.background-yellow
{
background-color
:
rgb
(
42
,
212
,
0
);
}
.background-red
{
background-color
:
rgb
(
235
,
0
,
0
);
}
\ No newline at end of file
resources/views/coordenador/home.blade.php
View file @
b8e96d8a
...
@@ -14,7 +14,9 @@
...
@@ -14,7 +14,9 @@
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
@
php
$hoje
=
now
();
@
endphp
<
div
class
=
"row"
>
<
div
class
=
"row"
>
...
...
resources/views/index.blade.php
View file @
b8e96d8a
...
@@ -2,58 +2,155 @@
...
@@ -2,58 +2,155 @@
@
section
(
'content'
)
@
section
(
'content'
)
<
div
class
=
"container"
>
<
div
class
=
"container"
>
<
div
class
=
"row"
>
<
div
class
=
"row"
>
<
div
class
=
"col-sm-6"
style
=
"position: relative; top: 50px; padding: 25px;"
>
<
div
class
=
"col-sm-6"
style
=
"position: relative; top: 50px; padding: 25px;"
>
<
div
class
=
"row"
>
<
div
class
=
"row"
>
<
img
class
=
"position-image"
src
=
"{{ asset('img/icons/logo_submeta_grande.png') }}"
alt
=
""
>
<
img
class
=
"position-image"
src
=
"{{ asset('img/icons/logo_submeta_grande.png') }}"
alt
=
""
>
</
div
>
</
div
>
<
div
class
=
"row position-text"
>
<
div
class
=
"row position-text"
>
<
p
style
=
"text-indent: 0.5cm;"
>
<
p
style
=
"text-indent: 0.5cm;"
>
O
Submeta
é
um
sistema
de
submissão
de
projetos
acadêmicos
,
que
pode
ser
adotado
para
os
diferentes
propósitos
de
Ensino
,
Pesquisa
e
Extensão
.
O
sistema
abrange
todas
as
principais
etapas
relacionadas
à
submissão
de
projetos
,
permitindo
o
lançamento
e
configuração
de
editais
,
além
de
gerenciar
a
distribuição
das
avaliações
e
os
pareceres
técnicos
dos
avaliadores
,
como
também
,
visualizar
os
projetos
submetidos
pelos
proponentes
.
O
Submeta
é
um
sistema
de
submissão
de
projetos
acadêmicos
,
que
pode
ser
adotado
para
os
diferentes
propósitos
de
Ensino
,
Pesquisa
e
Extensão
.
O
sistema
abrange
todas
as
principais
etapas
relacionadas
à
submissão
de
projetos
,
permitindo
o
lançamento
e
configuração
de
editais
,
além
de
gerenciar
a
distribuição
das
avaliações
e
os
pareceres
técnicos
dos
avaliadores
,
como
também
,
visualizar
os
projetos
submetidos
pelos
proponentes
.
</
p
>
</
p
>
</
div
>
</
div
>
<
div
class
=
"row position-text"
>
<
div
class
=
"row position-text"
>
{{
--
<
button
class
=
"btn btn-opcoes-edital"
style
=
"margin-bottom: 20px;"
>
{{
--
<
button
class
=
"btn btn-opcoes-edital"
style
=
"margin-bottom: 20px;"
>
Leia
mais
Leia
mais
</
button
>
--
}}
</
button
>
--
}}
</
div
>
</
div
>
</
div
>
</
div
>
<
br
>
<
br
>
<
div
class
=
"col-sm-6"
style
=
" position: relative; top: 50px; padding: 25px;"
>
<
div
class
=
"col-sm-6"
style
=
" position: relative; top: 50px; padding: 25px;"
>
<
h4
style
=
"color: rgb(0, 140, 255);"
>
Editais
</
h4
>
<
h4
style
=
"color: rgb(0, 140, 255);"
>
Editais
</
h4
>
<
div
id
=
"editais"
>
<
div
id
=
"editais"
>
<
ul
class
=
"col-sm-12 list-editais flexcroll"
style
=
"list-style-type: none;"
>
<
ul
class
=
"col-sm-12 list-editais flexcroll"
style
=
"list-style-type: none;"
>
@
foreach
(
$eventos
as
$evento
)
@
php
@
if
(
\
Carbon\Carbon
::
create
(
$evento
->
fimSubmissao
)
>=
\
Carbon\Carbon
::
create
(
$hoje
))
$today
=
\
Carbon\Carbon
::
create
(
$hoje
);
<
li
class
=
"col-sm-12 li-editais"
>
@
endphp
<
div
class
=
"container"
>
@
foreach
(
$eventos
as
$i
=>
$evento
)
<
div
class
=
"row"
>
@
php
<
div
class
=
"col-sm-1"
>
$fimSub
=
\
Carbon\Carbon
::
create
(
$evento
->
fimSubmissao
);
$inicioRev
=
\
Carbon\Carbon
::
create
(
$evento
->
inicioRevisao
);
$fimRev
=
\
Carbon\Carbon
::
create
(
$evento
->
fimRevisao
);
@
endphp
@
if
(
$fimSub
>=
$today
)
<
li
class
=
"col-sm-12 li-editais aberto"
>
<
div
class
=
"container"
>
<
div
class
=
"row"
>
<
div
class
=
"col-sm-1"
>
<
img
class
=
"img-arquivo"
src
=
"{{ asset('img/icons/logo_arquivo.png') }}"
alt
=
""
>
<
img
class
=
"img-arquivo"
src
=
"{{ asset('img/icons/logo_arquivo.png') }}"
alt
=
""
>
</
div
>
<
div
class
=
"col-sm-8"
>
<
div
>
{{
$evento
->
nome
}}
</
div
>
<
div
class
=
"color-subtitle-edital"
>
Submissão
até
o
dia
{{
date
(
'd/m/Y'
,
strtotime
(
$evento
->
fimSubmissao
))
}}
</
div
>
</
div
>
<
div
class
=
"col-sm-3"
>
<
a
href
=
"{{ route('evento.visualizarNaoLogado', ['id' =>
$evento->id
]) }}"
>
<
button
class
=
"btn btn-opcoes-edital"
style
=
"float: right;"
>
Visualizar
</
button
>
</
a
>
</
div
>
</
div
>
</
div
>
<
div
class
=
"col-sm-8"
>
</
div
>
</
li
>
@
elseif
(
$fimSub
<
$today
&&
$fimRev
>=
$today
||
$i
==
1
)
<
li
class
=
"col-sm-12 li-editais avaliacao"
style
=
"display: none;"
>
<
div
class
=
"container"
>
<
div
class
=
"row"
>
<
div
class
=
"col-sm-1"
>
<
img
class
=
"img-arquivo"
src
=
"{{ asset('img/icons/logo_arquivo.png') }}"
alt
=
""
>
</
div
>
<
div
class
=
"col-sm-7"
>
<
div
>
{{
$evento
->
nome
}}
</
div
>
<
div
>
{{
$evento
->
nome
}}
</
div
>
<
div
class
=
"color-subtitle-edital"
>
Submissão
até
o
dia
{{
date
(
'd/m/Y'
,
strtotime
(
$evento
->
fimSubmissao
))
}}
</
div
>
<
div
class
=
"color-subtitle-edital"
>
Submissão
até
o
dia
{{
date
(
'd/m/Y'
,
strtotime
(
$evento
->
fimSubmissao
))
}}
</
div
>
</
div
>
<
div
class
=
"col-sm-4"
>
<
button
class
=
"btn btn-opcoes-edital background-yellow"
style
=
"float: right;"
disable
>
Em
avaliação
</
button
>
</
div
>
</
div
>
</
div
>
<
div
class
=
"col-sm-3"
>
</
div
>
<
a
href
=
"{{ route('evento.visualizarNaoLogado', ['id' =>
$evento->id
]) }}"
>
</
li
>
<
button
class
=
"btn btn-opcoes-edital"
style
=
"float: left;"
>
@
elseif
(
$fimRev
<=
$today
)
Visualizar
<
li
class
=
"col-sm-12 li-editais encerrado"
style
=
"display: none;"
>
<
div
class
=
"container"
>
<
div
class
=
"row"
>
<
div
class
=
"col-sm-1"
>
<
img
class
=
"img-arquivo"
src
=
"{{ asset('img/icons/logo_arquivo.png') }}"
alt
=
""
>
</
div
>
<
div
class
=
"col-sm-8"
>
<
div
>
{{
$evento
->
nome
}}
</
div
>
<
div
class
=
"color-subtitle-edital"
>
Submissão
até
o
dia
{{
date
(
'd/m/Y'
,
strtotime
(
$evento
->
fimSubmissao
))
}}
</
div
>
</
div
>
<
div
class
=
"col-sm-3"
>
<
button
class
=
"btn btn-opcoes-edital background-red"
style
=
"float: right;"
disabled
>
Encerrado
</
button
>
</
button
>
</
a
>
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
</
li
>
</
li
>
@
endif
@
endif
@
endforeach
@
endforeach
</
ul
>
</
div
>
</
div
>
</
div
>
<
br
>
</
div
>
<
div
class
=
"row"
>
<
div
class
=
"col-md-8"
style
=
"float: right;"
>
</
div
>
<
div
class
=
"col-md-4"
style
=
"float: right;"
>
<
select
id
=
""
class
=
"form-control select-submeta"
onchange
=
"exibirEditais(this)"
>
<
option
value
=
"aberto"
selected
>
Aberto
</
option
>
<
option
value
=
"avaliacao"
>
Em
Avaliação
</
option
>
<
option
value
=
"encerrado"
>
Encerrado
</
option
>
<
option
value
=
"todos"
>
Todos
</
option
>
</
select
>
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
</
div
>
@
endsection
@
endsection
@
section
(
'javascript'
)
@
section
(
'javascript'
)
<
script
>
function
exibirEditais
(
select
)
{
var
abertos
=
document
.
getElementsByClassName
(
"aberto"
);
var
avaliacao
=
document
.
getElementsByClassName
(
"avaliacao"
);
var
encerrado
=
document
.
getElementsByClassName
(
"encerrado"
);
console
.
log
(
abertos
);
if
(
select
.
value
==
"aberto"
||
select
.
value
==
"todos"
)
{
for
(
var
i
=
0
;
i
<
abertos
.
length
;
i
++
)
{
abertos
[
i
]
.
style
.
display
=
""
;
}
}
else
{
for
(
var
i
=
0
;
i
<
abertos
.
length
;
i
++
)
{
abertos
[
i
]
.
style
.
display
=
"none"
;
}
}
if
(
select
.
value
==
"avaliacao"
||
select
.
value
==
"todos"
)
{
for
(
var
i
=
0
;
i
<
avaliacao
.
length
;
i
++
)
{
avaliacao
[
i
]
.
style
.
display
=
""
;
}
}
else
{
for
(
var
i
=
0
;
i
<
avaliacao
.
length
;
i
++
)
{
avaliacao
[
i
]
.
style
.
display
=
"none"
;
}
}
if
(
select
.
value
==
"encerrado"
||
select
.
value
==
"todos"
)
{
for
(
var
i
=
0
;
i
<
encerrado
.
length
;
i
++
)
{
encerrado
[
i
]
.
style
.
display
=
""
;
}
}
else
{
for
(
var
i
=
0
;
i
<
encerrado
.
length
;
i
++
)
{
encerrado
[
i
]
.
style
.
display
=
"none"
;
}
}
}
</
script
>
@
endsection
@
endsection
resources/views/naturezas/index.blade.php
View file @
b8e96d8a
...
@@ -97,7 +97,7 @@
...
@@ -97,7 +97,7 @@
<
thead
>
<
thead
>
<
tr
>
<
tr
>
<
th
scope
=
"col"
>
Nome
</
th
>
<
th
scope
=
"col"
>
Nome
</
th
>
<
th
scope
=
"col"
>
Data
de
c
riação
</
th
>
<
th
scope
=
"col"
>
Data
de
C
riação
</
th
>
<
th
scope
=
"col"
>
Opção
</
th
>
<
th
scope
=
"col"
>
Opção
</
th
>
</
tr
>
</
tr
>
</
thead
>
</
thead
>
...
@@ -203,7 +203,7 @@
...
@@ -203,7 +203,7 @@
<
thead
>
<
thead
>
<
tr
>
<
tr
>
<
th
scope
=
"col"
>
Nome
</
th
>
<
th
scope
=
"col"
>
Nome
</
th
>
<
th
scope
=
"col"
>
Data
de
c
riação
</
th
>
<
th
scope
=
"col"
>
Data
de
C
riação
</
th
>
<
th
scope
=
"col"
>
Opção
</
th
>
<
th
scope
=
"col"
>
Opção
</
th
>
</
tr
>
</
tr
>
</
thead
>
</
thead
>
...
...
resources/views/projeto/index.blade.php
View file @
b8e96d8a
...
@@ -39,7 +39,7 @@
...
@@ -39,7 +39,7 @@
<
table
class
=
"table table-bordered"
>
<
table
class
=
"table table-bordered"
>
<
thead
>
<
thead
>
<
tr
>
<
tr
>
<
th
scope
=
"col"
>
Nome
do
p
rojeto
</
th
>
<
th
scope
=
"col"
>
P
rojeto
</
th
>
<
th
scope
=
"col"
>
Status
</
th
>
<
th
scope
=
"col"
>
Status
</
th
>
<
th
scope
=
"col"
>
Data
de
Criação
</
th
>
<
th
scope
=
"col"
>
Data
de
Criação
</
th
>
<
th
scope
=
"col"
>
Opção
</
th
>
<
th
scope
=
"col"
>
Opção
</
th
>
...
@@ -57,7 +57,7 @@
...
@@ -57,7 +57,7 @@
@
elseif
(
$projeto
->
status
==
'Submetido'
)
@
elseif
(
$projeto
->
status
==
'Submetido'
)
<
td
style
=
"color: rgb(0, 0, 0)"
>
Submetido
</
td
>
<
td
style
=
"color: rgb(0, 0, 0)"
>
Submetido
</
td
>
@
endif
@
endif
<
td
>
{{
date
(
'd
-m-
Y'
,
strtotime
(
$projeto
->
updated_at
))
}}
</
td
>
<
td
>
{{
date
(
'd
/m/
Y'
,
strtotime
(
$projeto
->
updated_at
))
}}
</
td
>
<
td
>
<
td
>
<
div
class
=
"btn-group dropright dropdown-options"
>
<
div
class
=
"btn-group dropright dropdown-options"
>
<
a
id
=
"options"
class
=
"dropdown-toggle "
data
-
toggle
=
"dropdown"
aria
-
haspopup
=
"true"
aria
-
expanded
=
"false"
>
<
a
id
=
"options"
class
=
"dropdown-toggle "
data
-
toggle
=
"dropdown"
aria
-
haspopup
=
"true"
aria
-
expanded
=
"false"
>
...
...
resources/views/proponente/editais.blade.php
View file @
b8e96d8a
...
@@ -16,11 +16,11 @@
...
@@ -16,11 +16,11 @@
<
table
class
=
"table table-bordered"
>
<
table
class
=
"table table-bordered"
>
<
thead
>
<
thead
>
<
tr
>
<
tr
>
<
th
scope
=
"col"
>
Nome
do
Edital
</
th
>
<
th
scope
=
"col"
>
Edital
</
th
>
<
th
scope
=
"col"
>
Inicio
da
Submissão
</
th
>
<
th
scope
=
"col"
style
=
"text-align: center;"
>
Inicio
da
Submissão
</
th
>
<
th
scope
=
"col"
>
Fim
da
Submissão
</
th
>
<
th
scope
=
"col"
style
=
"text-align: center;"
>
Fim
da
Submissão
</
th
>
<
th
scope
=
"col"
>
Data
do
Resultado
</
th
>
<
th
scope
=
"col"
style
=
"text-align: center;"
>
Data
do
Resultado
</
th
>
<
th
scope
=
"col"
>
Baixar
e
dital
</
th
>
<
th
scope
=
"col"
style
=
"text-align: center;"
>
Baixar
E
dital
</
th
>
<
th
scope
=
"col"
>
Opção
</
th
>
<
th
scope
=
"col"
>
Opção
</
th
>
</
tr
>
</
tr
>
</
thead
>
</
thead
>
...
@@ -32,9 +32,9 @@
...
@@ -32,9 +32,9 @@
{{
$evento
->
nome
}}
{{
$evento
->
nome
}}
</
a
>
</
a
>
</
td
>
</
td
>
<
td
>
{{
date
(
'd/m/Y'
,
strtotime
(
$evento
->
inicioSubmissao
))
}}
</
td
>
<
td
style
=
"text-align: center;"
>
{{
date
(
'd/m/Y'
,
strtotime
(
$evento
->
inicioSubmissao
))
}}
</
td
>
<
td
>
{{
date
(
'd/m/Y'
,
strtotime
(
$evento
->
fimSubmissao
))
}}
</
td
>
<
td
style
=
"text-align: center;"
>
{{
date
(
'd/m/Y'
,
strtotime
(
$evento
->
fimSubmissao
))
}}
</
td
>
<
td
>
{{
date
(
'd/m/Y'
,
strtotime
(
$evento
->
created_at
))
}}
</
td
>
<
td
style
=
"text-align: center;"
>
{{
date
(
'd/m/Y'
,
strtotime
(
$evento
->
created_at
))
}}
</
td
>
<
td
style
=
"text-align: center"
>
<
td
style
=
"text-align: center"
>
<
a
href
=
"{{ route('baixar.edital', ['id' =>
$evento->id
]) }}"
>
<
a
href
=
"{{ route('baixar.edital', ['id' =>
$evento->id
]) }}"
>
<
img
src
=
"
{
{asset('img/icons/file-download-solid.svg')}
}
"
width
=
"15px"
>
<
img
src
=
"
{
{asset('img/icons/file-download-solid.svg')}
}
"
width
=
"15px"
>
...
...
resources/views/proponente/projetos.blade.php
View file @
b8e96d8a
...
@@ -22,7 +22,7 @@
...
@@ -22,7 +22,7 @@
<
table
class
=
"table table-bordered"
>
<
table
class
=
"table table-bordered"
>
<
thead
>
<
thead
>
<
tr
>
<
tr
>
<
th
scope
=
"col"
>
Nome
do
p
rojeto
</
th
>
<
th
scope
=
"col"
>
P
rojeto
</
th
>
<
th
scope
=
"col"
>
Status
</
th
>
<
th
scope
=
"col"
>
Status
</
th
>
<
th
scope
=
"col"
>
Data
de
Criação
</
th
>
<
th
scope
=
"col"
>
Data
de
Criação
</
th
>
<
th
scope
=
"col"
>
Opção
</
th
>
<
th
scope
=
"col"
>
Opção
</
th
>
...
@@ -42,7 +42,7 @@
...
@@ -42,7 +42,7 @@
@
elseif
(
$projeto
->
status
==
'Rascunho'
)
@
elseif
(
$projeto
->
status
==
'Rascunho'
)
<
td
style
=
"color: rgb(0, 0, 0)"
>
Rascunho
</
td
>
<
td
style
=
"color: rgb(0, 0, 0)"
>
Rascunho
</
td
>
@
endif
@
endif
<
td
>
{{
date
(
'd
-m-
Y'
,
strtotime
(
$projeto
->
updated_at
))
}}
</
td
>
<
td
>
{{
date
(
'd
/m/
Y'
,
strtotime
(
$projeto
->
updated_at
))
}}
</
td
>
<
td
>
<
td
>
<
div
class
=
"btn-group dropright dropdown-options"
>
<
div
class
=
"btn-group dropright dropdown-options"
>
<
a
id
=
"options"
class
=
"dropdown-toggle "
data
-
toggle
=
"dropdown"
aria
-
haspopup
=
"true"
aria
-
expanded
=
"false"
>
<
a
id
=
"options"
class
=
"dropdown-toggle "
data
-
toggle
=
"dropdown"
aria
-
haspopup
=
"true"
aria
-
expanded
=
"false"
>
...
...
routes/web.php
View file @
b8e96d8a
...
@@ -97,7 +97,7 @@ Route::prefix('avaliador')->name('avaliador.')->group(function(){
...
@@ -97,7 +97,7 @@ Route::prefix('avaliador')->name('avaliador.')->group(function(){
Route
::
get
(
'/trabalho/submeter/{id}'
,
'TrabalhoController@index'
)
->
name
(
'trabalho.index'
);
Route
::
get
(
'/trabalho/submeter/{id}'
,
'TrabalhoController@index'
)
->
name
(
'trabalho.index'
);
Route
::
get
(
'/trabalho/visualizar/{id}'
,
'TrabalhoController@show'
)
->
name
(
'trabalho.show'
);
Route
::
get
(
'/trabalho/visualizar/{id}'
,
'TrabalhoController@show'
)
->
name
(
'trabalho.show'
);
Route
::
post
(
'/trabalho/novaVersao'
,
'TrabalhoController@novaVersao'
)
->
name
(
'trabalho.novaVersao'
);
Route
::
post
(
'/trabalho/novaVersao'
,
'TrabalhoController@novaVersao'
)
->
name
(
'trabalho.novaVersao'
);
Route
::
post
(
'/trabalho/criar'
,
'TrabalhoController@s
tore
'
)
->
name
(
'trabalho.store'
);
Route
::
post
(
'/trabalho/criar'
,
'TrabalhoController@s
alvar
'
)
->
name
(
'trabalho.store'
);
Route
::
post
(
'/trabalho/criarRascunho'
,
'TrabalhoController@storeParcial'
)
->
name
(
'trabalho.storeParcial'
);
Route
::
post
(
'/trabalho/criarRascunho'
,
'TrabalhoController@storeParcial'
)
->
name
(
'trabalho.storeParcial'
);
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'
);
...
...
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