Browse Source

rename routes/control

windhamdavid 3 years ago
parent
commit
c610a61304

+ 8 - 8
app.js

@@ -103,12 +103,12 @@ app.use(function(req, res, next) {
 var router = express.Router();
 app.use(router);
 
-var homeController = require('./controllers/home');
-var userController = require('./controllers/user');
-var contactController = require('./controllers/contact');
-var eventsController = require('./controllers/events');
-var entriesController = require('./controllers/entries');
-var apiController = require('./controllers/api');
+var homeController = require('./controllers/home_control');
+var userController = require('./controllers/user_control');
+var contactController = require('./controllers/contact_control');
+var eventController = require('./controllers/event_control');
+var entryController = require('./controllers/entry_control');
+var apiController = require('./controllers/api_control');
 
 
 /********** user routes **************/
@@ -132,13 +132,13 @@ router.get('/account/unlink/:provider', passportConf.isAuthenticated, userContro
 
 /********** event routes **************/
 
-var eventRouter = require('./routes/events');
+var eventRouter = require('./routes/event_route');
 app.use('/event', eventRouter);
 
 
 /********** entry routes **************/
 
-var entryRouter = require('./routes/entry');
+var entryRouter = require('./routes/entry_route');
 app.use('/entry', entryRouter);
 
 

controllers/api.js → controllers/api_control.js


controllers/contact.js → controllers/contact_control.js


controllers/entries.js → controllers/entry_control.js


controllers/events.js → controllers/event_control.js


controllers/home.js → controllers/home_control.js


controllers/user.js → controllers/user_control.js


+ 0 - 8
routes/entry.js

@@ -1,8 +0,0 @@
-var express = require('express');
-var app = express();
-var router = express.Router();
-var eventsController = require('../controllers/events');
-
-router.get('/entry', eventsController.getEvent);
-
-module.exports = router;

+ 8 - 0
routes/entry_route.js

@@ -0,0 +1,8 @@
+var express = require('express');
+var app = express();
+var router = express.Router();
+var eventsController = require('../controllers/entry_control');
+
+router.get('/entry', entryController.getEvent);
+
+module.exports = router;

+ 8 - 0
routes/event_route.js

@@ -0,0 +1,8 @@
+var express = require('express');
+var app = express();
+var router = express.Router();
+var eventController = require('../controllers/event_control');
+
+router.get('/event', eventController.getEvent);
+
+module.exports = router;

+ 0 - 8
routes/events.js

@@ -1,8 +0,0 @@
-var express = require('express');
-var app = express();
-var router = express.Router();
-var eventsController = require('../controllers/events');
-
-router.get('../event', eventsController.getEvent);
-
-module.exports = router;

routes/static.js → routes/static_route.js


routes/user.js → routes/user_route.js