747 lines
29 KiB
PHP
747 lines
29 KiB
PHP
<?php
|
||
if (!$_SESSION['connected']) die();
|
||
|
||
$tabInfo = $_SESSION['tabInfo'];
|
||
|
||
$siret=trim(preg_replace('/[^0-9]/', '', $_REQUEST['siret']));
|
||
if (strlen($siret)<>0 && strlen($siret)<>9 && strlen($siret)<>14) die('Paramètres incorrects !');
|
||
|
||
$idEntreprise=trim(preg_replace('/[^0-9]/', '', $_REQUEST['idEntreprise']))*1; // Si id=0 alors non communiqué
|
||
if (($siret*1)==0 && $idEntreprise==0) die('Paramètres incorrects !');
|
||
$siren=substr($siret,0,9);
|
||
|
||
$raisonSociale=$tabInfo['entrep']['raisonSociale'];
|
||
|
||
try {
|
||
$O = $client->getRatios($siren, 'bilan');
|
||
$bilansInfos = $O['result']['BilansInfos'];
|
||
$ratiosInfos = $O['result']['RatiosInfos'];
|
||
$ratiosEntrep = $O['result']['RatiosEntrep'];
|
||
$ratiosEntrepEvol = $O['result']['RatiosEntrepEvol'];
|
||
|
||
$dataActif = array( graphPercent('r51','r22'),
|
||
graphPercent('r52','r22'),
|
||
graphPercent('r53','r22'),
|
||
graphPercent('r60','r22'),
|
||
graphPercent('r61','r22'),
|
||
graphPercent('r62','r22'),
|
||
graphPercent('r63','r22'),
|
||
);
|
||
|
||
$dataPassif = array( graphPercent('r70','r22'),
|
||
graphPercent('r71','r22'),
|
||
graphPercent('r72','r22'),
|
||
graphPercent('r83','r22'),
|
||
graphPercent('r84','r22'),
|
||
graphPercent('r85','r22'),
|
||
graphPercent('r86','r22'),
|
||
graphPercent('r87','r22'),
|
||
);
|
||
|
||
$dataSIG = array( graphPercent('r101','r101')-graphPercent('r122','r101'),
|
||
graphPercent('r122','r101')-graphPercent('r130','r101'),
|
||
graphPercent('r130','r101')-graphPercent('r140','r101'),
|
||
graphPercent('r140','r101')-graphPercent('r150','r101'),
|
||
graphPercent('r150','r101')-graphPercent('r170','r101'),
|
||
graphPercent('r170','r101')-graphPercent('r199','r101'),
|
||
graphPercent('r199','r101'),
|
||
);
|
||
|
||
}catch (SoapFault $fault) {
|
||
include_once(realpath(dirname(__FILE__).'/../../').'/includes/soaperror.php');
|
||
processSoapFault($client,$fault,$tabInfo);
|
||
die();
|
||
}
|
||
|
||
function graphPercent($nRatio,$totalRatio){
|
||
global $firephp;
|
||
global $ratiosEntrep;
|
||
$ratio = isset($ratiosEntrep[0][$nRatio]) ? $ratiosEntrep[0][$nRatio] : 0;
|
||
$totalRatio = $ratiosEntrep[0][$totalRatio];
|
||
$firephp->log($totalRatio,'totalRatio');
|
||
|
||
if ( ($ratio!='NS' || $ratio!=NULL) && ($totalRatio!=0 || $totalRatio!='NS')){
|
||
return $ratio*100/$totalRatio;
|
||
}else{
|
||
return 0;
|
||
}
|
||
}
|
||
|
||
function dPercent($nAnnee,$nRatio,$totalRatio){
|
||
global $ratiosEntrep;
|
||
$ratio = $ratiosEntrep[$nAnnee][$nRatio];
|
||
$totalRatio = $ratiosEntrep[$nAnnee][$totalRatio];
|
||
if ($ratio=='NS') {
|
||
print 'NS';
|
||
}elseif($ratio==NULL){
|
||
print '-';
|
||
}else {
|
||
if ($totalRatio!=0 || $totalRatio!='NS'){
|
||
$percent = $ratio*100/$totalRatio;
|
||
}else{
|
||
$percent = 0;
|
||
}
|
||
print round($percent, 2);
|
||
}
|
||
}
|
||
|
||
function dRatio($nAnnee,$nRatio){
|
||
global $ratiosEntrep;
|
||
global $ratiosInfos;
|
||
$ratio = $ratiosEntrep[$nAnnee][$nRatio];
|
||
if ($ratio=='NS') {
|
||
print 'NS';
|
||
}elseif($ratio==NULL){
|
||
print '-';
|
||
}else {
|
||
if ( $ratiosInfos[$nRatio]['unite']=='EUR' && ((abs($ratio)/1000)>0) ){
|
||
print number_format($ratio/1000, 0, '', ' ').' K€';
|
||
}elseif ($ratiosInfos[$nRatio]['unite']=='EUR' && ((abs($ratio)/1000)<0)) {
|
||
print number_format($ratio, 0, '', ' ').' €';
|
||
}else{
|
||
print $ratio.' '.$ratiosInfos[$nRatio]['unite'];
|
||
}
|
||
}
|
||
}
|
||
|
||
?>
|
||
<style>
|
||
#container {width:580px; background-color:#FFFFFF; }
|
||
.bilans {font-family:"Lucida Sans Unicode", "Lucida Grande", Sans-Serif; font-size:12px; margin:0; width:580px; text-align:left; border-collapse:collapse;}
|
||
.bilans th {padding:4px; font-weight:normal; font-size:11px; border:1px solid #000; color:#000; background:#b9c9fe; text-align:center; font-weight:bold;}
|
||
.bilans td {padding:4px; border:1px solid #000; color:#000;}
|
||
.bilans th.date {font-size:10px;}
|
||
.bilans td.right {text-align:right;}
|
||
.bilans td.center {text-align: center;}
|
||
.bilans td.italique {font-style:italic;}
|
||
.bilans tr.subhead td {padding:4px; background:#b9c9fe; border: 1px solid #000; font-weight:bold; color:#000;}
|
||
.entete {margin:1px;}
|
||
.subentete {margin:2px;}
|
||
</style>
|
||
<div id="container">
|
||
<div><img class="entete" src="./img/rub_bilans.png" width="577" height="36"></div>
|
||
<table>
|
||
<tr>
|
||
<td width="30"> </td>
|
||
<td width="200" class="StyleInfoLib">Numéro identifiant Siren</td>
|
||
<td width="350" class="StyleInfoData"><?=substr($siren,0,3).' '.substr($siren,3,3).' '.substr($siren,6,3)?></td>
|
||
</tr>
|
||
<tr>
|
||
<td width="30"> </td>
|
||
<td width="200" class="StyleInfoLib">Raison Sociale</td>
|
||
<td width="350" class="StyleInfoData"><?=$tabInfo['entrep']['raisonSociale']?></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<?php
|
||
if (count($ratiosEntrep)==0 || !isset($ratiosEntrep)){
|
||
?>
|
||
<table>
|
||
<tr><td width="30"> </td><td><b>Aucun bilan disponible pour cette entreprise !</b></td></tr>
|
||
</table>
|
||
<?php
|
||
}else{
|
||
?>
|
||
<div><img class="subentete" src="./img/srub_bilanap.png" width="576" height="27" /></div>
|
||
|
||
<table class="bilans">
|
||
<thead>
|
||
<tr>
|
||
<th>ACTIF</th>
|
||
<th class="date">
|
||
<?php
|
||
if(isset($bilansInfos[4]['dateCloture'])) {
|
||
print substr($bilansInfos[4]['dateCloture'],6,2).'/'.substr($bilansInfos[4]['dateCloture'],4,2).'/'.substr($bilansInfos[4]['dateCloture'],0,4);?><br/><?php print $bilansInfos[4]['duree']; ?> mois
|
||
<?php }else{ print '-'; } ?>
|
||
</th>
|
||
<th class="date">
|
||
<?php
|
||
if(isset($bilansInfos[3]['dateCloture'])) {
|
||
print substr($bilansInfos[3]['dateCloture'],6,2).'/'.substr($bilansInfos[3]['dateCloture'],4,2).'/'.substr($bilansInfos[3]['dateCloture'],0,4);?><br/><?php print $bilansInfos[3]['duree']; ?> mois
|
||
<?php }else{ print '-'; } ?>
|
||
</th>
|
||
<th class="date">
|
||
<?php
|
||
if(isset($bilansInfos[2]['dateCloture'])) {
|
||
print substr($bilansInfos[2]['dateCloture'],6,2).'/'.substr($bilansInfos[2]['dateCloture'],4,2).'/'.substr($bilansInfos[2]['dateCloture'],0,4);?><br/><?php print $bilansInfos[2]['duree']; ?> mois
|
||
<?php }else{ print '-'; } ?>
|
||
</th>
|
||
<th class="date">
|
||
<?php
|
||
if(isset($bilansInfos[1]['dateCloture'])) {
|
||
print substr($bilansInfos[1]['dateCloture'],6,2).'/'.substr($bilansInfos[1]['dateCloture'],4,2).'/'.substr($bilansInfos[1]['dateCloture'],0,4);?><br/><?php print $bilansInfos[1]['duree']; ?> mois
|
||
<?php }else{ print '-'; } ?>
|
||
</th>
|
||
<th class="date">
|
||
<?php
|
||
if(isset($bilansInfos[0]['dateCloture'])) {
|
||
print substr($bilansInfos[0]['dateCloture'],6,2).'/'.substr($bilansInfos[0]['dateCloture'],4,2).'/'.substr($bilansInfos[0]['dateCloture'],0,4);?><br/><?php print $bilansInfos[0]['duree']; ?> mois
|
||
<?php }else{ print '-'; } ?>
|
||
</th>
|
||
<th>% T.B.</th>
|
||
</tr>
|
||
</thead>
|
||
<tbody>
|
||
<tr class="subhead">
|
||
<td>Actif Immobilisé Net</td>
|
||
<td class="right"><?php dRatio(4,'r59'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r59'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r59'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r59'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r59'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r59','r22')?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>Incorporelles</td>
|
||
<td class="right"><?php dRatio(4,'r51'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r51'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r51'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r51'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r51'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r51','r22')?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>Corporelles</td>
|
||
<td class="right"><?php dRatio(4,'r52'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r52'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r52'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r52'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r52'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r52','r22')?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>Financières</td>
|
||
<td class="right"><?php dRatio(4,'r53'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r53'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r53'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r53'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r53'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r53','r22')?></td>
|
||
</tr>
|
||
<tr class="subhead">
|
||
<td>Actif Circulant Net</td>
|
||
<td class="right"><?php dRatio(4,'r69'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r69'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r69'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r69'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r69'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r69','r22')?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>Stock et encours</td>
|
||
<td class="right"><?php dRatio(4,'r60'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r60'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r60'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r60'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r60'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r60','r22')?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>Créances Clients</td>
|
||
<td class="right"><?php dRatio(4,'r61'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r61'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r61'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r61'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r61'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r61','r22')?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>Autres Créances</td>
|
||
<td class="right"><?php dRatio(4,'r62'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r62'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r62'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r62'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r62'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r62','r22')?></td>
|
||
</tr>
|
||
<tr>
|
||
<td> </td>
|
||
<td></td>
|
||
<td></td>
|
||
<td></td>
|
||
<td></td>
|
||
<td></td>
|
||
<td></td>
|
||
</tr>
|
||
<tr>
|
||
<td>Trésorerie Active</td>
|
||
<td class="right"><?php dRatio(4,'r63'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r63'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r63'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r63'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r63'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r63','r22')?></td>
|
||
</tr>
|
||
<tr class="subhead">
|
||
<td>TOTAL ACTIF</td>
|
||
<td class="right"><?php dRatio(4,'r22'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r22'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r22'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r22'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r22'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r22','r22')?></td>
|
||
</tr>
|
||
<tr><td colspan="7"><img src="./graphs/bilan_graph_actif.php?d=<?=urlencode(serialize($dataActif))?>"/></td></tr>
|
||
|
||
</tbody>
|
||
</table>
|
||
<br/><br/>
|
||
|
||
<table class="bilans">
|
||
<thead>
|
||
<tr>
|
||
<th>PASSIF</th>
|
||
<th class="date">
|
||
<?php
|
||
if(isset($bilansInfos[4]['dateCloture'])) {
|
||
print substr($bilansInfos[4]['dateCloture'],6,2).'/'.substr($bilansInfos[4]['dateCloture'],4,2).'/'.substr($bilansInfos[4]['dateCloture'],0,4);?><br/><?php print $bilansInfos[4]['duree']; ?> mois
|
||
<?php }else{ print '-'; } ?>
|
||
</th>
|
||
<th class="date">
|
||
<?php
|
||
if(isset($bilansInfos[3]['dateCloture'])) {
|
||
print substr($bilansInfos[3]['dateCloture'],6,2).'/'.substr($bilansInfos[3]['dateCloture'],4,2).'/'.substr($bilansInfos[3]['dateCloture'],0,4);?><br/><?php print $bilansInfos[3]['duree']; ?> mois
|
||
<?php }else{ print '-'; } ?>
|
||
</th>
|
||
<th class="date">
|
||
<?php
|
||
if(isset($bilansInfos[2]['dateCloture'])) {
|
||
print substr($bilansInfos[2]['dateCloture'],6,2).'/'.substr($bilansInfos[2]['dateCloture'],4,2).'/'.substr($bilansInfos[2]['dateCloture'],0,4);?><br/><?php print $bilansInfos[2]['duree']; ?> mois
|
||
<?php }else{ print '-'; } ?>
|
||
</th>
|
||
<th class="date">
|
||
<?php
|
||
if(isset($bilansInfos[1]['dateCloture'])) {
|
||
print substr($bilansInfos[1]['dateCloture'],6,2).'/'.substr($bilansInfos[1]['dateCloture'],4,2).'/'.substr($bilansInfos[1]['dateCloture'],0,4);?><br/><?php print $bilansInfos[1]['duree']; ?> mois
|
||
<?php }else{ print '-'; } ?>
|
||
</th>
|
||
<th class="date">
|
||
<?php
|
||
if(isset($bilansInfos[0]['dateCloture'])) {
|
||
print substr($bilansInfos[0]['dateCloture'],6,2).'/'.substr($bilansInfos[0]['dateCloture'],4,2).'/'.substr($bilansInfos[0]['dateCloture'],0,4);?><br/><?php print $bilansInfos[0]['duree']; ?> mois
|
||
<?php }else{ print '-'; } ?>
|
||
</th>
|
||
<th>% T.B.</th>
|
||
</tr>
|
||
</thead>
|
||
<tbody>
|
||
<tr class="subhead">
|
||
<td>Ressources Propres</td>
|
||
<td class="right"><?php dRatio(4,'r79'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r79'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r79'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r79'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r79'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r79','r22')?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>Fonds Propres</td>
|
||
<td class="right"><?php dRatio(4,'r70'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r70'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r70'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r70'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r70'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r70','r22')?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>Provisions Risques</td>
|
||
<td class="right"><?php dRatio(4,'r71'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r71'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r71'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r71'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r71'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r71','r22')?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>Comptes Courants</td>
|
||
<td class="right"><?php dRatio(4,'r72'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r72'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r72'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r72'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r72'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r72','r22')?></td>
|
||
</tr>
|
||
<tr class="subhead">
|
||
<td>Ressources Externes</td>
|
||
<td class="right"><?php dRatio(4,'r90'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r90'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r90'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r90'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r90'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r90','r22')?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>Dettes Financières</td>
|
||
<td class="right"><?php dRatio(4,'r83'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r83'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r83'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r83'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r83'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r83','r22')?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>Dettes Fournisseurs</td>
|
||
<td class="right"><?php dRatio(4,'r84'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r84'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r84'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r84'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r84'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r84','r22')?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>Dettes Fiscales</td>
|
||
<td class="right"><?php dRatio(4,'r85'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r85'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r85'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r85'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r85'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r85','r22')?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>Autres Dettes</td>
|
||
<td class="right"><?php dRatio(4,'r86'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r86'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r86'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r86'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r86'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r86','r22')?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>Trésorerie Passive</td>
|
||
<td class="right"><?php dRatio(4,'r87'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r87'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r87'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r87'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r87'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r87','r22')?></td>
|
||
</tr>
|
||
<tr class="subhead">
|
||
<td>TOTAL PASSIF</td>
|
||
<td class="right"><?php dRatio(4,'r22'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r22'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r22'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r22'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r22'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r22','r22')?></td>
|
||
</tr>
|
||
<tr><td colspan="7"><img src="./graphs/bilan_graph_passif.php?d=<?=urlencode(serialize($dataPassif))?>"/></td></tr>
|
||
|
||
</tbody>
|
||
</table>
|
||
<br/><br/>
|
||
|
||
<div><img class="subentete" src="./img/srub_sig.png" width="576" height="27" /></div>
|
||
|
||
<table class="bilans">
|
||
<thead>
|
||
<tr>
|
||
<th colspan="2">SOLDES INTERMEDIAIRES DE GESTION</th>
|
||
<th class="date">
|
||
<?php
|
||
if(isset($bilansInfos[4]['dateCloture'])) {
|
||
print substr($bilansInfos[4]['dateCloture'],6,2).'/'.substr($bilansInfos[4]['dateCloture'],4,2).'/'.substr($bilansInfos[4]['dateCloture'],0,4);?><br/><?php print $bilansInfos[4]['duree']; ?> mois
|
||
<?php }else{ print '-'; } ?>
|
||
</th>
|
||
<th class="date">
|
||
<?php
|
||
if(isset($bilansInfos[3]['dateCloture'])) {
|
||
print substr($bilansInfos[3]['dateCloture'],6,2).'/'.substr($bilansInfos[3]['dateCloture'],4,2).'/'.substr($bilansInfos[3]['dateCloture'],0,4);?><br/><?php print $bilansInfos[3]['duree']; ?> mois
|
||
<?php }else{ print '-'; } ?>
|
||
</th>
|
||
<th class="date">
|
||
<?php
|
||
if(isset($bilansInfos[2]['dateCloture'])) {
|
||
print substr($bilansInfos[2]['dateCloture'],6,2).'/'.substr($bilansInfos[2]['dateCloture'],4,2).'/'.substr($bilansInfos[2]['dateCloture'],0,4);?><br/><?php print $bilansInfos[2]['duree']; ?> mois
|
||
<?php }else{ print '-'; } ?>
|
||
</th>
|
||
<th class="date">
|
||
<?php
|
||
if(isset($bilansInfos[1]['dateCloture'])) {
|
||
print substr($bilansInfos[1]['dateCloture'],6,2).'/'.substr($bilansInfos[1]['dateCloture'],4,2).'/'.substr($bilansInfos[1]['dateCloture'],0,4);?><br/><?php print $bilansInfos[1]['duree']; ?> mois
|
||
<?php }else{ print '-'; } ?>
|
||
</th>
|
||
<th class="date">
|
||
<?php
|
||
if(isset($bilansInfos[0]['dateCloture'])) {
|
||
print substr($bilansInfos[0]['dateCloture'],6,2).'/'.substr($bilansInfos[0]['dateCloture'],4,2).'/'.substr($bilansInfos[0]['dateCloture'],0,4);?><br/><?php print $bilansInfos[0]['duree']; ?> mois
|
||
<?php }else{ print '-'; } ?>
|
||
</th>
|
||
<th>% C.A.</th>
|
||
</tr>
|
||
</thead>
|
||
<tbody>
|
||
<tr class="subhead">
|
||
<td class="center" colspan="2">CHIFFRE D'AFFAIRES HORS TAXE</td>
|
||
<td class="right"><?php dRatio(4,'r101'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r101'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r101'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r101'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r101'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r101','r101'); ?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>-</td><td>Achat de marchandises, de matières premières</td>
|
||
<td class="right"><?php dRatio(4,'r102'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r102'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r102'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r102'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r102'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r102','r101'); ?></td>
|
||
</tr>
|
||
<tr class="subhead">
|
||
<td class="center" colspan="2">MARGE COMMERCIALE</td>
|
||
<td class="right"><?php dRatio(4,'r110'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r110'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r110'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r110'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r110'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r110','r101'); ?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>+</td><td>Production vendue</td>
|
||
<td class="right"><?php dRatio(4,'r111'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r111'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r111'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r111'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r111'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r111','r101'); ?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>+</td><td>Production immobilisée et stockée</td>
|
||
<td class="right"><?php dRatio(4,'r112'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r112'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r112'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r112'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r112'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r112','r101'); ?></td>
|
||
</tr>
|
||
<tr class="subhead">
|
||
<td class="center" colspan="2">PRODUCTION DE L'EXERCICE</td>
|
||
<td class="right"><?php dRatio(4,'r120'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r120'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r120'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r120'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r120'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r120','r101'); ?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>±</td><td>Variation de stock de marchandises et matières premières</td>
|
||
<td class="right"><?php dRatio(4,'r121'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r121'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r121'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r121'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r121'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r121','r101'); ?></td>
|
||
</tr>
|
||
<tr class="subhead">
|
||
<td class="center" colspan="2">MARGE BRUTE</td>
|
||
<td class="right"><?php dRatio(4,'r122'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r122'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r122'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r122'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r122'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r122','r101'); ?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>-</td><td>Autres charges externes</td>
|
||
<td class="right"><?php dRatio(4,'r123'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r123'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r123'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r123'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r123'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r123','r101'); ?></td>
|
||
</tr>
|
||
<tr class="subhead">
|
||
<td class="center" colspan="2">VALEUR AJOUTÉE</td>
|
||
<td class="right"><?php dRatio(4,'r130'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r130'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r130'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r130'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r130'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r130','r101'); ?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>-</td><td>Charges de personnel</td>
|
||
<td class="right"><?php dRatio(4,'r132'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r132'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r132'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r132'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r132'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r132','r101'); ?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>-</td><td>Impôts, taxes & versements assimilés</td>
|
||
<td class="right"><?php dRatio(4,'r133'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r133'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r133'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r133'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r133'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r133','r101'); ?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>+</td><td>Subventions d'exploitation</td>
|
||
<td class="right"><?php dRatio(4,'r131'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r131'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r131'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r131'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r131'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r131','r101'); ?></td>
|
||
</tr>
|
||
<tr class="subhead">
|
||
<td class="center" colspan="2">EXCÉDENT BRUT D'EXPLOITATION (EBE)</td>
|
||
<td class="right"><?php dRatio(4,'r140'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r140'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r140'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r140'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r140'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r140','r101'); ?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>+</td><td>Autres produits d'exploitation</td>
|
||
<td class="right"><?php dRatio(4,'r141'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r141'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r141'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r141'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r141'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r141','r101'); ?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>-</td><td>Autres charges d'exploitation</td>
|
||
<td class="right"><?php dRatio(4,'r142'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r142'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r142'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r142'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r142'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r142','r101'); ?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>+</td><td>Reprise sur dotations & transferts de charges</td>
|
||
<td class="right"><?php dRatio(4,'r143'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r143'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r143'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r143'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r143'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r143','r101'); ?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>+</td><td>70% Loyer de crédit bail</td>
|
||
<td class="right"><?php dRatio(4,'r144'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r144'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r144'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r144'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r144'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r144','r101'); ?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>-</td><td>Dotations d'exploitation & provisions d'exploitation</td>
|
||
<td class="right"><?php dRatio(4,'r145'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r145'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r145'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r145'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r145'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r145','r101'); ?></td>
|
||
</tr>
|
||
<tr class="subhead">
|
||
<td class="center" colspan="2">RÉSULTAT D'EXPLOITATION</td>
|
||
<td class="right"><?php dRatio(4,'r150'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r150'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r150'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r150'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r150'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r150','r101'); ?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>+</td><td>Produits financiers</td>
|
||
<td class="right"><?php dRatio(4,'r151'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r151'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r151'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r151'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r151'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r151','r101'); ?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>+</td><td>30% Loyer de crédit bail</td>
|
||
<td class="right"><?php dRatio(4,'r152'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r152'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r152'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r152'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r152'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r152','r101'); ?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>+</td><td>Charges financières</td>
|
||
<td class="right"><?php dRatio(4,'r153'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r153'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r153'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r153'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r153'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r153','r101'); ?></td>
|
||
</tr>
|
||
<tr class="subhead">
|
||
<td class="center" colspan="2">RÉSULTAT COURANT AVANT IMPOTS</td>
|
||
<td class="right"><?php dRatio(4,'r170'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r170'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r170'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r170'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r170'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r170','r101'); ?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>+</td><td>Produits exceptionnels</td>
|
||
<td class="right"><?php dRatio(4,'r171'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r171'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r171'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r171'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r171'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r171','r101'); ?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>-</td><td>Charges exceptionnelles</td>
|
||
<td class="right"><?php dRatio(4,'r172'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r172'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r172'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r172'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r172'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r172','r101'); ?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>-</td><td>Impôts sur les bénéfices</td>
|
||
<td class="right"><?php dRatio(4,'r181'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r181'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r181'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r181'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r181'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r181','r101'); ?></td>
|
||
</tr>
|
||
<tr>
|
||
<td>-</td><td>Participation salariale</td>
|
||
<td class="right"><?php dRatio(4,'r182'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r182'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r182'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r182'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r182'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r182','r101'); ?></td>
|
||
</tr>
|
||
<tr class="subhead">
|
||
<td class="center" colspan="2">RÉSULTAT NET</td>
|
||
<td class="right"><?php dRatio(4,'r199'); ?></td>
|
||
<td class="right"><?php dRatio(3,'r199'); ?></td>
|
||
<td class="right"><?php dRatio(2,'r199'); ?></td>
|
||
<td class="right"><?php dRatio(1,'r199'); ?></td>
|
||
<td class="right"><?php dRatio(0,'r199'); ?></td>
|
||
<td class="right"><?php dPercent(0,'r199','r101'); ?></td>
|
||
</tr>
|
||
|
||
</tbody>
|
||
</table>
|
||
|
||
<img src="./graphs/bilan_graph_sig.php?d=<?=urlencode(serialize($dataSIG))?>"/>
|
||
<?php
|
||
}
|
||
?>
|
||
|
||
|
||
</div>
|
||
|
||
|