a
This commit is contained in:
parent
22db8f480f
commit
5b1168aa7e
|
|
@ -777,7 +777,9 @@
|
|||
|
||||
// Redirection automatique après 5 secondes
|
||||
startCountdown(5, () => {
|
||||
window.location.href = data.redirect_url || 'dashboard.php';
|
||||
// window.location.href = data.redirect_url || 'dashboard.php';
|
||||
// On recharge la page
|
||||
location.reload();
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -104,8 +104,8 @@ class FacialVerificationAPI {
|
|||
'SimilarityThreshold' => 80
|
||||
]);
|
||||
|
||||
var_dump($result);
|
||||
exit;
|
||||
// var_dump($result);
|
||||
// exit;
|
||||
|
||||
if (empty($result['FaceMatches'])) {
|
||||
return [
|
||||
|
|
@ -180,6 +180,8 @@ class FacialVerificationAPI {
|
|||
*/
|
||||
private function createAuthorizationSession($assureId, $verificationRequestId) {
|
||||
$sessionToken = bin2hex(random_bytes(32));
|
||||
|
||||
/*
|
||||
$expiresAt = date('Y-m-d H:i:s', time() + 3600);
|
||||
|
||||
$sql = "INSERT INTO prestation_authorization_sessions
|
||||
|
|
@ -188,8 +190,10 @@ class FacialVerificationAPI {
|
|||
|
||||
$stmt = $this->db->prepare($sql);
|
||||
$stmt->execute([$assureId, $verificationRequestId, $sessionToken, $expiresAt]);
|
||||
|
||||
*/
|
||||
|
||||
return $sessionToken;
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
@ -252,8 +256,8 @@ class FacialVerificationAPI {
|
|||
'match' => true,
|
||||
'confidence' => $comparisonResult['confidence'],
|
||||
'message' => 'Identité vérifiée avec succès',
|
||||
'session_token' => $sessionToken,
|
||||
'redirect_url' => 'saisie_prestations.php?token=' . $sessionToken
|
||||
// 'session_token' => $sessionToken,
|
||||
// 'redirect_url' => 'saisie_prestations.php?token=' . $sessionToken
|
||||
];
|
||||
} else {
|
||||
$attemptsRemaining = $this->maxAttempts - ($request['attempts'] + 1);
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user