Commit d1e33ec0 by Torkel Ödegaard

Moved routes

parent 39f3cfc1
......@@ -50,7 +50,6 @@ function (angular, $, _, appLevelRequire, config) {
};
app.config(function ($routeProvider, $controllerProvider, $compileProvider, $filterProvider, $provide) {
$routeProvider.otherwise({ redirectTo: config.default_route });
// this is how the internet told me to dynamically add modules :/
register_fns.controller = $controllerProvider.register;
......@@ -86,7 +85,7 @@ function (angular, $, _, appLevelRequire, config) {
'directives/all',
'filters/all',
'components/partials',
'routes/all',
'routes/standalone/default',
];
_.each(config.plugins.dependencies, function(dep) {
......
define([
'./dashboard-from-db',
'./dashboard-from-file',
'./dashboard-from-script',
'./dashboard-default',
],
function () {});
define([
'angular',
'config',
'store'
'store',
'./fromDB',
'./fromFile',
'./fromScript',
],
function (angular, config, store) {
"use strict";
'use strict';
var module = angular.module('grafana.routes');
module.config(function($routeProvider) {
$routeProvider
.when('/', {
redirectTo: function() {
return store.get('grafanaDashboardDefault') || config.default_route;
}
});
.when('/', {
redirectTo: function() {
return store.get('grafanaDashboardDefault') || config.default_route;
}
});
});
});
......@@ -62,7 +62,7 @@ module.exports = function(config,grunt) {
'directives/all',
'filters/all',
'controllers/all',
'routes/all',
'routes/standalone/default',
'components/partials',
]
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment