ADD: create and get a transaction endpoints
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
const express = require('express')
|
||||
const transactionController = require('./transactionController')
|
||||
// const perm = require('../../middlewares/permissionMiddleware')
|
||||
const loginCheck = require('../../middlewares/loginCheck')
|
||||
|
||||
const router = new express.Router()
|
||||
|
||||
router.use(loginCheck.loginProtect)
|
||||
|
||||
router.get(
|
||||
'/admin/self',
|
||||
// perm.requires('getallbelongings'),
|
||||
transactionController.getUserTransaction
|
||||
)
|
||||
|
||||
router.post(
|
||||
'/admin/create',
|
||||
// perm.requires('getallbelongings'),
|
||||
transactionController.createTransaction
|
||||
)
|
||||
|
||||
module.exports = router
|
||||
Reference in New Issue
Block a user