a
This commit is contained in:
parent
38219c989f
commit
9c658d86dc
|
|
@ -27,7 +27,7 @@ class ControleurRechercheparcarte extends Controleur {
|
|||
|
||||
}
|
||||
|
||||
public function index($donneesCarte="")
|
||||
public function index($donneesCarte="", $msgErreur=null)
|
||||
{
|
||||
$this->beneficiaire->getModeBiometrie();
|
||||
|
||||
|
|
@ -55,7 +55,8 @@ class ControleurRechercheparcarte extends Controleur {
|
|||
// exit();
|
||||
|
||||
if (count($parts) !== 3 || $parts[0] !== 'IS1') {
|
||||
die("Carte invalide");
|
||||
// die("Carte invalide");
|
||||
$msgErreur = 'Carte invalide / Invalid card';
|
||||
}
|
||||
|
||||
$codeEntite = $parts[1];
|
||||
|
|
@ -75,8 +76,9 @@ class ControleurRechercheparcarte extends Controleur {
|
|||
|
||||
if($codeEntite<=" " || $numeroBeneficiaireCarte<=" ")
|
||||
{
|
||||
$this->rediriger("Rechercheparcarte");
|
||||
exit();
|
||||
// $this->rediriger("Rechercheparcarte");
|
||||
// exit();
|
||||
$msgErreur = 'Carte invalide / Invalid card';
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
@ -90,8 +92,10 @@ class ControleurRechercheparcarte extends Controleur {
|
|||
|
||||
if($nbLignes==0)
|
||||
{
|
||||
$this->rediriger("Recherche");
|
||||
exit();
|
||||
// $this->rediriger("Recherche");
|
||||
// exit();
|
||||
|
||||
$msgErreur = 'Carte introuvable / Card not found';
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
@ -113,8 +117,7 @@ class ControleurRechercheparcarte extends Controleur {
|
|||
$this->rediriger("Fichebeneficiaire");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
$this->genererVue();
|
||||
$this->genererVue(array('msgErreur' => $msgErreur));
|
||||
}
|
||||
}
|
||||
|
|
@ -22,7 +22,7 @@
|
|||
</tbody>
|
||||
</table>
|
||||
|
||||
<?php if (isset($msgErreur)): ?>
|
||||
<?php if (): ?>
|
||||
<?php if ($codeEtatBon=="1"): ?>
|
||||
<div id ="msgErreur" class="alert alert-success" style="height:38px; padding:5px;">
|
||||
<H4><?= $msgErreur ?></H4>
|
||||
|
|
|
|||
|
|
@ -6,3 +6,10 @@
|
|||
<INPUT style='font-size:40pt;height: 50px;' class="form-control" TYPE="text" id="donneesCarte" name="donneesCarte" autofocus AUTOCOMPLETE="OFF" placeholder="<?= _("Veuillez scanner la carte NFC!")?>">
|
||||
<input id="lancerrechercheparcarte" name="lancerrechercheparcarte" class="sr-only" type="submit" value="<?= _("Rechercher") ?>" >
|
||||
</form>
|
||||
|
||||
|
||||
<?php if (isset($msgErreur)): ?>
|
||||
<div class="alert alert-danger" style="height:38px; padding:5px;" >
|
||||
<H4><?= $msgErreur ?></H4>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
Loading…
Reference in New Issue
Block a user