21 lines
644 B
PHP
21 lines
644 B
PHP
|
<?php
|
||
|
/**
|
||
|
* Created by PhpStorm.
|
||
|
* User: seekdasky
|
||
|
* Date: 03/12/15
|
||
|
* Time: 11:52
|
||
|
*/
|
||
|
|
||
|
require_once('autoloader.php');
|
||
|
|
||
|
$jsonP = json_decode('Docs/PatientExemple.json',true);
|
||
|
$jsonM = json_decode('Docs/MedecinExemple.json',true);
|
||
|
$repo = new PatientRepo();
|
||
|
|
||
|
foreach($jsonM as $patient) {
|
||
|
$repo->add($patient['Civilite'], $patient['Prenom'], $patient['Nom']);
|
||
|
}
|
||
|
|
||
|
foreach($jsonP as $patient){
|
||
|
$repo->add($patient['Civilite'],$patient['Prenom'],$patient['Nom'],$patient['Adresse'],$patient['Ville'],$patient['CodePostal'],$patient['DateNaissance'],$patient['LieuNaissance'],$patient['NumSecuriteSociale'],$patient['MedecinTraitant'])
|
||
|
}
|