main.js revision 0c69f7dcc39578744f9b3bdf86148d1ad7fb2117
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne/**
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne *
e217869edbae075c18fd85c2d468a7ce9050b3b3Jake Feasel * Copyright (c) 2014-2015 ForgeRock AS. All rights reserved.
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne *
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne * The contents of this file are subject to the terms
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne * of the Common Development and Distribution License
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne * (the License). You may not use this file except in
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne * compliance with the License.
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne *
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne * You can obtain a copy of the License at
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne * http://forgerock.org/license/CDDLv1.0.html
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne * See the License for the specific language governing
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne * permission and limitations under the License.
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne *
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne * When distributing Covered Code, include this CDDL
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne * Header Notice in each file and include the License file
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne * at http://forgerock.org/license/CDDLv1.0.html
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne * If applicable, add the following below the CDDL Header,
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne * with the fields enclosed by brackets [] replaced by
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne * your own identifying information:
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne * "Portions Copyrighted [year] [name of copyright owner]"
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne */
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel/*global require, define, window */
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Brownerequire.config({
3c3d2165b8fd5cb73ae09a5c515512718ad145ddJake Feasel map: {
3c3d2165b8fd5cb73ae09a5c515512718ad145ddJake Feasel "*" : {
3c3d2165b8fd5cb73ae09a5c515512718ad145ddJake Feasel "UserDelegate": "org/forgerock/openidm/ui/common/util/UserDelegate",
3c3d2165b8fd5cb73ae09a5c515512718ad145ddJake Feasel "ThemeManager": "org/forgerock/openidm/ui/common/util/ThemeManager",
3c3d2165b8fd5cb73ae09a5c515512718ad145ddJake Feasel "AuthnDelegate": "org/forgerock/openidm/ui/common/delegates/AuthnDelegate",
3c3d2165b8fd5cb73ae09a5c515512718ad145ddJake Feasel "LoginView": "org/forgerock/openidm/ui/admin/login/LoginView",
3c3d2165b8fd5cb73ae09a5c515512718ad145ddJake Feasel "LoginDialog": "org/forgerock/commons/ui/common/LoginDialog"
3c3d2165b8fd5cb73ae09a5c515512718ad145ddJake Feasel }
3c3d2165b8fd5cb73ae09a5c515512718ad145ddJake Feasel },
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne paths: {
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne i18next: "libs/i18next-1.7.3-min",
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne i18nGrid: "libs/i18n/grid.locale-en",
40cf8018f65835fdf706efcbf62e9a3a06cb3179Jake Feasel backbone: "libs/backbone-1.1.2-min",
ea4b5953a78d3812cef59dcb7a3067575c1e9b82Jake Feasel "backbone.paginator": "libs/backbone.paginator.min-2.0.2-min",
ea4b5953a78d3812cef59dcb7a3067575c1e9b82Jake Feasel "backbone-relational": "libs/backbone-relational-0.9.0-min",
ea4b5953a78d3812cef59dcb7a3067575c1e9b82Jake Feasel "backgrid": "libs/backgrid.min-0.3.5-min",
ea4b5953a78d3812cef59dcb7a3067575c1e9b82Jake Feasel "backgrid-filter": "libs/backgrid-filter.min-0.3.5-min",
ea4b5953a78d3812cef59dcb7a3067575c1e9b82Jake Feasel "backgrid-paginator": "libs/backgrid-paginator.min-0.3.5-min",
26a6ec53bb06b3fb881e2a0cf5855c300513cad6Jake Feasel underscore: "libs/lodash-2.4.1-min",
26a6ec53bb06b3fb881e2a0cf5855c300513cad6Jake Feasel js2form: "libs/js2form-2.0",
26a6ec53bb06b3fb881e2a0cf5855c300513cad6Jake Feasel form2js: "libs/form2js-2.0",
26a6ec53bb06b3fb881e2a0cf5855c300513cad6Jake Feasel spin: "libs/spin-2.0.1-min",
e217869edbae075c18fd85c2d468a7ce9050b3b3Jake Feasel jquery: "libs/jquery-2.1.1-min",
26a6ec53bb06b3fb881e2a0cf5855c300513cad6Jake Feasel jqueryui: "libs/jquery-ui-1.11.1-min",
0c69f7dcc39578744f9b3bdf86148d1ad7fb2117Elizabeth jquerySortable: "libs/jquery-nestingSortable-0.9.12",
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne jqgrid: "libs/jquery.jqGrid-4.5.4-min",
d5b7485f164e9584d8b84bd882cb8df10c61bfa9Elizabeth Browne gentleSelect: "libs/jquery-gentleSelect-0.1.3.1-min",
da94b90a76ad985d8b442a0571f96a2cf8e1d551Elizabeth Browne cron: "libs/jquery-cron-r2427",
26a6ec53bb06b3fb881e2a0cf5855c300513cad6Jake Feasel xdate: "libs/xdate-0.8-min",
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne doTimeout: "libs/jquery.ba-dotimeout-1.0-min",
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel handlebars: "libs/handlebars-3.0.3-min",
5ba21fe7054811ca234da9534ff33b26242a3c70Elizabeth Browne "bootstrap-tabdrop": "libs/bootstrap-tabdrop-1.0",
15595eee56a2a6752f46b1e6d814e677a093fc96Jake Feasel bootstrap: "libs/bootstrap-3.3.5-custom",
c362d9c19bc8e34b97e12fafb19ec4abbb794bc8Jason Browne "bootstrap-dialog": "libs/bootstrap-dialog-1.34.4-min",
c362d9c19bc8e34b97e12fafb19ec4abbb794bc8Jason Browne placeholder: "libs/jquery.placeholder-2.0.8",
15b38efb2ff497ce4f3efd3bd89d2c0e8e8eca1eJason Browne selectize : "libs/selectize-0.12.1-min",
36f4d2ecf602e95c78eb83d3faa179121240e881huck.elliott d3 : "libs/d3-3.5.5-min",
26a6ec53bb06b3fb881e2a0cf5855c300513cad6Jake Feasel moment: "libs/moment-2.8.1-min",
cbbe3a4aab44b4352cec9dac8831028f16c392d2Elizabeth Browne jsonEditor: "libs/jsoneditor-0.7.9-min",
8a00e3f41bc3c54322fa09b130c4b5fe0289cdb8Jason Browne "ldapjs-filter": "libs/ldapjs-filter-2253-min",
8a00e3f41bc3c54322fa09b130c4b5fe0289cdb8Jason Browne faiconpicker: "libs/fontawesome-iconpicker-1.0.0-min"
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne },
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne shim: {
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne underscore: {
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne exports: "_"
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne },
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne backbone: {
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne deps: ["underscore"],
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne exports: "Backbone"
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne },
ea4b5953a78d3812cef59dcb7a3067575c1e9b82Jake Feasel "backbone.paginator": {
ea4b5953a78d3812cef59dcb7a3067575c1e9b82Jake Feasel deps: ["backbone"]
ea4b5953a78d3812cef59dcb7a3067575c1e9b82Jake Feasel },
ea4b5953a78d3812cef59dcb7a3067575c1e9b82Jake Feasel "backgrid": {
ea4b5953a78d3812cef59dcb7a3067575c1e9b82Jake Feasel deps: ["jquery", "underscore", "backbone"],
ea4b5953a78d3812cef59dcb7a3067575c1e9b82Jake Feasel exports: "Backgrid"
ea4b5953a78d3812cef59dcb7a3067575c1e9b82Jake Feasel },
ea4b5953a78d3812cef59dcb7a3067575c1e9b82Jake Feasel "backgrid-filter": {
ea4b5953a78d3812cef59dcb7a3067575c1e9b82Jake Feasel deps: ["backgrid"]
ea4b5953a78d3812cef59dcb7a3067575c1e9b82Jake Feasel },
ea4b5953a78d3812cef59dcb7a3067575c1e9b82Jake Feasel "backgrid-paginator": {
ea4b5953a78d3812cef59dcb7a3067575c1e9b82Jake Feasel deps: ["backgrid", "backbone.paginator"]
ea4b5953a78d3812cef59dcb7a3067575c1e9b82Jake Feasel },
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne js2form: {
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne exports: "js2form"
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne },
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne form2js: {
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne exports: "form2js"
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne },
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne spin: {
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne exports: "spin"
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne },
cbbe3a4aab44b4352cec9dac8831028f16c392d2Elizabeth Browne jsonEditor: {
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel deps: ["handlebars"],
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel init: function (Handlebars) {
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel window.Handlebars = Handlebars;
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel return this.JSONEditor;
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel },
fcfeab652394e5fddf0101c230ea3d30b9649538huck.elliott exports: "JSONEditor"
cbbe3a4aab44b4352cec9dac8831028f16c392d2Elizabeth Browne },
d5b7485f164e9584d8b84bd882cb8df10c61bfa9Elizabeth Browne cron: {
da94b90a76ad985d8b442a0571f96a2cf8e1d551Elizabeth Browne deps: ["jquery"]
da94b90a76ad985d8b442a0571f96a2cf8e1d551Elizabeth Browne },
da94b90a76ad985d8b442a0571f96a2cf8e1d551Elizabeth Browne gentleSelect: {
da94b90a76ad985d8b442a0571f96a2cf8e1d551Elizabeth Browne deps: ["jquery"]
d5b7485f164e9584d8b84bd882cb8df10c61bfa9Elizabeth Browne },
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne jqueryui: {
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel deps: ["jquery"]
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne },
0c69f7dcc39578744f9b3bdf86148d1ad7fb2117Elizabeth jquerySortable: {
0c69f7dcc39578744f9b3bdf86148d1ad7fb2117Elizabeth deps: ["jquery"]
0c69f7dcc39578744f9b3bdf86148d1ad7fb2117Elizabeth },
26a6ec53bb06b3fb881e2a0cf5855c300513cad6Jake Feasel i18nGrid: {
26a6ec53bb06b3fb881e2a0cf5855c300513cad6Jake Feasel deps: ["jquery"]
26a6ec53bb06b3fb881e2a0cf5855c300513cad6Jake Feasel },
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne jqgrid: {
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne deps: ["jqueryui", "i18nGrid"]
da94b90a76ad985d8b442a0571f96a2cf8e1d551Elizabeth Browne },
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne xdate: {
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne exports: "xdate"
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne },
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne doTimeout: {
26a6ec53bb06b3fb881e2a0cf5855c300513cad6Jake Feasel deps: ["jquery"],
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne exports: "doTimeout"
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne },
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne handlebars: {
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne exports: "handlebars"
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne },
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne i18next: {
4e74818e3d2f5b362c256e8d08ea2da2222f7a4bJake Feasel deps: ["jquery", "handlebars"],
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne exports: "i18next"
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne },
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne moment: {
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne exports: "moment"
95f6a8dff82d34449590f9a50ccc70df924d5a8fJason Browne },
15b38efb2ff497ce4f3efd3bd89d2c0e8e8eca1eJason Browne selectize: {
15b38efb2ff497ce4f3efd3bd89d2c0e8e8eca1eJason Browne deps: ["jquery"]
15b38efb2ff497ce4f3efd3bd89d2c0e8e8eca1eJason Browne },
36f4d2ecf602e95c78eb83d3faa179121240e881huck.elliott d3: {
36f4d2ecf602e95c78eb83d3faa179121240e881huck.elliott exports: "d3"
36f4d2ecf602e95c78eb83d3faa179121240e881huck.elliott },
8d7f4062530cb28c3500555d87f62ed1a95cc630Jason Browne bootstrap: {
8d7f4062530cb28c3500555d87f62ed1a95cc630Jason Browne deps: ["jquery"]
95f6a8dff82d34449590f9a50ccc70df924d5a8fJason Browne },
95f6a8dff82d34449590f9a50ccc70df924d5a8fJason Browne placeholder: {
95f6a8dff82d34449590f9a50ccc70df924d5a8fJason Browne deps: ["jquery"]
8d7f4062530cb28c3500555d87f62ed1a95cc630Jason Browne },
8d7f4062530cb28c3500555d87f62ed1a95cc630Jason Browne 'bootstrap-dialog': {
8d7f4062530cb28c3500555d87f62ed1a95cc630Jason Browne deps: ["jquery", "underscore","backbone", "bootstrap"]
5ba21fe7054811ca234da9534ff33b26242a3c70Elizabeth Browne },
5ba21fe7054811ca234da9534ff33b26242a3c70Elizabeth Browne 'bootstrap-tabdrop': {
5ba21fe7054811ca234da9534ff33b26242a3c70Elizabeth Browne deps: ["jquery", "bootstrap"]
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne }
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne }
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne});
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Brownerequire([
cbbe3a4aab44b4352cec9dac8831028f16c392d2Elizabeth Browne "org/forgerock/commons/ui/common/util/Constants",
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne "org/forgerock/commons/ui/common/main/EventManager",
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel "jsonEditor",
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel "org/forgerock/commons/ui/common/main",
cbbe3a4aab44b4352cec9dac8831028f16c392d2Elizabeth Browne "org/forgerock/openidm/ui/common/main",
48ddd46e9e22ee57a7fb400c6296f977c11173b3Elizabeth Browne "org/forgerock/openidm/ui/admin/main",
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel "config/main",
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel "jquery",
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel "underscore",
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel "backbone",
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel "handlebars",
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel "i18next",
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel "spin",
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel "placeholder",
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel "selectize"
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel], function(
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel Constants,
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel EventManager,
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel JSONEditor) {
4e74818e3d2f5b362c256e8d08ea2da2222f7a4bJake Feasel
e26e5073e1266868172d72453c97f413fe2fb603Jake Feasel EventManager.sendEvent(Constants.EVENT_DEPENDECIES_LOADED);
15b38efb2ff497ce4f3efd3bd89d2c0e8e8eca1eJason Browne
9ad7d0020702ab233be7bce3c52cf209ebec0e35huck.elliott JSONEditor.defaults.options.theme = 'bootstrap3';
9ad7d0020702ab233be7bce3c52cf209ebec0e35huck.elliott JSONEditor.defaults.options.iconlib = "fontawesome4";
ea4b5953a78d3812cef59dcb7a3067575c1e9b82Jake Feasel});