Personal blog written from scratch using Node.js, Bootstrap, and MySQL. https://jrtechs.net
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

17 lines
468 B

  1. const routes = require('express').Router();
  2. const builder = require('../../utils/pageBuilder');
  3. routes.get('/', (request, result) =>
  4. {
  5. builder.constructAdminPage(request, result, require("../../admin/adminDownloads").main)
  6. });
  7. routes.post('/', (request, result) =>
  8. {
  9. builder.adminPostRoute(request ,require("../../admin/adminDownloads").processPostData).then(function()
  10. {
  11. result.redirect('/admin/downloads');
  12. })
  13. });
  14. module.exports = routes;