1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73
| <style type="text/css">
table{width: 100%; border-collapse:collapse; font-size:18px}
.header td{width: 50%; vertical-align: top, background-color: #57B223}
.text-left{text-align: left}
.text-right{text-align: right}
.text-center{text-align: center}
.separator{height: 150px; width: 100%}
.content td{border:solid 1px #CFD1D2; padding: 5px;}
.content th{border:solid 1px #000000; padding: 5px; background-color: #000000; color: #FFFFFF}
.ligne1Content{background-color:#57B223}
.couleurgris{background-color:#DDDDDD; height:200px}
</style>
<page backtop="20mm" backright="10mm" backbottom="20mm" backleft="10mm">
<?php
require_once 'connexion.php';
$resFC1=$base->prepare("SELECT * FROM infosfacture WHERE num= ?");
$resFC1->bindValue(1, $id, PDO::PARAM_INT);
$resFC1->execute(array($_GET['num']));
$resFC = $base->prepare('SELECT infosfacture.num, infosfacture.client, infosfacture.datefacture, infosfacture.facturede, infosfacture.conditions, facturation.designation, facturation.quantite, facturation.prixht
FROM infosfacture
INNER JOIN facturation
ON infosfacture.num=? AND facturation.fk_facturation_id=infosfacture.id');
$resFC->execute(array($_GET['num']));
?>
<?php foreach ($resFC1 as $req): ?>
<table class="header">
<tr>
<td class="text-left">
<b>Facturé à : <?php echo $req['client'] ?></b>
<br>
</td>
<td class="text-right">
<b>Facture de : <?php echo $req['$facturede'] ?></b>
<br>
</td>
</tr>
</table>
<div class="separator"></div>
<table>
<tr>
<td class="text-left">N° de facture: <?php echo $req['num'] ?> </td>
<td class="text-right">Date: <?php echo $req['datefacture'] ?></td>
</tr>
</table>
<?php endforeach; ?>
<br/><br/>
<table class="content">
<thead>
<tr class="ligne1Content">
<td class="text-left">PRESTATION</td>
<td class="text-center">NOMBRE DE JOURS</td>
<td class="text-center">TARIF JOURNALIER</td>
<td class="text-right">TOTAL HT</td>
</tr>
</thead>
<tbody>
<?php foreach ($resFC as $req): ?>
<tr class="couleurgris">
<td class="text-left"><?php echo $req['designation'] ?></td>
<td class="text-center"><?php echo $req['$quantite'] ?></td>
<td class="text-center"><?php echo $req['$prixht'] ?></td>
<td class="text-right"><?php echo $req['quantite'] * $req['prixht'] ?></td>
</tr>
<?php endforeach; ?>
</tbody>
<tfoot>
</tfoot>
</table>
</page> |
Partager