From 48f1c51f80d520a3927543bfe9547f1544609213 Mon Sep 17 00:00:00 2001 From: "Oscar J. Rodriguez B" Date: Tue, 10 Sep 2019 10:27:34 -0400 Subject: [PATCH] Deletion of web.ejs and its routes --- src/routes/index.js | 19 +------------------ src/views/web.ejs | 34 ---------------------------------- 2 files changed, 1 insertion(+), 52 deletions(-) delete mode 100644 src/views/web.ejs diff --git a/src/routes/index.js b/src/routes/index.js index bae8559..ccb9d94 100644 --- a/src/routes/index.js +++ b/src/routes/index.js @@ -3,7 +3,7 @@ const { } = require('express'); const router = new Router(); -let alumnos = []; +//let alumnos = []; router.get("/", (req, res) => { res.render("index", { @@ -15,23 +15,6 @@ router.get("/flex", (req, res) => { res.render("flex") }); -router.get('/web', (req, res) => { - res.render('web') -}); - -router.post('/web', (req, res) => { - let { - nombre, - documento - } = req.body; - let nuevoRegistro = { - nombre, - documento, - fecha: new Date() - }; - alumnos.push(nuevoRegistro); - res.redirect("/"); -}); router.get('/free', (req, res) => { var sys = require('sys') diff --git a/src/views/web.ejs b/src/views/web.ejs deleted file mode 100644 index c1ec349..0000000 --- a/src/views/web.ejs +++ /dev/null @@ -1,34 +0,0 @@ - - - - - Register new - <%include ../../partials/head%> - - - -
- <%include ../../partials/header%> -
-
-
-

Nuevo registro

-
-
- - -
-
- - -
-
- -
-
-
-
- -<%include ../../partials/footer%> - - \ No newline at end of file -- 2.25.1