Maj librairie au 23/05/2016

This commit is contained in:
Michael RICOIS 2016-05-23 11:11:55 +02:00
parent 2314188b29
commit b096a34b86
7 changed files with 424 additions and 428 deletions

View File

@ -0,0 +1,57 @@
<?php
return array(
'ACD' => "Action contre/relative au(x) dirigeant(s)",
'ACT' => "Conflit d'actionnaires",
'AFF' => "Demande relative à un affacturage",
'APC' => "Assignation en procédure collective",
'BAN' => "Demande relative au droit bancaire",
'CAU' => "Demande d'intervention de la caution",
'CBA' => "Demande relative au crédit bail",
'CDL' => "Action en concurrence déloyale",
'CES' => "Cession de titres ou de parts sociales",
'COA' => "Demande relative à un contrat assurance",
'CON' => "Demande relative à un contrat",
'CPT' => "Injonction du président pour dépôt des comptes annuels",
'CRN' => "Demande relative à cession/nantissement de créance",
'CTX' => "Contentieux",
'DBA' => "Demande formée contre une banque",
'DCO' => "Action en garantie des vices caches ou en sanction du défaut de conformité",
'DCP' => "Demande d'ouverture de procédure collective",
'DIR' => "Demande(s) relative(s) au(x) dirigeant(s) de la société",
'DIV' => "Divers",
'DOC' => "Demande de production de document(s)",
'DOM' => "Action en dommages et intérêts",
'DSV' => "Demande d'ouverture de procédure de sauvegarde",
'ERR' => "Rectification d'erreur matérielle",
'EXP' => "Expulsion",
'EXT' => "Expertise",
'FCT' => "Demande relative au fonctionnement de l'entité/actionnaires",
'HOC' => "Mandat ad hoc",
'HOM' => "Homologation par le tribunal d'un compromis ou d'une transaction",
'IMP' => "Impayé(s)",
'IND' => "Demande de paiement des indemnités d'assurances dommages",
'INJ' => "Injonction de payer",
'LGF' => "Demande en matière de location gérance du fonds",
'LIC' => "Ordonnance d'autorisation de licenciements",
'LOC' => "Demande relative à un contrat de location (hors immobilier)",
'LSQ' => "Séquestre / Désignation ou Levée de séquestre",
'NAC' => "Nullité d'un acte",
'NAN' => "Demande en matière de nantissement du fonds",
'NCO' => "Nullité d'un contrat",
'NOM' => "Demande de cessation d'utilisation d'un nom ou d'une enseigne",
'NVT' => "Nullité d'une vente",
'ODT' => "Opposition à dissolution entraînant T.U.P.",
'PCL' => "Action, Demande ou Jugement en cours de procédure collective",
'PCV' => "Vente en cours de procédure collective",
'PRT' => "Privilèges",
'RBT' => "Demande de remboursement de prêt ou du solde du compte bancaire",
'RES' => "Action en restitution de la chose, inexécution ou du prix reçu indûment",
'RIN' => "Demande relative/radiation inscription (priv/nantissement...)",
'RRC' => "Demande en réparation suite à rupture brutale relation commerciale",
'RSP' => "Demande en responsabilité",
'SAN' => "Demande de sanctions commerciales",
'TRA' => "Demande relative travaux en bâtiment",
'TSP' => "Demande relative au transport",
'VTE' => "Demande relatives à la vente",
'' => "Affaires diverses",
);

View File

