2010-04-26 14:43:33 +00:00
|
|
|
<?php
|
|
|
|
/**
|
|
|
|
* Etat des inscriptions privilèges
|
|
|
|
* Afficher la liste des privilèges
|
|
|
|
* Si l'entité est sous surveillance privilèges, afficher les détails
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
2010-04-27 08:09:23 +00:00
|
|
|
if (!page_checkParams()) die('Paramètres incorrects !');
|
2010-04-26 14:43:33 +00:00
|
|
|
|
2010-05-21 16:38:12 +00:00
|
|
|
require_once 'common/dates.php';
|
2010-05-24 08:24:36 +00:00
|
|
|
require_once 'scoresws/scoresws.php';
|
2010-04-26 14:43:33 +00:00
|
|
|
|
2010-05-21 16:38:12 +00:00
|
|
|
$detail = isset($_REQUEST['vue']) &&
|
|
|
|
($_REQUEST['vue']=='03' || $_REQUEST['vue']=='04');
|
|
|
|
|
|
|
|
if ($detail){
|
|
|
|
$vue = (string)$_REQUEST['vue'];
|
|
|
|
} else {
|
|
|
|
$vue = '';
|
|
|
|
}
|
2010-05-24 08:24:36 +00:00
|
|
|
|
|
|
|
$O = scorews_privileges($siret, $siren, $detail, $vue);
|
2010-05-21 16:38:12 +00:00
|
|
|
|
2010-05-26 13:47:55 +00:00
|
|
|
FB::log($O, 'privileges');
|
|
|
|
|
2010-05-21 16:38:12 +00:00
|
|
|
if (is_array($O) && count($O)>0){
|
|
|
|
foreach($O as $key => $priv){
|
|
|
|
$numDebiteur = $priv['numDebiteur'];
|
|
|
|
$greffeLib = $priv['greffeLib'];
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
?>
|
2010-05-27 09:24:43 +00:00
|
|
|
<script type="text/javascript">
|
|
|
|
$(document).ready(function(){
|
|
|
|
|
|
|
|
});
|
|
|
|
</script>
|
2010-05-21 16:38:12 +00:00
|
|
|
<div id="center">
|
|
|
|
<?php
|
|
|
|
if ($detail)
|
|
|
|
{
|
|
|
|
?>
|
|
|
|
<h1>Détails des inscriptions d'endettement</h1>
|
|
|
|
<?php
|
|
|
|
} else {
|
|
|
|
?>
|
|
|
|
<h1>Synthèse des inscriptions d'endettement</h1>
|
|
|
|
<?php
|
|
|
|
}
|
|
|
|
?>
|
|
|
|
<div class="blockh2">
|
|
|
|
<div style="margin-left:30px;">
|
|
|
|
<table>
|
|
|
|
<tr>
|
|
|
|
<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="200" class="StyleInfoLib">Raison Sociale</td>
|
|
|
|
<td width="350" class="StyleInfoData"><?=$raisonSociale?></td>
|
|
|
|
</tr>
|
2010-05-27 09:24:43 +00:00
|
|
|
|
|
|
|
<?php
|
|
|
|
if (!empty($numDebiteur))
|
|
|
|
{
|
|
|
|
?>
|
2010-05-21 16:38:12 +00:00
|
|
|
<tr>
|
|
|
|
<td width="200" class="StyleInfoLib">Numéro de débiteur</td>
|
|
|
|
<td width="350" class="StyleInfoData"><?=$numDebiteur?></td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<td width="200" class="StyleInfoLib">Greffe</td>
|
|
|
|
<td width="350" class="StyleInfoData"><?=$greffeLib?></td>
|
|
|
|
</tr>
|
2010-05-27 09:24:43 +00:00
|
|
|
<?php
|
|
|
|
} else {
|
|
|
|
?>
|
|
|
|
<tr>
|
|
|
|
<td colspan="2" width="100%" class="StyleInfoLib">
|
|
|
|
Cette entreprise n'est pas en suivi privilèges.
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
<?php
|
|
|
|
require_once 'surveillance/surveillance.php';
|
|
|
|
if(hasPerm('survpriv')){
|
|
|
|
?>
|
|
|
|
<tr>
|
|
|
|
<td colspan="2" width="100%" class="StyleInfoLib">
|
|
|
|
<?=getSurveillance('privileges', $siret)?>
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
<?php
|
|
|
|
}
|
|
|
|
}
|
|
|
|
?>
|
2010-05-21 16:38:12 +00:00
|
|
|
</table>
|
|
|
|
|
|
|
|
<?php
|
|
|
|
if ($detail){
|
|
|
|
?>
|
|
|
|
<a href="./?page=privileges&siret=<?=$siret?>">Synthese des inscriptions</a><br/>
|
|
|
|
<?php
|
|
|
|
}
|
|
|
|
?>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<?php
|
|
|
|
if ($detail){
|
|
|
|
if ($vue == '03'){
|
|
|
|
?>
|
|
|
|
<h2>Privilèges de la sécurité sociale et des régimes complémentaires</h2>
|
|
|
|
<?php
|
|
|
|
}elseif ($vue == '04'){
|
|
|
|
?>
|
|
|
|
<h2>Privilèges du trésor public</h2>
|
|
|
|
<?php
|
|
|
|
}
|
|
|
|
?>
|
|
|
|
<div class="blockh2">
|
|
|
|
<?php
|
|
|
|
foreach($O as $priv)
|
|
|
|
{
|
|
|
|
?>
|
|
|
|
<table style="border:1px solid;width:100%;margin:5px 0;">
|
|
|
|
<tr>
|
|
|
|
<td style="width:30%;"><i>Inscription du <?=WDate::dateT('Y-m-d', 'd/m/Y',$priv['insDate'])?></i></td>
|
|
|
|
<td style="width:70%;"><i>Numéro <?=$priv['insNum']?></i></td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<td class="StyleInfoLib">Montant de la créance</td>
|
2010-05-26 13:47:55 +00:00
|
|
|
<td><?=number_format($priv['insMontant'], 2, ',', ' ')?> <?=$priv['insDev']?></td>
|
2010-05-21 16:38:12 +00:00
|
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<td class="StyleInfoLib" style="vertical-align:top;">Organisme créancier</td>
|
|
|
|
<td>
|
|
|
|
<?=$priv['creNom']?><br/>
|
|
|
|
<?=$priv['creAdresse1']?>
|
|
|
|
<?=$priv['creAdresse2']?>
|
|
|
|
<?=$priv['creAdresse3']?>
|
|
|
|
<?=$priv['creCP']?>
|
|
|
|
<?=$priv['creVille']?><br/>
|
|
|
|
<?=$priv['crePays']?>
|
|
|
|
<?=$priv['creAutres']?>
|
|
|
|
</td>
|
|
|
|
</tr>
|
2010-05-26 13:47:55 +00:00
|
|
|
|
|
|
|
<?php
|
|
|
|
if (!empty($priv['radDate']) && $priv['radDate']!='0000-00-00' ||
|
|
|
|
!empty($priv['radPartiel']))
|
|
|
|
{
|
|
|
|
?>
|
2010-05-21 16:38:12 +00:00
|
|
|
<tr>
|
|
|
|
<td class="StyleInfoLib" style="vertical-align:top;">Compléments</td>
|
|
|
|
<td>
|
|
|
|
<?php
|
2010-05-24 08:24:36 +00:00
|
|
|
if (!empty($priv['radDate']) && $priv['radDate']!='0000-00-00'){
|
|
|
|
echo 'Radié le '.WDate::dateT('Y-m-d', 'd/m/Y',$priv['radDate']);
|
|
|
|
} elseif (!empty($priv['radPartiel'])){
|
2010-05-21 16:38:12 +00:00
|
|
|
if ($priv['radMention']!='0000-00-00'){
|
2010-05-24 08:24:36 +00:00
|
|
|
echo 'Partiellement radié le '.WDate::dateT('Y-m-d', 'd/m/Y',$priv['radMention']);
|
|
|
|
}
|
|
|
|
if (!empty($priv['radPartMt'])){
|
2010-05-26 13:47:55 +00:00
|
|
|
echo ' pour un montant de '.
|
|
|
|
number_format($priv['radPartMt'], 2, ',', ' ') .
|
|
|
|
' ' . $priv['radDev'];
|
2010-05-21 16:38:12 +00:00
|
|
|
}
|
|
|
|
?>
|
2010-05-24 08:24:36 +00:00
|
|
|
<br/>
|
|
|
|
<?=$priv['radPartiel']?>
|
2010-05-21 16:38:12 +00:00
|
|
|
<?php
|
|
|
|
}
|
|
|
|
?>
|
|
|
|
</td>
|
|
|
|
</tr>
|
2010-05-26 13:47:55 +00:00
|
|
|
<?php
|
|
|
|
}
|
|
|
|
?>
|
|
|
|
|
2010-05-21 16:38:12 +00:00
|
|
|
</table>
|
|
|
|
<?php
|
|
|
|
}
|
|
|
|
?>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
<?php
|
2010-05-27 09:24:43 +00:00
|
|
|
//Synthèse
|
2010-05-21 16:38:12 +00:00
|
|
|
} else {
|
|
|
|
?>
|
|
|
|
|
|
|
|
<h2>Privilèges de la sécurité sociale et des régimes complémentaires</h2>
|
|
|
|
<div class="blockh2">
|
|
|
|
<div style="margin:20px;">
|
|
|
|
<?php
|
|
|
|
if (isset($O['03'])){
|
|
|
|
$priv = $O['03'];
|
|
|
|
?>
|
|
|
|
Greffe du <?=$priv['greffeLib']?> en date du <?=WDate::dateT('Y-m-d','d/m/Y',$priv['dateFraiche'])?><br/>
|
|
|
|
<br/>
|
2010-06-04 13:31:40 +00:00
|
|
|
<?=$priv['nb']?> inscription(s) pour un montant conservé de <?=number_format($priv['insCumul'], 2, ',', ' ')?> €<br/>
|
2010-05-21 16:38:12 +00:00
|
|
|
Dernière inscription par <?=$priv['nomDerCre']?> faîtes le <?=WDate::dateT('Y-m-d','d/m/Y',$priv['dateDerInsc'])?><br/>
|
|
|
|
<br/>
|
|
|
|
<a href="./?page=privileges&siret=<?=$siret?>&vue=03">Voir le détail des inscriptions</a>
|
|
|
|
|
|
|
|
<?php
|
|
|
|
} else {
|
|
|
|
?>
|
|
|
|
Néant.
|
|
|
|
<?php
|
|
|
|
}
|
|
|
|
?>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<h2>Privilèges du trésor public</h2>
|
|
|
|
<div class="blockh2">
|
|
|
|
<div style="margin:20px;">
|
|
|
|
<?php
|
|
|
|
if (isset($O['04'])){
|
|
|
|
$priv = $O['04'];
|
|
|
|
?>
|
|
|
|
Greffe du <?=$priv['greffeLib']?> en date du <?=WDate::dateT('Y-m-d','d/m/Y',$priv['dateFraiche'])?><br/>
|
|
|
|
<br/>
|
2010-06-04 13:31:40 +00:00
|
|
|
<?=$priv['nb']?> inscription(s) pour un montant conservé de <?=number_format($priv['insCumul'], 2, ',', ' ')?> €<br/>
|
2010-05-21 16:38:12 +00:00
|
|
|
Dernière inscription par <?=$priv['nomDerCre']?> faîtes le <?=WDate::dateT('Y-m-d','d/m/Y',$priv['dateDerInsc'])?><br/>
|
|
|
|
<br/>
|
|
|
|
<a href="./?page=privileges&siret=<?=$siret?>&vue=04">Voir le détail des inscriptions</a>
|
|
|
|
<?php
|
|
|
|
} else {
|
|
|
|
?>
|
|
|
|
Néant.
|
|
|
|
<?php
|
|
|
|
}
|
|
|
|
?>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<?php
|
|
|
|
}
|
|
|
|
?>
|
|
|
|
</div>
|