You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

25 lines
1.2 KiB

const router = require('express').Router();
const homeController = require('../controller/home.js');
const dash = require('../controller/dashboard.js');
const api = require('../controller/api.js');
module.exports = (io, bot)=>
{
router.route('/').get(homeController.home(io));
router.route('/api/getUser').post(api.getUser(io));
router.route('/api/getGuildData/').post(api.guildData(io, bot));
router.route('/api/Change/').post(api.updateGuild(io));
router.route('/api/getRules').get(api.getRules);
router.route('/api/getFeeds').get(api.getFeeds);
router.route('/api/getFeed').get(api.getFeed);
router.route('/api/deleteFeed').post(api.deleteFeed);
router.route('/api/addFeed').post(api.addFeed(bot));
router.route('/api/updateFeed').post(api.addFeed(bot));
router.route('/api/getMessage').get(api.getMessage(bot));
router.route('/api/getChannelName').get(api.getChannelName);
router.route('/api/updateRule').post(api.updateRule(bot));
router.route('/api/deleteRule').post(api.deleteRule);
router.route('/dashboard').get(dash.get(io))
.post(dash.post(io));
router.route('/getMessage').get(api.getMessage(bot))
return router;
};