change student post to get
This commit is contained in:
+2
-8
@@ -1,16 +1,10 @@
|
||||
const express = require('express');
|
||||
const router = express.Router();
|
||||
const pool = require('../db');
|
||||
const studentValidator = require('../validators/studentValidator');
|
||||
const handleValidation = require('../middleware/handleValidation');
|
||||
const verifyToken = require('../middleware/verifyToken');
|
||||
|
||||
router.post('/',
|
||||
verifyToken,
|
||||
handleValidation,
|
||||
studentValidator,
|
||||
router.get('/:numAccount',
|
||||
async (req, res) => {
|
||||
const { numAccount } = req.body;
|
||||
const { numAccount } = req.params;
|
||||
|
||||
try {
|
||||
const [results] = await pool.query(
|
||||
|
||||
Reference in New Issue
Block a user