Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
th-app-java
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Oscar Enrique Gonzalez Escurra
th-app-java
Commits
91d8e43b
Commit
91d8e43b
authored
Nov 23, 2021
by
Cesar Giulano Gonzalez Maqueda
Browse files
Options
Browse Files
Download
Plain Diff
merge con joel
parents
fc14b503
ea8da093
Hide whitespace changes
Inline
Side-by-side
Showing
17 changed files
with
390 additions
and
107 deletions
+390
-107
curriculumsearch/pom.xml
+6
-17
curriculumsearch/src/main/java/com/roshka/CurriculumsearchApplication.java
+1
-0
curriculumsearch/src/main/java/com/roshka/controller/PostulanteController.java
+1
-4
curriculumsearch/src/main/java/com/roshka/controller/PostulanteRRHHController.java
+23
-0
curriculumsearch/src/main/java/com/roshka/modelo/Postulante.java
+3
-0
curriculumsearch/src/main/java/com/roshka/modelo/PostulanteTecnologia.java
+1
-1
curriculumsearch/src/main/java/com/roshka/service/PdfGenerator.java
+169
-0
curriculumsearch/src/main/java/com/roshka/utils/Helper.java
+28
-3
curriculumsearch/src/main/resources/json/postulante.json
+9
-9
curriculumsearch/src/main/resources/json/tecnologia.json
+13
-0
curriculumsearch/src/main/webapp/css/formPostulanteStyle.css
+6
-0
curriculumsearch/src/main/webapp/jsp/cargos.jsp
+36
-31
curriculumsearch/src/main/webapp/jsp/convocatorias.jsp
+16
-10
curriculumsearch/src/main/webapp/jsp/detallepostulante.jsp
+3
-0
curriculumsearch/src/main/webapp/jsp/dp.jsp
+16
-0
curriculumsearch/src/main/webapp/jsp/postulante-form.jsp
+23
-2
curriculumsearch/src/main/webapp/jsp/tecnologias.jsp
+36
-30
No files found.
curriculumsearch/pom.xml
View file @
91d8e43b
...
@@ -92,24 +92,7 @@
...
@@ -92,24 +92,7 @@
<scope>
compile
</scope>
<scope>
compile
</scope>
</dependency>
</dependency>
<dependency>
<groupId>
com.itextpdf
</groupId>
<artifactId>
kernel
</artifactId>
<version>
7.1.12
</version>
</dependency>
<dependency>
<groupId>
com.itextpdf
</groupId>
<artifactId>
html2pdf
</artifactId>
<version>
3.0.1
</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-starter-thymeleaf -->
<!-- <dependency>-->
<!-- <groupId>org.springframework.boot</groupId>-->
<!-- <artifactId>spring-boot-starter-thymeleaf</artifactId>-->
<!-- <version>2.6.0</version>-->
<!-- </dependency>-->
<dependency>
<dependency>
<groupId>
org.apache.poi
</groupId>
<groupId>
org.apache.poi
</groupId>
...
@@ -117,6 +100,12 @@
...
@@ -117,6 +100,12 @@
<version>
4.1.0
</version>
<version>
4.1.0
</version>
</dependency>
</dependency>
<dependency>
<groupId>
com.itextpdf
</groupId>
<artifactId>
itextpdf
</artifactId>
<version>
5.5.13
</version>
</dependency>
</dependencies>
</dependencies>
...
...
curriculumsearch/src/main/java/com/roshka/CurriculumsearchApplication.java
View file @
91d8e43b
...
@@ -42,6 +42,7 @@ public class CurriculumsearchApplication {
...
@@ -42,6 +42,7 @@ public class CurriculumsearchApplication {
guardarJson
(
convR
,
"/json/convocatoria.json"
,
ConvocatoriaCargo
.
class
);
guardarJson
(
convR
,
"/json/convocatoria.json"
,
ConvocatoriaCargo
.
class
);
guardarJson
(
depR
,
"/json/Departamento.json"
,
Departamento
.
class
);
guardarJson
(
depR
,
"/json/Departamento.json"
,
Departamento
.
class
);
guardarJson
(
ciudR
,
"/json/Ciudad.json"
,
Ciudad
.
class
);
guardarJson
(
ciudR
,
"/json/Ciudad.json"
,
Ciudad
.
class
);
guardarJson
(
tecRepo
,
"/json/tecnologia.json"
,
Tecnologia
.
class
);
guardarJson
(
postRepo
,
"/json/postulante.json"
,
Postulante
.
class
);
guardarJson
(
postRepo
,
"/json/postulante.json"
,
Postulante
.
class
);
String
password
=
new
BCryptPasswordEncoder
().
encode
(
"test"
);
String
password
=
new
BCryptPasswordEncoder
().
encode
(
"test"
);
...
...
curriculumsearch/src/main/java/com/roshka/controller/PostulanteController.java
View file @
91d8e43b
...
@@ -114,10 +114,7 @@ public class PostulanteController {
...
@@ -114,10 +114,7 @@ public class PostulanteController {
DBFile
cv
=
Helper
.
createFile
(
file
);
DBFile
cv
=
Helper
.
createFile
(
file
);
if
(
cv
!=
null
)
cv
.
setPostulante
(
postulante
);
if
(
cv
!=
null
)
cv
.
setPostulante
(
postulante
);
postulante
.
setCvFile
(
cv
);
postulante
.
setCvFile
(
cv
);
}
}
postulante
.
getTecnologias
().
stream
().
filter
(
tec
->
tec
.
getTecnologia
().
getId
()
!=
0
)
.
forEach
(
tec
->
tec
.
setTecnologia
(
tecRepo
.
getById
(
tec
.
getTecnologia
().
getId
())));
for
(
Estudio
estudio:
postulante
.
getEstudios
()){
for
(
Estudio
estudio:
postulante
.
getEstudios
()){
String
nombreIns
=
""
;
String
nombreIns
=
""
;
nombreIns
=
estudio
.
getInstitucion
().
getNombre
().
toLowerCase
();
nombreIns
=
estudio
.
getInstitucion
().
getNombre
().
toLowerCase
();
...
...
curriculumsearch/src/main/java/com/roshka/controller/PostulanteRRHHController.java
View file @
91d8e43b
...
@@ -26,6 +26,7 @@ import com.roshka.repositorio.ExperienciaRepository;
...
@@ -26,6 +26,7 @@ import com.roshka.repositorio.ExperienciaRepository;
import
com.roshka.repositorio.InstitucionRepository
;
import
com.roshka.repositorio.InstitucionRepository
;
import
com.roshka.repositorio.PostulanteRepository
;
import
com.roshka.repositorio.PostulanteRepository
;
import
com.roshka.repositorio.TecnologiaRepository
;
import
com.roshka.repositorio.TecnologiaRepository
;
import
com.roshka.service.PdfGenerator
;
import
com.roshka.utils.Helper
;
import
com.roshka.utils.Helper
;
...
@@ -247,5 +248,26 @@ public class PostulanteRRHHController {
...
@@ -247,5 +248,26 @@ public class PostulanteRRHHController {
}
}
}
}
@GetMapping
(
"/postulantes/{id}/pdf"
)
public
ResponseEntity
<
Resource
>
downloadPDF
(
@PathVariable
Long
id
)
{
// Load file from database
PdfGenerator
pdf
=
new
PdfGenerator
();
try
{
Postulante
postulante
=
post
.
findById
(
id
)
.
orElseThrow
(()
->
new
Exception
(
"Postulante no encontrado"
));
return
ResponseEntity
.
ok
()
.
contentType
(
MediaType
.
parseMediaType
(
"application/pdf"
))
.
header
(
HttpHeaders
.
CONTENT_DISPOSITION
,
"attachment; filename=\""
+
postulante
.
getNroDocument
()
+
".pdf"
+
"\""
)
.
body
(
new
ByteArrayResource
(
pdf
.
generatePdfReport
(
postulante
)));
}
catch
(
Exception
e
)
{
// TODO Auto-generated catch block
e
.
printStackTrace
();
return
ResponseEntity
.
notFound
().
build
();
}
}
}
}
\ No newline at end of file
curriculumsearch/src/main/java/com/roshka/modelo/Postulante.java
View file @
91d8e43b
...
@@ -96,6 +96,9 @@ public class Postulante {
...
@@ -96,6 +96,9 @@ public class Postulante {
@Column
(
name
=
"disponibilidad"
,
length
=
2
)
@Column
(
name
=
"disponibilidad"
,
length
=
2
)
private
Disponibilidad
disponibilidad
;
private
Disponibilidad
disponibilidad
;
@Column
(
name
=
"tecnologia_otros"
)
private
String
tecnologiaOtros
;
@JsonManagedReference
(
value
=
"postulantetecnologia-postulante"
)
@JsonManagedReference
(
value
=
"postulantetecnologia-postulante"
)
@OneToMany
(
mappedBy
=
"postulante"
,
cascade
=
CascadeType
.
ALL
)
@OneToMany
(
mappedBy
=
"postulante"
,
cascade
=
CascadeType
.
ALL
)
private
List
<
PostulanteTecnologia
>
tecnologias
;
private
List
<
PostulanteTecnologia
>
tecnologias
;
...
...
curriculumsearch/src/main/java/com/roshka/modelo/PostulanteTecnologia.java
View file @
91d8e43b
...
@@ -31,7 +31,7 @@ public class PostulanteTecnologia {
...
@@ -31,7 +31,7 @@ public class PostulanteTecnologia {
@Min
(
value
=
1
)
@Min
(
value
=
1
)
@Max
(
value
=
5
)
@Max
(
value
=
5
)
private
Long
nivel
;
private
Long
nivel
;
@ManyToOne
(
cascade
=
{
CascadeType
.
PERSIST
},
optional
=
false
)
@ManyToOne
()
@JoinColumn
@JoinColumn
private
Tecnologia
tecnologia
;
private
Tecnologia
tecnologia
;
...
...
curriculumsearch/src/main/java/com/roshka/service/PdfGenerator.java
0 → 100644
View file @
91d8e43b
package
com
.
roshka
.
service
;
import
java.io.ByteArrayOutputStream
;
import
java.util.Date
;
import
java.util.stream.Collectors
;
import
com.itextpdf.text.List
;
import
com.itextpdf.text.ListItem
;
import
org.springframework.stereotype.Component
;
import
com.itextpdf.text.Document
;
import
com.itextpdf.text.DocumentException
;
import
com.itextpdf.text.Element
;
import
com.itextpdf.text.Font
;
import
com.itextpdf.text.Paragraph
;
import
com.itextpdf.text.pdf.PdfWriter
;
import
com.roshka.modelo.Estudio
;
import
com.roshka.modelo.Experiencia
;
import
com.roshka.modelo.Postulante
;
import
com.roshka.utils.Helper
;
@Component
(
"pdfGenerator"
)
public
class
PdfGenerator
{
private
static
Font
COURIER
=
new
Font
(
Font
.
FontFamily
.
COURIER
,
20
,
Font
.
BOLD
);
private
static
Font
COURIER_MEDIUM
=
new
Font
(
Font
.
FontFamily
.
COURIER
,
16
,
Font
.
BOLD
);
private
static
Font
COURIER_SMALL
=
new
Font
(
Font
.
FontFamily
.
COURIER
,
14
,
Font
.
UNDERLINE
);
public
byte
[]
generatePdfReport
(
Postulante
postulante
)
{
Document
document
=
new
Document
();
try
{
ByteArrayOutputStream
byteArrayOutputStream
=
new
ByteArrayOutputStream
();
PdfWriter
.
getInstance
(
document
,
byteArrayOutputStream
);
document
.
open
();
addDocTitle
(
document
,
postulante
);
createTable
(
document
,
postulante
);
document
.
close
();
System
.
out
.
println
(
"------------------Your PDF Report is ready!-------------------------"
);
return
byteArrayOutputStream
.
toByteArray
();
}
catch
(
DocumentException
e
)
{
// TODO Auto-generated catch block
e
.
printStackTrace
();
return
null
;
}
}
private
void
addDocTitle
(
Document
document
,
Postulante
postulante
)
throws
DocumentException
{
Paragraph
p1
=
new
Paragraph
();
leaveEmptyLine
(
p1
,
1
);
p1
.
add
(
new
Paragraph
(
"Detalles del postulante"
,
COURIER
));
p1
.
setAlignment
(
Element
.
ALIGN_CENTER
);
document
.
add
(
p1
);
}
private
void
agregarEncabezado
(
Document
document
,
String
titulo
)
throws
DocumentException
{
Paragraph
p1
=
new
Paragraph
();
p1
.
setAlignment
(
Element
.
ALIGN_CENTER
);
p1
.
add
(
new
Paragraph
(
titulo
,
COURIER_MEDIUM
));
document
.
add
(
p1
);
}
private
void
agregarSubEncabezado
(
Document
document
,
String
titulo
)
throws
DocumentException
{
Paragraph
p1
=
new
Paragraph
();
p1
.
setAlignment
(
Element
.
ALIGN_CENTER
);
p1
.
add
(
new
Paragraph
(
titulo
,
COURIER_SMALL
));
document
.
add
(
p1
);
}
private
void
agregarLabelTexto
(
Document
document
,
String
label
,
Object
texto
)
throws
DocumentException
{
if
(
texto
==
null
)
return
;
if
(
texto
instanceof
Date
)
texto
=
Helper
.
formatDate
((
Date
)
texto
,
"dd-MM-yyyy"
);
Paragraph
paragraph
=
new
Paragraph
();
paragraph
.
add
(
label
+
": "
);
paragraph
.
add
(
texto
.
toString
());
document
.
add
(
paragraph
);
}
private
void
createTable
(
Document
document
,
Postulante
postulante
)
throws
DocumentException
{
Paragraph
paragraph
=
new
Paragraph
();
leaveEmptyLine
(
paragraph
,
3
);
//paragraph.add();
agregarEncabezado
(
document
,
"Datos personales"
);
agregarLabelTexto
(
document
,
"Nombre"
,
postulante
.
getNombre
()
+
" "
+
postulante
.
getApellido
());
agregarLabelTexto
(
document
,
"Nro de Documento"
,
postulante
.
getNroDocument
());
agregarLabelTexto
(
document
,
"Correo"
,
postulante
.
getCorreo
());
agregarLabelTexto
(
document
,
"Direccion"
,
postulante
.
getDireccion
());
agregarLabelTexto
(
document
,
"Ciudad"
,
postulante
.
getCiudad
().
getNombre
());
agregarLabelTexto
(
document
,
"Telefono"
,
postulante
.
getTelefono
());
agregarLabelTexto
(
document
,
"Edad"
,
Helper
.
calculateAge
(
postulante
.
getFechaNacimiento
())
);
agregarLabelTexto
(
document
,
"Nivel de Ingles"
,
postulante
.
getNivelIngles
());
agregarLabelTexto
(
document
,
"Nacionalidad"
,
postulante
.
getNacionalidad
().
getDescripcion
());
agregarEncabezado
(
document
,
"Experiencias"
);
for
(
Experiencia
ex
:
postulante
.
getExperiencias
()){
agregarSubEncabezado
(
document
,
ex
.
getInstitucion
());
agregarLabelTexto
(
document
,
"Fecha Inicio"
,
ex
.
getFechaDesde
());
agregarLabelTexto
(
document
,
"Fecha Fin"
,
ex
.
getFechaHasta
());
agregarLabelTexto
(
document
,
"Cargo"
,
ex
.
getCargo
());
agregarLabelTexto
(
document
,
"Tipo Experiencia"
,
ex
.
getTipoExperiencia
());
agregarLabelTexto
(
document
,
"Descripcion"
,
ex
.
getDescripcion
());
agregarLabelTexto
(
document
,
"Nombre Referencia"
,
ex
.
getNombreReferencia
());
agregarLabelTexto
(
document
,
"Telefono Referencia"
,
ex
.
getTelefonoReferencia
());
agregarLabelTexto
(
document
,
"Motivo Salida"
,
ex
.
getMotivoSalida
());
}
agregarEncabezado
(
document
,
"Estudios"
);
for
(
Estudio
ex
:
postulante
.
getEstudios
()){
agregarSubEncabezado
(
document
,
ex
.
getInstitucion
().
getNombre
());
agregarLabelTexto
(
document
,
"Fecha Inicio"
,
ex
.
getFechaDesde
());
agregarLabelTexto
(
document
,
"Fecha Fin"
,
ex
.
getFechaHasta
());
agregarLabelTexto
(
document
,
"Tema de Estudio"
,
ex
.
getTemaDeEstudio
());
agregarLabelTexto
(
document
,
"Tipo de Estudio"
,
ex
.
getTipoDeEstudio
());
agregarLabelTexto
(
document
,
"Descripcion"
,
ex
.
getEstado
().
toString
());
}
agregarEncabezado
(
document
,
"Cargo al cual postula"
);
agregarList
(
postulante
.
getPostulaciones
().
stream
()
.
map
(
cc
->
cc
.
getCargo
().
getNombre
())
.
collect
(
Collectors
.
toList
()),
document
);
agregarEncabezado
(
document
,
"Tecnologias"
);
agregarList
(
postulante
.
getTecnologias
().
stream
()
.
map
(
cc
->
cc
.
getTecnologia
().
getNombre
())
.
collect
(
Collectors
.
toList
()),
document
);
agregarEncabezado
(
document
,
"Referencias Personales"
);
agregarList
(
postulante
.
getReferencias
().
stream
()
.
map
(
cc
->
"Nombre: "
+
cc
.
getNombre
()
+
". Relacion: "
+
cc
.
getRelacion
()
+
". Telefono: "
+
cc
.
getTelefono
()
)
.
collect
(
Collectors
.
toList
()),
document
);
}
private
void
agregarList
(
java
.
util
.
List
<
String
>
items
,
Document
document
)
throws
DocumentException
{
List
list
=
new
List
(
false
);
for
(
String
item
:
items
){
list
.
add
(
new
ListItem
(
item
));
}
document
.
add
(
list
);
}
private
static
void
leaveEmptyLine
(
Paragraph
paragraph
,
int
number
)
{
for
(
int
i
=
0
;
i
<
number
;
i
++)
{
paragraph
.
add
(
new
Paragraph
(
" "
));
}
}
}
curriculumsearch/src/main/java/com/roshka/utils/Helper.java
View file @
91d8e43b
...
@@ -3,9 +3,9 @@ package com.roshka.utils;
...
@@ -3,9 +3,9 @@ package com.roshka.utils;
import
java.io.IOException
;
import
java.io.IOException
;
import
java.text.ParseException
;
import
java.text.ParseException
;
import
java.text.SimpleDateFormat
;
import
java.text.SimpleDateFormat
;
import
java.time.
YearMonth
;
import
java.time.
LocalDate
;
import
java.time.
ZoneOffset
;
import
java.time.
Period
;
import
java.time.
temporal.ChronoUnit
;
import
java.time.
format.DateTimeFormatter
;
import
java.util.Date
;
import
java.util.Date
;
import
java.util.concurrent.TimeUnit
;
import
java.util.concurrent.TimeUnit
;
...
@@ -46,6 +46,31 @@ public class Helper {
...
@@ -46,6 +46,31 @@ public class Helper {
return
Math
.
round
(
diff
/
30
.
d
)
;
return
Math
.
round
(
diff
/
30
.
d
)
;
}
}
public
static
LocalDate
convertToLocalDateViaSqlDate
(
Date
dateToConvert
)
{
return
new
java
.
sql
.
Date
(
dateToConvert
.
getTime
()).
toLocalDate
();
}
public
static
int
calculateAge
(
LocalDate
birthDate
,
LocalDate
currentDate
)
{
if
((
birthDate
!=
null
)
&&
(
currentDate
!=
null
))
{
return
Period
.
between
(
birthDate
,
currentDate
).
getYears
();
}
else
{
return
0
;
}
}
public
static
int
calculateAge
(
Date
birthDate
)
{
LocalDate
currentDate
=
LocalDate
.
now
();
return
calculateAge
(
convertToLocalDateViaSqlDate
(
birthDate
),
currentDate
);
}
public
static
String
formatDate
(
LocalDate
fecha
,
String
format
){
if
(
fecha
==
null
||
format
==
null
)
return
null
;
return
fecha
.
format
(
DateTimeFormatter
.
ofPattern
(
format
));
}
public
static
String
formatDate
(
Date
fecha
,
String
format
){
return
formatDate
(
convertToLocalDateViaSqlDate
(
fecha
),
format
);
}
public
static
DBFile
createFile
(
MultipartFile
file
)
{
public
static
DBFile
createFile
(
MultipartFile
file
)
{
// Normalize file name
// Normalize file name
String
fileName
=
StringUtils
.
cleanPath
(
file
.
getOriginalFilename
());
String
fileName
=
StringUtils
.
cleanPath
(
file
.
getOriginalFilename
());
...
...
curriculumsearch/src/main/resources/json/postulante.json
View file @
91d8e43b
...
@@ -40,19 +40,19 @@
...
@@ -40,19 +40,19 @@
"tecnologias"
:
[
"tecnologias"
:
[
{
{
"tecnologia"
:
{
"tecnologia"
:
{
"
nombre"
:
"JAVA"
"
id"
:
1
},
},
"nivel"
:
5
"nivel"
:
5
},
},
{
{
"tecnologia"
:
{
"tecnologia"
:
{
"
nombre"
:
"Python"
"
id"
:
2
},
},
"nivel"
:
4
"nivel"
:
4
},
},
{
{
"tecnologia"
:
{
"tecnologia"
:
{
"
nombre"
:
"C"
"
id"
:
3
},
},
"nivel"
:
5
"nivel"
:
5
}
}
...
@@ -99,7 +99,7 @@
...
@@ -99,7 +99,7 @@
"tecnologias"
:
[
"tecnologias"
:
[
{
{
"tecnologia"
:
{
"tecnologia"
:
{
"
nombre"
:
"Spring"
"
id"
:
4
},
},
"nivel"
:
2
"nivel"
:
2
}
}
...
@@ -146,7 +146,7 @@
...
@@ -146,7 +146,7 @@
"tecnologias"
:
[
"tecnologias"
:
[
{
{
"tecnologia"
:
{
"tecnologia"
:
{
"
nombre"
:
"Django"
"
id"
:
5
},
},
"nivel"
:
3
"nivel"
:
3
}
}
...
@@ -193,7 +193,7 @@
...
@@ -193,7 +193,7 @@
"tecnologias"
:
[
"tecnologias"
:
[
{
{
"tecnologia"
:
{
"tecnologia"
:
{
"
nombre"
:
"Flutter"
"
id"
:
6
},
},
"nivel"
:
2
"nivel"
:
2
}
}
...
@@ -240,7 +240,7 @@
...
@@ -240,7 +240,7 @@
"tecnologias"
:
[
"tecnologias"
:
[
{
{
"tecnologia"
:
{
"tecnologia"
:
{
"
nombre"
:
"Switf"
"
id"
:
3
},
},
"nivel"
:
5
"nivel"
:
5
}
}
...
@@ -287,7 +287,7 @@
...
@@ -287,7 +287,7 @@
"tecnologias"
:
[
"tecnologias"
:
[
{
{
"tecnologia"
:
{
"tecnologia"
:
{
"
nombre"
:
"SL"
"
id"
:
2
},
},
"nivel"
:
4
"nivel"
:
4
}
}
...
@@ -334,7 +334,7 @@
...
@@ -334,7 +334,7 @@
"tecnologias"
:
[
"tecnologias"
:
[
{
{
"tecnologia"
:
{
"tecnologia"
:
{
"
nombre"
:
"Scala"
"
id"
:
5
},
},
"nivel"
:
5
"nivel"
:
5
}
}
...
...
curriculumsearch/src/main/resources/json/tecnologia.json
View file @
91d8e43b
...
@@ -18,5 +18,17 @@
...
@@ -18,5 +18,17 @@
{
{
"id"
:
5
,
"id"
:
5
,
"nombre"
:
"spring"
"nombre"
:
"spring"
},
{
"id"
:
6
,
"nombre"
:
"php"
},
{
"id"
:
7
,
"nombre"
:
"laravel"
},
{
"id"
:
8
,
"nombre"
:
"sqlserver"
}
}
]
]
\ No newline at end of file
curriculumsearch/src/main/webapp/css/formPostulanteStyle.css
View file @
91d8e43b
...
@@ -213,4 +213,9 @@ h4{
...
@@ -213,4 +213,9 @@ h4{
}
}
form
[
name
=
"postulante"
]
{
form
[
name
=
"postulante"
]
{
color
:
#ffffff
;
color
:
#ffffff
;
}
.form-check-input
:checked
{
background-color
:
#198754
;
border-color
:
#0d6efd
;
}
}
\ No newline at end of file
curriculumsearch/src/main/webapp/jsp/cargos.jsp
View file @
91d8e43b
...
@@ -20,40 +20,45 @@ contentType="text/html;charset=UTF-8" language="java" %>
...
@@ -20,40 +20,45 @@ contentType="text/html;charset=UTF-8" language="java" %>
</form>
</form>
<a href="/cargo">Agregar Nuevo Cargo</a>
<a href="/cargo">Agregar Nuevo Cargo</a>
</div>
</div>
<div>
<div class="card text-dark bg-light mt-3">
<table class="table">
<thead>
<div class="card-body">
<tr>
<div class="table-responsive">
<th scope="col">#</th>
<table class="table">
<th scope="col">Cargo</th>
<thead>
</tr>
</thead>
<tbody>
<c:forEach items="${cargos}" var="cargo" varStatus="sta">
<tr>
<tr>
<th scope="row">${sta.index+1}</th>
<th scope="col">#</th>
<td>${cargo.getNombre()}</td>
<th scope="col">Cargo</th>
<td>
<a href="/convocatorias?cargoId=${cargo.id}"
>Ver Convocatorias</a
>
</td>
<td><a href="/cargo/${cargo.id}">Editar cargo</a></td>
</tr>
</tr>
</c:forEach>
</thead>
</tbody>
<tbody>
</table>
<c:forEach items="${cargos}" var="cargo" varStatus="sta">
<tr>
<th scope="row">${sta.index+1}</th>
<td>${cargo.getNombre()}</td>
<td>
<a href="/convocatorias?cargoId=${cargo.id}"
>Ver Convocatorias</a
>
</td>
<td><a href="/cargo/${cargo.id}">Editar cargo</a></td>
</tr>
</c:forEach>
</tbody>
</table>
</div>
</div>
</div>
</div>
</div
>
<div class="card-footer"
>
<div class="card-footer"
>
<div
>
<div
>
<nav aria-label="Page navigation example"
>
<nav aria-label="Page navigation example
">
<ul class="pagination
">
<ul class="pagination
">
<c:forEach begin="1" end="${pages}" var="nro
">
<c:forEach begin="1" end="${pages}" var="nro"
>
<li class="page-item ${(param.nroPagina == null and nro == 1) or param.nroPagina == nro-1 ? 'active' : ''}"><a class="page-link" href="javascript:buscarPagina(${nro})">${nro}</a></li
>
<
li class="page-item ${(param.nroPagina == null and nro == 1) or param.nroPagina == nro-1 ? 'active' : ''}"><a class="page-link" href="javascript:buscarPagina(${nro})">${nro}</a></li
>
<
/c:forEach
>
</
c:forEach
>
</
ul
>
</
ul
>
</
nav
>
</
na
v>
</
di
v>
</div>
</div>
</div>
</div>
</div>
</div>
...
...
curriculumsearch/src/main/webapp/jsp/convocatorias.jsp
View file @
91d8e43b
...
@@ -2,6 +2,8 @@
...
@@ -2,6 +2,8 @@
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib uri="http://kwonnam.pe.kr/jsp/template-inheritance" prefix="layout"%>
<%@ taglib uri="http://kwonnam.pe.kr/jsp/template-inheritance" prefix="layout"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<layout:extends name="layouts/base.jsp">
<layout:extends name="layouts/base.jsp">
<layout:put block="cssDeclaracion" type="APPEND"></layout:put>
<layout:put block="cssDeclaracion" type="APPEND"></layout:put>
<layout:put block="contents" type="REPLACE">
<layout:put block="contents" type="REPLACE">
...
@@ -25,12 +27,15 @@
...
@@ -25,12 +27,15 @@
<input type="submit" value="Buscar">
<input type="submit" value="Buscar">
</form>
</form>
</div>
</div>
<div>
<a href="/convocatoria">Agregar Nueva Convocatoria</a>
<a href="/convocatoria">Agregar Nueva Convocatoria</a>
<c:if test="${SUCCESS_MESSAGE != null}">
<c:if test="${SUCCESS_MESSAGE != null}">
<div id="status_message">${SUCCESS_MESSAGE}</div>
<div id="status_message">${SUCCESS_MESSAGE}</div>
</c:if>
</c:if>
<table class="table">
<div class="card text-dark bg-light mt-3">
<div class="card-body">
<div class="table-responsive">
<table class="table">
<thead>
<thead>
<tr>
<tr>
<th scope="col">#</th>
<th scope="col">#</th>
...
@@ -47,9 +52,9 @@
...
@@ -47,9 +52,9 @@
<th scope="row">${sta.index+1}</th>
<th scope="row">${sta.index+1}</th>
<td>${convocatoria.getCargo().getNombre()}</td>
<td>${convocatoria.getCargo().getNombre()}</td>
<td>${convocatoria.getEstado().getDescripcion()}</td>
<td>${convocatoria.getEstado().getDescripcion()}</td>
<td>
${convocatoria.getFechaInicio().toString().split(" ")[0]}
</td>
<td>
<fmt:formatDate value="${convocatoria.getFechaInicio()}" pattern="dd-MM-yyyy" />
</td>
<td>
${convocatoria.getFechaFin().toString().split(" ")[0]}
</td>
<td>
<fmt:formatDate value="${convocatoria.getFechaFin()}" pattern="dd-MM-yyyy" />
</td>
<td>
Ver Postulantes
</td>
<td>
<a href="/postulantes?convId=${convocatoria.id}">Ver postulantes</a>
</td>
<td><button onclick=window.location.href="/convocatoria/${convocatoria.id}">Cerrar convocatoria</button></td>
<td><button onclick=window.location.href="/convocatoria/${convocatoria.id}">Cerrar convocatoria</button></td>
</tr>
</tr>
</c:forEach>
</c:forEach>
...
@@ -57,8 +62,9 @@
...
@@ -57,8 +62,9 @@
</tbody>
</tbody>
</table>
</table>
</div>
</div>
</div>
</div>
</layout:put>
</layout:put>
...
...
curriculumsearch/src/main/webapp/jsp/detallepostulante.jsp
View file @
91d8e43b
...
@@ -145,6 +145,9 @@
...
@@ -145,6 +145,9 @@
</c:when>
</c:when>
</c:choose>
</c:choose>
<div class="col">
<a class="btn btn-link" target="__blank" href="/postulantes/${postulante.id}/pdf">Obtener pdf</a>
</div>
</div>
</div>
</div>
</div>
...
...
curriculumsearch/src/main/webapp/jsp/dp.jsp
0 → 100644
View file @
91d8e43b
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
<%@ taglib uri="http://kwonnam.pe.kr/jsp/template-inheritance" prefix="layout"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<layout:extends name="layouts/base.jsp">
<layout:put block="contents" type="REPLACE">
<h2 style="text-align: center;">
DETALLE POSTULANTE
</h2>
${postulante.nombre} ${postulante.apellido}
</layout:put>
</layout:extends>
curriculumsearch/src/main/webapp/jsp/postulante-form.jsp
View file @
91d8e43b
...
@@ -217,6 +217,27 @@
...
@@ -217,6 +217,27 @@
</div>
</div>
</div>
</div>
<!-- Button Otras tecnologias -->
<hr>
<div
class=
"inputs mb-3 col-md-12"
>
<div
class=
"row w-100 gy-2 mx-auto"
>
<div
class=
"col-12 px-0"
>
<h4
class=
"text-start"
>
Otras Tecnologias
</h4>
</div>
<div
class=
"col-6"
>
<div
class=
"mb-3"
>
<textarea
class=
"form-control"
id=
"exampleFormControlTextarea1"
name=
"tecnologiaOtros"
placeholder=
"Si tienes alguna tecnologia que no figura en la seccion anterior. Escribelos aqui."
></textarea>
</div>
</div>
</div>
</div>
<!-- Button Agregar Experiencia -->
<!-- Button Agregar Experiencia -->
<hr>
<hr>
...
@@ -238,7 +259,7 @@
...
@@ -238,7 +259,7 @@
<div
class=
"inputs mb-3 col-md-12"
>
<div
class=
"inputs mb-3 col-md-12"
>
<div
class=
"row w-100 gy-2 mx-auto"
>
<div
class=
"row w-100 gy-2 mx-auto"
>
<div
class=
"col-12 px-0"
>
<div
class=
"col-12 px-0"
>
<h4
class=
"text-start"
>
Referencia
Personal
<i
class=
"bi bi-plus-square"
data-bs-toggle=
"modal"
data-bs-target=
"#referenciaForm"
></i></h4>
<h4
class=
"text-start"
>
Referencia
s Personales
<i
class=
"bi bi-plus-square"
data-bs-toggle=
"modal"
data-bs-target=
"#referenciaForm"
></i></h4>
</div>
</div>
<div
class=
"col-12"
>
<div
class=
"col-12"
>
<div
class=
"mt-3 gap-2 row row-cols-4"
id=
"referencia"
>
<div
class=
"mt-3 gap-2 row row-cols-4"
id=
"referencia"
>
...
@@ -371,7 +392,7 @@
...
@@ -371,7 +392,7 @@
<div
class=
"modal-dialog"
role=
"document"
>
<div
class=
"modal-dialog"
role=
"document"
>
<div
class=
"modal-content"
>
<div
class=
"modal-content"
>
<div
class=
"modal-header"
>
<div
class=
"modal-header"
>
<h5
class=
"modal-title"
id=
"exampleModalLabel"
>
t
ecnologia
</h5>
<h5
class=
"modal-title"
id=
"exampleModalLabel"
>
T
ecnologia
</h5>
<button
type=
"button"
class=
"close"
data-bs-dismiss=
"modal"
aria-label=
"Close"
style=
"color:#21130d;"
>
<button
type=
"button"
class=
"close"
data-bs-dismiss=
"modal"
aria-label=
"Close"
style=
"color:#21130d;"
>
<span
aria-hidden=
"true"
>
×
</span>
<span
aria-hidden=
"true"
>
×
</span>
</button>
</button>
...
...
curriculumsearch/src/main/webapp/jsp/tecnologias.jsp
View file @
91d8e43b
...
@@ -15,41 +15,47 @@
...
@@ -15,41 +15,47 @@
</form>
</form>
<a href="/tecnologia">Agregar Nueva Tecnologia</a>
<a href="/tecnologia">Agregar Nueva Tecnologia</a>
</div>
</div>
<div>
<div class="card text-dark bg-light mt-3">
<table class="table">
<thead>
<div class="card-body">
<tr>
<div class="table-responsive">
<th scope="col">#</th>
<table class="table">
<th scope="col">Tecnologia</th>
<thead>
</tr>
<tr>
</thead>
<th scope="col">#</th>
<tbody>
<th scope="col">Tecnologia</th>
<th scope="col"></th>
<c:forEach items="${tecnologias}" var="tecnologia" varStatus="sta">
</tr>
<tr>
</thead>
<th scope="row">${sta.index+1}</th>
<tbody>
<td>${tecnologia.getNombre()}</td>
<c:forEach items="${tecnologias}" var="tecnologia" varStatus="sta">
<td><a href="/tecnologia/${tecnologia.id}">Editar tecnologia</a></td>
<tr>
</tr>
<th scope="row">${sta.index+1}</th>
</c:forEach>
<td>${tecnologia.getNombre()}</td>
<td><a href="/tecnologia/${tecnologia.id}"><i class="bi bi-pencil-fill"></i></a></td>
</tr>
</c:forEach>
</tbody>
</tbody>
</table>
</table>
</div>
<div class="card-footer">
<div>
<nav aria-label="Page navigation example">
<ul class="pagination">
<c:forEach begin="1" end="${pages}" var="nro">
<li class="page-item ${(param.nroPagina == null and nro == 1) or param.nroPagina == nro-1 ? 'active' : ''}"><a class="page-link" href="javascript:buscarPagina(${nro})">${nro}</a></li>
</c:forEach>
</ul>
</nav>
</div>
</div>
</div>
</div>
<div class="card-footer">
<div>
<nav aria-label="Page navigation example">
<ul class="pagination">
<c:forEach begin="1" end="${pages}" var="nro">
<li class="page-item ${(param.nroPagina == null and nro == 1) or param.nroPagina == nro-1 ? 'active' : ''}"><a class="page-link" href="javascript:buscarPagina(${nro})">${nro}</a></li>
</c:forEach>
</ul>
</nav>
</div>
</div>
</div>
</div>
</div>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment