38 lines
1.1 KiB
PHP
38 lines
1.1 KiB
PHP
<?php
|
|
require_once 'Framework/Modele.php';
|
|
|
|
class Finger extends Modele {
|
|
|
|
public function vider_finger_temp($user_id)
|
|
{
|
|
$sql = 'call sp_p_vider_finger(?)';
|
|
$this->executerRequete($sql, array($user_id));
|
|
}
|
|
|
|
public function verifier_tentative_identification($user_id)
|
|
{
|
|
$sql = 'call sp_p_compteur_tentative_identification(?)';
|
|
$resultat = $this->executerRequete($sql, array($user_id));
|
|
$ligne = $resultat->fetch(PDO::FETCH_ASSOC);
|
|
return $ligne['nbTentative'];
|
|
}
|
|
|
|
public function compteur_tentative_identification($user_id)
|
|
{
|
|
$sql = 'call sp_p_compteur_tentative_identification(?)';
|
|
$resultat = $this->executerRequete($sql, array($user_id));
|
|
$ligne = $resultat->fetch(PDO::FETCH_ASSOC);
|
|
return $ligne['nbTentative'];
|
|
}
|
|
|
|
public function saveenroleur($user_id)
|
|
{
|
|
$codePrestataire = $_SESSION['p_codePrestataire_C'];
|
|
$user = $_SESSION['p_login'];
|
|
|
|
$sql = 'call sp_p_save_enroleur(?, ?, ?)';
|
|
|
|
$this->executerRequete($sql, array($user_id, $codePrestataire, $user));
|
|
}
|
|
}
|