From 5858f4013f4e85ce5fe693a477369c60bf24088f Mon Sep 17 00:00:00 2001 From: xdrm-brackets Date: Mon, 14 Dec 2015 10:16:29 +0100 Subject: [PATCH] Modifs mineures --- Consultations.php | 1 - css/login-material.css | 0 js/lib/API.js | 0 managers/Patient.class.php | 14 ++++++++------ src/svg/notifications/close.svg | 0 src/svg/notifications/error.svg | 0 src/svg/notifications/info.svg | 0 src/svg/notifications/success.svg | 0 8 files changed, 8 insertions(+), 7 deletions(-) mode change 100644 => 100755 css/login-material.css mode change 100644 => 100755 js/lib/API.js mode change 100644 => 100755 src/svg/notifications/close.svg mode change 100644 => 100755 src/svg/notifications/error.svg mode change 100644 => 100755 src/svg/notifications/info.svg mode change 100644 => 100755 src/svg/notifications/success.svg diff --git a/Consultations.php b/Consultations.php index ebac30d..a4b0228 100755 --- a/Consultations.php +++ b/Consultations.php @@ -4,7 +4,6 @@ if(!Authentification::checkUser(0)){ header("Location: http://".$_SERVER['HTTP_HOST']."/index.php"); die(); }; - // formattage $_GET['type'] $answerType = (isset($_GET['type'])) ? $_GET['type'] : null; diff --git a/css/login-material.css b/css/login-material.css old mode 100644 new mode 100755 diff --git a/js/lib/API.js b/js/lib/API.js old mode 100644 new mode 100755 diff --git a/managers/Patient.class.php b/managers/Patient.class.php index b7514c9..f2d35c2 100755 --- a/managers/Patient.class.php +++ b/managers/Patient.class.php @@ -12,13 +12,15 @@ class Patient $params['date_naissance'] = DateTime::createFromFormat('d/m/Y', $params['date_naissance']); if(PatientRepo::add($params['civilite'],strtolower($params['prenom']),strtolower($params['nom']),$params['adresse'],$params['adresse2'],$params['ville'],$params['code_postal'], $params['date_naissance']->format('Y-m-d'),$params['lieu_naissance'],$params['num_secu'],$params['medecin_traitant']) !==FALSE){ - $response = new Response(); - $response->setHeader('Location',"http://".$_SERVER['HTTP_HOST']."/Patients.php?type=creation"); - $response->send(); + // $response = new Response(); + // $response->setHeader('Location',"http://".$_SERVER['HTTP_HOST']."/Patients.php?type=creation"); + // $response->send(); + Response::quickResponse(200, json_encode(['status'=>'success'])); }else{ - $response = new Response(500); - $response->setHeader('Location',"http://".$_SERVER['HTTP_HOST']."/Patients.php?type=error"); - $response->send(); + Response::quickResponse(200, json_encode(['status'=>'error'])); + // $response = new Response(500); + // $response->setHeader('Location',"http://".$_SERVER['HTTP_HOST']."/Patients.php?type=error"); + // $response->send(); } } diff --git a/src/svg/notifications/close.svg b/src/svg/notifications/close.svg old mode 100644 new mode 100755 diff --git a/src/svg/notifications/error.svg b/src/svg/notifications/error.svg old mode 100644 new mode 100755 diff --git a/src/svg/notifications/info.svg b/src/svg/notifications/info.svg old mode 100644 new mode 100755 diff --git a/src/svg/notifications/success.svg b/src/svg/notifications/success.svg old mode 100644 new mode 100755