| Current Path : /home/happyrenas/old/happy-and-pay.fr/administration/templates/admin3/ |
Linux webd005.cluster105.gra.hosting.ovh.net 5.15.206-ovh-vps-grsec-zfs-classid #1 SMP Fri May 15 02:41:25 UTC 2026 x86_64 |
| Current File : /home/happyrenas/old/happy-and-pay.fr/administration/templates/admin3/fiche_reservation.php |
<?
session_start();
error_reporting(E_ALL);
ini_set('display_errors','On');
include("config.php");
$page="index";
$reservation_id = $_REQUEST['reservation_id'];
$myquery = "SELECT * from client_reservation where id=".$reservation_id;
$reservation = $db->get_row($myquery);
if ($reservation->paiement_type==1) {$paiement_type_affiche="ACOMPTE ";}
if ($reservation->paiement_type==2) {$paiement_type_affiche="SOLDE ";}
if ($reservation->date_debut!="0000-00-00") {$date_debut=date("d-m-Y", strtotime($reservation->date_debut));}
if ($reservation->date_fin!="0000-00-00") {$date_fin=date("d-m-Y", strtotime($reservation->date_fin));}
$myquery = "SELECT * from client where id=".$reservation->client_id;
$client = $db->get_row($myquery);
$myquery = "SELECT * from client_reservation_proprietaire where proprietaire_mail='".$reservation->proprietaire_mail."'";
$proprietaire = $db->get_row($myquery);
?>
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title></title>
<script type='text/javascript' src='/js/lib/dummy.js'></script>
<link rel="stylesheet" type="text/css" href="/css/result-light.css">
</head>
<body>
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
<h2 class="modal-title"><b><?echo $paiement_type_affiche;?> <?echo $reservation->montant;?> €, client : <?echo $client->prenom;?> <?echo $client->nom;?> (<?echo date("d-m-Y", strtotime($client->date_creation));?>)</b></h2>
<?
if ($reservation->statut==4 && $reservation->payment_id){?>
<h4>Paiement effectué (<?echo $reservation->payment_id;?> )</h4>
<h4>Montant : <?echo $reservation->payment_id_montant;?> €</h4>
<h4>Commission : <?echo $reservation->payment_id_commission;?> €</h4>
<h4>Date : <?echo date("d-m-Y", strtotime($reservation->payment_id_date));?> </h4>
<h4><b>Wallet : <?echo $reservation->createdWallet;?> </b></h4>
<?if ($reservation->is_repayed==0 && $reservation->paiement_type==1)
{
//$date_remboursement = strtotime(date("d-m-Y", strtotime($reservation->date_debut)) . " +5 days");
//$date_remboursement = strtotime("+7 day", $date_debut);
//$date_remboursement = date("d-m-Y", strtotime($date_remboursement));
//$date_remboursement = date('d-m-Y', strtotime('+2 days'));
// ENFIN :
$date_remboursement = date('d-m-Y', strtotime(date("d-m-Y", strtotime($reservation->date_debut)) . " +2 days"));
echo "<h4>Date prévue du remboursement : ".$date_remboursement."</h4>";
}
?>
<?} else {?>
<h4>Paiement non effectué </h4>
<?}?>
</div>
<div class="modal-body">
<h4>Début du séjour : <?echo $date_debut;?></h4>
<h4>Fin du séjour : <?echo $date_fin;?></h4>
<br>
<h4>Adresse du lieu de séjour : <br><?echo $reservation->adresse;?><br><?echo $reservation->cp;?> <?echo $reservation->ville;?><br><?echo $reservation->pays;?></h4>
<?if ($reservation->assurance_annulation==1) {?><h4><b>Assurance annulation demandée </b></h4><?}?>
<h4>Mail client : <?echo $client->mail;?></h4>
<h4>Tél client : <?echo $client->tel;?></h4>
<br>
<h4>Mail propriétaire: <?echo $proprietaire->proprietaire_mail;?></h4>
<h4>Tel propriétaire: <?echo $proprietaire->proprietaire_tel;?></h4>
<?if ($proprietaire->proprietaire_id) {?><h4><b>Mangopay : <?echo $proprietaire->proprietaire_id;?></b></h4><?}?>
</div>
<div class="modal-footer">
<button type="button" class="btn default" onclick="javascript:window.location.reload()" data-dismiss="modal" >Fermer</button>
</div>
</body>
</html>