mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-18 20:47:54 +00:00
Autenticação com Basic Auth na classe authservice no método login().
This commit is contained in:
@@ -81,18 +81,22 @@ export class LoginPage implements OnInit {
|
|||||||
}*/
|
}*/
|
||||||
}
|
}
|
||||||
|
|
||||||
simpleLogin(){
|
async simpleLogin(){
|
||||||
//Go to our home in home/feed.
|
//Go to our home in home/feed.
|
||||||
|
|
||||||
if(this.validateInput()){
|
if(this.validateInput()){
|
||||||
this.router.navigate(['/home/feed']);
|
if (await this.authService.login(this.postData))
|
||||||
console.log(this.postData);
|
{
|
||||||
|
this.router.navigate(['/home/feed']);
|
||||||
|
console.log(this.postData);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
console.log("Não foi possível fazer login");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
console.log("Preencha todos campos");
|
console.log("Preencha todos campos");
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user