ajout de methode pour parler a backend et database
This commit is contained in:
@@ -86,14 +86,27 @@ export class LoginWindow extends fenetre {
|
|||||||
this.body.style.gap = "8px";
|
this.body.style.gap = "8px";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
connexion(){
|
||||||
|
console.log("methode connexion lancée");
|
||||||
|
}
|
||||||
|
|
||||||
|
inscription(){
|
||||||
|
console.log("methode inscription lancée");
|
||||||
|
}
|
||||||
|
|
||||||
bindEvents() {
|
bindEvents() {
|
||||||
this.switch.onclick = () => this.toggleMode();
|
this.switch.onclick = () => this.toggleMode();
|
||||||
|
|
||||||
this.submit.onclick = () => {
|
this.submit.onclick = () => {
|
||||||
this.message.innerText =
|
this.message.innerText = this.mode === "login"
|
||||||
this.mode === "login"
|
? "Tentative de connexion..."
|
||||||
? "Tentative de connexion..."
|
: "Tentative d'inscription...";
|
||||||
: "Tentative d'inscription...";
|
if (this.mode === "login"){
|
||||||
|
this.connexion();
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
this.inscription();
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user