diff --git a/public/src/require-config.js b/public/src/require-config.js new file mode 100644 index 0000000000..0ad2f8a58c --- /dev/null +++ b/public/src/require-config.js @@ -0,0 +1,11 @@ +require.config({ + baseUrl: config.relative_path + "/src/modules", + waitSeconds: 7, + urlArgs: "v=" + config['cache-buster'], + paths: { + 'forum': '../client', + 'admin': '../admin', + 'vendor': '../../vendor', + 'plugins': '../../plugins' + } +}); diff --git a/src/meta/js.js b/src/meta/js.js index b781a3b06f..ffd66f010e 100644 --- a/src/meta/js.js +++ b/src/meta/js.js @@ -26,6 +26,7 @@ module.exports = function(Meta) { 'public/vendor/jquery/bootstrap-tagsinput/bootstrap-tagsinput.min.js', 'public/vendor/jquery/textcomplete/jquery.textcomplete.js', 'public/vendor/requirejs/require.js', + 'public/src/require-config.js', 'public/vendor/bootbox/bootbox.min.js', 'public/vendor/tinycon/tinycon.js', 'public/vendor/xregexp/xregexp.js', diff --git a/src/views/admin/header.tpl b/src/views/admin/header.tpl index 3d797ed5be..b5a0f196c3 100644 --- a/src/views/admin/header.tpl +++ b/src/views/admin/header.tpl @@ -16,7 +16,8 @@ template: "{template.name}", user: JSON.parse('{{userJSON}}'), config: JSON.parse(decodeURIComponent("{{adminConfigJSON}}")), - flags: {} + flags: {}, + inAdmin: true }; @@ -30,20 +31,6 @@ - diff --git a/src/views/partials/requirejs-config.tpl b/src/views/partials/requirejs-config.tpl deleted file mode 100644 index c11b4aa9a3..0000000000 --- a/src/views/partials/requirejs-config.tpl +++ /dev/null @@ -1,13 +0,0 @@ - \ No newline at end of file