2009-03-13 14:58:10 +00:00
|
|
|
<?php
|
2009-07-20 16:17:33 +00:00
|
|
|
require_once 'partenaires/classMTva.php';
|
|
|
|
require_once 'common/dates.php';
|
2010-04-14 16:00:45 +00:00
|
|
|
require_once realpath(dirname(__FILE__).'/../pages_saisie/constantes.php');
|
2009-02-19 16:28:12 +00:00
|
|
|
|
2009-04-01 12:45:45 +00:00
|
|
|
$tabInfo = $_SESSION['tabInfo'];
|
|
|
|
|
2010-04-26 14:46:13 +00:00
|
|
|
if ( isset($_REQUEST['frmSaisie']) )
|
|
|
|
$tabSaisie = $_REQUEST['frmSaisie'];
|
|
|
|
if ( isset($_REQUEST['jugement']) )
|
|
|
|
$tabJugement = $_REQUEST['jugement'];
|
|
|
|
if ( isset($_REQUEST['actionnaire']) )
|
|
|
|
$tabActionna = $_REQUEST['actionnaire'];
|
|
|
|
if ( isset($_REQUEST['particip']) )
|
|
|
|
$tabParticip = $_REQUEST['particip'];
|
|
|
|
if ( isset($_REQUEST['perimetreVente']) )
|
|
|
|
$perimetreVente = $_REQUEST['perimetreVente'];
|
|
|
|
if ( isset($_REQUEST['etablissement5500']) )
|
|
|
|
$etablissement5500 = $_REQUEST['etablissement5500'];
|
|
|
|
if ( isset($_REQUEST['etabnic']) )
|
|
|
|
$etabnic = $_REQUEST['etabnic'];
|
|
|
|
|
|
|
|
if (isset($_FILES['logoFile']) &&
|
|
|
|
$_FILES['logoFile']['error']!=UPLOAD_ERR_NO_FILE )
|
2009-10-16 12:30:19 +00:00
|
|
|
{
|
2010-04-26 14:46:13 +00:00
|
|
|
/** Un fichier a été uploadé **/
|
|
|
|
$logoFile = $_FILES['logoFile'];
|
|
|
|
$tmp_file = $logoFile['tmp_name'];
|
|
|
|
|
|
|
|
if ($logoFile['error']!=UPLOAD_ERR_OK)
|
|
|
|
$message='Erreur lors de la copie du fichier';
|
|
|
|
|
|
|
|
if( !is_uploaded_file($tmp_file) )
|
|
|
|
$message="Le fichier est introuvable";
|
|
|
|
else {
|
|
|
|
// on vérifie maintenant l'extension
|
|
|
|
$type_file = $logoFile['type'];
|
|
|
|
$ext='';
|
|
|
|
if ( strstr($type_file, 'jpg')) $ext='jpg';
|
|
|
|
elseif( strstr($type_file, 'jpeg')) $ext='jpeg';
|
|
|
|
elseif( strstr($type_file, 'bmp')) $ext='bmp';
|
|
|
|
elseif( strstr($type_file, 'gif')) $ext='gif';
|
|
|
|
elseif( strstr($type_file, 'png')) $ext='png';
|
|
|
|
if ($ext=='')
|
|
|
|
$message="Le fichier n'est pas une image";
|
2009-02-19 16:28:12 +00:00
|
|
|
else {
|
2010-04-26 14:46:13 +00:00
|
|
|
// on copie le fichier dans le dossier de destination
|
|
|
|
$name_file = $siren.'.'.$ext;//$logoFile['name'];
|
|
|
|
if( !move_uploaded_file($tmp_file, PATH_LOGOS . $name_file) )
|
|
|
|
$message="Impossible de copier le fichier dans ".PATH_LOGOS;
|
|
|
|
else
|
|
|
|
$message="Le fichier a bien été uploadé";
|
2009-02-19 16:28:12 +00:00
|
|
|
}
|
2010-04-26 14:46:13 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
elseif ( isset($_REQUEST['logoUrl']['del']) ||
|
|
|
|
( isset($_REQUEST['logoUrl']['url']) &&
|
|
|
|
$_REQUEST['logoUrl']['url']!='' ) )
|
|
|
|
{
|
|
|
|
if ( isset($_REQUEST['logoUrl']['del']) && $_REQUEST['logoUrl']['del'] )
|
|
|
|
{
|
|
|
|
@unlink(PATH_LOGOS.$siren.'.jpeg');
|
|
|
|
@unlink(PATH_LOGOS.$siren.'.jpg');
|
|
|
|
@unlink(PATH_LOGOS.$siren.'.png');
|
|
|
|
@unlink(PATH_LOGOS.$siren.'.gif');
|
|
|
|
@unlink(PATH_LOGOS.$siren.'.bmp');
|
|
|
|
@unlink(PATH_LOGOS.$siren.'.');
|
2010-02-23 15:27:18 +00:00
|
|
|
}
|
2010-04-26 14:46:13 +00:00
|
|
|
else
|
2010-02-23 15:27:18 +00:00
|
|
|
{
|
2010-04-26 14:46:13 +00:00
|
|
|
require_once 'common/curl.php';
|
|
|
|
$logoUrl = $_REQUEST['logoUrl']['url'];
|
|
|
|
$tabTmp = parse_url($logoUrl);
|
|
|
|
$hostUrl = $tabTmp['host'];
|
|
|
|
$pathUrl = $tabTmp['path'];
|
|
|
|
$tmp=explode('.', basename($pathUrl));
|
|
|
|
$ext=strtolower(end($tmp));
|
|
|
|
$page=getUrl($logoUrl, '', '', '', false, $hostUrl, '', 7);
|
|
|
|
$body=$page['body'];
|
|
|
|
//die(print_r());
|
|
|
|
|
|
|
|
if ( $ext<>'jpeg' &&
|
|
|
|
$ext<>'jpg' &&
|
|
|
|
$ext<>'png' &&
|
|
|
|
$ext<>'gif' &&
|
|
|
|
$ext<>'bmp')
|
2010-02-23 15:27:18 +00:00
|
|
|
{
|
2010-04-26 14:46:13 +00:00
|
|
|
$tmp=explode('/', $page['header']['Content-Type']);
|
|
|
|
$ext=trim(str_replace('?', '',strtolower(end($tmp))));
|
2009-02-19 16:28:12 +00:00
|
|
|
}
|
2010-04-26 14:46:13 +00:00
|
|
|
$name_file = $siren.'.'.$ext;
|
|
|
|
$fp=@fopen(PATH_LOGOS.$name_file, 'w');
|
|
|
|
@fwrite($fp, $body);
|
|
|
|
@fclose($fp);
|
|
|
|
//die('Logo traité');
|
|
|
|
}
|
|
|
|
} else $message='';
|
2009-07-07 16:35:28 +00:00
|
|
|
|
2010-04-26 14:46:13 +00:00
|
|
|
if ($tabSaisie['action']=='sauver')
|
|
|
|
{
|
|
|
|
//Vente et Cession evénement 5500
|
|
|
|
if(isset($perimetreVente) && count($perimetreVente)>0)
|
2009-10-27 13:16:42 +00:00
|
|
|
{
|
2010-04-26 14:46:13 +00:00
|
|
|
$tabJugement['even'] = array_merge($tabJugement['even'],$perimetreVente);
|
|
|
|
}
|
2010-04-14 16:00:45 +00:00
|
|
|
|
2010-04-26 14:46:13 +00:00
|
|
|
if (isset($etablissement5500) && count($etablissement5500)>0)
|
|
|
|
{
|
|
|
|
$countEtab = 0;
|
|
|
|
$txtEtab = '';
|
|
|
|
foreach($etablissement5500 as $etab){
|
|
|
|
$txtEtab.= $etab;
|
|
|
|
$countEtab++;
|
|
|
|
if($countEtab>10) break;
|
|
|
|
if( count($etablissement5500) > $countEtab )
|
|
|
|
{ $txtEtab.=', '; }
|
2009-04-10 13:24:51 +00:00
|
|
|
}
|
2009-07-07 16:35:28 +00:00
|
|
|
|
2010-04-26 14:46:13 +00:00
|
|
|
if ( count($etablissement5500)>1 )
|
|
|
|
{ $txt = 'Etablissement(s) concerné(s) : '; }
|
|
|
|
else{ $txt = 'Etablissement concerné : '; }
|
2009-09-10 15:31:37 +00:00
|
|
|
|
2010-04-26 14:46:13 +00:00
|
|
|
if ($tabJugement['comp']!='')
|
|
|
|
$tabJugement['comp'].= ' '.$txt.$txtEtab;
|
|
|
|
else
|
|
|
|
$tabJugement['comp'] = ' '.$txt.$txtEtab;
|
|
|
|
}
|
2009-07-07 16:35:28 +00:00
|
|
|
|
2010-04-26 14:46:13 +00:00
|
|
|
if(isset($etabnic) && $etabnic != '')
|
|
|
|
{
|
|
|
|
if( isset($txtEtab) && $txtEtab!='' )
|
|
|
|
$tabJugement['comp'].= ', '.$etabnic;
|
|
|
|
else
|
|
|
|
$tabJugement['comp'].= 'Etablissement concerné : '.$etabnic;
|
|
|
|
}
|
2009-04-02 15:04:20 +00:00
|
|
|
|
2010-04-26 14:46:13 +00:00
|
|
|
if( $tabJugement['oppo'] == 'adresse'){
|
|
|
|
if ($tabJugement['comp']!='')
|
|
|
|
$tabJugement['comp'].= ' Opposition : A l\'adresse du bien vendu';
|
|
|
|
else
|
|
|
|
$tabJugement['comp'] = 'Opposition : A l\'adresse du bien vendu';
|
|
|
|
}
|
2010-04-14 16:00:45 +00:00
|
|
|
|
2010-04-26 14:46:13 +00:00
|
|
|
//Traitement des chaînes de caractères
|
|
|
|
require 'i18n/cleanchar.php';
|
|
|
|
$tabSaisie = cleanstring_deep($tabSaisie);
|
|
|
|
$tabJugement = cleanstring_deep($tabJugement);
|
|
|
|
$tabActionna = cleanstring_deep($tabActionna);
|
|
|
|
$tabParticip = cleanstring_deep($tabParticip);
|
|
|
|
|
|
|
|
$tabInfos = array(
|
|
|
|
'identite'=>$tabSaisie,
|
|
|
|
'jugement'=>$tabJugement,
|
|
|
|
'actionnaire'=>$tabActionna,
|
|
|
|
'participation'=>$tabParticip,
|
|
|
|
);
|
|
|
|
$firephp->log($tabInfos, 'tabInfo');
|
|
|
|
|
|
|
|
$message='Erreur lors de l\'enregistrement !';
|
|
|
|
try {
|
|
|
|
$O = $client->setInfosEntrep($siret, $idEntreprise, $tabInfos);
|
|
|
|
if ($O['result']==1) $message='Informations mises à jour !';
|
|
|
|
} catch (SoapFault $fault) {
|
|
|
|
require_once 'soaperror.php';
|
|
|
|
processSoapFault($client,$fault,$tabInfo);
|
2009-02-19 16:28:12 +00:00
|
|
|
}
|
2009-07-07 16:35:28 +00:00
|
|
|
|
2010-04-26 14:46:13 +00:00
|
|
|
$tabSaisie=array(
|
|
|
|
'source' => $tabJugement['source'],
|
|
|
|
'dateParution' => $tabJugement['dateParution'],
|
|
|
|
'numParution' => $tabJugement['numParution']
|
|
|
|
);
|
|
|
|
|
|
|
|
$_SESSION['saisie'] = $tabSaisie;
|
|
|
|
}
|
|
|
|
|
2009-03-06 16:29:16 +00:00
|
|
|
try {
|
2010-01-12 16:58:19 +00:00
|
|
|
$O = $client->getIdentite($siret, $idEntreprise, false);
|
2009-02-19 16:28:12 +00:00
|
|
|
$etab=$O['result'];
|
|
|
|
$tabEntrep=array();
|
|
|
|
$tabEntrep['raisonSociale']=$etab['Nom'];
|
|
|
|
$tabEntrep['siren']=$etab['Siren'];
|
|
|
|
$tabEntrep['tva']=$etab['TvaNumero'];
|
|
|
|
$tabEntrep['isin']=$etab['Isin'];
|
|
|
|
$tabEntrep['AutreId']=$etab['AutreId'];
|
|
|
|
$tabEntrep['active']=$etab['Statut'];
|
|
|
|
$tabEntrep['Source']=$etab['Source'];
|
|
|
|
$tabEntrep['SourceId']=$etab['SourceId'];
|
|
|
|
$tabEntrep['codeCommune']=$etab['Dept'].$etab['codeCommune'];
|
|
|
|
$tabEntrep['nafEn']=$etab['NafEnt'];
|
|
|
|
$tabEntrep['nafEt']=$etab['NafEtab'];
|
|
|
|
$_SESSION['tabInfo']['entrep']=$tabEntrep;
|
|
|
|
} catch (SoapFault $fault) {
|
2009-07-21 07:17:54 +00:00
|
|
|
require_once 'soaperror.php';
|
2009-02-26 17:16:11 +00:00
|
|
|
processSoapFault($client,$fault,$tabInfo);
|
2009-02-19 16:28:12 +00:00
|
|
|
die();
|
|
|
|
}
|
|
|
|
|
|
|
|
?>
|
2009-07-21 12:35:13 +00:00
|
|
|
|
|
|
|
<div id="center">
|
|
|
|
<?php
|
|
|
|
if ($etab['Siege']==0){
|
|
|
|
?>
|
|
|
|
<h1 class="titre">IDENTITE DE L'ÉTABLISSEMENT</h1>
|
|
|
|
<?php
|
|
|
|
}else{
|
|
|
|
?>
|
|
|
|
<h1 class="titre">IDENTITE DE L'ENTREPRISE</h1>
|
|
|
|
<?php
|
|
|
|
}
|
|
|
|
?>
|
2010-02-23 15:27:18 +00:00
|
|
|
<form name="form_saisie" action="./?page=saisie" method="post" enctype="multipart/form-data">
|
2009-02-19 16:28:12 +00:00
|
|
|
<input type="hidden" name="frmSaisie[action]" value="sauver"/>
|
|
|
|
<input type="hidden" name="siret" value="<?=$siret?>"/>
|
2009-03-11 07:51:18 +00:00
|
|
|
<input type="hidden" name="id" value="<?=$idEntreprise?>"/>
|
2009-02-19 16:28:12 +00:00
|
|
|
<!--<input type="hidden" name="MAX_FILE_SIZE" value="2097152" />-->
|
|
|
|
<?php
|
2009-03-13 14:58:10 +00:00
|
|
|
if ($message<>'') {
|
|
|
|
?>
|
2010-06-14 14:47:33 +00:00
|
|
|
<div style="margin:5px; padding: 0pt 0.7em;" class="ui-state-highlight ui-corner-all">
|
|
|
|
<p><span style="float: left; margin-right: 0.3em;" class="ui-icon ui-icon-info"></span>
|
|
|
|
<?=$message;?></p>
|
|
|
|
</div>
|
2009-03-13 14:58:10 +00:00
|
|
|
<?php
|
|
|
|
}
|
|
|
|
?>
|
2010-06-14 14:47:33 +00:00
|
|
|
<div>
|
2009-03-13 14:58:10 +00:00
|
|
|
<label>Numéro identifiant, Siret</label>
|
2009-04-10 13:24:51 +00:00
|
|
|
<input type="hidden" name="siren" value="<?php print $etab['Siren'];?>" />
|
2009-09-10 15:31:37 +00:00
|
|
|
<input type="hidden" name="nic" value="<?php print $etab['Nic'];?>" />
|
2009-03-17 14:16:38 +00:00
|
|
|
<?=substr($etab['Siren'],0,3).' '.substr($etab['Siren'],3,3).' '.substr($etab['Siren'],6,3).' <i>'.substr($etab['Siret'],9,5).'</i>'?>
|
2010-06-14 14:47:33 +00:00
|
|
|
</div>
|
|
|
|
|
|
|
|
<div>
|
2009-03-13 14:58:10 +00:00
|
|
|
<label>Raison Sociale</label>
|
2010-06-14 14:47:33 +00:00
|
|
|
<?=$etab['Nom']; if ($etab['Nom2']<>'') echo '<br/>'.$etab['Nom2'];?>
|
|
|
|
</div>
|
2009-07-07 16:35:28 +00:00
|
|
|
|
2009-02-19 16:28:12 +00:00
|
|
|
<?php
|
|
|
|
if ($etab['Enseigne']<>'' && $etab['Sigle']<>'') { $titre='Enseigne / Sigle'; $lib=$etab['Enseigne'].' / '.$etab['Sigle']; }
|
|
|
|
elseif ($etab['Enseigne']<>'' && $etab['Sigle']=='') { $titre='Enseigne'; $lib=$etab['Enseigne']; }
|
|
|
|
elseif ($etab['Enseigne']=='' && $etab['Sigle']<>'') { $titre='Sigle'; $lib=$etab['Sigle']; }
|
2009-07-21 12:35:13 +00:00
|
|
|
else $titre='';
|
2009-03-13 14:58:10 +00:00
|
|
|
if ($titre<>'') {}
|
2009-02-19 16:28:12 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
** On recherche un logo
|
|
|
|
**/
|
|
|
|
$urlImg=$siteWeb='';
|
|
|
|
$locImg=PATH_LOGOS.$etab['Siren'];
|
2009-07-07 16:35:28 +00:00
|
|
|
if (file_exists($locImg.'.gif')) { $urlImg='/logos/'.$etab['Siren'].'.gif'; $ext='.gif'; }
|
|
|
|
elseif (file_exists($locImg.'.png')) { $urlImg='/logos/'.$etab['Siren'].'.png'; $ext='.png'; }
|
|
|
|
elseif (file_exists($locImg.'.jpg')) { $urlImg='/logos/'.$etab['Siren'].'.jpg'; $ext='.jpg'; }
|
|
|
|
elseif (file_exists($locImg.'.jpeg')) { $urlImg='/logos/'.$etab['Siren'].'.jpeg'; $ext='.jpeg'; }
|
|
|
|
|
2009-02-19 16:28:12 +00:00
|
|
|
if ($urlImg=='' && $etab['Isin']<>'') {
|
|
|
|
$locImg=PATH_LOGOS.$etab['Isin'];
|
2009-07-07 16:35:28 +00:00
|
|
|
if (file_exists($locImg.'.gif')) { $urlImg='/logos/'.$etab['Isin'].'.gif'; $ext='.gif'; }
|
|
|
|
elseif (file_exists($locImg.'.png')) { $urlImg='/logos/'.$etab['Isin'].'.png'; $ext='.png'; }
|
|
|
|
elseif (file_exists($locImg.'.jpg')) { $urlImg='/logos/'.$etab['Isin'].'.jpg'; $ext='.jpg'; }
|
|
|
|
elseif (file_exists($locImg.'.jpeg')) { $urlImg='/logos/'.$etab['Isin'].'.jpeg'; $ext='.jpeg'; }
|
2009-02-19 16:28:12 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
if (substr($etab['Web'],0,7)<>'http://')
|
|
|
|
$siteWeb='http://'.$etab['Web'];
|
|
|
|
else
|
|
|
|
$siteWeb=$etab['Web'];
|
|
|
|
|
|
|
|
if ($urlImg<>'') {
|
|
|
|
$tabTmp=@getimagesize($locImg.$ext);
|
|
|
|
$w=$tabTmp[0];
|
|
|
|
$h=$tabTmp[1];
|
|
|
|
if ($w>350) $strSize=@redimage($locImg.$ext,350,150);
|
|
|
|
else $strSize='';
|
|
|
|
}
|
|
|
|
?>
|
2009-03-13 14:58:10 +00:00
|
|
|
<fieldset>
|
2009-07-07 16:35:28 +00:00
|
|
|
<legend>Logo</legend>
|
2010-06-14 14:47:33 +00:00
|
|
|
<div><?php if ($urlImg<>'') { echo "<img src=\"$urlImg\" $strSize/>"; }?></div>
|
2009-03-13 14:58:10 +00:00
|
|
|
<label>Fichier</label><input type="file" name="logoFile" size="30" />
|
|
|
|
<label>ou URL</label><input type="text" name="logoUrl[url]" size="40" maxlength="200"/><br/>
|
|
|
|
<label>ou Supprimer le logo existant</label><input type="checkbox" name="logoUrl[del]" value="true" />
|
|
|
|
</fieldset>
|
2009-04-16 15:48:14 +00:00
|
|
|
|
2010-02-10 17:27:03 +00:00
|
|
|
<h2>Raison sociale et coordonnées</h2>
|
2009-07-07 16:35:28 +00:00
|
|
|
|
2009-03-13 14:58:10 +00:00
|
|
|
<label>Téléphone</label>
|
|
|
|
<input type="text" name="frmSaisie[tel]" size="25" maxlength="100" value="<?=trim($etab['Tel'])?>" />
|
|
|
|
<label>Fax</label>
|
|
|
|
<input type="text" name="frmSaisie[fax]" size="25" maxlength="100" value="<?=trim($etab['Fax'])?>" />
|
|
|
|
<label>Site Internet</label>
|
|
|
|
<input type="text" name="frmSaisie[web]" size="40" maxlength="100" value="<?=$siteWeb?>" />
|
|
|
|
<label>E-mail</label>
|
|
|
|
<input type="text" name="frmSaisie[mail]" size="40" maxlength="100" value="<?=trim($etab['Mail'])?>" />
|
2009-07-07 16:35:28 +00:00
|
|
|
|
2010-02-10 17:27:03 +00:00
|
|
|
<h2>Activité(s) et Chiffres d'Affaires</h2>
|
2009-03-13 14:58:10 +00:00
|
|
|
|
|
|
|
<label>Code ISIN</label>
|
2009-07-07 16:35:28 +00:00
|
|
|
<input type="text" name="frmSaisie[isin]" size="15" maxlength="15" value="<?=trim($etab['Isin'])?>" />
|
2009-03-13 14:58:10 +00:00
|
|
|
<label>Activité déclarée de l'entreprise</label>
|
|
|
|
<textarea name="frmSaisie[activite]" rows="5" cols="40"><?=$etab['Activite']?></textarea>
|
|
|
|
|
|
|
|
<fieldset>
|
|
|
|
<legend>Capital</legend>
|
|
|
|
<label>Montant</label>
|
|
|
|
<input type="text" name="frmSaisie[capital_mt]" size="10" maxlength="11" value="<?=trim($etab['Capital'])*1.0?>" disabled/>
|
|
|
|
<label>Devise</label>
|
|
|
|
<select disabled name="frmSaisie[capital_dev]">
|
|
|
|
<?php
|
2009-02-19 16:28:12 +00:00
|
|
|
$tmp=$client->getDevises();
|
|
|
|
$liste=$tmp['result'];
|
|
|
|
$selOne=false;
|
|
|
|
foreach ($liste as $iso=>$lib) {
|
|
|
|
if (trim($etab['CapitalDev'])==$iso) { $selOne=true; $sel='selected'; } else $sel='';
|
|
|
|
if (strlen($lib)>39) $lib=substr($lib,0,41).'...';
|
|
|
|
echo "<option value=\"$iso\" $sel >$lib</option>";
|
2009-03-13 14:58:10 +00:00
|
|
|
}
|
|
|
|
if (!$selOne) echo '<option value="0000" selected>-</option>';
|
|
|
|
?>
|
|
|
|
</select>
|
|
|
|
</fieldset>
|
2009-02-19 16:28:12 +00:00
|
|
|
|
2009-07-21 12:35:13 +00:00
|
|
|
<h2>BODACC</h2>
|
2009-03-13 14:58:10 +00:00
|
|
|
|
|
|
|
<label>Source <font color="Red">*</font></label>
|
|
|
|
<select name="jugement[source]">
|
2009-04-10 13:24:51 +00:00
|
|
|
|
2009-03-13 14:58:10 +00:00
|
|
|
<option value="TS" <?if (!isset($_SESSION['saisie']['source']) || $_SESSION['saisie']['source']=='TS') echo 'selected';?>>Tribunal via CCI</option>
|
|
|
|
<option value="TD" <?if ($_SESSION['saisie']['source']=='TD') echo 'selected';?>>Tribunal directement</option>
|
|
|
|
<option value="TA" <?if ($_SESSION['saisie']['source']=='TA') echo 'selected';?>>Tribunal via autre tiers</option>
|
2009-07-07 16:35:28 +00:00
|
|
|
<?php
|
2009-03-13 14:58:10 +00:00
|
|
|
$tmp=$client->getListeJalCollecte();
|
2009-07-07 16:35:28 +00:00
|
|
|
$liste=$tmp['result'];
|
2009-03-13 14:58:10 +00:00
|
|
|
foreach ($liste as $id=>$lib) {
|
|
|
|
echo "<option value=\"JS$id\" ";
|
|
|
|
if ($_SESSION['saisie']['source']=="JS$id") echo 'selected';
|
|
|
|
echo ">$lib</option>";
|
|
|
|
}
|
|
|
|
?>
|
2009-04-10 13:24:51 +00:00
|
|
|
|
2009-03-13 14:58:10 +00:00
|
|
|
</select>
|
2009-02-19 16:28:12 +00:00
|
|
|
|
2009-03-17 10:16:49 +00:00
|
|
|
<div id="dateParution">
|
2009-03-13 14:58:10 +00:00
|
|
|
<label>Date de parution <font color="Red">*</font></label>
|
|
|
|
<input class="date" type="text" name="jugement[dateParution]" size="10" maxlength="10" value="<?if (isset($_SESSION['saisie']['dateParution'])) echo $_SESSION['saisie']['dateParution'];?>" />
|
|
|
|
<span class="left">(Format JJ/MM/AAAA)</span>
|
2009-03-17 10:16:49 +00:00
|
|
|
</div>
|
|
|
|
|
2009-07-07 16:35:28 +00:00
|
|
|
<div id="numParution">
|
2009-03-13 14:58:10 +00:00
|
|
|
<label>N° de parution</label>
|
|
|
|
<input type="text" name="jugement[numParution]" size="10" maxlength="10" value="<?if (isset($_SESSION['saisie']['numParution'])) echo $_SESSION['saisie']['numParution'];?>" />
|
2009-03-17 10:16:49 +00:00
|
|
|
</div>
|
2009-07-07 16:35:28 +00:00
|
|
|
|
2009-03-13 14:58:10 +00:00
|
|
|
<label>Date évènement / jugement<font color="Red">*</font></label>
|
|
|
|
<input class="date" type="text" name="jugement[dateJuge]" size="10" maxlength="10" value="" />
|
|
|
|
<span class="left">(Format JJ/MM/AAAA)</span>
|
2009-07-07 16:35:28 +00:00
|
|
|
|
2009-03-13 14:58:10 +00:00
|
|
|
<label>Tribunal <font color="Red">*</font></label>
|
|
|
|
<select id="tribunal" name="jugement[tribunal]">
|
|
|
|
<option value="-" selected>-</option>
|
|
|
|
<?php
|
2010-02-10 17:27:03 +00:00
|
|
|
//Affectation du code tribunal présent dans la fiche identité pour comparaison
|
2009-03-26 16:01:15 +00:00
|
|
|
$codeCmp = $etab['TribunalCode'];
|
|
|
|
|
2010-02-10 17:27:03 +00:00
|
|
|
//Si le code tribunal n'est pas défini dans la fiche identité
|
|
|
|
//alors en sélectionner un par défault suivant le code INSEE
|
2009-03-26 16:01:15 +00:00
|
|
|
if ($codeCmp == ''){
|
|
|
|
try {
|
|
|
|
$O = $client->getListeCompetences($etab['Siret'], 'tri', $_SESSION['tabInfo']['entrep']['codeCommune']);
|
|
|
|
$competences = $O['result'];
|
2009-07-07 16:35:28 +00:00
|
|
|
$firephp->log($competences,'Competences');
|
2009-03-26 16:01:15 +00:00
|
|
|
foreach($competences as $item){
|
2009-07-07 16:35:28 +00:00
|
|
|
if ($item['Type'] == 'C'){
|
2009-03-26 16:01:15 +00:00
|
|
|
$codeCmp = $item['Code'];
|
2009-07-07 16:35:28 +00:00
|
|
|
break;
|
2009-03-26 16:01:15 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
} catch (SoapFault $fault) {
|
2009-07-21 07:17:54 +00:00
|
|
|
include_once 'soaperror.php';
|
2009-03-26 16:01:15 +00:00
|
|
|
processSoapFault($client,$fault,$tabInfo);
|
|
|
|
die();
|
2009-07-07 16:35:28 +00:00
|
|
|
}
|
2009-03-26 16:01:15 +00:00
|
|
|
}
|
|
|
|
|
2009-12-04 17:17:09 +00:00
|
|
|
$tmp=$client->getTribunaux(array('C','I','G','M','P'));
|
2009-07-07 16:35:28 +00:00
|
|
|
$liste=$tmp['result'];
|
2009-03-13 14:58:10 +00:00
|
|
|
asort($liste);
|
|
|
|
foreach ($liste as $code=>$lib) {
|
|
|
|
if (strlen($lib)>39) $lib=substr($lib,0,41).'...';
|
|
|
|
echo '<option value="'.$code.'"';
|
2009-03-26 16:01:15 +00:00
|
|
|
if ($code==$codeCmp) echo ' selected';
|
2009-03-13 14:58:10 +00:00
|
|
|
echo ">$lib</option>";
|
|
|
|
}
|
|
|
|
?>
|
|
|
|
</select>
|
2009-07-07 16:35:28 +00:00
|
|
|
|
2009-03-13 14:58:10 +00:00
|
|
|
<label>Évènement / Jugement <font color="Red">*</font></label>
|
2009-07-07 16:35:28 +00:00
|
|
|
<?php
|
2009-10-16 12:30:19 +00:00
|
|
|
if (!isset($_REQUEST['event']) || $_REQUEST['event']==''){
|
|
|
|
$event = '0000';
|
|
|
|
}else{
|
|
|
|
$event = $_REQUEST['event'];
|
|
|
|
}
|
|
|
|
|
|
|
|
$tabEvent = array(
|
|
|
|
'1100' => 'Ouverture sauvegarde',
|
|
|
|
'1200' => 'Redressement Judiciaire',
|
|
|
|
'1201' => 'Conversion sauvegarde en Redressement Judiciaire',
|
|
|
|
'1300' => 'Conversion Redressement Judiciaire en Liquidation Judiciaire',
|
|
|
|
'1301' => 'Ouverture Liquidation Judiciaire',
|
2010-02-10 17:27:03 +00:00
|
|
|
'1302' => 'Ouverture Liquidation Judiciaire Simplifiée',
|
|
|
|
'1303' => 'Ouverture Liquidation Judiciaire sur résolution du plan',
|
|
|
|
'1304' => 'Réouverture Liquidation Judiciaire',
|
2009-10-16 12:30:19 +00:00
|
|
|
'1305' => 'Liquidation Judiciaire',
|
2010-02-10 17:27:03 +00:00
|
|
|
'1306' => 'Liquidation Judiciaire simplifiée',
|
2009-10-16 12:30:19 +00:00
|
|
|
'1307' => 'Conversion sauvegarde en Liquidation Judiciaire',
|
2010-02-10 17:27:03 +00:00
|
|
|
'1308' => 'Fin du régime de Liquidation Judiciaire Simplifiée',
|
|
|
|
'1309' => 'Conversion Liquidation Judiciaire en Liquidation Judiciaire Simplifiée',
|
|
|
|
'1310' => 'Procédure d\'insolvabilité européenne',
|
|
|
|
'1311' => 'Liquidation Judiciaire par extension au(x) gérant(s)',
|
2009-10-16 12:30:19 +00:00
|
|
|
'1312' => 'Liquidation Judiciaire avec continuation d\'exploitation',
|
|
|
|
'1408' => 'Modification du plan de cession',
|
2010-02-10 17:27:03 +00:00
|
|
|
'1411' => 'Arrêt du plan de cession',
|
|
|
|
'1412' => 'Arrêt du plan de cession partielle',
|
|
|
|
'1413' => 'Arrêt du plan de continuation',
|
|
|
|
'1414' => 'Arrêt du plan de redressement',
|
2009-10-16 12:30:19 +00:00
|
|
|
'1415' => 'Prolongement du plan de cession',
|
2010-02-10 17:27:03 +00:00
|
|
|
'1511' => 'Résolution du plan de cession',
|
|
|
|
'1503' => 'Clôture de la procédure pour insuffisance d\'actif',
|
|
|
|
'1512' => 'Résolution du plan de continuation',
|
2009-10-16 12:30:19 +00:00
|
|
|
'1600' => 'Faillite personnelle',
|
2010-02-10 17:27:03 +00:00
|
|
|
'1601' => 'Interdiction de gérer',
|
|
|
|
'1999' => 'Autre procédure collective',
|
2009-10-16 12:30:19 +00:00
|
|
|
'2102' => 'Augmentation du capital social',
|
|
|
|
'2100' => 'Diminution du capital social',
|
|
|
|
'2202' => 'Dissolution',
|
|
|
|
'2206' => 'Mise en sommeil',
|
2010-02-10 17:27:03 +00:00
|
|
|
'2319' => 'Poursuite de l\'activité malgré perte > moitié du capital social',
|
2009-10-16 12:30:19 +00:00
|
|
|
'2315' => 'Modification de l\'administration',
|
2010-02-10 17:27:03 +00:00
|
|
|
'2313' => 'Modification de l\'activité',
|
|
|
|
'2305' => 'Modification de la dénomination',
|
2009-10-16 12:30:19 +00:00
|
|
|
'2307' => 'Modification de la forme juridique',
|
2010-02-10 17:27:03 +00:00
|
|
|
'2303' => 'Modification de la date de clôture de l\'exercice',
|
|
|
|
'2306' => 'Modification de la durée de la société',
|
|
|
|
'2901' => 'Transfert de siège',
|
|
|
|
'5500' => 'Vente/cession : Entreprise réalisant la vente',
|
2009-10-16 12:30:19 +00:00
|
|
|
'6700' => 'Radiation',
|
2010-04-20 15:28:04 +00:00
|
|
|
'1010' => 'Déclaration de cessation de paiement',
|
|
|
|
'1050' => 'Homologation de la conciliation',
|
|
|
|
'1055' => 'Résolution de la conciliation',
|
2009-10-16 12:30:19 +00:00
|
|
|
);
|
|
|
|
|
2009-03-13 14:58:10 +00:00
|
|
|
?>
|
2010-04-20 15:28:04 +00:00
|
|
|
<select id="jugement" name="jugement[even][]" size="5">
|
2009-03-13 14:58:10 +00:00
|
|
|
<option value="0000">-</option>
|
2009-10-16 12:30:19 +00:00
|
|
|
<?php
|
2010-04-20 15:28:04 +00:00
|
|
|
//Tri des libellées par ordre alphabétique
|
2009-10-16 12:30:19 +00:00
|
|
|
asort($tabEvent);
|
|
|
|
//Affichage
|
|
|
|
foreach($tabEvent as $key => $event)
|
|
|
|
{
|
2010-04-14 16:00:45 +00:00
|
|
|
?>
|
|
|
|
<option value="<?=$key?>"><?=$event?></option>
|
|
|
|
<?php
|
2009-10-16 12:30:19 +00:00
|
|
|
}
|
|
|
|
?>
|
2009-03-13 14:58:10 +00:00
|
|
|
</select>
|
2009-02-19 16:28:12 +00:00
|
|
|
|
2009-03-13 14:58:10 +00:00
|
|
|
<div id="subFormSaisie">
|
2009-07-07 16:35:28 +00:00
|
|
|
<?php
|
|
|
|
include('./pages_saisie/event_0000.php');
|
2009-04-10 13:24:51 +00:00
|
|
|
?>
|
2009-03-13 14:58:10 +00:00
|
|
|
</div>
|
|
|
|
|
2009-07-21 12:35:13 +00:00
|
|
|
<h2>Actionnariat</h2>
|
|
|
|
|
2009-03-18 10:47:46 +00:00
|
|
|
<p><a href="#" onclick="displayBlock('#formActionnaire');">Afficher/Masquer le formulaire</a></p>
|
2009-03-13 14:58:10 +00:00
|
|
|
<div id="formActionnaire">
|
|
|
|
<label>Siren actionnaire</label>
|
|
|
|
<input type="text" name="actionnaire[siren]" size="8" maxlength="12" value="" />
|
2009-07-21 12:35:13 +00:00
|
|
|
<label>Pourcentage</label><input type="text" class="percent" name="actionnaire[pct]" size="3" maxlength="5" value="" />
|
2009-03-20 09:07:19 +00:00
|
|
|
<span class="left">%</span>
|
2009-09-10 15:31:37 +00:00
|
|
|
<label> Major. / </label><input type="radio" class="widthauto" name="actionnaire[majMin]" value="maj">
|
|
|
|
<label> Minor.</label><input type="radio" class="widthauto" name="actionnaire[majMin]" value="min">
|
|
|
|
<label>au DateMAJ</label><input type="text" class="date" name="actionnaire[dateMAJ]" size="10" maxlength="10" value="" />
|
2009-03-20 09:07:19 +00:00
|
|
|
<span class="left">(Format JJ/MM/AAAA)</span>
|
2009-03-13 14:58:10 +00:00
|
|
|
<label>Pays</label>
|
|
|
|
<select name="actionnaire[pays]"><?=$strSelectPays?></select>
|
|
|
|
<label>Raison sociale</label>
|
|
|
|
<input type="text" name="actionnaire[nom]" size="35" maxlength="80" value=""/>
|
|
|
|
<span class="left">si étranger</span>
|
|
|
|
</div>
|
|
|
|
|
2009-07-21 12:35:13 +00:00
|
|
|
<h2>Participations</h2>
|
|
|
|
|
2009-03-17 10:16:49 +00:00
|
|
|
<p><a href="#" onclick="displayBlock('#formParticipation');">Afficher/Masquer le formulaire</a></p>
|
2009-03-13 14:58:10 +00:00
|
|
|
<div id="formParticipation">
|
|
|
|
<label>Siren participation</label>
|
|
|
|
<input type="text" name="particip[siren]" size="8" maxlength="12" value="" />
|
|
|
|
<label>à</label>
|
2009-07-21 12:35:13 +00:00
|
|
|
<label>Pourcentage</label><input class="percent" type="text" name="particip[pct]" size="3" maxlength="5" value="" /><span class="left">%</span>
|
2009-09-10 15:31:37 +00:00
|
|
|
<label> Major. / </label><input type="radio" class="widthauto" name="particip[majMin]" value="maj">
|
|
|
|
<label> Minor.</label><input type="radio" class="widthauto" name="particip[majMin]" value="min">
|
|
|
|
<label>au DateMAJ</label><input type="text" class="date" name="particip[dateMAJ]" size="10" maxlength="10" value="" />
|
2009-03-20 09:07:19 +00:00
|
|
|
<span class="left">(Format JJ/MM/AAAA)</span>
|
2009-03-17 10:16:49 +00:00
|
|
|
<label>Pays</label><select name="particip[pays]"><?=$strSelectPays?></select>
|
2009-03-13 14:58:10 +00:00
|
|
|
<label>Raison sociale</label>
|
|
|
|
<input type="text" name="particip[nom]" size="35" maxlength="80" value=""/>
|
|
|
|
<span class="left"> si étranger</span>
|
|
|
|
</div>
|
|
|
|
|
2009-12-04 17:17:09 +00:00
|
|
|
<h2>Informations diverses</h2>
|
2010-01-14 08:50:17 +00:00
|
|
|
<label>Autre siren (doublon)</label>
|
|
|
|
<input type="text" size="11" name="frmSaisie[sirenDoublon]" value="<?=$etab['sirenDoublon']?>"/>
|
2009-12-04 17:17:09 +00:00
|
|
|
|
2010-04-14 16:00:45 +00:00
|
|
|
<?php
|
2010-01-14 11:29:30 +00:00
|
|
|
if($etab['FJ'][0]==1)
|
2010-01-14 08:50:17 +00:00
|
|
|
{
|
|
|
|
?>
|
2010-02-10 17:27:03 +00:00
|
|
|
<label>Entreprise ayant exercée son droit d'opposition en</label>
|
2010-01-14 11:29:30 +00:00
|
|
|
<input type="checkbox" name="oppositionInsee" value="1"/>
|
|
|
|
<div id="divOppositionInsee"></div>
|
2010-01-14 08:50:17 +00:00
|
|
|
<?php
|
|
|
|
}
|
|
|
|
?>
|
2009-07-21 12:35:13 +00:00
|
|
|
<p class="submit"><input type="submit" name="submit" value="Sauver"/></p>
|
2009-03-13 14:58:10 +00:00
|
|
|
|
2009-07-21 12:35:13 +00:00
|
|
|
</form>
|
2010-04-26 14:46:13 +00:00
|
|
|
</div>
|