@ -426,7 +426,8 @@ class Metier_Partenaires_MBilans
}
$classWDate = new WDate();
$millesimeDB = $classWDate->dateT('d/m/Y', 'Ymd', $millesime);
$clotureDate = new Zend_Date($millesime, 'dd/MM/yyyy');
$clotureDateSql = $clotureDate->toString('yyyyMMdd');
if ($accesPartenaire) {
// On ne veut pas de bilans "Téléchargés" directement sur Internet
$strSansBilansWeb=' AND partenaire<>7 ';
@ -438,7 +439,7 @@ class Metier_Partenaires_MBilans
$ret = $this->iDb->select('jo.bilans',
'dateProvPartenaire, dateExercice, dateExercicePre, dureeExercice, dureeExercicePre, monnaie, typeBilan, monnaieOrigine, unite, postes, partenaire, id, confidentiel, dateInsert',
"siren='$this->siren' AND typeBilan='$typeBilan' AND dateExercice='$millesimeDB' $strSansBilansWeb", false, MYSQL_ASSOC);
"siren='$this->siren' AND typeBilan='$typeBilan' AND dateExercice='$clotureDateSql' $strSansBilansWeb", false, MYSQL_ASSOC);
if ( $accesPartenaire ) {
$iGreffe = new Metier_Partenaires_MGreffes($this->iDb);
@ -480,10 +481,12 @@ class Metier_Partenaires_MBilans
'partenaire' => $tabBilan['SOURCE'],
);
if (!$this->iDb->insert('jo.bilans', $tabInsert, true)) {
$this->iDb->update('jo.bilans', $tabInsert, "siren='$this->siren' AND typeBilan='$typeBilan' AND dateExercice='$millesimeDB'");
$this->iDb->update('jo.bilans', $tabInsert, "siren='$this->siren' AND typeBilan='$typeBilan' AND dateExercice='$clotureDateSql'");
}
$ret = $this->iDb->select('jo.bilans', 'dateProvPartenaire, dateExercice, dateExercicePre, dureeExercice, dureeExercicePre, monnaie, typeBilan, monnaieOrigine, unite, postes, partenaire, id, confidentiel, dateInsert', "siren='$this->siren' AND typeBilan='$typeBilan' AND dateExercice='$millesimeDB'", true);
$ret = $this->iDb->select('jo.bilans',
'dateProvPartenaire, dateExercice, dateExercicePre, dureeExercice, dureeExercicePre, monnaie, typeBilan, monnaieOrigine, unite, postes, partenaire, id, confidentiel, dateInsert',
"siren='$this->siren' AND typeBilan='$typeBilan' AND dateExercice='$clotureDateSql'", true);
if (count($ret) > 0) {
$bilan = $ret[0];
}
@ -491,14 +494,14 @@ class Metier_Partenaires_MBilans
}
}
// --- Selection du premier bilan
if (count($ret) > 0) {
$bilan = $ret[0];
}
$tabBilan = $tabBilanPre = $bilanPre = array();
if ($bilan !== null)
{
if ($bilan !== null) {
$tabBilan['SIREN'] = $this->siren;
$tabBilan['DATE_FRAICHE_BILAN'] = $bilan['dateProvPartenaire']; // SSAAMMJJ
$tabBilan['DATE_CLOTURE'] = $bilan['dateExercice']; // SSAAMMJJ
@ -514,7 +517,7 @@ class Metier_Partenaires_MBilans
$tabBilan['DATE_BILAN_SD'] = $bilan['dateInsert'];
$tabBilan['TOP_CONFIDENTIEL'] = $bilan['confidentiel'];
// Devise et Unité
// --- Devise et Unité
if ($bilan['monnaie']=='EUR') $monnaie='&euro;'; else $monnaie=$bilan['monnaie'];
switch (strtoupper($bilan['unite'])) {
case 'K': $unite='K'; break;
@ -550,8 +553,7 @@ class Metier_Partenaires_MBilans
}
/** Calcul des valeures NET si l'information est absente en base **/
if ($tabBilan['CONSOLIDE']=='N' || $tabBilan['CONSOLIDE']=='C')
{
if ($tabBilan['CONSOLIDE']=='N' || $tabBilan['CONSOLIDE']=='C') {
if (!isset($tabBilan['AA2']) && isset($tabBilan['AA'])) $tabBilan['AA2']=$tabBilan['AA'];
if (!isset($tabBilan['AC1']) && (isset($tabBilan['AB'])||isset($tabBilan['AC']))) $tabBilan['AC1']=$tabBilan['AB']-$tabBilan['AC'];
if (!isset($tabBilan['AE1']) && (isset($tabBilan['AD'])||isset($tabBilan['AE']))) $tabBilan['AE1']=$tabBilan['AD']-$tabBilan['AE'];
@ -592,8 +594,7 @@ class Metier_Partenaires_MBilans
if (!isset($tabBilan['1A1']) && (isset($tabBilan['CO'])||isset($tabBilan['1A']))) $tabBilan['1A1']=$tabBilan['CO']-$tabBilan['1A'];
}
elseif ($tabBilan['CONSOLIDE']=='S')
{
elseif ($tabBilan['CONSOLIDE']=='S') {
//if (!isset($tabBilan['AC1']) && (isset($tabBilan['AB'])||isset($tabBilan['AC']))) $tabBilan['AC1']=$tabBilan['AB']-$tabBilan['AC'];
if (!isset($tabBilan['013']) && (isset($tabBilan['010'])||isset($tabBilan['012']))) $tabBilan['013']=$tabBilan['010']-$tabBilan['012'];
if (!isset($tabBilan['017']) && (isset($tabBilan['014'])||isset($tabBilan['016']))) $tabBilan['017']=$tabBilan['014']-$tabBilan['016'];
@ -613,352 +614,355 @@ class Metier_Partenaires_MBilans
if (!isset($tabBilan['113']) && (isset($tabBilan['110'])||isset($tabBilan['112']))) $tabBilan['113']=$tabBilan['110']-$tabBilan['112'];
}
/** Y a t'il suffisament d'informations sur le bilan précédent **/
// Bilan précédent existe ?
if ( $bilan['dateExercicePre']*1==0 || $bilan['dureeExercicePre']*1==0
|| ( ($tabBilan['FL1']*1==0 || $tabBilan['EE1']*1==0) && ($tabBilan['CONSOLIDE']=='N' || $tabBilan['CONSOLIDE']=='C') ) // Réel Normal ou Consolidé
|| ( ($tabBilan['NA3']*1==0 || $tabBilan['NP3']*1==0) && ($tabBilan['CONSOLIDE']=='A' || $tabBilan['CONSOLIDE']=='B') ) // Banque ou Assurance
|| ( ($tabBilan['N15']*1==0 || $tabBilan['N32']*1==0) && $tabBilan['CONSOLIDE']=='S' ) // Réel Simplifié
) {
/** Il n'y a aucune information sur le bilan précédent **/
$ret=$this->iDb->select('jo.bilans', 'dateProvPartenaire, dateExercice, dateExercicePre, dureeExercice, dureeExercicePre, monnaie, typeBilan, monnaieOrigine, unite, postes', "siren='$this->siren' AND typeBilan='$typeBilan' AND dateExercice<'$millesimeDB' ORDER BY dateExercice DESC LIMIT 0,1", true);
$bilanPre=$ret[0];
$tabBilan['DATE_CLOTURE_PRE'] = $bilanPre['dateExercice']; // SSAAMMJJ
$tabBilan['DUREE_MOIS_PRE'] = $bilanPre['dureeExercice'];
if ($bilanPre['monnaie']=='EUR') {
$monnaiePre='&euro;';
} else {
$monnaiePre=$bilanPre['monnaie'];
}
switch (strtoupper($bilanPre['unite'])) {
case 'K': $unitePre='K'; break;
case 'U':
case ' ':
case '' : $unitePre=''; break;
case 'M': $unitePre='M'; break;
default: die('Unite Bilan ('. $bilanPre['unite'] .') non prise en charge !'); break;
}
$tabBilanPre['devise'] = $monnaiePre;
$cloturePreDate = $clotureDate->subMonth($bilan['dureeExercice']);
$cloturePreDateSql = $cloturePreDate->toString('yyyyMM');
$tabTmp=explode(';', $bilanPre['postes']);
foreach ($tabTmp as $i=>$strTmp) {
$tabTmp2=explode('=', $strTmp);
if (isset($tabTmp2[1])) {
if ( ($unite=='K' || $unite=='M') && !in_array($tabTmp2[0], array(
'YP', 'YP1', '376', // Effectifs 2033 et 2050
'M2G', 'M2H', // Autres effectifs
'ZK', 'ZK1', // Taux
'IJ', 'JG', 'JH', 'JJ', 'ZR', // pour holding/ste mere
'XP' // Numero de centre de gestion agréé
) ) ) {
if ($unite=='K') {
$tabBilanPre[$tabTmp2[0]]=$tabTmp2[1]*1000;
} else if ($unite=='M') {
$tabBilanPre[$tabTmp2[0]]=$tabTmp2[1]*1000000;
// --- Recherche des infos du bilan précédent
$ret = $this->iDb->select('jo.bilans',
'dateProvPartenaire, dateExercice, dateExercicePre, dureeExercice, dureeExercicePre, monnaie, typeBilan, monnaieOrigine, unite, postes',
"siren='$this->siren' AND typeBilan='$typeBilan' AND dateExercice BETWEEN '".$cloturePreDateSql."-01' AND '".$cloturePreDateSql."-31' ORDER BY dateExercice DESC LIMIT 0,1", true);
if (count($ret) > 0) {
$bilanPre = $ret[0];
$tabBilan['DATE_CLOTURE_PRE'] = $bilanPre['dateExercice']; // SSAAMMJJ
$tabBilan['DUREE_MOIS_PRE'] = $bilanPre['dureeExercice'];
if ($bilanPre['monnaie']=='EUR') {
$monnaiePre='&euro;';
} else {
$monnaiePre=$bilanPre['monnaie'];
}
switch (strtoupper($bilanPre['unite'])) {
case 'K': $unitePre='K'; break;
case 'U':
case ' ':
case '' : $unitePre=''; break;
case 'M': $unitePre='M'; break;
default: die('Unite Bilan ('. $bilanPre['unite'] .') non prise en charge !'); break;
}
$tabBilanPre['devise'] = $monnaiePre;
$tabTmp=explode(';', $bilanPre['postes']);
foreach ($tabTmp as $i=>$strTmp) {
$tabTmp2=explode('=', $strTmp);
if (isset($tabTmp2[1])) {
if ( ($unite=='K' || $unite=='M') && !in_array($tabTmp2[0], array(
'YP', 'YP1', '376', // Effectifs 2033 et 2050
'M2G', 'M2H', // Autres effectifs
'ZK', 'ZK1', // Taux
'IJ', 'JG', 'JH', 'JJ', 'ZR', // pour holding/ste mere
'XP' // Numero de centre de gestion agréé
) ) ) {
if ($unite=='K') {
$tabBilanPre[$tabTmp2[0]]=$tabTmp2[1]*1000;
} else if ($unite=='M') {
$tabBilanPre[$tabTmp2[0]]=$tabTmp2[1]*1000000;
}
} else {
$tabBilanPre[$tabTmp2[0]]=$tabTmp2[1];
}
} else {
$tabBilanPre[$tabTmp2[0]]=$tabTmp2[1];
}
}
}
/** Calcul des valeures NET N-1 si l'information est absente du bilan N-1 en base **/
if ($tabBilan['CONSOLIDE']=='N' || $tabBilan['CONSOLIDE']=='C')
{
if (!isset($tabBilanPre['AA2']) && isset($tabBilanPre['AA'])) $tabBilanPre['AA2']=$tabBilanPre['AA'];
if (!isset($tabBilanPre['AC1']) && (isset($tabBilanPre['AB'])||isset($tabBilanPre['AC']))) $tabBilanPre['AC1']=$tabBilanPre['AB']-$tabBilanPre['AC'];
if (!isset($tabBilanPre['AE1']) && (isset($tabBilanPre['AD'])||isset($tabBilanPre['AE']))) $tabBilanPre['AE1']=$tabBilanPre['AD']-$tabBilanPre['AE'];
if (!isset($tabBilanPre['AG1']) && (isset($tabBilanPre['AF'])||isset($tabBilanPre['AG']))) $tabBilanPre['AG1']=$tabBilanPre['AF']-$tabBilanPre['AG'];
if (!isset($tabBilanPre['AI1']) && (isset($tabBilanPre['AH'])||isset($tabBilanPre['AI']))) $tabBilanPre['AI1']=$tabBilanPre['AH']-$tabBilanPre['AI'];
if (!isset($tabBilanPre['AK1']) && (isset($tabBilanPre['AJ'])||isset($tabBilanPre['AK']))) $tabBilanPre['AK1']=$tabBilanPre['AJ']-$tabBilanPre['AK'];
if (!isset($tabBilanPre['AM1']) && (isset($tabBilanPre['AL'])||isset($tabBilanPre['AM']))) $tabBilanPre['AM1']=$tabBilanPre['AL']-$tabBilanPre['AM'];
if (!isset($tabBilanPre['AO1']) && (isset($tabBilanPre['AN'])||isset($tabBilanPre['AO']))) $tabBilanPre['AO1']=$tabBilanPre['AN']-$tabBilanPre['AO'];
if (!isset($tabBilanPre['AQ1']) && (isset($tabBilanPre['AP'])||isset($tabBilanPre['AQ']))) $tabBilanPre['AQ1']=$tabBilanPre['AP']-$tabBilanPre['AQ'];
if (!isset($tabBilanPre['AS1']) && (isset($tabBilanPre['AR'])||isset($tabBilanPre['AS']))) $tabBilanPre['AS1']=$tabBilanPre['AR']-$tabBilanPre['AS'];
if (!isset($tabBilanPre['AU1']) && (isset($tabBilanPre['AT'])||isset($tabBilanPre['AU']))) $tabBilanPre['AU1']=$tabBilanPre['AT']-$tabBilanPre['AU'];
if (!isset($tabBilanPre['AW1']) && (isset($tabBilanPre['AV'])||isset($tabBilanPre['AW']))) $tabBilanPre['AW1']=$tabBilanPre['AV']-$tabBilanPre['AW'];
if (!isset($tabBilanPre['AY1']) && (isset($tabBilanPre['AX'])||isset($tabBilanPre['AY']))) $tabBilanPre['AY1']=$tabBilanPre['AX']-$tabBilanPre['AY'];
if (!isset($tabBilanPre['CT1']) && (isset($tabBilanPre['CS'])||isset($tabBilanPre['CT']))) $tabBilanPre['CT1']=$tabBilanPre['CS']-$tabBilanPre['CT'];
if (!isset($tabBilanPre['CV1']) && (isset($tabBilanPre['CU'])||isset($tabBilanPre['CV']))) $tabBilanPre['CV1']=$tabBilanPre['CU']-$tabBilanPre['CV'];
if (!isset($tabBilanPre['BC1']) && (isset($tabBilanPre['BB'])||isset($tabBilanPre['BC']))) $tabBilanPre['BC1']=$tabBilanPre['BB']-$tabBilanPre['BC'];
if (!isset($tabBilanPre['BE1']) && (isset($tabBilanPre['BD'])||isset($tabBilanPre['BE']))) $tabBilanPre['BE1']=$tabBilanPre['BD']-$tabBilanPre['BE'];
if (!isset($tabBilanPre['BG1']) && (isset($tabBilanPre['BF'])||isset($tabBilanPre['BG']))) $tabBilanPre['BG1']=$tabBilanPre['BF']-$tabBilanPre['BG'];
if (!isset($tabBilanPre['BI1']) && (isset($tabBilanPre['BH'])||isset($tabBilanPre['BI']))) $tabBilanPre['BI1']=$tabBilanPre['BH']-$tabBilanPre['BI'];
if (!isset($tabBilanPre['BK1']) && (isset($tabBilanPre['BJ'])||isset($tabBilanPre['BK']))) $tabBilanPre['BK1']=$tabBilanPre['BJ']-$tabBilanPre['BK'];
if (!isset($tabBilanPre['BM1']) && (isset($tabBilanPre['BL'])||isset($tabBilanPre['BM']))) $tabBilanPre['BM1']=$tabBilanPre['BL']-$tabBilanPre['BM'];
if (!isset($tabBilanPre['BO1']) && (isset($tabBilanPre['BN'])||isset($tabBilanPre['BO']))) $tabBilanPre['BO1']=$tabBilanPre['BN']-$tabBilanPre['BO'];
if (!isset($tabBilanPre['BQ1']) && (isset($tabBilanPre['BP'])||isset($tabBilanPre['BQ']))) $tabBilanPre['BQ1']=$tabBilanPre['BP']-$tabBilanPre['BQ'];
if (!isset($tabBilanPre['BS1']) && (isset($tabBilanPre['BR'])||isset($tabBilanPre['BS']))) $tabBilanPre['BS1']=$tabBilanPre['BR']-$tabBilanPre['BS'];
if (!isset($tabBilanPre['BU1']) && (isset($tabBilanPre['BT'])||isset($tabBilanPre['BU']))) $tabBilanPre['BU1']=$tabBilanPre['BT']-$tabBilanPre['BU'];
if (!isset($tabBilanPre['BW1']) && (isset($tabBilanPre['BV'])||isset($tabBilanPre['BW']))) $tabBilanPre['BW1']=$tabBilanPre['BV']-$tabBilanPre['BW'];
if (!isset($tabBilanPre['BY1']) && (isset($tabBilanPre['BX'])||isset($tabBilanPre['BY']))) $tabBilanPre['BY1']=$tabBilanPre['BX']-$tabBilanPre['BY'];
if (!isset($tabBilanPre['CA1']) && (isset($tabBilanPre['BZ'])||isset($tabBilanPre['CA']))) $tabBilanPre['CA1']=$tabBilanPre['BZ']-$tabBilanPre['CA'];
if (!isset($tabBilanPre['CC1']) && (isset($tabBilanPre['CB'])||isset($tabBilanPre['CC']))) $tabBilanPre['CC1']=$tabBilanPre['CB']-$tabBilanPre['CC'];
if (!isset($tabBilanPre['CE1']) && (isset($tabBilanPre['CD'])||isset($tabBilanPre['CE']))) $tabBilanPre['CE1']=$tabBilanPre['CD']-$tabBilanPre['CE'];
if (!isset($tabBilanPre['CG1']) && (isset($tabBilanPre['CF'])||isset($tabBilanPre['CG']))) $tabBilanPre['CG1']=$tabBilanPre['CF']-$tabBilanPre['CG'];
if (!isset($tabBilanPre['CI1']) && (isset($tabBilanPre['CH'])||isset($tabBilanPre['CI']))) $tabBilanPre['CI1']=$tabBilanPre['CH']-$tabBilanPre['CI'];
if (!isset($tabBilanPre['CK1']) && (isset($tabBilanPre['CJ'])||isset($tabBilanPre['CK']))) $tabBilanPre['CK1']=$tabBilanPre['CJ']-$tabBilanPre['CK'];
// --- Calcul des valeures NET N-1 si l'information est absente du bilan N-1 en base
if ($tabBilan['CONSOLIDE']=='N' || $tabBilan['CONSOLIDE']=='C') {
if (!isset($tabBilanPre['AA2']) && isset($tabBilanPre['AA'])) $tabBilanPre['AA2']=$tabBilanPre['AA'];
if (!isset($tabBilanPre['AC1']) && (isset($tabBilanPre['AB'])||isset($tabBilanPre['AC']))) $tabBilanPre['AC1']=$tabBilanPre['AB']-$tabBilanPre['AC'];
if (!isset($tabBilanPre['AE1']) && (isset($tabBilanPre['AD'])||isset($tabBilanPre['AE']))) $tabBilanPre['AE1']=$tabBilanPre['AD']-$tabBilanPre['AE'];
if (!isset($tabBilanPre['AG1']) && (isset($tabBilanPre['AF'])||isset($tabBilanPre['AG']))) $tabBilanPre['AG1']=$tabBilanPre['AF']-$tabBilanPre['AG'];
if (!isset($tabBilanPre['AI1']) && (isset($tabBilanPre['AH'])||isset($tabBilanPre['AI']))) $tabBilanPre['AI1']=$tabBilanPre['AH']-$tabBilanPre['AI'];
if (!isset($tabBilanPre['AK1']) && (isset($tabBilanPre['AJ'])||isset($tabBilanPre['AK']))) $tabBilanPre['AK1']=$tabBilanPre['AJ']-$tabBilanPre['AK'];
if (!isset($tabBilanPre['AM1']) && (isset($tabBilanPre['AL'])||isset($tabBilanPre['AM']))) $tabBilanPre['AM1']=$tabBilanPre['AL']-$tabBilanPre['AM'];
if (!isset($tabBilanPre['AO1']) && (isset($tabBilanPre['AN'])||isset($tabBilanPre['AO']))) $tabBilanPre['AO1']=$tabBilanPre['AN']-$tabBilanPre['AO'];
if (!isset($tabBilanPre['AQ1']) && (isset($tabBilanPre['AP'])||isset($tabBilanPre['AQ']))) $tabBilanPre['AQ1']=$tabBilanPre['AP']-$tabBilanPre['AQ'];
if (!isset($tabBilanPre['AS1']) && (isset($tabBilanPre['AR'])||isset($tabBilanPre['AS']))) $tabBilanPre['AS1']=$tabBilanPre['AR']-$tabBilanPre['AS'];
if (!isset($tabBilanPre['AU1']) && (isset($tabBilanPre['AT'])||isset($tabBilanPre['AU']))) $tabBilanPre['AU1']=$tabBilanPre['AT']-$tabBilanPre['AU'];
if (!isset($tabBilanPre['AW1']) && (isset($tabBilanPre['AV'])||isset($tabBilanPre['AW']))) $tabBilanPre['AW1']=$tabBilanPre['AV']-$tabBilanPre['AW'];
if (!isset($tabBilanPre['AY1']) && (isset($tabBilanPre['AX'])||isset($tabBilanPre['AY']))) $tabBilanPre['AY1']=$tabBilanPre['AX']-$tabBilanPre['AY'];
if (!isset($tabBilanPre['CT1']) && (isset($tabBilanPre['CS'])||isset($tabBilanPre['CT']))) $tabBilanPre['CT1']=$tabBilanPre['CS']-$tabBilanPre['CT'];
if (!isset($tabBilanPre['CV1']) && (isset($tabBilanPre['CU'])||isset($tabBilanPre['CV']))) $tabBilanPre['CV1']=$tabBilanPre['CU']-$tabBilanPre['CV'];
if (!isset($tabBilanPre['BC1']) && (isset($tabBilanPre['BB'])||isset($tabBilanPre['BC']))) $tabBilanPre['BC1']=$tabBilanPre['BB']-$tabBilanPre['BC'];
if (!isset($tabBilanPre['BE1']) && (isset($tabBilanPre['BD'])||isset($tabBilanPre['BE']))) $tabBilanPre['BE1']=$tabBilanPre['BD']-$tabBilanPre['BE'];
if (!isset($tabBilanPre['BG1']) && (isset($tabBilanPre['BF'])||isset($tabBilanPre['BG']))) $tabBilanPre['BG1']=$tabBilanPre['BF']-$tabBilanPre['BG'];
if (!isset($tabBilanPre['BI1']) && (isset($tabBilanPre['BH'])||isset($tabBilanPre['BI']))) $tabBilanPre['BI1']=$tabBilanPre['BH']-$tabBilanPre['BI'];
if (!isset($tabBilanPre['BK1']) && (isset($tabBilanPre['BJ'])||isset($tabBilanPre['BK']))) $tabBilanPre['BK1']=$tabBilanPre['BJ']-$tabBilanPre['BK'];
if (!isset($tabBilanPre['BM1']) && (isset($tabBilanPre['BL'])||isset($tabBilanPre['BM']))) $tabBilanPre['BM1']=$tabBilanPre['BL']-$tabBilanPre['BM'];
if (!isset($tabBilanPre['BO1']) && (isset($tabBilanPre['BN'])||isset($tabBilanPre['BO']))) $tabBilanPre['BO1']=$tabBilanPre['BN']-$tabBilanPre['BO'];
if (!isset($tabBilanPre['BQ1']) && (isset($tabBilanPre['BP'])||isset($tabBilanPre['BQ']))) $tabBilanPre['BQ1']=$tabBilanPre['BP']-$tabBilanPre['BQ'];
if (!isset($tabBilanPre['BS1']) && (isset($tabBilanPre['BR'])||isset($tabBilanPre['BS']))) $tabBilanPre['BS1']=$tabBilanPre['BR']-$tabBilanPre['BS'];
if (!isset($tabBilanPre['BU1']) && (isset($tabBilanPre['BT'])||isset($tabBilanPre['BU']))) $tabBilanPre['BU1']=$tabBilanPre['BT']-$tabBilanPre['BU'];
if (!isset($tabBilanPre['BW1']) && (isset($tabBilanPre['BV'])||isset($tabBilanPre['BW']))) $tabBilanPre['BW1']=$tabBilanPre['BV']-$tabBilanPre['BW'];
if (!isset($tabBilanPre['BY1']) && (isset($tabBilanPre['BX'])||isset($tabBilanPre['BY']))) $tabBilanPre['BY1']=$tabBilanPre['BX']-$tabBilanPre['BY'];
if (!isset($tabBilanPre['CA1']) && (isset($tabBilanPre['BZ'])||isset($tabBilanPre['CA']))) $tabBilanPre['CA1']=$tabBilanPre['BZ']-$tabBilanPre['CA'];
if (!isset($tabBilanPre['CC1']) && (isset($tabBilanPre['CB'])||isset($tabBilanPre['CC']))) $tabBilanPre['CC1']=$tabBilanPre['CB']-$tabBilanPre['CC'];
if (!isset($tabBilanPre['CE1']) && (isset($tabBilanPre['CD'])||isset($tabBilanPre['CE']))) $tabBilanPre['CE1']=$tabBilanPre['CD']-$tabBilanPre['CE'];
if (!isset($tabBilanPre['CG1']) && (isset($tabBilanPre['CF'])||isset($tabBilanPre['CG']))) $tabBilanPre['CG1']=$tabBilanPre['CF']-$tabBilanPre['CG'];
if (!isset($tabBilanPre['CI1']) && (isset($tabBilanPre['CH'])||isset($tabBilanPre['CI']))) $tabBilanPre['CI1']=$tabBilanPre['CH']-$tabBilanPre['CI'];
if (!isset($tabBilanPre['CK1']) && (isset($tabBilanPre['CJ'])||isset($tabBilanPre['CK']))) $tabBilanPre['CK1']=$tabBilanPre['CJ']-$tabBilanPre['CK'];
if (!isset($tabBilanPre['CL2']) && isset($tabBilanPre['CL'])) $tabBilanPre['CL2']=$tabBilanPre['CL'];
if (!isset($tabBilanPre['CM2']) && isset($tabBilanPre['CM'])) $tabBilanPre['CM2']=$tabBilanPre['CM'];
if (!isset($tabBilanPre['CN2']) && isset($tabBilanPre['CN'])) $tabBilanPre['CN2']=$tabBilanPre['CN'];
if (!isset($tabBilanPre['CL2']) && isset($tabBilanPre['CL'])) $tabBilanPre['CL2']=$tabBilanPre['CL'];
if (!isset($tabBilanPre['CM2']) && isset($tabBilanPre['CM'])) $tabBilanPre['CM2']=$tabBilanPre['CM'];
if (!isset($tabBilanPre['CN2']) && isset($tabBilanPre['CN'])) $tabBilanPre['CN2']=$tabBilanPre['CN'];
if (!isset($tabBilanPre['1A1']) && (isset($tabBilanPre['CO'])||isset($tabBilanPre['1A']))) $tabBilanPre['1A1']=$tabBilanPre['CO']-$tabBilanPre['1A'];
if (!isset($tabBilanPre['1A1']) && (isset($tabBilanPre['CO'])||isset($tabBilanPre['1A']))) $tabBilanPre['1A1']=$tabBilanPre['CO']-$tabBilanPre['1A'];
/** Reprises des valeures N-1 si l'information est absente en base **/
// Actif
if (!isset($tabBilan['AA3']) && isset($tabBilanPre['AA2'])) $tabBilan['AA3']=$tabBilanPre['AA2'];
if (!isset($tabBilan['AC2']) && isset($tabBilanPre['AC1'])) $tabBilan['AC2']=$tabBilanPre['AC1'];
if (!isset($tabBilan['AE2']) && isset($tabBilanPre['AE1'])) $tabBilan['AE2']=$tabBilanPre['AE1'];
if (!isset($tabBilan['AG2']) && isset($tabBilanPre['AG1'])) $tabBilan['AG2']=$tabBilanPre['AG1'];
if (!isset($tabBilan['AI2']) && isset($tabBilanPre['AI1'])) $tabBilan['AI2']=$tabBilanPre['AI1'];
if (!isset($tabBilan['AK2']) && isset($tabBilanPre['AK1'])) $tabBilan['AK2']=$tabBilanPre['AK1'];
if (!isset($tabBilan['AM2']) && isset($tabBilanPre['AM1'])) $tabBilan['AM2']=$tabBilanPre['AM1'];
if (!isset($tabBilan['AO2']) && isset($tabBilanPre['AO1'])) $tabBilan['AO2']=$tabBilanPre['AO1'];
if (!isset($tabBilan['AQ2']) && isset($tabBilanPre['AQ1'])) $tabBilan['AQ2']=$tabBilanPre['AQ1'];
if (!isset($tabBilan['AS2']) && isset($tabBilanPre['AS1'])) $tabBilan['AS2']=$tabBilanPre['AS1'];
if (!isset($tabBilan['AU2']) && isset($tabBilanPre['AU1'])) $tabBilan['AU2']=$tabBilanPre['AU1'];
if (!isset($tabBilan['AW2']) && isset($tabBilanPre['AW1'])) $tabBilan['AW2']=$tabBilanPre['AW1'];
if (!isset($tabBilan['AY2']) && isset($tabBilanPre['AY1'])) $tabBilan['AY2']=$tabBilanPre['AY1'];
if (!isset($tabBilan['CT2']) && isset($tabBilanPre['CT1'])) $tabBilan['CT2']=$tabBilanPre['CT1'];
if (!isset($tabBilan['CV2']) && isset($tabBilanPre['CV1'])) $tabBilan['CV2']=$tabBilanPre['CV1'];
if (!isset($tabBilan['BC2']) && isset($tabBilanPre['BC1'])) $tabBilan['BC2']=$tabBilanPre['BC1'];
if (!isset($tabBilan['BE2']) && isset($tabBilanPre['BE1'])) $tabBilan['BE2']=$tabBilanPre['BE1'];
if (!isset($tabBilan['BG2']) && isset($tabBilanPre['BG1'])) $tabBilan['BG2']=$tabBilanPre['BG1'];
if (!isset($tabBilan['BI2']) && isset($tabBilanPre['BI1'])) $tabBilan['BI2']=$tabBilanPre['BI1'];
if (!isset($tabBilan['BK2']) && isset($tabBilanPre['BK1'])) $tabBilan['BK2']=$tabBilanPre['BK1'];
if (!isset($tabBilan['BM2']) && isset($tabBilanPre['BM1'])) $tabBilan['BM2']=$tabBilanPre['BM1'];
if (!isset($tabBilan['BO2']) && isset($tabBilanPre['BO1'])) $tabBilan['BO2']=$tabBilanPre['BO1'];
if (!isset($tabBilan['BQ2']) && isset($tabBilanPre['BQ1'])) $tabBilan['BQ2']=$tabBilanPre['BQ1'];
if (!isset($tabBilan['BS2']) && isset($tabBilanPre['BS1'])) $tabBilan['BS2']=$tabBilanPre['BS1'];
if (!isset($tabBilan['BU2']) && isset($tabBilanPre['BU1'])) $tabBilan['BU2']=$tabBilanPre['BU1'];
if (!isset($tabBilan['BW2']) && isset($tabBilanPre['BW1'])) $tabBilan['BW2']=$tabBilanPre['BW1'];
if (!isset($tabBilan['BY2']) && isset($tabBilanPre['BY1'])) $tabBilan['BY2']=$tabBilanPre['BY1'];
if (!isset($tabBilan['CA2']) && isset($tabBilanPre['CA1'])) $tabBilan['CA2']=$tabBilanPre['CA1'];
if (!isset($tabBilan['CC2']) && isset($tabBilanPre['CC1'])) $tabBilan['CC2']=$tabBilanPre['CC1'];
if (!isset($tabBilan['CE2']) && isset($tabBilanPre['CE1'])) $tabBilan['CE2']=$tabBilanPre['CE1'];
if (!isset($tabBilan['CG2']) && isset($tabBilanPre['CG1'])) $tabBilan['CG2']=$tabBilanPre['CG1'];
if (!isset($tabBilan['CI2']) && isset($tabBilanPre['CI1'])) $tabBilan['CI2']=$tabBilanPre['CI1'];
if (!isset($tabBilan['CK2']) && isset($tabBilanPre['CK1'])) $tabBilan['CK2']=$tabBilanPre['CK1'];
if (!isset($tabBilan['CL3']) && isset($tabBilanPre['CL2'])) $tabBilan['CL3']=$tabBilanPre['CL2'];
if (!isset($tabBilan['CM3']) && isset($tabBilanPre['CM2'])) $tabBilan['CM3']=$tabBilanPre['CM2'];
if (!isset($tabBilan['CN3']) && isset($tabBilanPre['CN2'])) $tabBilan['CN3']=$tabBilanPre['CN2'];
if (!isset($tabBilan['1A2']) && isset($tabBilanPre['1A1'])) $tabBilan['1A2']=$tabBilanPre['1A1'];
// Passif
if (!isset($tabBilan['DA1']) && isset($tabBilanPre['DA'])) $tabBilan['DA1']=$tabBilanPre['DA'];
if (!isset($tabBilan['DB1']) && isset($tabBilanPre['DB'])) $tabBilan['DB1']=$tabBilanPre['DB'];
if (!isset($tabBilan['DC1']) && isset($tabBilanPre['DC'])) $tabBilan['DC1']=$tabBilanPre['DC'];
if (!isset($tabBilan['DD1']) && isset($tabBilanPre['DD'])) $tabBilan['DD1']=$tabBilanPre['DD'];
if (!isset($tabBilan['DE1']) && isset($tabBilanPre['DE'])) $tabBilan['DE1']=$tabBilanPre['DE'];
if (!isset($tabBilan['DF1']) && isset($tabBilanPre['DF'])) $tabBilan['DF1']=$tabBilanPre['DF'];
if (!isset($tabBilan['DG1']) && isset($tabBilanPre['DG'])) $tabBilan['DG1']=$tabBilanPre['DG'];
if (!isset($tabBilan['DH1']) && isset($tabBilanPre['DH'])) $tabBilan['DH1']=$tabBilanPre['DH'];
if (!isset($tabBilan['DI1']) && isset($tabBilanPre['DI'])) $tabBilan['DI1']=$tabBilanPre['DI'];
if (!isset($tabBilan['DJ1']) && isset($tabBilanPre['DJ'])) $tabBilan['DJ1']=$tabBilanPre['DJ'];
if (!isset($tabBilan['DK1']) && isset($tabBilanPre['DK'])) $tabBilan['DK1']=$tabBilanPre['DK'];
if (!isset($tabBilan['DL1']) && isset($tabBilanPre['DL'])) $tabBilan['DL1']=$tabBilanPre['DL'];
if (!isset($tabBilan['DM1']) && isset($tabBilanPre['DM'])) $tabBilan['DM1']=$tabBilanPre['DM'];
if (!isset($tabBilan['DN1']) && isset($tabBilanPre['DN'])) $tabBilan['DN1']=$tabBilanPre['DN'];
if (!isset($tabBilan['DO1']) && isset($tabBilanPre['DO'])) $tabBilan['DO1']=$tabBilanPre['DO'];
if (!isset($tabBilan['DP1']) && isset($tabBilanPre['DP'])) $tabBilan['DP1']=$tabBilanPre['DP'];
if (!isset($tabBilan['DQ1']) && isset($tabBilanPre['DQ'])) $tabBilan['DQ1']=$tabBilanPre['DQ'];
if (!isset($tabBilan['DR1']) && isset($tabBilanPre['DR'])) $tabBilan['DR1']=$tabBilanPre['DR'];
if (!isset($tabBilan['DS1']) && isset($tabBilanPre['DS'])) $tabBilan['DS1']=$tabBilanPre['DS'];
if (!isset($tabBilan['DT1']) && isset($tabBilanPre['DT'])) $tabBilan['DT1']=$tabBilanPre['DT'];
if (!isset($tabBilan['DU1']) && isset($tabBilanPre['DU'])) $tabBilan['DU1']=$tabBilanPre['DU'];
if (!isset($tabBilan['DV1']) && isset($tabBilanPre['DV'])) $tabBilan['DV1']=$tabBilanPre['DV'];
if (!isset($tabBilan['DW1']) && isset($tabBilanPre['DW'])) $tabBilan['DW1']=$tabBilanPre['DW'];
if (!isset($tabBilan['DX1']) && isset($tabBilanPre['DX'])) $tabBilan['DX1']=$tabBilanPre['DX'];
if (!isset($tabBilan['DY1']) && isset($tabBilanPre['DY'])) $tabBilan['DY1']=$tabBilanPre['DY'];
if (!isset($tabBilan['DZ1']) && isset($tabBilanPre['DZ'])) $tabBilan['DZ1']=$tabBilanPre['DZ'];
if (!isset($tabBilan['EA1']) && isset($tabBilanPre['EA'])) $tabBilan['EA1']=$tabBilanPre['EA'];
if (!isset($tabBilan['EB1']) && isset($tabBilanPre['EB'])) $tabBilan['EB1']=$tabBilanPre['EB'];
if (!isset($tabBilan['EC1']) && isset($tabBilanPre['EC'])) $tabBilan['EC1']=$tabBilanPre['EC'];
if (!isset($tabBilan['ED1']) && isset($tabBilanPre['ED'])) $tabBilan['ED1']=$tabBilanPre['ED'];
if (!isset($tabBilan['EE1']) && isset($tabBilanPre['EE'])) $tabBilan['EE1']=$tabBilanPre['EE'];
if (!isset($tabBilan['1B1']) && isset($tabBilanPre['1B'])) $tabBilan['1B1']=$tabBilanPre['1B'];
if (!isset($tabBilan['1C1']) && isset($tabBilanPre['1C'])) $tabBilan['1C1']=$tabBilanPre['1C'];
if (!isset($tabBilan['1D1']) && isset($tabBilanPre['1D'])) $tabBilan['1D1']=$tabBilanPre['1D'];
if (!isset($tabBilan['1E1']) && isset($tabBilanPre['1E'])) $tabBilan['1E1']=$tabBilanPre['1E'];
if (!isset($tabBilan['EF1']) && isset($tabBilanPre['EF'])) $tabBilan['EF1']=$tabBilanPre['EF'];
if (!isset($tabBilan['EG1']) && isset($tabBilanPre['EG'])) $tabBilan['EG1']=$tabBilanPre['EG'];
if (!isset($tabBilan['EH1']) && isset($tabBilanPre['EH'])) $tabBilan['EH1']=$tabBilanPre['EH'];
// Compte de Résultats
if (!isset($tabBilan['FC1']) && isset($tabBilanPre['FC'])) $tabBilan['FC1']=$tabBilanPre['FC'];
if (!isset($tabBilan['FF1']) && isset($tabBilanPre['FF'])) $tabBilan['FF1']=$tabBilanPre['FF'];
if (!isset($tabBilan['FI1']) && isset($tabBilanPre['FI'])) $tabBilan['FI1']=$tabBilanPre['FI'];
if (!isset($tabBilan['FL1']) && isset($tabBilanPre['FL'])) $tabBilan['FL1']=$tabBilanPre['FL'];
if (!isset($tabBilan['FM1']) && isset($tabBilanPre['FM'])) $tabBilan['FM1']=$tabBilanPre['FM'];
if (!isset($tabBilan['FN1']) && isset($tabBilanPre['FN'])) $tabBilan['FN1']=$tabBilanPre['FN'];
if (!isset($tabBilan['FO1']) && isset($tabBilanPre['FO'])) $tabBilan['FO1']=$tabBilanPre['FO'];
if (!isset($tabBilan['FP1']) && isset($tabBilanPre['FP'])) $tabBilan['FP1']=$tabBilanPre['FP'];
if (!isset($tabBilan['FQ1']) && isset($tabBilanPre['FQ'])) $tabBilan['FQ1']=$tabBilanPre['FQ'];
if (!isset($tabBilan['FR1']) && isset($tabBilanPre['FR'])) $tabBilan['FR1']=$tabBilanPre['FR'];
if (!isset($tabBilan['FS1']) && isset($tabBilanPre['FS'])) $tabBilan['FS1']=$tabBilanPre['FS'];
if (!isset($tabBilan['FT1']) && isset($tabBilanPre['FT'])) $tabBilan['FT1']=$tabBilanPre['FT'];
if (!isset($tabBilan['FU1']) && isset($tabBilanPre['FU'])) $tabBilan['FU1']=$tabBilanPre['FU'];
if (!isset($tabBilan['FV1']) && isset($tabBilanPre['FV'])) $tabBilan['FV1']=$tabBilanPre['FV'];
if (!isset($tabBilan['FW1']) && isset($tabBilanPre['FW'])) $tabBilan['FW1']=$tabBilanPre['FW'];
if (!isset($tabBilan['FX1']) && isset($tabBilanPre['FX'])) $tabBilan['FX1']=$tabBilanPre['FX'];
if (!isset($tabBilan['FY1']) && isset($tabBilanPre['FY'])) $tabBilan['FY1']=$tabBilanPre['FY'];
if (!isset($tabBilan['FZ1']) && isset($tabBilanPre['FZ'])) $tabBilan['FZ1']=$tabBilanPre['FZ'];
if (!isset($tabBilan['GA1']) && isset($tabBilanPre['GA'])) $tabBilan['GA1']=$tabBilanPre['GA'];
if (!isset($tabBilan['GB1']) && isset($tabBilanPre['GB'])) $tabBilan['GB1']=$tabBilanPre['GB'];
if (!isset($tabBilan['GC1']) && isset($tabBilanPre['GC'])) $tabBilan['GC1']=$tabBilanPre['GC'];
if (!isset($tabBilan['GD1']) && isset($tabBilanPre['GD'])) $tabBilan['GD1']=$tabBilanPre['GD'];
if (!isset($tabBilan['GE1']) && isset($tabBilanPre['GE'])) $tabBilan['GE1']=$tabBilanPre['GE'];
if (!isset($tabBilan['GF1']) && isset($tabBilanPre['GF'])) $tabBilan['GF1']=$tabBilanPre['GF'];
if (!isset($tabBilan['GG1']) && isset($tabBilanPre['GG'])) $tabBilan['GG1']=$tabBilanPre['GG'];
if (!isset($tabBilan['GH1']) && isset($tabBilanPre['GH'])) $tabBilan['GH1']=$tabBilanPre['GH'];
if (!isset($tabBilan['GI1']) && isset($tabBilanPre['GI'])) $tabBilan['GI1']=$tabBilanPre['GI'];
if (!isset($tabBilan['GJ1']) && isset($tabBilanPre['GJ'])) $tabBilan['GJ1']=$tabBilanPre['GJ'];
if (!isset($tabBilan['GK1']) && isset($tabBilanPre['GK'])) $tabBilan['GK1']=$tabBilanPre['GK'];
if (!isset($tabBilan['GL1']) && isset($tabBilanPre['GL'])) $tabBilan['GL1']=$tabBilanPre['GL'];
if (!isset($tabBilan['GM1']) && isset($tabBilanPre['GM'])) $tabBilan['GM1']=$tabBilanPre['GM'];
if (!isset($tabBilan['GN1']) && isset($tabBilanPre['GN'])) $tabBilan['GN1']=$tabBilanPre['GN'];
if (!isset($tabBilan['GO1']) && isset($tabBilanPre['GO'])) $tabBilan['GO1']=$tabBilanPre['GO'];
if (!isset($tabBilan['GP1']) && isset($tabBilanPre['GP'])) $tabBilan['GP1']=$tabBilanPre['GP'];
if (!isset($tabBilan['GQ1']) && isset($tabBilanPre['GQ'])) $tabBilan['GQ1']=$tabBilanPre['GQ'];
if (!isset($tabBilan['GR1']) && isset($tabBilanPre['GR'])) $tabBilan['GR1']=$tabBilanPre['GR'];
if (!isset($tabBilan['GS1']) && isset($tabBilanPre['GS'])) $tabBilan['GS1']=$tabBilanPre['GS'];
if (!isset($tabBilan['GT1']) && isset($tabBilanPre['GT'])) $tabBilan['GT1']=$tabBilanPre['GT'];
if (!isset($tabBilan['GU1']) && isset($tabBilanPre['GU'])) $tabBilan['GU1']=$tabBilanPre['GU'];
if (!isset($tabBilan['GV1']) && isset($tabBilanPre['GV'])) $tabBilan['GV1']=$tabBilanPre['GV'];
if (!isset($tabBilan['GW1']) && isset($tabBilanPre['GW'])) $tabBilan['GW1']=$tabBilanPre['GW'];
if (!isset($tabBilan['HA1']) && isset($tabBilanPre['HA'])) $tabBilan['HA1']=$tabBilanPre['HA'];
if (!isset($tabBilan['HB1']) && isset($tabBilanPre['HB'])) $tabBilan['HB1']=$tabBilanPre['HB'];
if (!isset($tabBilan['HC1']) && isset($tabBilanPre['HC'])) $tabBilan['HC1']=$tabBilanPre['HC'];
if (!isset($tabBilan['HD1']) && isset($tabBilanPre['HD'])) $tabBilan['HD1']=$tabBilanPre['HD'];
if (!isset($tabBilan['HE1']) && isset($tabBilanPre['HE'])) $tabBilan['HE1']=$tabBilanPre['HE'];
if (!isset($tabBilan['HF1']) && isset($tabBilanPre['HF'])) $tabBilan['HF1']=$tabBilanPre['HF'];
if (!isset($tabBilan['HG1']) && isset($tabBilanPre['HG'])) $tabBilan['HG1']=$tabBilanPre['HG'];
if (!isset($tabBilan['HH1']) && isset($tabBilanPre['HH'])) $tabBilan['HH1']=$tabBilanPre['HH'];
if (!isset($tabBilan['HI1']) && isset($tabBilanPre['HI'])) $tabBilan['HI1']=$tabBilanPre['HI'];
if (!isset($tabBilan['HJ1']) && isset($tabBilanPre['HJ'])) $tabBilan['HJ1']=$tabBilanPre['HJ'];
if (!isset($tabBilan['HK1']) && isset($tabBilanPre['HK'])) $tabBilan['HK1']=$tabBilanPre['HK'];
if (!isset($tabBilan['HL1']) && isset($tabBilanPre['HL'])) $tabBilan['HL1']=$tabBilanPre['HL'];
if (!isset($tabBilan['HM1']) && isset($tabBilanPre['HM'])) $tabBilan['HM1']=$tabBilanPre['HM'];
if (!isset($tabBilan['HN1']) && isset($tabBilanPre['HN'])) $tabBilan['HN1']=$tabBilanPre['HN'];
if (!isset($tabBilan['HO1']) && isset($tabBilanPre['HO'])) $tabBilan['HO1']=$tabBilanPre['HO'];
if (!isset($tabBilan['HY1']) && isset($tabBilanPre['HY'])) $tabBilan['HY1']=$tabBilanPre['HY'];
if (!isset($tabBilan['1G1']) && isset($tabBilanPre['1G'])) $tabBilan['1G1']=$tabBilanPre['1G'];
if (!isset($tabBilan['HP1']) && isset($tabBilanPre['HP'])) $tabBilan['HP1']=$tabBilanPre['HP'];
if (!isset($tabBilan['HQ1']) && isset($tabBilanPre['HQ'])) $tabBilan['HQ1']=$tabBilanPre['HQ'];
if (!isset($tabBilan['1H1']) && isset($tabBilanPre['1H'])) $tabBilan['1H1']=$tabBilanPre['1H'];
if (!isset($tabBilan['1J1']) && isset($tabBilanPre['1J'])) $tabBilan['1J1']=$tabBilanPre['1J'];
if (!isset($tabBilan['1K1']) && isset($tabBilanPre['1K'])) $tabBilan['1K1']=$tabBilanPre['1K'];
if (!isset($tabBilan['HX1']) && isset($tabBilanPre['HX'])) $tabBilan['HX1']=$tabBilanPre['HX'];
if (!isset($tabBilan['A11']) && isset($tabBilanPre['A1'])) $tabBilan['A11']=$tabBilanPre['A1'];
if (!isset($tabBilan['A21']) && isset($tabBilanPre['A2'])) $tabBilan['A21']=$tabBilanPre['A2'];
if (!isset($tabBilan['A31']) && isset($tabBilanPre['A3'])) $tabBilan['A31']=$tabBilanPre['A3'];
if (!isset($tabBilan['A41']) && isset($tabBilanPre['A4'])) $tabBilan['A41']=$tabBilanPre['A4'];
}
elseif ($tabBilan['CONSOLIDE']=='S')
{
// Calcul des chiffres net N-1 si absent 2033
if (!isset($tabBilanPre['013']) && (isset($tabBilanPre['010']) || isset($tabBilanPre['012']))) $tabBilanPre['013']=$tabBilanPre['010']-$tabBilanPre['012'];
if (!isset($tabBilanPre['017']) && (isset($tabBilanPre['014']) || isset($tabBilanPre['016']))) $tabBilanPre['017']=$tabBilanPre['014']-$tabBilanPre['016'];
if (!isset($tabBilanPre['031']) && (isset($tabBilanPre['028']) || isset($tabBilanPre['030']))) $tabBilanPre['031']=$tabBilanPre['028']-$tabBilanPre['030'];
if (!isset($tabBilanPre['043']) && (isset($tabBilanPre['040']) || isset($tabBilanPre['042']))) $tabBilanPre['043']=$tabBilanPre['040']-$tabBilanPre['042'];
if (!isset($tabBilanPre['049']) && (isset($tabBilanPre['044']) || isset($tabBilanPre['048']))) $tabBilanPre['049']=$tabBilanPre['044']-$tabBilanPre['048'];
if (!isset($tabBilanPre['053']) && (isset($tabBilanPre['050']) || isset($tabBilanPre['052']))) $tabBilanPre['053']=$tabBilanPre['050']-$tabBilanPre['052'];
if (!isset($tabBilanPre['063']) && (isset($tabBilanPre['060']) || isset($tabBilanPre['062']))) $tabBilanPre['063']=$tabBilanPre['060']-$tabBilanPre['062'];
if (!isset($tabBilanPre['067']) && (isset($tabBilanPre['064']) || isset($tabBilanPre['066']))) $tabBilanPre['067']=$tabBilanPre['064']-$tabBilanPre['066'];
if (!isset($tabBilanPre['071']) && (isset($tabBilanPre['068']) || isset($tabBilanPre['070']))) $tabBilanPre['071']=$tabBilanPre['068']-$tabBilanPre['070'];
if (!isset($tabBilanPre['075']) && (isset($tabBilanPre['072']) || isset($tabBilanPre['074']))) $tabBilanPre['075']=$tabBilanPre['072']-$tabBilanPre['074'];
if (!isset($tabBilanPre['083']) && (isset($tabBilanPre['080']) || isset($tabBilanPre['082']))) $tabBilanPre['083']=$tabBilanPre['080']-$tabBilanPre['082'];
if (!isset($tabBilanPre['087']) && (isset($tabBilanPre['084']) || isset($tabBilanPre['086']))) $tabBilanPre['087']=$tabBilanPre['084']-$tabBilanPre['086'];
if (!isset($tabBilanPre['091']) && (isset($tabBilanPre['088']) || isset($tabBilanPre['090']))) $tabBilanPre['091']=$tabBilanPre['088']-$tabBilanPre['090'];
if (!isset($tabBilanPre['095']) && (isset($tabBilanPre['092']) || isset($tabBilanPre['094']))) $tabBilanPre['095']=$tabBilanPre['092']-$tabBilanPre['094'];
if (!isset($tabBilanPre['099']) && (isset($tabBilanPre['096']) || isset($tabBilanPre['098']))) $tabBilanPre['099']=$tabBilanPre['096']-$tabBilanPre['098'];
if (!isset($tabBilanPre['113']) && (isset($tabBilanPre['110']) || isset($tabBilanPre['112']))) $tabBilanPre['113']=$tabBilanPre['110']-$tabBilanPre['112'];
// Récupération des chiffres N-1 si absent du bilan N
// ACTIF 2033
if (!isset($tabBilan['N00']) && isset($tabBilanPre['013'])) $tabBilan['N00']=$tabBilanPre['013'];
if (!isset($tabBilan['N01']) && isset($tabBilanPre['017'])) $tabBilan['N01']=$tabBilanPre['017'];
if (!isset($tabBilan['N02']) && isset($tabBilanPre['031'])) $tabBilan['N02']=$tabBilanPre['031'];
if (!isset($tabBilan['N03']) && isset($tabBilanPre['043'])) $tabBilan['N03']=$tabBilanPre['043'];
if (!isset($tabBilan['N04']) && isset($tabBilanPre['049'])) $tabBilan['N04']=$tabBilanPre['049'];
if (!isset($tabBilan['N05']) && isset($tabBilanPre['053'])) $tabBilan['N05']=$tabBilanPre['053'];
if (!isset($tabBilan['N06']) && isset($tabBilanPre['063'])) $tabBilan['N06']=$tabBilanPre['063'];
if (!isset($tabBilan['N07']) && isset($tabBilanPre['067'])) $tabBilan['N07']=$tabBilanPre['067'];
if (!isset($tabBilan['N08']) && isset($tabBilanPre['071'])) $tabBilan['N08']=$tabBilanPre['071'];
if (!isset($tabBilan['N09']) && isset($tabBilanPre['075'])) $tabBilan['N09']=$tabBilanPre['075'];
if (!isset($tabBilan['N10']) && isset($tabBilanPre['083'])) $tabBilan['N10']=$tabBilanPre['083'];
if (!isset($tabBilan['N11']) && isset($tabBilanPre['087'])) $tabBilan['N11']=$tabBilanPre['087'];
if (!isset($tabBilan['N12']) && isset($tabBilanPre['091'])) $tabBilan['N12']=$tabBilanPre['091'];
if (!isset($tabBilan['N13']) && isset($tabBilanPre['095'])) $tabBilan['N13']=$tabBilanPre['095'];
if (!isset($tabBilan['N14']) && isset($tabBilanPre['099'])) $tabBilan['N14']=$tabBilanPre['099'];
if (!isset($tabBilan['N15']) && isset($tabBilanPre['113'])) $tabBilan['N15']=$tabBilanPre['113'];
// PASSIF 2033
if (!isset($tabBilan['N16']) && isset($tabBilanPre['120'])) $tabBilan['N16']=$tabBilanPre['120'];
if (!isset($tabBilan['N17']) && isset($tabBilanPre['124'])) $tabBilan['N17']=$tabBilanPre['124'];
if (!isset($tabBilan['N18']) && isset($tabBilanPre['126'])) $tabBilan['N18']=$tabBilanPre['126'];
if (!isset($tabBilan['N19']) && isset($tabBilanPre['130'])) $tabBilan['N19']=$tabBilanPre['130'];
if (!isset($tabBilan['N20']) && isset($tabBilanPre['132'])) $tabBilan['N20']=$tabBilanPre['132'];
if (!isset($tabBilan['N21']) && isset($tabBilanPre['134'])) $tabBilan['N21']=$tabBilanPre['134'];
if (!isset($tabBilan['N22']) && isset($tabBilanPre['136'])) $tabBilan['N22']=$tabBilanPre['136'];
if (!isset($tabBilan['N23']) && isset($tabBilanPre['140'])) $tabBilan['N23']=$tabBilanPre['140'];
if (!isset($tabBilan['N24']) && isset($tabBilanPre['142'])) $tabBilan['N24']=$tabBilanPre['142'];
if (!isset($tabBilan['N25']) && isset($tabBilanPre['154'])) $tabBilan['N25']=$tabBilanPre['154'];
if (!isset($tabBilan['N26']) && isset($tabBilanPre['156'])) $tabBilan['N26']=$tabBilanPre['156'];
if (!isset($tabBilan['N27']) && isset($tabBilanPre['164'])) $tabBilan['N27']=$tabBilanPre['164'];
if (!isset($tabBilan['N28']) && isset($tabBilanPre['166'])) $tabBilan['N28']=$tabBilanPre['166'];
if (!isset($tabBilan['N29']) && isset($tabBilanPre['172'])) $tabBilan['N29']=$tabBilanPre['172'];
if (!isset($tabBilan['N30']) && isset($tabBilanPre['174'])) $tabBilan['N30']=$tabBilanPre['174'];
if (!isset($tabBilan['N31']) && isset($tabBilanPre['176'])) $tabBilan['N31']=$tabBilanPre['176'];
if (!isset($tabBilan['N32']) && isset($tabBilanPre['180'])) $tabBilan['N32']=$tabBilanPre['180'];
// COMPTE DE RESULTAT 2033
if (!isset($tabBilan['N33']) && isset($tabBilanPre['210'])) $tabBilan['N33']=$tabBilanPre['210'];
if (!isset($tabBilan['N34']) && isset($tabBilanPre['214'])) $tabBilan['N34']=$tabBilanPre['214'];
if (!isset($tabBilan['N35']) && isset($tabBilanPre['218'])) $tabBilan['N35']=$tabBilanPre['218'];
if (!isset($tabBilan['N36']) && isset($tabBilanPre['222'])) $tabBilan['N36']=$tabBilanPre['222'];
if (!isset($tabBilan['N37']) && isset($tabBilanPre['224'])) $tabBilan['N37']=$tabBilanPre['224'];
if (!isset($tabBilan['N38']) && isset($tabBilanPre['226'])) $tabBilan['N38']=$tabBilanPre['226'];
if (!isset($tabBilan['N39']) && isset($tabBilanPre['230'])) $tabBilan['N39']=$tabBilanPre['230'];
if (!isset($tabBilan['N40']) && isset($tabBilanPre['232'])) $tabBilan['N40']=$tabBilanPre['232'];
if (!isset($tabBilan['N41']) && isset($tabBilanPre['234'])) $tabBilan['N41']=$tabBilanPre['234'];
if (!isset($tabBilan['N42']) && isset($tabBilanPre['236'])) $tabBilan['N42']=$tabBilanPre['236'];
if (!isset($tabBilan['N43']) && isset($tabBilanPre['238'])) $tabBilan['N43']=$tabBilanPre['238'];
if (!isset($tabBilan['N44']) && isset($tabBilanPre['240'])) $tabBilan['N44']=$tabBilanPre['240'];
if (!isset($tabBilan['N45']) && isset($tabBilanPre['242'])) $tabBilan['N45']=$tabBilanPre['242'];
if (!isset($tabBilan['N46']) && isset($tabBilanPre['244'])) $tabBilan['N46']=$tabBilanPre['244'];
if (!isset($tabBilan['N47']) && isset($tabBilanPre['250'])) $tabBilan['N47']=$tabBilanPre['250'];
if (!isset($tabBilan['N48']) && isset($tabBilanPre['252'])) $tabBilan['N48']=$tabBilanPre['252'];
if (!isset($tabBilan['N49']) && isset($tabBilanPre['254'])) $tabBilan['N49']=$tabBilanPre['254'];
if (!isset($tabBilan['N50']) && isset($tabBilanPre['256'])) $tabBilan['N50']=$tabBilanPre['256'];
if (!isset($tabBilan['N51']) && isset($tabBilanPre['262'])) $tabBilan['N51']=$tabBilanPre['262'];
if (!isset($tabBilan['N52']) && isset($tabBilanPre['264'])) $tabBilan['N52']=$tabBilanPre['264'];
if (!isset($tabBilan['N53']) && isset($tabBilanPre['270'])) $tabBilan['N53']=$tabBilanPre['270'];
if (!isset($tabBilan['N54']) && isset($tabBilanPre['280'])) $tabBilan['N54']=$tabBilanPre['280'];
if (!isset($tabBilan['N55']) && isset($tabBilanPre['290'])) $tabBilan['N55']=$tabBilanPre['290'];
if (!isset($tabBilan['N56']) && isset($tabBilanPre['294'])) $tabBilan['N56']=$tabBilanPre['294'];
if (!isset($tabBilan['N57']) && isset($tabBilanPre['300'])) $tabBilan['N57']=$tabBilanPre['300'];
if (!isset($tabBilan['N58']) && isset($tabBilanPre['306'])) $tabBilan['N58']=$tabBilanPre['306'];
if (!isset($tabBilan['N59']) && isset($tabBilanPre['310'])) $tabBilan['N59']=$tabBilanPre['310'];
}
elseif ($tabBilan['CONSOLIDE']=='A' || $tabBilan['CONSOLIDE']=='B')
{
// BANQUES
if (!isset($tabBilan['NA1']) && isset($tabBilanPre['AA1'])) $tabBilan['NA1']=$tabBilanPre['AA1'];
if (!isset($tabBilan['NA2']) && isset($tabBilanPre['AA2'])) $tabBilan['NA2']=$tabBilanPre['AA2'];
if (!isset($tabBilan['NA3']) && isset($tabBilanPre['AA3'])) $tabBilan['NA3']=$tabBilanPre['AA3'];
if (!isset($tabBilan['NP1']) && isset($tabBilanPre['AP1'])) $tabBilan['NP1']=$tabBilanPre['AP1'];
if (!isset($tabBilan['NP2']) && isset($tabBilanPre['AP2'])) $tabBilan['NP2']=$tabBilanPre['AP2'];
if (!isset($tabBilan['NP3']) && isset($tabBilanPre['AP3'])) $tabBilan['NP3']=$tabBilanPre['AP3'];
if (!isset($tabBilan['NP4']) && isset($tabBilanPre['AP4'])) $tabBilan['NP4']=$tabBilanPre['AP4'];
if (!isset($tabBilan['NP5']) && isset($tabBilanPre['AP5'])) $tabBilan['NP5']=$tabBilanPre['AP5'];
if (!isset($tabBilan['NP6']) && isset($tabBilanPre['AP6'])) $tabBilan['NP6']=$tabBilanPre['AP6'];
if (!isset($tabBilan['NP7']) && isset($tabBilanPre['AP7'])) $tabBilan['NP7']=$tabBilanPre['AP7'];
if (!isset($tabBilan['NP8']) && isset($tabBilanPre['AP8'])) $tabBilan['NP8']=$tabBilanPre['AP8'];
if (!isset($tabBilan['NP9']) && isset($tabBilanPre['AP9'])) $tabBilan['NP9']=$tabBilanPre['AP9'];
if (!isset($tabBilan['NR1']) && isset($tabBilanPre['AR1'])) $tabBilan['NR1']=$tabBilanPre['AR1'];
if (!isset($tabBilan['NR2']) && isset($tabBilanPre['AR2'])) $tabBilan['NR2']=$tabBilanPre['AR2'];
if (!isset($tabBilan['NR3']) && isset($tabBilanPre['AR3'])) $tabBilan['NR3']=$tabBilanPre['AR3'];
// ASSURANCE
if (!isset($tabBilan['NR4']) && isset($tabBilanPre['AR4'])) $tabBilan['AR4']=$tabBilanPre['AR4'];
}
/** Reprises des valeures N-1 si l'information est absente en base **/
// Actif
if (!isset($tabBilan['AA3']) && isset($tabBilanPre['AA2'])) $tabBilan['AA3']=$tabBilanPre['AA2'];
if (!isset($tabBilan['AC2']) && isset($tabBilanPre['AC1'])) $tabBilan['AC2']=$tabBilanPre['AC1'];
if (!isset($tabBilan['AE2']) && isset($tabBilanPre['AE1'])) $tabBilan['AE2']=$tabBilanPre['AE1'];
if (!isset($tabBilan['AG2']) && isset($tabBilanPre['AG1'])) $tabBilan['AG2']=$tabBilanPre['AG1'];
if (!isset($tabBilan['AI2']) && isset($tabBilanPre['AI1'])) $tabBilan['AI2']=$tabBilanPre['AI1'];
if (!isset($tabBilan['AK2']) && isset($tabBilanPre['AK1'])) $tabBilan['AK2']=$tabBilanPre['AK1'];
if (!isset($tabBilan['AM2']) && isset($tabBilanPre['AM1'])) $tabBilan['AM2']=$tabBilanPre['AM1'];
if (!isset($tabBilan['AO2']) && isset($tabBilanPre['AO1'])) $tabBilan['AO2']=$tabBilanPre['AO1'];
if (!isset($tabBilan['AQ2']) && isset($tabBilanPre['AQ1'])) $tabBilan['AQ2']=$tabBilanPre['AQ1'];
if (!isset($tabBilan['AS2']) && isset($tabBilanPre['AS1'])) $tabBilan['AS2']=$tabBilanPre['AS1'];
if (!isset($tabBilan['AU2']) && isset($tabBilanPre['AU1'])) $tabBilan['AU2']=$tabBilanPre['AU1'];
if (!isset($tabBilan['AW2']) && isset($tabBilanPre['AW1'])) $tabBilan['AW2']=$tabBilanPre['AW1'];
if (!isset($tabBilan['AY2']) && isset($tabBilanPre['AY1'])) $tabBilan['AY2']=$tabBilanPre['AY1'];
if (!isset($tabBilan['CT2']) && isset($tabBilanPre['CT1'])) $tabBilan['CT2']=$tabBilanPre['CT1'];
if (!isset($tabBilan['CV2']) && isset($tabBilanPre['CV1'])) $tabBilan['CV2']=$tabBilanPre['CV1'];
if (!isset($tabBilan['BC2']) && isset($tabBilanPre['BC1'])) $tabBilan['BC2']=$tabBilanPre['BC1'];
if (!isset($tabBilan['BE2']) && isset($tabBilanPre['BE1'])) $tabBilan['BE2']=$tabBilanPre['BE1'];
if (!isset($tabBilan['BG2']) && isset($tabBilanPre['BG1'])) $tabBilan['BG2']=$tabBilanPre['BG1'];
if (!isset($tabBilan['BI2']) && isset($tabBilanPre['BI1'])) $tabBilan['BI2']=$tabBilanPre['BI1'];
if (!isset($tabBilan['BK2']) && isset($tabBilanPre['BK1'])) $tabBilan['BK2']=$tabBilanPre['BK1'];
if (!isset($tabBilan['BM2']) && isset($tabBilanPre['BM1'])) $tabBilan['BM2']=$tabBilanPre['BM1'];
if (!isset($tabBilan['BO2']) && isset($tabBilanPre['BO1'])) $tabBilan['BO2']=$tabBilanPre['BO1'];
if (!isset($tabBilan['BQ2']) && isset($tabBilanPre['BQ1'])) $tabBilan['BQ2']=$tabBilanPre['BQ1'];
if (!isset($tabBilan['BS2']) && isset($tabBilanPre['BS1'])) $tabBilan['BS2']=$tabBilanPre['BS1'];
if (!isset($tabBilan['BU2']) && isset($tabBilanPre['BU1'])) $tabBilan['BU2']=$tabBilanPre['BU1'];
if (!isset($tabBilan['BW2']) && isset($tabBilanPre['BW1'])) $tabBilan['BW2']=$tabBilanPre['BW1'];
if (!isset($tabBilan['BY2']) && isset($tabBilanPre['BY1'])) $tabBilan['BY2']=$tabBilanPre['BY1'];
if (!isset($tabBilan['CA2']) && isset($tabBilanPre['CA1'])) $tabBilan['CA2']=$tabBilanPre['CA1'];
if (!isset($tabBilan['CC2']) && isset($tabBilanPre['CC1'])) $tabBilan['CC2']=$tabBilanPre['CC1'];
if (!isset($tabBilan['CE2']) && isset($tabBilanPre['CE1'])) $tabBilan['CE2']=$tabBilanPre['CE1'];
if (!isset($tabBilan['CG2']) && isset($tabBilanPre['CG1'])) $tabBilan['CG2']=$tabBilanPre['CG1'];
if (!isset($tabBilan['CI2']) && isset($tabBilanPre['CI1'])) $tabBilan['CI2']=$tabBilanPre['CI1'];
if (!isset($tabBilan['CK2']) && isset($tabBilanPre['CK1'])) $tabBilan['CK2']=$tabBilanPre['CK1'];
if (!isset($tabBilan['CL3']) && isset($tabBilanPre['CL2'])) $tabBilan['CL3']=$tabBilanPre['CL2'];
if (!isset($tabBilan['CM3']) && isset($tabBilanPre['CM2'])) $tabBilan['CM3']=$tabBilanPre['CM2'];
if (!isset($tabBilan['CN3']) && isset($tabBilanPre['CN2'])) $tabBilan['CN3']=$tabBilanPre['CN2'];
if (!isset($tabBilan['1A2']) && isset($tabBilanPre['1A1'])) $tabBilan['1A2']=$tabBilanPre['1A1'];
// Passif
if (!isset($tabBilan['DA1']) && isset($tabBilanPre['DA'])) $tabBilan['DA1']=$tabBilanPre['DA'];
if (!isset($tabBilan['DB1']) && isset($tabBilanPre['DB'])) $tabBilan['DB1']=$tabBilanPre['DB'];
if (!isset($tabBilan['DC1']) && isset($tabBilanPre['DC'])) $tabBilan['DC1']=$tabBilanPre['DC'];
if (!isset($tabBilan['DD1']) && isset($tabBilanPre['DD'])) $tabBilan['DD1']=$tabBilanPre['DD'];
if (!isset($tabBilan['DE1']) && isset($tabBilanPre['DE'])) $tabBilan['DE1']=$tabBilanPre['DE'];
if (!isset($tabBilan['DF1']) && isset($tabBilanPre['DF'])) $tabBilan['DF1']=$tabBilanPre['DF'];
if (!isset($tabBilan['DG1']) && isset($tabBilanPre['DG'])) $tabBilan['DG1']=$tabBilanPre['DG'];
if (!isset($tabBilan['DH1']) && isset($tabBilanPre['DH'])) $tabBilan['DH1']=$tabBilanPre['DH'];
if (!isset($tabBilan['DI1']) && isset($tabBilanPre['DI'])) $tabBilan['DI1']=$tabBilanPre['DI'];
if (!isset($tabBilan['DJ1']) && isset($tabBilanPre['DJ'])) $tabBilan['DJ1']=$tabBilanPre['DJ'];
if (!isset($tabBilan['DK1']) && isset($tabBilanPre['DK'])) $tabBilan['DK1']=$tabBilanPre['DK'];
if (!isset($tabBilan['DL1']) && isset($tabBilanPre['DL'])) $tabBilan['DL1']=$tabBilanPre['DL'];
if (!isset($tabBilan['DM1']) && isset($tabBilanPre['DM'])) $tabBilan['DM1']=$tabBilanPre['DM'];
if (!isset($tabBilan['DN1']) && isset($tabBilanPre['DN'])) $tabBilan['DN1']=$tabBilanPre['DN'];
if (!isset($tabBilan['DO1']) && isset($tabBilanPre['DO'])) $tabBilan['DO1']=$tabBilanPre['DO'];
if (!isset($tabBilan['DP1']) && isset($tabBilanPre['DP'])) $tabBilan['DP1']=$tabBilanPre['DP'];
if (!isset($tabBilan['DQ1']) && isset($tabBilanPre['DQ'])) $tabBilan['DQ1']=$tabBilanPre['DQ'];
if (!isset($tabBilan['DR1']) && isset($tabBilanPre['DR'])) $tabBilan['DR1']=$tabBilanPre['DR'];
if (!isset($tabBilan['DS1']) && isset($tabBilanPre['DS'])) $tabBilan['DS1']=$tabBilanPre['DS'];
if (!isset($tabBilan['DT1']) && isset($tabBilanPre['DT'])) $tabBilan['DT1']=$tabBilanPre['DT'];
if (!isset($tabBilan['DU1']) && isset($tabBilanPre['DU'])) $tabBilan['DU1']=$tabBilanPre['DU'];
if (!isset($tabBilan['DV1']) && isset($tabBilanPre['DV'])) $tabBilan['DV1']=$tabBilanPre['DV'];
if (!isset($tabBilan['DW1']) && isset($tabBilanPre['DW'])) $tabBilan['DW1']=$tabBilanPre['DW'];
if (!isset($tabBilan['DX1']) && isset($tabBilanPre['DX'])) $tabBilan['DX1']=$tabBilanPre['DX'];
if (!isset($tabBilan['DY1']) && isset($tabBilanPre['DY'])) $tabBilan['DY1']=$tabBilanPre['DY'];
if (!isset($tabBilan['DZ1']) && isset($tabBilanPre['DZ'])) $tabBilan['DZ1']=$tabBilanPre['DZ'];
if (!isset($tabBilan['EA1']) && isset($tabBilanPre['EA'])) $tabBilan['EA1']=$tabBilanPre['EA'];
if (!isset($tabBilan['EB1']) && isset($tabBilanPre['EB'])) $tabBilan['EB1']=$tabBilanPre['EB'];
if (!isset($tabBilan['EC1']) && isset($tabBilanPre['EC'])) $tabBilan['EC1']=$tabBilanPre['EC'];
if (!isset($tabBilan['ED1']) && isset($tabBilanPre['ED'])) $tabBilan['ED1']=$tabBilanPre['ED'];
if (!isset($tabBilan['EE1']) && isset($tabBilanPre['EE'])) $tabBilan['EE1']=$tabBilanPre['EE'];
if (!isset($tabBilan['1B1']) && isset($tabBilanPre['1B'])) $tabBilan['1B1']=$tabBilanPre['1B'];
if (!isset($tabBilan['1C1']) && isset($tabBilanPre['1C'])) $tabBilan['1C1']=$tabBilanPre['1C'];
if (!isset($tabBilan['1D1']) && isset($tabBilanPre['1D'])) $tabBilan['1D1']=$tabBilanPre['1D'];
if (!isset($tabBilan['1E1']) && isset($tabBilanPre['1E'])) $tabBilan['1E1']=$tabBilanPre['1E'];
if (!isset($tabBilan['EF1']) && isset($tabBilanPre['EF'])) $tabBilan['EF1']=$tabBilanPre['EF'];
if (!isset($tabBilan['EG1']) && isset($tabBilanPre['EG'])) $tabBilan['EG1']=$tabBilanPre['EG'];
if (!isset($tabBilan['EH1']) && isset($tabBilanPre['EH'])) $tabBilan['EH1']=$tabBilanPre['EH'];
// Compte de Résultats
if (!isset($tabBilan['FC1']) && isset($tabBilanPre['FC'])) $tabBilan['FC1']=$tabBilanPre['FC'];
if (!isset($tabBilan['FF1']) && isset($tabBilanPre['FF'])) $tabBilan['FF1']=$tabBilanPre['FF'];
if (!isset($tabBilan['FI1']) && isset($tabBilanPre['FI'])) $tabBilan['FI1']=$tabBilanPre['FI'];
if (!isset($tabBilan['FL1']) && isset($tabBilanPre['FL'])) $tabBilan['FL1']=$tabBilanPre['FL'];
if (!isset($tabBilan['FM1']) && isset($tabBilanPre['FM'])) $tabBilan['FM1']=$tabBilanPre['FM'];
if (!isset($tabBilan['FN1']) && isset($tabBilanPre['FN'])) $tabBilan['FN1']=$tabBilanPre['FN'];
if (!isset($tabBilan['FO1']) && isset($tabBilanPre['FO'])) $tabBilan['FO1']=$tabBilanPre['FO'];
if (!isset($tabBilan['FP1']) && isset($tabBilanPre['FP'])) $tabBilan['FP1']=$tabBilanPre['FP'];
if (!isset($tabBilan['FQ1']) && isset($tabBilanPre['FQ'])) $tabBilan['FQ1']=$tabBilanPre['FQ'];
if (!isset($tabBilan['FR1']) && isset($tabBilanPre['FR'])) $tabBilan['FR1']=$tabBilanPre['FR'];
if (!isset($tabBilan['FS1']) && isset($tabBilanPre['FS'])) $tabBilan['FS1']=$tabBilanPre['FS'];
if (!isset($tabBilan['FT1']) && isset($tabBilanPre['FT'])) $tabBilan['FT1']=$tabBilanPre['FT'];
if (!isset($tabBilan['FU1']) && isset($tabBilanPre['FU'])) $tabBilan['FU1']=$tabBilanPre['FU'];
if (!isset($tabBilan['FV1']) && isset($tabBilanPre['FV'])) $tabBilan['FV1']=$tabBilanPre['FV'];
if (!isset($tabBilan['FW1']) && isset($tabBilanPre['FW'])) $tabBilan['FW1']=$tabBilanPre['FW'];
if (!isset($tabBilan['FX1']) && isset($tabBilanPre['FX'])) $tabBilan['FX1']=$tabBilanPre['FX'];
if (!isset($tabBilan['FY1']) && isset($tabBilanPre['FY'])) $tabBilan['FY1']=$tabBilanPre['FY'];
if (!isset($tabBilan['FZ1']) && isset($tabBilanPre['FZ'])) $tabBilan['FZ1']=$tabBilanPre['FZ'];
if (!isset($tabBilan['GA1']) && isset($tabBilanPre['GA'])) $tabBilan['GA1']=$tabBilanPre['GA'];
if (!isset($tabBilan['GB1']) && isset($tabBilanPre['GB'])) $tabBilan['GB1']=$tabBilanPre['GB'];
if (!isset($tabBilan['GC1']) && isset($tabBilanPre['GC'])) $tabBilan['GC1']=$tabBilanPre['GC'];
if (!isset($tabBilan['GD1']) && isset($tabBilanPre['GD'])) $tabBilan['GD1']=$tabBilanPre['GD'];
if (!isset($tabBilan['GE1']) && isset($tabBilanPre['GE'])) $tabBilan['GE1']=$tabBilanPre['GE'];
if (!isset($tabBilan['GF1']) && isset($tabBilanPre['GF'])) $tabBilan['GF1']=$tabBilanPre['GF'];
if (!isset($tabBilan['GG1']) && isset($tabBilanPre['GG'])) $tabBilan['GG1']=$tabBilanPre['GG'];
if (!isset($tabBilan['GH1']) && isset($tabBilanPre['GH'])) $tabBilan['GH1']=$tabBilanPre['GH'];
if (!isset($tabBilan['GI1']) && isset($tabBilanPre['GI'])) $tabBilan['GI1']=$tabBilanPre['GI'];
if (!isset($tabBilan['GJ1']) && isset($tabBilanPre['GJ'])) $tabBilan['GJ1']=$tabBilanPre['GJ'];
if (!isset($tabBilan['GK1']) && isset($tabBilanPre['GK'])) $tabBilan['GK1']=$tabBilanPre['GK'];
if (!isset($tabBilan['GL1']) && isset($tabBilanPre['GL'])) $tabBilan['GL1']=$tabBilanPre['GL'];
if (!isset($tabBilan['GM1']) && isset($tabBilanPre['GM'])) $tabBilan['GM1']=$tabBilanPre['GM'];
if (!isset($tabBilan['GN1']) && isset($tabBilanPre['GN'])) $tabBilan['GN1']=$tabBilanPre['GN'];
if (!isset($tabBilan['GO1']) && isset($tabBilanPre['GO'])) $tabBilan['GO1']=$tabBilanPre['GO'];
if (!isset($tabBilan['GP1']) && isset($tabBilanPre['GP'])) $tabBilan['GP1']=$tabBilanPre['GP'];
if (!isset($tabBilan['GQ1']) && isset($tabBilanPre['GQ'])) $tabBilan['GQ1']=$tabBilanPre['GQ'];
if (!isset($tabBilan['GR1']) && isset($tabBilanPre['GR'])) $tabBilan['GR1']=$tabBilanPre['GR'];
if (!isset($tabBilan['GS1']) && isset($tabBilanPre['GS'])) $tabBilan['GS1']=$tabBilanPre['GS'];
if (!isset($tabBilan['GT1']) && isset($tabBilanPre['GT'])) $tabBilan['GT1']=$tabBilanPre['GT'];
if (!isset($tabBilan['GU1']) && isset($tabBilanPre['GU'])) $tabBilan['GU1']=$tabBilanPre['GU'];
if (!isset($tabBilan['GV1']) && isset($tabBilanPre['GV'])) $tabBilan['GV1']=$tabBilanPre['GV'];
if (!isset($tabBilan['GW1']) && isset($tabBilanPre['GW'])) $tabBilan['GW1']=$tabBilanPre['GW'];
if (!isset($tabBilan['HA1']) && isset($tabBilanPre['HA'])) $tabBilan['HA1']=$tabBilanPre['HA'];
if (!isset($tabBilan['HB1']) && isset($tabBilanPre['HB'])) $tabBilan['HB1']=$tabBilanPre['HB'];
if (!isset($tabBilan['HC1']) && isset($tabBilanPre['HC'])) $tabBilan['HC1']=$tabBilanPre['HC'];
if (!isset($tabBilan['HD1']) && isset($tabBilanPre['HD'])) $tabBilan['HD1']=$tabBilanPre['HD'];
if (!isset($tabBilan['HE1']) && isset($tabBilanPre['HE'])) $tabBilan['HE1']=$tabBilanPre['HE'];
if (!isset($tabBilan['HF1']) && isset($tabBilanPre['HF'])) $tabBilan['HF1']=$tabBilanPre['HF'];
if (!isset($tabBilan['HG1']) && isset($tabBilanPre['HG'])) $tabBilan['HG1']=$tabBilanPre['HG'];
if (!isset($tabBilan['HH1']) && isset($tabBilanPre['HH'])) $tabBilan['HH1']=$tabBilanPre['HH'];
if (!isset($tabBilan['HI1']) && isset($tabBilanPre['HI'])) $tabBilan['HI1']=$tabBilanPre['HI'];
if (!isset($tabBilan['HJ1']) && isset($tabBilanPre['HJ'])) $tabBilan['HJ1']=$tabBilanPre['HJ'];
if (!isset($tabBilan['HK1']) && isset($tabBilanPre['HK'])) $tabBilan['HK1']=$tabBilanPre['HK'];
if (!isset($tabBilan['HL1']) && isset($tabBilanPre['HL'])) $tabBilan['HL1']=$tabBilanPre['HL'];
if (!isset($tabBilan['HM1']) && isset($tabBilanPre['HM'])) $tabBilan['HM1']=$tabBilanPre['HM'];
if (!isset($tabBilan['HN1']) && isset($tabBilanPre['HN'])) $tabBilan['HN1']=$tabBilanPre['HN'];
if (!isset($tabBilan['HO1']) && isset($tabBilanPre['HO'])) $tabBilan['HO1']=$tabBilanPre['HO'];
if (!isset($tabBilan['HY1']) && isset($tabBilanPre['HY'])) $tabBilan['HY1']=$tabBilanPre['HY'];
if (!isset($tabBilan['1G1']) && isset($tabBilanPre['1G'])) $tabBilan['1G1']=$tabBilanPre['1G'];
if (!isset($tabBilan['HP1']) && isset($tabBilanPre['HP'])) $tabBilan['HP1']=$tabBilanPre['HP'];
if (!isset($tabBilan['HQ1']) && isset($tabBilanPre['HQ'])) $tabBilan['HQ1']=$tabBilanPre['HQ'];
if (!isset($tabBilan['1H1']) && isset($tabBilanPre['1H'])) $tabBilan['1H1']=$tabBilanPre['1H'];
if (!isset($tabBilan['1J1']) && isset($tabBilanPre['1J'])) $tabBilan['1J1']=$tabBilanPre['1J'];
if (!isset($tabBilan['1K1']) && isset($tabBilanPre['1K'])) $tabBilan['1K1']=$tabBilanPre['1K'];
if (!isset($tabBilan['HX1']) && isset($tabBilanPre['HX'])) $tabBilan['HX1']=$tabBilanPre['HX'];
if (!isset($tabBilan['A11']) && isset($tabBilanPre['A1'])) $tabBilan['A11']=$tabBilanPre['A1'];
if (!isset($tabBilan['A21']) && isset($tabBilanPre['A2'])) $tabBilan['A21']=$tabBilanPre['A2'];
if (!isset($tabBilan['A31']) && isset($tabBilanPre['A3'])) $tabBilan['A31']=$tabBilanPre['A3'];
if (!isset($tabBilan['A41']) && isset($tabBilanPre['A4'])) $tabBilan['A41']=$tabBilanPre['A4'];
}
elseif ($tabBilan['CONSOLIDE']=='S') {
// Calcul des chiffres net N-1 si absent 2033
if (!isset($tabBilanPre['013']) && (isset($tabBilanPre['010']) || isset($tabBilanPre['012']))) $tabBilanPre['013']=$tabBilanPre['010']-$tabBilanPre['012'];
if (!isset($tabBilanPre['017']) && (isset($tabBilanPre['014']) || isset($tabBilanPre['016']))) $tabBilanPre['017']=$tabBilanPre['014']-$tabBilanPre['016'];
if (!isset($tabBilanPre['031']) && (isset($tabBilanPre['028']) || isset($tabBilanPre['030']))) $tabBilanPre['031']=$tabBilanPre['028']-$tabBilanPre['030'];
if (!isset($tabBilanPre['043']) && (isset($tabBilanPre['040']) || isset($tabBilanPre['042']))) $tabBilanPre['043']=$tabBilanPre['040']-$tabBilanPre['042'];
if (!isset($tabBilanPre['049']) && (isset($tabBilanPre['044']) || isset($tabBilanPre['048']))) $tabBilanPre['049']=$tabBilanPre['044']-$tabBilanPre['048'];
if (!isset($tabBilanPre['053']) && (isset($tabBilanPre['050']) || isset($tabBilanPre['052']))) $tabBilanPre['053']=$tabBilanPre['050']-$tabBilanPre['052'];
if (!isset($tabBilanPre['063']) && (isset($tabBilanPre['060']) || isset($tabBilanPre['062']))) $tabBilanPre['063']=$tabBilanPre['060']-$tabBilanPre['062'];
if (!isset($tabBilanPre['067']) && (isset($tabBilanPre['064']) || isset($tabBilanPre['066']))) $tabBilanPre['067']=$tabBilanPre['064']-$tabBilanPre['066'];
if (!isset($tabBilanPre['071']) && (isset($tabBilanPre['068']) || isset($tabBilanPre['070']))) $tabBilanPre['071']=$tabBilanPre['068']-$tabBilanPre['070'];
if (!isset($tabBilanPre['075']) && (isset($tabBilanPre['072']) || isset($tabBilanPre['074']))) $tabBilanPre['075']=$tabBilanPre['072']-$tabBilanPre['074'];
if (!isset($tabBilanPre['083']) && (isset($tabBilanPre['080']) || isset($tabBilanPre['082']))) $tabBilanPre['083']=$tabBilanPre['080']-$tabBilanPre['082'];
if (!isset($tabBilanPre['087']) && (isset($tabBilanPre['084']) || isset($tabBilanPre['086']))) $tabBilanPre['087']=$tabBilanPre['084']-$tabBilanPre['086'];
if (!isset($tabBilanPre['091']) && (isset($tabBilanPre['088']) || isset($tabBilanPre['090']))) $tabBilanPre['091']=$tabBilanPre['088']-$tabBilanPre['090'];
if (!isset($tabBilanPre['095']) && (isset($tabBilanPre['092']) || isset($tabBilanPre['094']))) $tabBilanPre['095']=$tabBilanPre['092']-$tabBilanPre['094'];
if (!isset($tabBilanPre['099']) && (isset($tabBilanPre['096']) || isset($tabBilanPre['098']))) $tabBilanPre['099']=$tabBilanPre['096']-$tabBilanPre['098'];
if (!isset($tabBilanPre['113']) && (isset($tabBilanPre['110']) || isset($tabBilanPre['112']))) $tabBilanPre['113']=$tabBilanPre['110']-$tabBilanPre['112'];
// Récupération des chiffres N-1 si absent du bilan N
// ACTIF 2033
if (!isset($tabBilan['N00']) && isset($tabBilanPre['013'])) $tabBilan['N00']=$tabBilanPre['013'];
if (!isset($tabBilan['N01']) && isset($tabBilanPre['017'])) $tabBilan['N01']=$tabBilanPre['017'];
if (!isset($tabBilan['N02']) && isset($tabBilanPre['031'])) $tabBilan['N02']=$tabBilanPre['031'];
if (!isset($tabBilan['N03']) && isset($tabBilanPre['043'])) $tabBilan['N03']=$tabBilanPre['043'];
if (!isset($tabBilan['N04']) && isset($tabBilanPre['049'])) $tabBilan['N04']=$tabBilanPre['049'];
if (!isset($tabBilan['N05']) && isset($tabBilanPre['053'])) $tabBilan['N05']=$tabBilanPre['053'];
if (!isset($tabBilan['N06']) && isset($tabBilanPre['063'])) $tabBilan['N06']=$tabBilanPre['063'];
if (!isset($tabBilan['N07']) && isset($tabBilanPre['067'])) $tabBilan['N07']=$tabBilanPre['067'];
if (!isset($tabBilan['N08']) && isset($tabBilanPre['071'])) $tabBilan['N08']=$tabBilanPre['071'];
if (!isset($tabBilan['N09']) && isset($tabBilanPre['075'])) $tabBilan['N09']=$tabBilanPre['075'];
if (!isset($tabBilan['N10']) && isset($tabBilanPre['083'])) $tabBilan['N10']=$tabBilanPre['083'];
if (!isset($tabBilan['N11']) && isset($tabBilanPre['087'])) $tabBilan['N11']=$tabBilanPre['087'];
if (!isset($tabBilan['N12']) && isset($tabBilanPre['091'])) $tabBilan['N12']=$tabBilanPre['091'];
if (!isset($tabBilan['N13']) && isset($tabBilanPre['095'])) $tabBilan['N13']=$tabBilanPre['095'];
if (!isset($tabBilan['N14']) && isset($tabBilanPre['099'])) $tabBilan['N14']=$tabBilanPre['099'];
if (!isset($tabBilan['N15']) && isset($tabBilanPre['113'])) $tabBilan['N15']=$tabBilanPre['113'];
// PASSIF 2033
if (!isset($tabBilan['N16']) && isset($tabBilanPre['120'])) $tabBilan['N16']=$tabBilanPre['120'];
if (!isset($tabBilan['N17']) && isset($tabBilanPre['124'])) $tabBilan['N17']=$tabBilanPre['124'];
if (!isset($tabBilan['N18']) && isset($tabBilanPre['126'])) $tabBilan['N18']=$tabBilanPre['126'];
if (!isset($tabBilan['N19']) && isset($tabBilanPre['130'])) $tabBilan['N19']=$tabBilanPre['130'];
if (!isset($tabBilan['N20']) && isset($tabBilanPre['132'])) $tabBilan['N20']=$tabBilanPre['132'];
if (!isset($tabBilan['N21']) && isset($tabBilanPre['134'])) $tabBilan['N21']=$tabBilanPre['134'];
if (!isset($tabBilan['N22']) && isset($tabBilanPre['136'])) $tabBilan['N22']=$tabBilanPre['136'];
if (!isset($tabBilan['N23']) && isset($tabBilanPre['140'])) $tabBilan['N23']=$tabBilanPre['140'];
if (!isset($tabBilan['N24']) && isset($tabBilanPre['142'])) $tabBilan['N24']=$tabBilanPre['142'];
if (!isset($tabBilan['N25']) && isset($tabBilanPre['154'])) $tabBilan['N25']=$tabBilanPre['154'];
if (!isset($tabBilan['N26']) && isset($tabBilanPre['156'])) $tabBilan['N26']=$tabBilanPre['156'];
if (!isset($tabBilan['N27']) && isset($tabBilanPre['164'])) $tabBilan['N27']=$tabBilanPre['164'];
if (!isset($tabBilan['N28']) && isset($tabBilanPre['166'])) $tabBilan['N28']=$tabBilanPre['166'];
if (!isset($tabBilan['N29']) && isset($tabBilanPre['172'])) $tabBilan['N29']=$tabBilanPre['172'];
if (!isset($tabBilan['N30']) && isset($tabBilanPre['174'])) $tabBilan['N30']=$tabBilanPre['174'];
if (!isset($tabBilan['N31']) && isset($tabBilanPre['176'])) $tabBilan['N31']=$tabBilanPre['176'];
if (!isset($tabBilan['N32']) && isset($tabBilanPre['180'])) $tabBilan['N32']=$tabBilanPre['180'];
// COMPTE DE RESULTAT 2033
if (!isset($tabBilan['N33']) && isset($tabBilanPre['210'])) $tabBilan['N33']=$tabBilanPre['210'];
if (!isset($tabBilan['N34']) && isset($tabBilanPre['214'])) $tabBilan['N34']=$tabBilanPre['214'];
if (!isset($tabBilan['N35']) && isset($tabBilanPre['218'])) $tabBilan['N35']=$tabBilanPre['218'];
if (!isset($tabBilan['N36']) && isset($tabBilanPre['222'])) $tabBilan['N36']=$tabBilanPre['222'];
if (!isset($tabBilan['N37']) && isset($tabBilanPre['224'])) $tabBilan['N37']=$tabBilanPre['224'];
if (!isset($tabBilan['N38']) && isset($tabBilanPre['226'])) $tabBilan['N38']=$tabBilanPre['226'];
if (!isset($tabBilan['N39']) && isset($tabBilanPre['230'])) $tabBilan['N39']=$tabBilanPre['230'];
if (!isset($tabBilan['N40']) && isset($tabBilanPre['232'])) $tabBilan['N40']=$tabBilanPre['232'];
if (!isset($tabBilan['N41']) && isset($tabBilanPre['234'])) $tabBilan['N41']=$tabBilanPre['234'];
if (!isset($tabBilan['N42']) && isset($tabBilanPre['236'])) $tabBilan['N42']=$tabBilanPre['236'];
if (!isset($tabBilan['N43']) && isset($tabBilanPre['238'])) $tabBilan['N43']=$tabBilanPre['238'];
if (!isset($tabBilan['N44']) && isset($tabBilanPre['240'])) $tabBilan['N44']=$tabBilanPre['240'];
if (!isset($tabBilan['N45']) && isset($tabBilanPre['242'])) $tabBilan['N45']=$tabBilanPre['242'];
if (!isset($tabBilan['N46']) && isset($tabBilanPre['244'])) $tabBilan['N46']=$tabBilanPre['244'];
if (!isset($tabBilan['N47']) && isset($tabBilanPre['250'])) $tabBilan['N47']=$tabBilanPre['250'];
if (!isset($tabBilan['N48']) && isset($tabBilanPre['252'])) $tabBilan['N48']=$tabBilanPre['252'];
if (!isset($tabBilan['N49']) && isset($tabBilanPre['254'])) $tabBilan['N49']=$tabBilanPre['254'];
if (!isset($tabBilan['N50']) && isset($tabBilanPre['256'])) $tabBilan['N50']=$tabBilanPre['256'];
if (!isset($tabBilan['N51']) && isset($tabBilanPre['262'])) $tabBilan['N51']=$tabBilanPre['262'];
if (!isset($tabBilan['N52']) && isset($tabBilanPre['264'])) $tabBilan['N52']=$tabBilanPre['264'];
if (!isset($tabBilan['N53']) && isset($tabBilanPre['270'])) $tabBilan['N53']=$tabBilanPre['270'];
if (!isset($tabBilan['N54']) && isset($tabBilanPre['280'])) $tabBilan['N54']=$tabBilanPre['280'];
if (!isset($tabBilan['N55']) && isset($tabBilanPre['290'])) $tabBilan['N55']=$tabBilanPre['290'];
if (!isset($tabBilan['N56']) && isset($tabBilanPre['294'])) $tabBilan['N56']=$tabBilanPre['294'];
if (!isset($tabBilan['N57']) && isset($tabBilanPre['300'])) $tabBilan['N57']=$tabBilanPre['300'];
if (!isset($tabBilan['N58']) && isset($tabBilanPre['306'])) $tabBilan['N58']=$tabBilanPre['306'];
if (!isset($tabBilan['N59']) && isset($tabBilanPre['310'])) $tabBilan['N59']=$tabBilanPre['310'];
}
elseif ($tabBilan['CONSOLIDE']=='A' || $tabBilan['CONSOLIDE']=='B') {
// BANQUES
if (!isset($tabBilan['NA1']) && isset($tabBilanPre['AA1'])) $tabBilan['NA1']=$tabBilanPre['AA1'];
if (!isset($tabBilan['NA2']) && isset($tabBilanPre['AA2'])) $tabBilan['NA2']=$tabBilanPre['AA2'];
if (!isset($tabBilan['NA3']) && isset($tabBilanPre['AA3'])) $tabBilan['NA3']=$tabBilanPre['AA3'];
if (!isset($tabBilan['NP1']) && isset($tabBilanPre['AP1'])) $tabBilan['NP1']=$tabBilanPre['AP1'];
if (!isset($tabBilan['NP2']) && isset($tabBilanPre['AP2'])) $tabBilan['NP2']=$tabBilanPre['AP2'];
if (!isset($tabBilan['NP3']) && isset($tabBilanPre['AP3'])) $tabBilan['NP3']=$tabBilanPre['AP3'];
if (!isset($tabBilan['NP4']) && isset($tabBilanPre['AP4'])) $tabBilan['NP4']=$tabBilanPre['AP4'];
if (!isset($tabBilan['NP5']) && isset($tabBilanPre['AP5'])) $tabBilan['NP5']=$tabBilanPre['AP5'];
if (!isset($tabBilan['NP6']) && isset($tabBilanPre['AP6'])) $tabBilan['NP6']=$tabBilanPre['AP6'];
if (!isset($tabBilan['NP7']) && isset($tabBilanPre['AP7'])) $tabBilan['NP7']=$tabBilanPre['AP7'];
if (!isset($tabBilan['NP8']) && isset($tabBilanPre['AP8'])) $tabBilan['NP8']=$tabBilanPre['AP8'];
if (!isset($tabBilan['NP9']) && isset($tabBilanPre['AP9'])) $tabBilan['NP9']=$tabBilanPre['AP9'];
if (!isset($tabBilan['NR1']) && isset($tabBilanPre['AR1'])) $tabBilan['NR1']=$tabBilanPre['AR1'];
if (!isset($tabBilan['NR2']) && isset($tabBilanPre['AR2'])) $tabBilan['NR2']=$tabBilanPre['AR2'];
if (!isset($tabBilan['NR3']) && isset($tabBilanPre['AR3'])) $tabBilan['NR3']=$tabBilanPre['AR3'];
// ASSURANCE
if (!isset($tabBilan['NR4']) && isset($tabBilanPre['AR4'])) $tabBilan['AR4']=$tabBilanPre['AR4'];
}
} // --- Fin traitement bilan précédent
}
//Put Result in memory

View File

@ -145,7 +145,7 @@ class Metier_Partenaires_MCadastre
'sdv1.cad_perloc l, sdv1.cad_permor e',
'e.INTCIF, e.DNUPER, e.CCOGRM, e.DDENPM, e.DSIPMO, e.DFORME, e.FILLER, e.DSIREN, e.DLIGN3, e.DLIGN4, e.DLIGN5, e.DLIGN6, e.CCODEP, e.CCOCOM,
l.CCODRO, l.CCOCOM, l.CCOPRF, l.CCOSEC, l.DNUPLA, l.DNUBAT, l.DESC, l.DNIV, l.DPOR, l.CCONLC, l.CCOAFF0, l.DSUPOD0, l.CCOAFF1, l.DSUPOD1, l.CCOAFF2, l.DSUPOD2, l.CCOAFF3, l.DSUPOD3, l.CCOAFF4, l.DSUPOD4, l.CCOAFF5, l.DSUPOD5, l.CCOAFF6, l.DSUPOD6, l.CCOAFF7, l.DSUPOD7, l.CCOAFF8, l.DSUPOD8, l.CCOAFF9, l.DSUPOD9, l.CCODEP, l.DLICOM, l.CCORIV, l.CNAVOI, l.DLIVOI, l.DNUVOI, l.DLTNUV',
"e.DSIREN=$siren AND e.INTCIF=l.INTCIF AND e.DNUPER=l.DNUPER", false, MYSQL_ASSOC);
"e.DSIREN='$siren' AND e.INTCIF=l.INTCIF AND e.DNUPER=l.DNUPER", false, MYSQL_ASSOC);
$tabRet=array();
if (count($tabTmp)>0 ) {
foreach ($tabTmp as $i=>$loc) {
@ -224,7 +224,7 @@ class Metier_Partenaires_MCadastre
'sdv1.cad_perpar p, sdv1.cad_permor e',
'e.INTCIF, e.DNUPER, e.CCOGRM, e.DDENPM, e.DSIPMO, e.DFORME, e.FILLER, e.DSIREN, e.DLIGN3, e.DLIGN4, e.DLIGN5, e.DLIGN6, e.CCODEP, e.CCOCOM,
p.CCODRO, p.CCOCOM, p.CCOPRF, p.CCOSEC, p.DNUPLA, p.DCNPAR, p.DSGRPF0, p.DCNSUF0, p.DSGRPF1, p.DCNSUF1, p.DSGRPF2, p.DCNSUF2, p.DSGRPF3, p.DCNSUF3, p.DSGRPF4, p.DCNSUF4, p.DSGRPF5, p.DCNSUF5, p.DSGRPF6, p.DCNSUF6, p.DSGRPF7, p.DCNSUF7, p.DSGRPF8, p.DCNSUF8, p.DSGRPF9, p.DCNSUF9, p.CCODEP, p.DLICOM, p.CCORIV, p.CNAVOI, p.DLIVOI, p.DNUVOI, p.DLTNUV',
"e.DSIREN=$siren AND e.INTCIF=p.INTCIF AND e.DNUPER=p.DNUPER", false, MYSQL_ASSOC);
"e.DSIREN='$siren' AND e.INTCIF=p.INTCIF AND e.DNUPER=p.DNUPER", false, MYSQL_ASSOC);
$tabRet=array();
foreach ($tabTmp as $i=>$loc) {
$tabLoc=array( 'idCentre'=>$loc['INTCIF'],

View File

@ -2717,7 +2717,7 @@ function calculIndiScore($siren, $nic=0, $accesDist=false, $cycleClient=2, $mail
// --- Cut Off
$ENQUETE='';
$tabTmp = $iDb->select('jo.scores_cutoff',
'encours, scoreSolv, scoreDir, scoreConf, DATE(dateInsert)*1 AS dateInsert, DATE(dateUpdate)*1 AS dateUpdate',
'encours, scoreSolv, scoreDir, scoreConf, paiement, DATE(dateInsert)*1 AS dateInsert, DATE(dateUpdate)*1 AS dateUpdate',
"siren=$siren", INDISCORE_DEBUG, MYSQL_ASSOC);
$timer['scores_cutoff'] = microtime(true);
if (count($tabTmp) > 0) {
@ -2728,6 +2728,8 @@ function calculIndiScore($siren, $nic=0, $accesDist=false, $cycleClient=2, $mail
}
// Si pas plus vieux que 6 mois
if ($classWdate->nbMoisEntre($dateMaj, date('Ymd')) <= $ENQUETELIM) {
$tabLibCS = $iFacto->getLibInfoCS($tabTmp[0]['paiement']);
$libInfoPaiement = $tabLibCS['LibCS'];
$encoursForce=$tabTmp[0]['encours'];
if ($tabTmp[0]['scoreConf'] !== null) {
$SCORECONF = $tabTmp[0]['scoreConf'];

View File

@ -41,6 +41,7 @@ return array (
'COMPETENCES' => "Compétences territoriales",
'CONVENTIONS' => "Conventions collectives",
'MARQUES' => "Marques déposées",
'CONTENTIEUX' => "Contentieux Judiciaires",
//EVALUATION
'INDISCORE' => "indiScore&copy;",

View File

@ -81,88 +81,7 @@ class Scores_Ws_Server
* code | label | category
*
*/
protected $listeDroits = array (
//RECHERCHE
'RECHCSV' => "Export des résultats de la recherche",
'IPARI' => "Investigation par l'image IparI&copy;",
'HISTOBODACC' => "Historique des annonces bodacc",
'INVESTIG' => "Investigation",
'SEARCHENT' => "Recherche Entreprise",
'SEARCHDIR' => "Recherche Dirigeant",
'SEARCHACT' => "Recherche Actionnaire",
//IDENTITE
'IDENTITE' => "Fiche d'identité",
'IDPROCOL' => 'Fiche procédure collective',
'LIENS' => "Liens inter-entreprise",
'ETABLISSEMENTS' => "Liste des établissements",
'GROUPE' => "Informations et organigramme du groupe",
'EVENINSEE' => '&Eacute;vènements INSEE',
'AVISINSEE' => 'Avis de situation INSEE',
'AVISRNCS' => 'Avis de situation RNCS',
'RNVP' => "Normalisation postale",
//DIRIGEANT
'DIRIGEANTS' => "Liste des dirigeants",
'DIRIGEANTSOP' => "Liste des dirigeants opérationnels",
//FINANCE
'SYNTHESE' => "Synthèse",
'RATIOS' => "Ratios",
'FLUX' => "Flux de trésorerie",
'LIASSE' => "Liasse fiscale",
'LIASSEXLS' => "Export des Liasses au format XLS",
'UPLOADBILAN' => "Saisie de bilan",
'BOURSE' => "Bourse & cotations",
'BANQUE' => "Relations bancaires",
//JURIDIQUE
'ANNONCES' => "Annonces légales",
'INFOSREG' => "Informations réglementée",
'COMPETENCES' => "Compétences territoriales",
'CONVENTIONS' => "Conventions collectives",
'MARQUES' => "Marques déposées",
//EVALUATION
'INDISCORE' => "indiScore&copy;",
'INDISCORE2' => "Rapport synthetique",
'INDISCORE3' => "Rapport complet",
'INDISCOREP' => "indiScore+",
'INDISCORE2P' => "Rapport synthetique+",
'INDISCORE3P' => "Rapport complet+",
'VALORISATION' => "Valorisation",
'SCORECSF' => "Score CSF",
'ENQUETEC' => "Enquête commerciale",
'AVISCREDIT' => "Avis de crédit personnalisé",
//PIECES
'KBIS' => "Extrait RCS",
'ACTES' => "Pièces officielles",
'PRIVILEGES' => "Privilèges",
//SURVEILLANCES
'SURVANNONCE' => "Surveillance des annonces légales",
'SURVINSEE' => "Surveillance des événements INSEE",
'SURVBILAN' => "Surveillance des bilans saisies (liasse fiscale)",
'SURVSCORE' => "Surveillance des événements sur le score",
'SURVACTES' => "Surveillance des pieces officielles (comptes annuels, actes)",
'SURVDIRIGEANTS'=> "Surveillance des dirigeants",
'SURVPAIEMENTS' => "Surveillance des paiements",
'SURVLIENS' => "Surveillance des liens financiers",
'SURVPRIV' => "Surveillance des privilèges",
//OPTIONS
'MONPROFIL' => "Mon profil",
'EDITION' => "Mode Edition",
'PORTEFEUILLE' => "Portefeuille",
'SURVLISTE' => "Liste des surveillances",
//DIVERS
'INTERNATIONAL' => "Recherche Internationale",
'BDF' => "Banque de France",
'WORLDCHECK' => "World-Check Risk Intelligence",
);
protected $listeDroits = array ();
protected $listeCategory = array(
'RECHERCHE' => array(
@ -378,6 +297,9 @@ class Scores_Ws_Server
defined('TIME_LISIBLE')
|| define ('TIME_LISIBLE', substr(DATETIME,8,2).':'.substr(DATETIME,10,2).':'.substr(DATETIME,12,2));
$this->listeDroits = include APPLICATION_PATH . '/../library/Scores/Account/Access.php';
}
/**

View File

@ -0,0 +1,10 @@
<?php
return array(
'DELIBERE' => "Affaire en délibéré",
'ENCOURS' => "Affaire en cours",
'EXPERT' => "Affaire en cours d'expertise",
'JUGRAP' => "Affaire devant le juge",
'TERMJON' => "Affaire terminée (jonction)",
'TERMJUG' => "Affaire jugée et terminée",
'TERMRAD' => "Affaire terminée (radiation)",
);