init: function(app) {

        /********* homepage Routes & Redirects ***********/
        var homepageRoutes = require(config.ROOT + '/app/routes/homepage');
        homepageRoutes.urlParams.init(app);
        homepageRoutes.routes.init(app);
        homepageRoutes.redirects.init(app);

        /********* services Routes & Redirects ***********/
        var servicesRoutes = require(config.ROOT + '/app/routes/services');
        servicesRoutes.urlParams.init(app);
        servicesRoutes.routes.init(app);
        servicesRoutes.redirects.init(app);

        /********* manager details Routes & Redirects ***********/
        var managerDetailsRoutes = require(config.ROOT + '/app/routes/manager-details');
        managerDetailsRoutes.urlParams.init(app);
        managerDetailsRoutes.routes.init(app);
        managerDetailsRoutes.redirects.init(app);

        /********* manager leagues Routes & Redirects ***********/
        var managerLeaguesRoutes = require(config.ROOT + '/app/routes/manager-leagues');
        managerLeaguesRoutes.urlParams.init(app);
        managerLeaguesRoutes.routes.init(app);
        managerLeaguesRoutes.redirects.init(app);


        /********* league details Routes & Redirects ***********/
        var leagueOverviewRoutes = require(config.ROOT + '/app/routes/league-overview');
        leagueOverviewRoutes.urlParams.init(app);
        leagueOverviewRoutes.routes.init(app);
        leagueOverviewRoutes.redirects.init(app);

        /********* fixtures details Routes & Redirects ***********/
        var fixturesGameweekRoutes = require(config.ROOT + '/app/routes/fixtures');
        fixturesGameweekRoutes.urlParams.init(app);
        fixturesGameweekRoutes.routes.init(app);
        fixturesGameweekRoutes.redirects.init(app);

    }
Example #2
0
// config
var config = require(__dirname + '/config/config');

// Require our libraries
var expressUtilities = require(config.ROOT + '/app/utilities/express');

/********* Express Configuration *******/
var app = expressUtilities.appConfiguration.init();


/********* popular Routes & Redirects ***********/
var popularRoutes = require(config.ROOT + '/app/routes/popular');
popularRoutes.urlParams.init(app);
popularRoutes.routes.init(app);
popularRoutes.redirects.init(app);

/********* search term Routes & Redirects ***********/
var searchTermPageRoutes = require(config.ROOT + '/app/routes/search-term');
searchTermPageRoutes.urlParams.init(app);
searchTermPageRoutes.routes.init(app);
searchTermPageRoutes.redirects.init(app);




app.listen(config.PORT);
config.logger.info('Service started on port ' + config.PORT);