diff --git a/index.html b/index.html index d1d3365..0928dcc 100644 --- a/index.html +++ b/index.html @@ -65,7 +65,7 @@

RTS

- +
diff --git a/js/main.js b/js/main.js index da6c191..b97a3e6 100644 --- a/js/main.js +++ b/js/main.js @@ -240,6 +240,17 @@ async function loadExamList(data) { if (global_cid == null) { global_cid = "u-" + global_uid; } + + $("#btn-user-login").hide(); + + let logout = $("[x]") + logout.click(() => { + user_db.user.clear().then(() => { + window.location = "/accounts/logout/"; + return; + }); + }) + $("#user").append(logout); } @@ -2453,7 +2464,7 @@ $("#btn-candidate-login").click(function(evt) { }); $("#btn-user-login").click(function(evt) { - window.location = "https://www.penracourses.org.uk/accounts/login/?next=/rts" + window.location = "/accounts/login/?next=/rts" //$(".exam-wrapper").toggle(); });