Skip to content
Snippets Groups Projects
Commit cbaced0b authored by Antony Le Courtes's avatar Antony Le Courtes
Browse files

Formattage des dates des données personnelles en lecture seule (#60707)

parent 81634a9e
No related branches found
No related tags found
No related merge requests found
Pipeline #35658 passed
...@@ -46,7 +46,9 @@ $dossierIdentiteComplementaire = $form->get('DossierIdentiteComplementaire'); ...@@ -46,7 +46,9 @@ $dossierIdentiteComplementaire = $form->get('DossierIdentiteComplementaire');
<div class="input-group cold-md-6 readonly"> <div class="input-group cold-md-6 readonly">
<?php <?php
if (!empty($dossierIdentiteComplementaire->get('dateNaissance')->getValue())) { if (!empty($dossierIdentiteComplementaire->get('dateNaissance')->getValue())) {
echo ($viewIdentite) ? $dossierIdentiteComplementaire->get('dateNaissance')->getValue() : '**/**/****'; $dateNaissance = $dossierIdentiteComplementaire->get('dateNaissance')->getValue();
$dateNaissanceFormatted = DateTime::createFromFormat('Y-m-d',$dateNaissance)->format('d/m/Y');
echo ($viewIdentite) ? $dateNaissanceFormatted : '**/**/****';
} }
?> ?>
</div> </div>
......
...@@ -99,7 +99,9 @@ $dossierIdentite = $form->get('DossierIdentite'); ...@@ -99,7 +99,9 @@ $dossierIdentite = $form->get('DossierIdentite');
<div class="input-group cold-md-6 readonly"> <div class="input-group cold-md-6 readonly">
<?php <?php
if (!empty($dossierIdentite->get('dateSituationMatrimoniale')->getValue())) { if (!empty($dossierIdentite->get('dateSituationMatrimoniale')->getValue())) {
echo ($viewIdentite) ? $dossierIdentite->get('dateSituationMatrimoniale')->getValue() : '**/**/****'; $dateMatrimoniale = $dossierIdentite->get('dateSituationMatrimoniale')->getValue();
$dateMatrimonialeFormatted = DateTime::createFromFormat('Y-m-d',$dateMatrimoniale)->format('d/m/Y');
echo ($viewIdentite) ? $dateMatrimonialeFormatted : '**/**/****';
} }
?> ?>
</div> </div>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment