import express from 'express'; import FalukantController from '../controllers/falukantController.js'; const router = express.Router(); const falukantController = new FalukantController(); router.get('/user', falukantController.getUser); router.post('/user', falukantController.createUser); router.get('/name/randomfirstname/:gender', falukantController.randomFirstName); router.get('/name/randomlastname', falukantController.randomLastName); router.get('/info', falukantController.getInfo); router.get('/branches/:branch', falukantController.getBranch); router.get('/branches', falukantController.getBranches); router.get('/productions', falukantController.getAllProductions); router.post('/production', falukantController.createProduction); router.get('/production/:branchId', falukantController.getProduction); router.get('/stocktypes', falukantController.getStockTypes); router.get('/stockoverview', falukantController.getStockOverview); router.get('/stock/?:branchId', falukantController.getStock); router.post('/stock', falukantController.createStock); router.get('/products', falukantController.getProducts); router.get('/inventory/?:branchId', falukantController.getInventory); router.post('/sell/all', falukantController.sellAllProducts); router.post('/sell', falukantController.sellProduct); router.post('/moneyhistory', falukantController.moneyHistory); router.get('/storage/:branchId', falukantController.getStorage); router.post('/storage', falukantController.buyStorage); router.delete('/storage', falukantController.sellStorage); router.post('/director/proposal', falukantController.getDirectorProposals); router.post('/director/convertproposal', falukantController.convertProposalToDirector); router.post('/director/settings', falukantController.setSetting); router.get('/director/:branchId', falukantController.getDirectorForBranch); router.post('/family/acceptmarriageproposal', falukantController.acceptMarriageProposal); router.get('/family/gifts', falukantController.getGifts); router.post('/family/gift', falukantController.sendGift); router.get('/family', falukantController.getFamily); router.get('/nobility/titels', falukantController.getTitelsOfNobility); router.get('/houses/types', falukantController.getHouseTypes); export default router;