File tree Expand file tree Collapse file tree 5 files changed +7
-9
lines changed
src/main/resources/static/js Expand file tree Collapse file tree 5 files changed +7
-9
lines changed Original file line number Diff line number Diff line change @@ -2,7 +2,6 @@ jQuery(document).ready(function () {
2
2
var frontendServiceUrl = $ ( '#frontendServiceUrl' ) . text ( ) ;
3
3
var frontendServicePath = "/backend" ;
4
4
function instanceModel ( ) {
5
- var router = new Navigo ( null , true , '#' ) ;
6
5
7
6
var self = this ;
8
7
self . instance = {
@@ -32,7 +31,7 @@ jQuery(document).ready(function () {
32
31
} ,
33
32
success : function ( responseData , XMLHttpRequest , textStatus ) {
34
33
$ . jGrowl ( responseData . message , { sticky : false , theme : 'Notify' } ) ;
35
- router . navigate ( 'switch-backend' ) ;
34
+ navigateToRoute ( 'switch-backend' ) ;
36
35
}
37
36
} ) ;
38
37
}
Original file line number Diff line number Diff line change @@ -141,7 +141,7 @@ function reloadRoute() {
141
141
routes [ currentUrl ] ( ) ;
142
142
}
143
143
144
- function navigateRoute ( route ) {
144
+ function navigateToRoute ( route ) {
145
145
router . navigate ( route ) ;
146
146
}
147
147
// End ## Routing ##
Original file line number Diff line number Diff line change 1
1
jQuery ( document ) . ready ( function ( ) {
2
- var router = new Navigo ( null , true , '#' ) ;
3
2
4
3
function checkBackendSecured ( ) {
5
4
var callback = {
@@ -9,11 +8,11 @@ jQuery(document).ready(function () {
9
8
var currentUser = getCurrentUserInSession ( ) ;
10
9
var ldapEnabled = responseData . security ;
11
10
if ( ldapEnabled == false || ( ldapEnabled == true && currentUser != null ) ) {
12
- router . navigate ( 'subscriptions' ) ;
11
+ navigateToRoute ( 'subscriptions' ) ;
13
12
}
14
13
} ,
15
14
error : function ( responseData ) {
16
- router . navigate ( 'subscriptions' ) ;
15
+ navigateToRoute ( 'subscriptions' ) ;
17
16
} ,
18
17
complete : function ( ) {
19
18
}
@@ -53,7 +52,7 @@ jQuery(document).ready(function () {
53
52
var currentUser = JSON . parse ( ko . toJSON ( responseData ) ) . user ;
54
53
$ . jGrowl ( "Welcome " + currentUser , { sticky : false , theme : 'Notify' } ) ;
55
54
doIfUserLoggedIn ( currentUser ) ;
56
- router . navigate ( 'subscriptions' ) ;
55
+ navigateToRoute ( 'subscriptions' ) ;
57
56
} ,
58
57
error : function ( XMLHttpRequest , textStatus , errorThrown ) {
59
58
window . logMessages ( "Bad credentials" ) ;
Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ jQuery(document).ready(function () {
18
18
var callback = {
19
19
complete : function ( ) {
20
20
doIfUserLoggedOut ( ) ;
21
- router . navigate ( '*' ) ;
21
+ navigateToRoute ( '*' ) ;
22
22
}
23
23
} ;
24
24
var ajaxHttpSender = new AjaxHttpSender ( ) ;
Original file line number Diff line number Diff line change @@ -46,7 +46,7 @@ jQuery(document).ready(function () {
46
46
}
47
47
self . submit = function ( ) {
48
48
sessionStorage . selectedActive = selected . name ;
49
- navigateRoute ( 'subscriptions' ) ;
49
+ navigateToRoute ( 'subscriptions' ) ;
50
50
}
51
51
}
52
52
You can’t perform that action at this time.
0 commit comments