|
|
|
@ -24,6 +24,7 @@ function Connexion() {
|
|
|
|
|
const [login, setLogin] = useState("");
|
|
|
|
|
const [password, setPassword] = useState("");
|
|
|
|
|
const [roleUser, setRole] = useState("");
|
|
|
|
|
const [mdpOublie, setMdpOublie] = useState(false);
|
|
|
|
|
|
|
|
|
|
function changeLogin(event) {
|
|
|
|
|
setLogin(event.target.value);
|
|
|
|
@ -98,6 +99,15 @@ function Connexion() {
|
|
|
|
|
) : (
|
|
|
|
|
<div className="page_connexion">
|
|
|
|
|
<img className="logo" srcSet="./LogoApp.svg"></img>
|
|
|
|
|
{ mdpOublie ?
|
|
|
|
|
<div className="formulaire_de_connexion">
|
|
|
|
|
<label className="connexion_text">
|
|
|
|
|
Mot de passe oublié
|
|
|
|
|
</label>
|
|
|
|
|
<p>Contactez votre administrateur système afin qu'il vérifie votre identité et vous regénére un mot de passe</p>
|
|
|
|
|
<button onClick={() => setMdpOublie(false)}>Retour</button>
|
|
|
|
|
</div>
|
|
|
|
|
:
|
|
|
|
|
<form onSubmit={chechAuth} className="formulaire_de_connexion">
|
|
|
|
|
<label className="connexion_text">
|
|
|
|
|
Connexion
|
|
|
|
@ -118,7 +128,8 @@ function Connexion() {
|
|
|
|
|
|
|
|
|
|
<p>{auth === ""?'':auth === "Failed"?'Authentification Echoué':'Utilisateur inconnu'}</p>
|
|
|
|
|
</form>
|
|
|
|
|
<a className="forgot_pw" href="http://localhost">Mot de passe oublié ?</a>
|
|
|
|
|
}
|
|
|
|
|
{ mdpOublie ? null : <a className="forgot_pw" onClick={() => setMdpOublie(true)}>Mot de passe oublié ?</a> }
|
|
|
|
|
</div>
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|