Commit 1f09e4cd by Yovan Martinez

Solucionando errores de merge

parent 55e461bf
package com.roshka.proyectofinal.Postulante;
import com.roshka.proyectofinal.DataBase;
import com.roshka.proyectofinal.entity.Postulante;
import jakarta.servlet.http.HttpServlet;
import javafx.geometry.Pos;
import javax.xml.crypto.Data;
import java.sql.Connection;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
<<<<<<< HEAD
import java.util.ArrayList;
import java.util.List;
public class PostulanteDao extends HttpServlet {
=======
import java.sql.SQLException;
import java.util.ArrayList;
import java.util.List;
public class PostulanteDao {
List<Postulante> postulante = null;
>>>>>>> 9f750c7a848792df924b81bbb2c48da70f9d8765
public static int save(Postulante postulante){
int status=0;
try{
Connection con= DataBase.getConnection();
PreparedStatement ps=con.prepareStatement(
"insert into postulante(nombre,apellido,nro_cedula,correo,telefono,direccion,experiencia_laboral,estudio_universitario,notebook,bootcamp_id,aceptado) values (?,?,?,?,?,?,?,?,?,?,?)");
ps.setString(1,postulante.getNombre());
ps.setString(2,postulante.getApellido());
ps.setInt(3,postulante.getNro_cedula());
ps.setString(4,postulante.getCorreo());
ps.setString(5,postulante.getTelefono());
ps.setString(6,postulante.getDireccion());
ps.setBoolean(7,postulante.getExpLaboral());
ps.setBoolean(8,postulante.getEstudioUniversitario());
ps.setBoolean(9,postulante.getNotebook());
ps.setInt(10,postulante.getBootcampId());
ps.setBoolean(11,postulante.getAceptado());
status=ps.executeUpdate();
con.close();
}catch(Exception ex){ex.printStackTrace();}
return status;
}
<<<<<<< HEAD
=======
public static List<Postulante> listarPostulante(){
List<Postulante> postulante = new ArrayList<>();
String sql = "select a.id, a.nombre, a.apellido, a.nro_cedula, a.correo, a.telefono, a.direccion, " +
"a.experiencia_laboral, a.estudio_universitario, a.bootcamp_id, a.notebook, c.nombre_lenguaje as bootcamp, \n" +
"a.aceptado from postulante a\n" +
" inner join bootcamp b on b.id= a.bootcamp_id\n" +
" inner join lenguaje c on c.id=b.id_lenguaje\n" +
" order by a.id;";
try{
Connection con= DataBase.getConnection();
PreparedStatement ps=con.prepareStatement(sql);
ResultSet rs = ps.executeQuery();
while(rs.next()){
Postulante postulanteObject = new Postulante();
postulanteObject.setId(rs.getInt("id"));
postulanteObject.setNombre(rs.getString("nombre"));
postulanteObject.setApellido(rs.getString("apellido"));
postulanteObject.setNroCedula(rs.getInt("nro_cedula"));
postulanteObject.setCorreo(rs.getString("correo"));
postulanteObject.setTelefono(rs.getString("telefono"));
postulanteObject.setDireccion(rs.getString("direccion"));
postulanteObject.setExpLaboral(rs.getBoolean("experiencia_laboral"));
postulanteObject.setEstudioUniversitario(rs.getBoolean("estudio_universitario"));
postulanteObject.setBootcampId(rs.getInt("bootcamp_id"));
postulanteObject.setNotebook(rs.getBoolean("notebook"));
postulanteObject.setNombreBootcamp(rs.getString("bootcamp"));
postulanteObject.setAceptado(rs.getBoolean("aceptado"));
postulante.add(postulanteObject);
public class PostulanteDao {
public static int save(Postulante postulante) {
int status = 0;
try {
Connection con = DataBase.getConnection();
PreparedStatement ps = con.prepareStatement(
"insert into postulante(nombre,apellido,nro_cedula,correo,telefono,direccion,experiencia_laboral,estudio_universitario,notebook,bootcamp_id,aceptado) values (?,?,?,?,?,?,?,?,?,?,?)");
ps.setString(1, postulante.getNombre());
ps.setString(2, postulante.getApellido());
ps.setInt(3, postulante.getNro_cedula());
ps.setString(4, postulante.getCorreo());
ps.setString(5, postulante.getTelefono());
ps.setString(6, postulante.getDireccion());
ps.setBoolean(7, postulante.getExpLaboral());
ps.setBoolean(8, postulante.getEstudioUniversitario());
ps.setBoolean(9, postulante.getNotebook());
ps.setInt(10, postulante.getBootcampId());
ps.setBoolean(11, postulante.getAceptado());
status = ps.executeUpdate();
con.close();
} catch (Exception ex) {
ex.printStackTrace();
}
con.close();
} catch (SQLException e) {
throw new RuntimeException(e);
return status;
}
return postulante;
}
public static void update(int id, Boolean valor){
if(valor==true){
try{
Connection con= DataBase.getConnection();
PreparedStatement ps=con.prepareStatement("update postulante set aceptado= false\n" +
"where id=?");
ps.setInt(1,id);
ps.executeUpdate();
con.close();
}catch(Exception ex){
ex.printStackTrace();
}
}else {
try{
Connection con= DataBase.getConnection();
PreparedStatement ps=con.prepareStatement("update postulante set aceptado= true\n" +
"where id=?");
ps.setInt(1,id);
ps.executeUpdate();
con.close();
}catch(Exception ex){
ex.printStackTrace();
}
}
}
public static List<Postulante> buscarPorNombre(String nombre){
List<Postulante> postulante = null;
Postulante postulanteObject = null;
try{
Connection con= DataBase.getConnection();
PreparedStatement ps=con.prepareStatement("select a.id, a.nombre, a.apellido, a.nro_cedula, a.correo, " +
"a.telefono, a.direccion, a.experiencia_laboral, a.estudio_universitario, a.bootcamp_id, a.notebook, " +
"c.nombre_lenguaje as bootcamp, \n" + "a.aceptado from postulante a\n" +
public static List<Postulante> listarPostulante() {
List<Postulante> postulante = new ArrayList<>();
String sql = "select a.id, a.nombre, a.apellido, a.nro_cedula, a.correo, a.telefono, a.direccion, " +
"a.experiencia_laboral, a.estudio_universitario, a.bootcamp_id, a.notebook, c.nombre_lenguaje as bootcamp, \n" +
"a.aceptado from postulante a\n" +
" inner join bootcamp b on b.id= a.bootcamp_id\n" +
" inner join lenguaje c on c.id=b.id_lenguaje\n" +
" where a.nombre ilike ? ");
ps.setString(1, "%" + nombre + "%");
System.out.println(nombre);
ResultSet rs = ps.executeQuery();
postulante = new ArrayList<>();
postulanteObject= new Postulante();
while(rs.next()){
" order by a.id;";
try {
Connection con = DataBase.getConnection();
PreparedStatement ps = con.prepareStatement(sql);
ResultSet rs = ps.executeQuery();
while (rs.next()) {
Postulante postulanteObject = new Postulante();
postulanteObject.setId(rs.getInt("id"));
postulanteObject.setNombre(rs.getString("nombre"));
postulanteObject.setApellido(rs.getString("apellido"));
postulanteObject.setNroCedula(rs.getInt("nro_cedula"));
postulanteObject.setCorreo(rs.getString("correo"));
postulanteObject.setTelefono(rs.getString("telefono"));
postulanteObject.setDireccion(rs.getString("direccion"));
postulanteObject.setExpLaboral(rs.getBoolean("experiencia_laboral"));
postulanteObject.setEstudioUniversitario(rs.getBoolean("estudio_universitario"));
postulanteObject.setBootcampId(rs.getInt("bootcamp_id"));
postulanteObject.setNotebook(rs.getBoolean("notebook"));
postulanteObject.setNombreBootcamp(rs.getString("bootcamp"));
postulanteObject.setAceptado(rs.getBoolean("aceptado"));
postulante.add(postulanteObject);
}
con.close();
} catch (SQLException e) {
throw new RuntimeException(e);
}
return postulante;
}
postulanteObject.setId(rs.getInt("id"));
postulanteObject.setNombre(rs.getString("nombre"));
postulanteObject.setApellido(rs.getString("apellido"));
postulanteObject.setNroCedula(rs.getInt("nro_cedula"));
postulanteObject.setCorreo(rs.getString("correo"));
postulanteObject.setTelefono(rs.getString("telefono"));
postulanteObject.setDireccion(rs.getString("direccion"));
postulanteObject.setExpLaboral(rs.getBoolean("experiencia_laboral"));
postulanteObject.setEstudioUniversitario(rs.getBoolean("estudio_universitario"));
postulanteObject.setBootcampId(rs.getInt("bootcamp_id"));
postulanteObject.setNotebook(rs.getBoolean("notebook"));
postulanteObject.setNombreBootcamp(rs.getString("bootcamp"));
postulanteObject.setAceptado(rs.getBoolean("aceptado"));
postulante.add(postulanteObject);
public static void update(int id, Boolean valor) {
if (valor == true) {
try {
Connection con = DataBase.getConnection();
PreparedStatement ps = con.prepareStatement("update postulante set aceptado= false\n" +
"where id=?");
ps.setInt(1, id);
ps.executeUpdate();
con.close();
} catch (Exception ex) {
ex.printStackTrace();
}
} else {
try {
Connection con = DataBase.getConnection();
PreparedStatement ps = con.prepareStatement("update postulante set aceptado= true\n" +
"where id=?");
ps.setInt(1, id);
ps.executeUpdate();
con.close();
} catch (Exception ex) {
ex.printStackTrace();
}
}
con.close();
}catch(Exception ex){
ex.printStackTrace();
}
return postulante;
}
public static List<Postulante> listarPostulanteAceptados(){
List<Postulante> postulante = null;
try{
Connection con= DataBase.getConnection();
PreparedStatement ps=con.prepareStatement("select a.id, a.nombre, a.apellido, a.nro_cedula, a.correo, " +
"a.telefono, a.direccion, a.experiencia_laboral, a.estudio_universitario, a.bootcamp_id, a.notebook, " +
"c.nombre_lenguaje as bootcamp, \n" + "a.aceptado from postulante a\n" +
" inner join bootcamp b on b.id= a.bootcamp_id\n" +
" inner join lenguaje c on c.id=b.id_lenguaje\n" +
" where a.aceptado= true ");
ResultSet rs = ps.executeQuery();
postulante = new ArrayList<>();
Postulante postulanteObject= new Postulante();
while(rs.next()){
postulanteObject.setId(rs.getInt("id"));
postulanteObject.setNombre(rs.getString("nombre"));
postulanteObject.setApellido(rs.getString("apellido"));
postulanteObject.setNroCedula(rs.getInt("nro_cedula"));
postulanteObject.setCorreo(rs.getString("correo"));
postulanteObject.setTelefono(rs.getString("telefono"));
postulanteObject.setDireccion(rs.getString("direccion"));
postulanteObject.setExpLaboral(rs.getBoolean("experiencia_laboral"));
postulanteObject.setEstudioUniversitario(rs.getBoolean("estudio_universitario"));
postulanteObject.setBootcampId(rs.getInt("bootcamp_id"));
postulanteObject.setNotebook(rs.getBoolean("notebook"));
postulanteObject.setNombreBootcamp(rs.getString("bootcamp"));
postulanteObject.setAceptado(rs.getBoolean("aceptado"));
postulante.add(postulanteObject);
public static List<Postulante> buscarPorNombre(String nombre) {
List<Postulante> postulante = null;
Postulante postulanteObject = null;
try {
Connection con = DataBase.getConnection();
PreparedStatement ps = con.prepareStatement("select a.id, a.nombre, a.apellido, a.nro_cedula, a.correo, " +
"a.telefono, a.direccion, a.experiencia_laboral, a.estudio_universitario, a.bootcamp_id, a.notebook, " +
"c.nombre_lenguaje as bootcamp, \n" + "a.aceptado from postulante a\n" +
" inner join bootcamp b on b.id= a.bootcamp_id\n" +
" inner join lenguaje c on c.id=b.id_lenguaje\n" +
" where a.nombre ilike ? ");
ps.setString(1, "%" + nombre + "%");
System.out.println(nombre);
ResultSet rs = ps.executeQuery();
postulante = new ArrayList<>();
postulanteObject = new Postulante();
while (rs.next()) {
postulanteObject.setId(rs.getInt("id"));
postulanteObject.setNombre(rs.getString("nombre"));
postulanteObject.setApellido(rs.getString("apellido"));
postulanteObject.setNroCedula(rs.getInt("nro_cedula"));
postulanteObject.setCorreo(rs.getString("correo"));
postulanteObject.setTelefono(rs.getString("telefono"));
postulanteObject.setDireccion(rs.getString("direccion"));
postulanteObject.setExpLaboral(rs.getBoolean("experiencia_laboral"));
postulanteObject.setEstudioUniversitario(rs.getBoolean("estudio_universitario"));
postulanteObject.setBootcampId(rs.getInt("bootcamp_id"));
postulanteObject.setNotebook(rs.getBoolean("notebook"));
postulanteObject.setNombreBootcamp(rs.getString("bootcamp"));
postulanteObject.setAceptado(rs.getBoolean("aceptado"));
postulante.add(postulanteObject);
}
con.close();
} catch (Exception ex) {
ex.printStackTrace();
}
con.close();
}catch(Exception ex){
ex.printStackTrace();
return postulante;
}
return postulante;
}
public static List<Postulante> listarPorBootcamp(String nombre){
List<Postulante> postulante = null;
try{
Connection con= DataBase.getConnection();
PreparedStatement ps=con.prepareStatement("select a.id, a.nombre, a.apellido, a.nro_cedula, a.correo, a.telefono, a.direccion, \n" +
" a.experiencia_laboral, a.estudio_universitario, a.bootcamp_id, a.notebook, c.nombre_lenguaje as bootcamp, \n" +
" a.aceptado from postulante a\n" +
" inner join bootcamp b on b.id= a.bootcamp_id\n" +
" inner join lenguaje c on c.id=b.id_lenguaje\n" +
" where c.nombre_lenguaje ilike ? ");
ps.setString(1, "%" + nombre + "%");
ResultSet rs = ps.executeQuery();
postulante = new ArrayList<>();
Postulante postulanteObject= new Postulante();
while(rs.next()){
postulanteObject.setId(rs.getInt("id"));
postulanteObject.setNombre(rs.getString("nombre"));
postulanteObject.setApellido(rs.getString("apellido"));
postulanteObject.setNroCedula(rs.getInt("nro_cedula"));
postulanteObject.setCorreo(rs.getString("correo"));
postulanteObject.setTelefono(rs.getString("telefono"));
postulanteObject.setDireccion(rs.getString("direccion"));
postulanteObject.setExpLaboral(rs.getBoolean("experiencia_laboral"));
postulanteObject.setEstudioUniversitario(rs.getBoolean("estudio_universitario"));
postulanteObject.setBootcampId(rs.getInt("bootcamp_id"));
postulanteObject.setNotebook(rs.getBoolean("notebook"));
postulanteObject.setNombreBootcamp(rs.getString("bootcamp"));
postulanteObject.setAceptado(rs.getBoolean("aceptado"));
postulante.add(postulanteObject);
public static List<Postulante> listarPostulanteAceptados() {
List<Postulante> postulante = null;
try {
Connection con = DataBase.getConnection();
PreparedStatement ps = con.prepareStatement("select a.id, a.nombre, a.apellido, a.nro_cedula, a.correo, " +
"a.telefono, a.direccion, a.experiencia_laboral, a.estudio_universitario, a.bootcamp_id, a.notebook, " +
"c.nombre_lenguaje as bootcamp, \n" + "a.aceptado from postulante a\n" +
" inner join bootcamp b on b.id= a.bootcamp_id\n" +
" inner join lenguaje c on c.id=b.id_lenguaje\n" +
" where a.aceptado= true ");
ResultSet rs = ps.executeQuery();
postulante = new ArrayList<>();
Postulante postulanteObject = new Postulante();
while (rs.next()) {
postulanteObject.setId(rs.getInt("id"));
postulanteObject.setNombre(rs.getString("nombre"));
postulanteObject.setApellido(rs.getString("apellido"));
postulanteObject.setNroCedula(rs.getInt("nro_cedula"));
postulanteObject.setCorreo(rs.getString("correo"));
postulanteObject.setTelefono(rs.getString("telefono"));
postulanteObject.setDireccion(rs.getString("direccion"));
postulanteObject.setExpLaboral(rs.getBoolean("experiencia_laboral"));
postulanteObject.setEstudioUniversitario(rs.getBoolean("estudio_universitario"));
postulanteObject.setBootcampId(rs.getInt("bootcamp_id"));
postulanteObject.setNotebook(rs.getBoolean("notebook"));
postulanteObject.setNombreBootcamp(rs.getString("bootcamp"));
postulanteObject.setAceptado(rs.getBoolean("aceptado"));
postulante.add(postulanteObject);
}
con.close();
} catch (Exception ex) {
ex.printStackTrace();
}
con.close();
}catch(Exception ex){
ex.printStackTrace();
return postulante;
}
return postulante;
}
public static List<Postulante> buscarPorNoteBook(){
List<Postulante> postulante = null;
Postulante postulanteObject = null;
try{
Connection con= DataBase.getConnection();
PreparedStatement ps=con.prepareStatement("select a.id, a.nombre, a.apellido, a.nro_cedula, a.correo, " +
"a.telefono, a.direccion, a.experiencia_laboral, a.estudio_universitario, a.bootcamp_id, a.notebook, " +
"c.nombre_lenguaje as bootcamp, \n" + "a.aceptado from postulante a\n" +
" inner join bootcamp b on b.id= a.bootcamp_id\n" +
" inner join lenguaje c on c.id=b.id_lenguaje\n" +
" where a.notebook=true ");
ResultSet rs = ps.executeQuery();
postulante = new ArrayList<>();
postulanteObject= new Postulante();
while(rs.next()){
public static List<Postulante> listarPorBootcamp(String nombre) {
List<Postulante> postulante = null;
try {
Connection con = DataBase.getConnection();
PreparedStatement ps = con.prepareStatement("select a.id, a.nombre, a.apellido, a.nro_cedula, a.correo, a.telefono, a.direccion, \n" +
" a.experiencia_laboral, a.estudio_universitario, a.bootcamp_id, a.notebook, c.nombre_lenguaje as bootcamp, \n" +
" a.aceptado from postulante a\n" +
" inner join bootcamp b on b.id= a.bootcamp_id\n" +
" inner join lenguaje c on c.id=b.id_lenguaje\n" +
" where c.nombre_lenguaje ilike ? ");
ps.setString(1, "%" + nombre + "%");
ResultSet rs = ps.executeQuery();
postulante = new ArrayList<>();
Postulante postulanteObject = new Postulante();
while (rs.next()) {
postulanteObject.setId(rs.getInt("id"));
postulanteObject.setNombre(rs.getString("nombre"));
postulanteObject.setApellido(rs.getString("apellido"));
postulanteObject.setNroCedula(rs.getInt("nro_cedula"));
postulanteObject.setCorreo(rs.getString("correo"));
postulanteObject.setTelefono(rs.getString("telefono"));
postulanteObject.setDireccion(rs.getString("direccion"));
postulanteObject.setExpLaboral(rs.getBoolean("experiencia_laboral"));
postulanteObject.setEstudioUniversitario(rs.getBoolean("estudio_universitario"));
postulanteObject.setBootcampId(rs.getInt("bootcamp_id"));
postulanteObject.setNotebook(rs.getBoolean("notebook"));
postulanteObject.setNombreBootcamp(rs.getString("bootcamp"));
postulanteObject.setAceptado(rs.getBoolean("aceptado"));
postulante.add(postulanteObject);
}
con.close();
} catch (Exception ex) {
ex.printStackTrace();
}
return postulante;
}
postulanteObject.setId(rs.getInt("id"));
postulanteObject.setNombre(rs.getString("nombre"));
postulanteObject.setApellido(rs.getString("apellido"));
postulanteObject.setNroCedula(rs.getInt("nro_cedula"));
postulanteObject.setCorreo(rs.getString("correo"));
postulanteObject.setTelefono(rs.getString("telefono"));
postulanteObject.setDireccion(rs.getString("direccion"));
postulanteObject.setExpLaboral(rs.getBoolean("experiencia_laboral"));
postulanteObject.setEstudioUniversitario(rs.getBoolean("estudio_universitario"));
postulanteObject.setBootcampId(rs.getInt("bootcamp_id"));
postulanteObject.setNotebook(rs.getBoolean("notebook"));
postulanteObject.setNombreBootcamp(rs.getString("bootcamp"));
postulanteObject.setAceptado(rs.getBoolean("aceptado"));
postulante.add(postulanteObject);
public static List<Postulante> buscarPorNoteBook() {
List<Postulante> postulante = null;
Postulante postulanteObject = null;
try {
Connection con = DataBase.getConnection();
PreparedStatement ps = con.prepareStatement("select a.id, a.nombre, a.apellido, a.nro_cedula, a.correo, " +
"a.telefono, a.direccion, a.experiencia_laboral, a.estudio_universitario, a.bootcamp_id, a.notebook, " +
"c.nombre_lenguaje as bootcamp, \n" + "a.aceptado from postulante a\n" +
" inner join bootcamp b on b.id= a.bootcamp_id\n" +
" inner join lenguaje c on c.id=b.id_lenguaje\n" +
" where a.notebook=true ");
ResultSet rs = ps.executeQuery();
postulante = new ArrayList<>();
postulanteObject = new Postulante();
while (rs.next()) {
postulanteObject.setId(rs.getInt("id"));
postulanteObject.setNombre(rs.getString("nombre"));
postulanteObject.setApellido(rs.getString("apellido"));
postulanteObject.setNroCedula(rs.getInt("nro_cedula"));
postulanteObject.setCorreo(rs.getString("correo"));
postulanteObject.setTelefono(rs.getString("telefono"));
postulanteObject.setDireccion(rs.getString("direccion"));
postulanteObject.setExpLaboral(rs.getBoolean("experiencia_laboral"));
postulanteObject.setEstudioUniversitario(rs.getBoolean("estudio_universitario"));
postulanteObject.setBootcampId(rs.getInt("bootcamp_id"));
postulanteObject.setNotebook(rs.getBoolean("notebook"));
postulanteObject.setNombreBootcamp(rs.getString("bootcamp"));
postulanteObject.setAceptado(rs.getBoolean("aceptado"));
postulante.add(postulanteObject);
}
con.close();
} catch (Exception ex) {
ex.printStackTrace();
}
con.close();
}catch(Exception ex){
ex.printStackTrace();
return postulante;
}
return postulante;
}
>>>>>>> 9f750c7a848792df924b81bbb2c48da70f9d8765
}
......@@ -69,7 +69,7 @@ public class SaveServlet extends HttpServlet {
if (request.getParameter("universidad") != null){
universidad = true;
}
Bootcamp bootcamp = new Bootcamp();
Postulante postulante=new Postulante();
PostulanteLenguaje cargarLenguaje = new PostulanteLenguaje();
int status = 0;
......@@ -105,51 +105,30 @@ public class SaveServlet extends HttpServlet {
}
}
}
<<<<<<< HEAD
if(status >0 && statusLenguaje > 0){
//out.println("<script> window.alert('Postulacion exitosa') </script>");
out.print("<p>Record saved successfully!</p>");
request.getRequestDispatcher("formulario.jsp").include(request, response);
}else{
if (rechazarDatos){
if (contador == 0){
out.println("Debe seleccionar al menos una opcion de lenguaje que conoce para postularse");
out.println("<a href=formulario.jsp >Volver al cuestionario</a>");
}else {
out.println("<p>El correo ingresado ya esta registrado para el bootcamp actual<p>");
}
}else{
out.println("Error");
if(status>0){
//out.print("<p>Record saved successfully!</p>");
out.print(" <div class=\"alert\">\n" +
" <span class=\"closebtn\" onclick=\"this.parentElement.style.display='none';\">&times;</span> \n" +
" <strong>Formulario Cargado!</strong> EXITOSAMENTE CARGADO\n" +
"</div>");
request.getRequestDispatcher("formulario.jsp").include(request, response);
}else{
if (rechazarDatos){
=======
int status=PostulanteDao.save(postulante);
if(status>0){
//out.print("<p>Record saved successfully!</p>");
out.print(" <div class=\"alert\">\n" +
out.print(" <div class=\"alert info\">\n" +
" <span class=\"closebtn\" onclick=\"this.parentElement.style.display='none';\">&times;</span> \n" +
" <strong>Formulario Cargado!</strong> EXITOSAMENTE CARGADO\n" +
" <strong>Formulario ya Cargado!</strong> YA EXISTE EL FORMULARIO\n" +
"</div>");
request.getRequestDispatcher("formulario.jsp").include(request, response);
}else {
out.println("Error al cargar datos");
out.print(" <div class=\"alert info error\">\n" +
" <span class=\"closebtn\" onclick=\"this.parentElement.style.display='none';\">&times;</span> \n" +
" <strong>Formulario ya Cargado!</strong> YA EXISTE EL FORMULARIO\n" +
"</div>");
request.getRequestDispatcher("formulario.jsp").include(request, response);
}else{
if (rechazarDatos){
//out.println("El correo ingresado ya esta registrado para el bootcamp actual");
out.print(" <div class=\"alert info\">\n" +
" <span class=\"closebtn\" onclick=\"this.parentElement.style.display='none';\">&times;</span> \n" +
" <strong>Formulario ya Cargado!</strong> YA EXISTE EL FORMULARIO\n" +
"</div>");
request.getRequestDispatcher("formulario.jsp").include(request, response);
}else {
out.println("Error al cargar datos");
out.print(" <div class=\"alert info error\">\n" +
" <span class=\"closebtn\" onclick=\"this.parentElement.style.display='none';\">&times;</span> \n" +
" <strong>Formulario ya Cargado!</strong> YA EXISTE EL FORMULARIO\n" +
"</div>");
request.getRequestDispatcher("formulario.jsp").include(request, response);
>>>>>>> 9f750c7a848792df924b81bbb2c48da70f9d8765
}
}
}
}catch (Exception ex){
ex.printStackTrace();
}
......
......@@ -48,10 +48,6 @@ public class Postulante {
return id;
}
public void setId(int id) {
this.id = id;
}
public int getNro_cedula() {
return nroCedula;
}
......@@ -123,35 +119,13 @@ public class Postulante {
this.id = id;
}
public int getNroCedula() {
return nroCedula;
}
public void setNroCedula(int nroCedula) {
this.nroCedula = nroCedula;
}
public String getNombreBootcamp() {
return nombreBootcamp;
}
public void setNombreBootcamp(String nombreBootcamp) {
this.nombreBootcamp = nombreBootcamp;
}
public boolean isExpLaboral() {
return expLaboral;
}
public boolean isEstudioUniversitario() {
return estudioUniversitario;
}
public boolean isNotebook() {
return notebook;
}
public boolean isAceptado() {
return aceptado;
}
}
......@@ -2,20 +2,8 @@
pageEncoding="UTF-8"%>
<%@ page import="java.sql.*,java.sql.Connection,java.sql.ResultSet,com.roshka.proyectofinal.DataBase,jakarta.servlet.http.HttpServlet,jakarta.servlet.http.HttpServletRequest"%>
<<<<<<< HEAD
<!DOCTYPE html>
<html>
=======
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link href="form.css" rel="stylesheet" type="text/css" />
<link rel="shortcut icon" href="imagenes/roshkaicon.ico" sizes="any" />
<!-- CSS only -->
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.2.0-beta1/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-0evHe/X+R7YkIZDRvuzKMRqM+OrBnVFBL6DOitfPri4tjfHxaWutUpFmBp4vmVor" crossorigin="anonymous">
<link rel="stylesheet" media="(max-width: 800px)" href="example.css" />
<title>Formulario Postulante</title>
</head>
>>>>>>> 9f750c7a848792df924b81bbb2c48da70f9d8765
<head>
<link href="estilos/form.css" rel="stylesheet" type="text/css" />
......@@ -29,32 +17,7 @@ pageEncoding="UTF-8"%>
<link rel="stylesheet" media="(max-width: 800px)" href="example.css" />
<title>Formulario Postulante</title>
<<<<<<< HEAD
</head>
=======
<form method="post" action="SaveServlet" class="form">
<label class="mr-2" for="nombre">Ingrese su Nombre:</label>
<input required id="nombre" name="nombre" type="text"><br>
<label for="apellido">Ingrese su Apellido:</label>
<input required id="apellido" name="apellido" type="text"><br>
<label for="cedula">Numero de cedula:</label>
<input required id="cedula" name="cedula" type="number"><br>
<label for="correo">Correo:</label>
<input required id="correo" name="correo" type="email"><br>
<label for="telefono">Telefono:</label>
<input required id="telefono" name="telefono" type="text"><br>
<label for="direccion">Direccion:</label>
<input required id="direccion" name="direccion" type="text"><br>
<%@ page import="com.roshka.proyectofinal.entity.Lenguaje, com.roshka.proyectofinal.lenguaje.LenguajeDao, java.util.List,java.util.Iterator" %>
>>>>>>> 9f750c7a848792df924b81bbb2c48da70f9d8765
<body>
<header>
......@@ -72,14 +35,6 @@ pageEncoding="UTF-8"%>
ResultSet rs = stmt.executeQuery("SELECT * FROM bootcamp WHERE id= "+id+ " LIMIT 1" );
rs.next();
%>
<<<<<<< HEAD
=======
<li class="d-flex check-inline" >
<label for=<%=len.getNombre_lenguaje() %> > <%= len.getNombre_lenguaje() %> </label><input value=<%=len.getId() %> id=
<%=len.getNombre_lenguaje() %> name=
<%=len.getNombre_lenguaje() %> type="checkbox"><br>
</li>
>>>>>>> 9f750c7a848792df924b81bbb2c48da70f9d8765
<h2>Descripcion:</h2>
<p>
......@@ -87,39 +42,11 @@ pageEncoding="UTF-8"%>
</p>
<p class="enter">Si sigues interesado y cumples con los requisitos, completa el siguiente formulario: </p>
<<<<<<< HEAD
<form method="post" action="SaveServlet" class="form">
=======
</ul>
<li class="d-flex">
<label for="experiencia_laboral" >Experiencia laboral</label>
</li>
<!-- Si no lo marca el valor que envia es null y si lo marca es "ON" -->
<input id="experiencia_laboral" name="experiencia_laboral" type="checkbox" ><br>
<p for="experiencia_programando">Lenguajes de programacion que conoces:</p>
<label for="notebook">Cuenta con notebook</label>
<input id="notebook" name="notebook" type="checkbox"><br>
<label for="universidad">Estudio Universitario </label>
<input id="universidad" name="universidad" type="checkbox"><br>
<input class="enviar info error" type="submit">
<input class="borrar" type="reset" value="Borrar"><br>
<label for="otro">otro</label>
<input id="otro" name="otro" type="checkbox"><br>
<a href="index.html">volver</a>
</form>
</article>
>>>>>>> 9f750c7a848792df924b81bbb2c48da70f9d8765
<input type="hidden" name="bootcamp_id" value="<%= request.getParameter("bootcamp") %>">
<<<<<<< HEAD
<label for="nombre">Ingrese su Nombre:</label>
<input required id="nombre" name="nombre" type="text"><br>
......@@ -219,7 +146,4 @@ pageEncoding="UTF-8"%>
}
init();
})();
</script>
=======
>>>>>>> 9f750c7a848792df924b81bbb2c48da70f9d8765
</script>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment