/*
    MANAMA SOFTWARE SOLUTIONS (MSS)
*/
; (function () {
	if (!window.console) window.console = {};
	if (!window.console.log) window.console.log = function () { };
   
    var paths = { 
        jquery: 'libs/jquery/jquery', 
        underscore: 'libs/underscore/underscore',
        backbone: 'libs/backbone/backbone',
		json2: 'libs/json/json2',
        text: 'libs/require/text',
        jqueryform: 'libs/jqueryform/jqueryform',
        jqueryui: 'libs/jqueryui/jquery-ui',
        slimscroll: 'libs/slimscroll/slimScroll',
        i18next: 'libs/i18next/i18next',
        common: 'libs/commons/common',
        utility : 'runtime/util/utility',
		service: 'runtime/services/service',		
		loggerutil : 'runtime/util/logger',
		logmanagerutil: 'runtime/util/logmanager',
        readmodel:'runtime/models/read'
        
    };

    window.configData = window.configData || {};
    window.configData.serverPath = location.protocol + "//" + window.location.host;

    require.config({
        paths: paths,
		shim: {
                'underscore': {
                    exports: '_'
                },
                'backbone': {
                    deps: ['underscore', 'jquery'],
                    exports: 'Backbone'
                },
                'i18next': {
					deps: ['jquery', 'json2'],
					exports: 'i18n'
				}
		    }
    });

    require(['router'],
        function(Router) {
            Router.initialize();
        });
})();

