const express = require('express');
const router = express.Router();

const authRoutes = require('./auth.routes');
const sheepsRoutes = require('./sheeps.routes');
const constructorRoutes = require('./constructor.routes');
const housesRoutes = require('./houses.routes');
const homesteadsRoutes = require('./homesteads.routes');
const homesteadJointRoutes = require('./homestead.joint.routes');
const buildingsRoutes = require('./buildings.routes');
const entrancesRoutes = require('./entrances.routes');
const apartmentsRoutes = require('./apartments.routes');
const historyEntranceRoutes = require('./history.entrance.routes');
const historyHomesteadRoutes = require('./history.homestead.routes');
const historyApartmentRoutes = require('./history.apartment.routes');
const standRoutes = require('./stand.routes');
const pushRoutes = require('./push.routes');

const generatorCardsRoutes = require('./generator.cards.routes');
const generatorReportTerritoriesRoutes = require('./generator.report.territories.routes');

router.use('/auth', authRoutes);
router.use('/sheeps?', sheepsRoutes);
router.use('/constructor', constructorRoutes);
router.use('/houses?', housesRoutes);
router.use('/homestead/joint/:homestead_id', homesteadJointRoutes);
router.use('/homesteads?', homesteadsRoutes);
router.use('/buildings?', buildingsRoutes);
router.use('/house/:house_id/entrances', entrancesRoutes);
router.use('/apartments?/:entrance_id', apartmentsRoutes);
router.use('/history/entrance/:entrance_id', historyEntranceRoutes);
router.use('/history/homestead/:homestead_id', historyHomesteadRoutes);
router.use('/history/apartments?', historyApartmentRoutes);
router.use('/stand', standRoutes);
router.use('/push', pushRoutes);

router.use('/generator/cards', generatorCardsRoutes);
router.use('/generator/report/territories', generatorReportTerritoriesRoutes);

module.exports = router;