summaryrefslogtreecommitdiff
path: root/js/codeq
diff options
context:
space:
mode:
Diffstat (limited to 'js/codeq')
-rw-r--r--js/codeq/core.js4
-rw-r--r--js/codeq/login.js1
-rw-r--r--js/codeq/navigation.js9
-rw-r--r--js/codeq/statusbar.js2
4 files changed, 14 insertions, 2 deletions
diff --git a/js/codeq/core.js b/js/codeq/core.js
index 1685dd7..3dfa7c2 100644
--- a/js/codeq/core.js
+++ b/js/codeq/core.js
@@ -389,5 +389,7 @@
codeq.setLang(lang || 'en'); // initial language setting
// go to login
codeq.globalStateMachine.transition('login');
- });
+
+ //For performance reasons, the Tooltip and Popover data-apis are opt-in, meaning you must initialize them yourself.
+ $('[data-toggle="popover"]').popover()});
})();
diff --git a/js/codeq/login.js b/js/codeq/login.js
index c400f06..f590acb 100644
--- a/js/codeq/login.js
+++ b/js/codeq/login.js
@@ -29,6 +29,7 @@
codeq.globalStateMachine.register('login',{
'enter': function(){
$("#submit").on('click', loginFun);
+ //$('#modalLogin').modal();
$("#screen_login").css('display', '');
$('#disabled').css('display', 'none');
diff --git a/js/codeq/navigation.js b/js/codeq/navigation.js
index 1a7799f..80fd321 100644
--- a/js/codeq/navigation.js
+++ b/js/codeq/navigation.js
@@ -97,4 +97,13 @@
codeq.globalStateMachine.transition('prolog');
e.preventDefault();
});
+ $('#navigation-logout').on('click', function(e){
+ codeq.globalStateMachine.transition('login');
+ e.preventDefault();//prevent this since we'll trigger a page reload otherwise
+ });
+ $('#navigation-profile').on('click', function(e){
+ codeq.globalStateMachine.transition('profile');
+ e.preventDefault();//prevent this since we'll trigger a page reload otherwise
+ });
+
})(); \ No newline at end of file
diff --git a/js/codeq/statusbar.js b/js/codeq/statusbar.js
index 2134b93..56070bd 100644
--- a/js/codeq/statusbar.js
+++ b/js/codeq/statusbar.js
@@ -6,7 +6,7 @@
(function () {
var langs = codeq.supportedLangs,
- jqMenu = jqBar.find('.dropdown-menu'),
+ jqMenu = jqLang.find('.dropdown-menu'),
lang, cssClass;
for (lang in langs) {
if (!langs.hasOwnProperty(lang)) continue;