diff --git a/src/main/java/com/roshka/proyectofinal/Postulante/EditServletPostulante.java b/src/main/java/com/roshka/proyectofinal/Postulante/EditServletPostulante.java deleted file mode 100644 index 2eb5167..0000000 --- a/src/main/java/com/roshka/proyectofinal/Postulante/EditServletPostulante.java +++ /dev/null @@ -1,49 +0,0 @@ -package com.roshka.proyectofinal.Postulante; - -import com.roshka.proyectofinal.DataBase; -import com.roshka.proyectofinal.entity.Postulante; -import com.roshka.proyectofinal.entity.Bootcamp; -import com.roshka.proyectofinal.entity.PostulanteLenguaje; -import jakarta.servlet.ServletException; -import jakarta.servlet.annotation.WebServlet; -import jakarta.servlet.http.HttpServlet; -import jakarta.servlet.http.HttpServletRequest; -import jakarta.servlet.http.HttpServletResponse; -import javafx.geometry.Pos; - -import java.io.IOException; -import java.io.PrintWriter; -import java.sql.*; -import java.util.List; - -@WebServlet("/EditServletPostulante") - public class EditServletPostulante extends HttpServlet { - protected void doPost(HttpServletRequest request, HttpServletResponse response) - throws ServletException, IOException { - response.setContentType("text/html"); - PrintWriter out = response.getWriter(); - - String sid = request.getParameter("id"); - boolean accion; - if (request.getParameter("value") == "Rechazar") { - accion = false; - } else { - accion = true; - } - int id = Integer.parseInt(sid); - Postulante e = new Postulante(); - e.setId(id); - e.setAceptado(accion); - - - int status = PostulanteDao.update(e); - if (status > 0) { - response.sendRedirect("ViewServlet"); - } else { - out.println("Sorry! unable to update record"); - } - - out.close(); - } - } - diff --git a/src/main/java/com/roshka/proyectofinal/Postulante/SaveServlet.java b/src/main/java/com/roshka/proyectofinal/Postulante/SaveServlet.java index 5201c6a..60d7fec 100644 --- a/src/main/java/com/roshka/proyectofinal/Postulante/SaveServlet.java +++ b/src/main/java/com/roshka/proyectofinal/Postulante/SaveServlet.java @@ -24,7 +24,7 @@ public class SaveServlet extends HttpServlet { response.setContentType("text/html"); PrintWriter out=response.getWriter(); boolean rechazarDatos = false; - int bootcampActual = 2; + int bootcampActual = Integer.parseInt(request.getParameter("bootcamp_id")); try { Connection con = DataBase.getConnection(); @@ -116,11 +116,11 @@ public class SaveServlet extends HttpServlet { out.println("Volver al cuestionario"); }else { out.println("
El correo ingresado ya esta registrado para el bootcamp actual
"); - request.getRequestDispatcher("").include(request, response); + //request.getRequestDispatcher("").include(request, response); } }else{ out.println("Error"); - out.println(""); + //out.println(""); } } diff --git a/src/main/java/com/roshka/proyectofinal/Postulante/ViewServletPostulantes.java b/src/main/java/com/roshka/proyectofinal/Postulante/ViewServletPostulantes.java deleted file mode 100644 index 84bc05c..0000000 --- a/src/main/java/com/roshka/proyectofinal/Postulante/ViewServletPostulantes.java +++ /dev/null @@ -1,60 +0,0 @@ -package com.roshka.proyectofinal.Postulante; -import java.io.IOException; -import java.io.PrintWriter; -import java.util.List; - -import com.roshka.proyectofinal.DataBase; -import com.roshka.proyectofinal.entity.Postulante; -import com.roshka.proyectofinal.entity.Bootcamp; -import com.roshka.proyectofinal.entity.PostulanteLenguaje; -import jakarta.servlet.ServletException; -import jakarta.servlet.annotation.WebServlet; -import jakarta.servlet.http.HttpServlet; -import jakarta.servlet.http.HttpServletRequest; -import jakarta.servlet.http.HttpServletResponse; -import javafx.geometry.Pos; -import com.roshka.proyectofinal.DataBase; -import com.roshka.proyectofinal.entity.Postulante; -import com.roshka.proyectofinal.entity.Bootcamp; -import com.roshka.proyectofinal.entity.PostulanteLenguaje; -import jakarta.servlet.ServletException; -import jakarta.servlet.annotation.WebServlet; -import jakarta.servlet.http.HttpServlet; -import jakarta.servlet.http.HttpServletRequest; -import jakarta.servlet.http.HttpServletResponse; -import java.io.IOException; -import java.io.PrintWriter; -import java.sql.Connection; -import java.sql.PreparedStatement; -import java.sql.ResultSet; -import java.sql.Statement; - -import java.io.IOException; -import java.io.PrintWriter; -import java.sql.*; -import java.util.List; -@WebServlet("/ViewServletPostulante") -public class ViewServletPostulantes extends HttpServlet{ - protected void doGet(HttpServletRequest request, HttpServletResponse response) - throws ServletException, IOException { - response.setContentType("text/html"); - PrintWriter out=response.getWriter(); - out.println("
Id | Nombre | Apellido | Direccion | Edit | Delete | "); - for(Postulante e:list){ - out.print("|
---|---|---|---|---|---|---|
"+e.getId()+" | "+e.getNombre()+" | "+e.getApellido()+" | "+e.getCorreo()+" | "+e.getDireccion()+" | edit | delete |
BOOTCAMP JAVA
-Inicio: 18/04/2023
-Fin: 18/05/2023
- -+ <%= rs.getString("titulo") %> +
+Inicio: + <%=rs.getString("fecha_inicio")%> +
+Fin: + <%=rs.getString("fecha_fin")%> +
+ +BOOTCAMP ANDROID
-Inicio: 18/06/2023
-Fin: 18/07/2023
- -BOOTCAMP iOS
-Inicio: 18/08/2023
-Fin: 18/09/2023
- -