|
|
|
@ -2,6 +2,18 @@ const DEFAULT_USER = "defaultUser";
|
|
|
|
|
const DEFAULT_SESSION = "defaultSession"; |
|
|
|
|
const DEFAULT_WALLPAPPER = "defaultWallpapper"; |
|
|
|
|
|
|
|
|
|
function togglePasswordVisibility() { |
|
|
|
|
var passwd = document.getElementById("password"); |
|
|
|
|
var eye = document.getElementById("eye"); |
|
|
|
|
if (passwd.type === "password") { |
|
|
|
|
passwd.type = "text"; |
|
|
|
|
eye.src = "images/eye2.png" |
|
|
|
|
} else { |
|
|
|
|
passwd.type = "password"; |
|
|
|
|
eye.src = "images/eye.png" |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
function updateDefaults(user, session) { |
|
|
|
|
|
|
|
|
|
localStorage.setItem(DEFAULT_USER, user) |
|
|
|
@ -34,6 +46,7 @@ function selectItemByValue(elmnt, value){
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
function doLogin() { |
|
|
|
|
event.preventDefault(); |
|
|
|
|
var user = document.getElementById("user").textContent |
|
|
|
|
var password = document.getElementById("password").value |
|
|
|
|
var session = document.getElementById("sessions").value |
|
|
|
|