aboutsummaryrefslogtreecommitdiff
path: root/server/routes
diff options
context:
space:
mode:
authorMateja <mail@matejamaric.com>2021-07-27 18:32:14 +0200
committerMateja <mail@matejamaric.com>2021-07-27 18:32:14 +0200
commit306c59e56c5038d13f94b9477bcdd060ab282ee6 (patch)
tree29e4fb6aae725256033e271fbdbdc655a41938e7 /server/routes
parent4999a967fd11db8e5142b0a14c0c3f37283290df (diff)
downloadmevn-ecommerce-306c59e56c5038d13f94b9477bcdd060ab282ee6.tar.gz
mevn-ecommerce-306c59e56c5038d13f94b9477bcdd060ab282ee6.zip
Add API endpoint for paid orders.
Diffstat (limited to 'server/routes')
-rw-r--r--server/routes/api.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/server/routes/api.js b/server/routes/api.js
index feea5dd..cf1d2d6 100644
--- a/server/routes/api.js
+++ b/server/routes/api.js
@@ -17,7 +17,8 @@ router.post('/products', isAuth, isAdmin, upload.single('image'), productsContro
router.patch('/products/:id', isAuth, isAdmin, upload.single('image'), productsController.update);
router.delete('/products/:id', isAuth, isAdmin, productsController.destroy);
-router.post('/transaction/setup', transactionController.setup);
-router.post('/transaction/capture', transactionController.capture);
+router.get('/transactions/paid', transactionController.showPaid);
+router.post('/transactions/setup', transactionController.setup);
+router.post('/transactions/capture', transactionController.capture);
module.exports = router;