Merge from trunk

This commit is contained in:
Michael RICOIS 2013-07-02 09:56:14 +00:00
commit e37f155137
10 changed files with 232 additions and 27 deletions

View File

@ -15,14 +15,6 @@ class DirigeantController extends Zend_Controller_Action
require_once 'common/dates.php';
}
/**
* Forward
*/
public function indexAction()
{
$this->_forward('index', 'index');
}
/**
* Affichage de la liste des dirigeants
*/
@ -50,6 +42,8 @@ class DirigeantController extends Zend_Controller_Action
$this->view->assign('dirigeantsop', $href);
}
$this->view->assign('edition', $user->checkModeEdition());
$this->view->assign('siren', $siren);
$this->view->assign('siret', $this->siret);
$this->view->assign('raisonSociale', $session->getRaisonSociale());

View File

@ -141,10 +141,15 @@ class SurveillanceController extends Zend_Controller_Action
$delete = $request->getParam('delete', false);
$encours = $request->getParam('encours', 0);
$validateur = new Zend_Validate_EmailAddress();
//Vérification siret / email / ref
if (empty($siret) || empty($email) | empty($ref)){
if (empty($siret) || empty($email) || empty($ref)){
$msg = 'Erreur email ou reférence non définie !';
}
elseif (!$validateur->isValid($email)) {
$msg = "Email invalide.";
}
//Vérification de l'encours (chiffres)
elseif (!preg_match('/([0-9]+)/', $encours)){
$msg = 'Encours incorrect';

View File

@ -92,6 +92,14 @@ table.data td { border:1px solid #ccc; padding:5px; }
<?php if ($dir->Siren!='') {?>
<a title="Consulter la fiche identité" href="<?=$this->url(array('controller'=>'identite', 'action'=>'fiche', 'siret'=>$dir->Siren))?>">
<?=$this->SirenTexte($dir->Siren)?></a>
<?php if (empty($this->AutrePage) && $this->edition) {?>
<div style="line-height:16px;">
<a class="dialog" title="Ajouter un actionnaire" href="<?=$this->url(array('controller'=>'saisie','action'=>'lien','type'=>'actionnaire','mode'=>'add','siren'=>$this->siren,'createfiche'=>$dir->Siren),null,true)?>">
<img style="vertical-align:middle;" src="/themes/default/images/interfaces/ajouter.png" /></a>
</div>
<?php }?>
<?php }?>
</td>
</tr>
@ -108,7 +116,39 @@ table.data td { border:1px solid #ccc; padding:5px; }
<?php } ?>
</div>
<?php if (empty($this->AutrePage)):?>
<?php if (empty($this->AutrePage)) {?>
<?=$this->render('cgu.phtml', $this->cgu)?>
</div>
<?php endif;?>
<?php }?>
<?php if (empty($this->AutrePage)) {?>
</div>
<?php }?>
<?php if (empty($this->AutrePage) && $this->edition) {?>
<script>
$('a.dialog').on('click', function(){
var href = $(this).attr('href');
if (href!='#') {
var title = $(this).attr('title');
var dialogOpts = {
bgiframe: true,
title: title,
width: 650,
height: 600,
modal: true,
open: function(event, ui) {
$(this).html('Chargement...');
$(this).load(href);
},
buttons: {
Quitter: function() { $(this).dialog('close'); }
},
close: function() { $('#dialog').remove(); }
};
$('<div id="dialog"></div>').dialog(dialogOpts);
return false;
}
});
</script>
<?php }?>

View File

@ -688,7 +688,7 @@
<tr>
<td>Production vendue services</td>
<td align="center">FG</td>
<td align="right"><?php echo $this->liasse['FG'];?>0</td>
<td align="right"><?php echo $this->liasse['FG'];?></td>
<td align="center">FH</td>
<td align="right"><?php echo $this->liasse['FH'];?></td>
<td align="center">FI</td>

View File

@ -1799,14 +1799,14 @@
</tr>
<tr>
<td align="right" colspan="2"><b>TOTAL GENERAL (I+II+III)</b></td>
<td align="center">ON</td>
<td align="right"><?=$this->Editable('ON',$this->liasse['ON'],'poste');?></td>
<td align="center">OP</td>
<td align="right"><?=$this->Editable('OP',$this->liasse['OP'],'poste');?></td>
<td align="center">OQ</td>
<td align="right"><?=$this->Editable('OQ',$this->liasse['OQ'],'poste');?></td>
<td align="center">OR</td>
<td align="right"><?=$this->Editable('OR',$this->liasse['OR'],'poste');?></td>
<td align="center">0N</td>
<td align="right"><?=$this->Editable('0N',$this->liasse['0N'],'poste');?></td>
<td align="center">0P</td>
<td align="right"><?=$this->Editable('0P',$this->liasse['0P'],'poste');?></td>
<td align="center">0Q</td>
<td align="right"><?=$this->Editable('0Q',$this->liasse['0Q'],'poste');?></td>
<td align="center">0R</td>
<td align="right"><?=$this->Editable('0R',$this->liasse['0R'],'poste');?></td>
</tr>
</tbody>
</table>
@ -1825,7 +1825,7 @@
<td align="center" colspan="2"><b>amortissements dégressifs</b></td>
<td align="center" colspan="2"><b>amortissements exceptionnels</b></td>
<td align="center" colspan="3"><b>Dotations</b></td>
<td align="center" colspan="2"><b> Reprises</b></td>
<td align="center" colspan="2"><b>Reprises</b></td>
</tr>
<tr>
<td>Frais établi R&amp;D</td>
@ -3400,8 +3400,8 @@ pour les entreprises placées sous le régime de l'article 39-1. 1 e bis Al. 2 d
<td colspan="10">Personnel extérieur à l'entreprise</td>
<td align="center">YU</td>
<td align="right"><?=$this->Editable('YU',$this->liasse['YU'],'poste');?></td>
<td align="center">YU</td>
<td align="right"><?=$this->Editable('YU',$this->liasse['YU'],'poste');?></td>
<td align="center">YU1</td>
<td align="right"><?=$this->Editable('YU1',$this->liasse['YU1'],'poste');?></td>
</tr>
<tr>
<td colspan="10">Rémunérations d'intermédiaires et honoraires (hors rétrocessions)</td>

View File

@ -0,0 +1,67 @@
<style>
#bloc-addemail { display:none; }
</style>
<p>Modification des emails associés au compte</p>
<form>
<div>
<label>Adresse Email principal :</label><br/>
<input type="text" size="50" maxlength="80" name="email1" value="<?=$this->email1?>"/>
<span id="email1-response"></span>
</div>
<br/>
<a href="#" id="addemail">Ajouter des adresses emails secondaires</a>
<div id="bloc-addemail">
<label>Email 1 :</label><br/>
<input type="text" size="50" maxlength="80" name="email2" value="<?=$this->email2?>"/>
<span id="email2-response"></span>
<br/><br/>
<label>Email 2 :</label><br/>
<input type="text" size="50" maxlength="80" name="email3" value="<?=$this->email3?>"/>
<span id="email3-response"></span>
</div>
<div id="response"></div>
</form>
<script>
$('a#addemail').click(function(){
$display = $('div#bloc-addemail').css('display');
if ($display == 'block') {
$('div#bloc-addemail').css('display', 'none');
} else {
$('div#bloc-addemail').css('display', 'block');
}
});
$('#dialog').dialog({ buttons: [
{ text: "Valider", click: function() {
var flagAllValid = true;
var emails = [];
var source = ['email1', 'email2', 'email3'];
$.each( source, function( key, value ) {
var email = $('input[name='+value+']').val();
if (email!='') {
$.post('/user/emailvalid', {q: email}, function(data){
if(data.valid==false) {
flagAllValid = false;
$('#dialog span#'+value+'-response').html('<strong>Email invalide !</strong>');
}
}, 'json');
emails.push(email);
}
});
if(flagAllValid) {
$('input[name="frmOptions[email]"]').val(emails.join(';'));
$(this).dialog("close");
}
} },
{ text: "Quitter", click: function() { $(this).dialog("close"); } }
]});
</script>

View File

@ -0,0 +1 @@
<?=json_encode($this->result);?>

View File

@ -44,8 +44,45 @@ if ($this->action != 'new') {
<div class="infoTitle StyleInfoLib">Adresse e-mail</div>
<div class="infoData">
<input type="text" size="30" maxlength="80" name="frmOptions[email]" value="<?=$this->options->email?>"/>
<?php $emails = explode(';', $this->options->email); ?>
<?php foreach ( $emails as $email ) {?>
<span><?=$email?></span><br/>
<?php }?>
</div>
<div style="float:left;">
<button id="user-emails">Editer les emails</button>
<script>
$('button#user-emails').button({
icons: { primary: "ui-icon-pencil" },
text: false
}).click(function( event ) {
event.preventDefault();
var title = $(this).text();
var href = '/user/emails/q/'+$('input[name="frmOptions[email]"]').val();
var dialogOpts = {
bgiframe: true,
title: title,
width: 500,
height: 300,
modal: true,
open: function(event, ui) {
$(this).html('Chargement...');
$(this).load(href);
},
buttons: {
Quitter: function() { $(this).dialog('close'); }
},
close: function() { $('#dialog').remove(); }
};
$('<div id="dialog"></div>').dialog(dialogOpts);
return false;
});
</script>
</div>
<input type="hidden" name="frmOptions[email]" value="<?=$this->options->email?>"/>
<div class="infoTitle StyleInfoLib">
Num&eacute;ros de t&eacute;l&eacute;phone<br/><i>(Fixe, Fax, Mobile)</i>
@ -224,9 +261,7 @@ foreach ($this->prefsLib as $code => $lib) {
<?php }?>
</div>
<?php
if ( $this->options->idClient == 1 && !in_array('edition',$this->droits) ) {
?>
<?php if ( $this->options->idClient == 1 && !in_array('edition',$this->droits) ) { ?>
<h2>Mode spéciaux</h2>
<div class="infoTitle StyleInfoLib">Mode Edition</div>
<div class="infoData last">

View File

@ -177,6 +177,10 @@ class Liasse
'YY'=>'374',
'YZ'=>'378',
'YP'=>'376',
//@todo : Traiter N-1
);
$bilanRN=array();

View File

@ -0,0 +1,59 @@
[production]
phpSettings.date.timezone = "Europe/Paris"
phpSettings.display_startup_errors = 0
phpSettings.display_errors = 0
phpSettings.soap.wsdl_cache_dir = APPLICATION_PATH "/../data/wsdl"
bootstrap.path = APPLICATION_PATH "/Bootstrap.php"
bootstrap.class = "Bootstrap"
appnamespace = "Application"
resources.session.save_path = APPLICATION_PATH "/../data/sessions"
resources.useragent.mobile.features.path = APPLICATION_PATH "/../library/Zend/Http/UserAgent/Features/Adapter/Browscap.php"
resources.useragent.mobile.features.classname = "Zend_Http_UserAgent_Features_Adapter_Browscap"
resources.frontController.controllerDirectory = APPLICATION_PATH "/controllers"
resources.frontController.plugins.Auth = "Application_Controller_Plugin_Auth"
resources.frontController.plugins.Theme = "Application_Controller_Plugin_Theme"
resources.frontController.plugins.Lang = "Application_Controller_Plugin_Lang"
resources.frontController.plugins.Menu = "Application_Controller_Plugin_Menu"
resources.frontController.plugins.Pdf = "Application_Controller_Plugin_Pdf"
resources.frontController.plugins.Xml = "Application_Controller_Plugin_Xml"
resources.frontController.plugins.Cgu = "Application_Controller_Plugin_Cgu"
resources.frontController.params.displayExceptions = 0
resources.layout.layout = "main"
resources.layout.layoutPath = APPLICATION_PATH "/views/default"
resources.view.basePath = APPLICATION_PATH "/views/default"
autoloaderNamespaces[] = "Application_"
autoloaderNamespaces[] = "Scores_"
; Scores configuration
profil.server.name = sd-46528
profil.webservice.location = celeste
profil.mail.method = sendmail
profil.mail.email.support = support@scores-decisions.com
profil.mail.email.supportdev = supportdev@scores-decisions.com
profil.mail.email.contact = contact@scores-decisions.com
profil.mail.email.production = production@scores-decisions.com
profil.path.cache = APPLICATION_PATH "/../data/cache"
profil.path.files = APPLICATION_PATH "/../data/files"
profil.path.pages = APPLICATION_PATH "/../data/pages"
profil.path.data = "/home/vhosts/data"
profil.wkhtmltopdf.path = "/home/vhosts/data/wkhtml/linux/wkhtmltopdf-amd64"
profil.db.sdv1.adapter=mysqli
profil.db.sdv1.params.host=localhost
profil.db.sdv1.params.username=extranet
profil.db.sdv1.params.password=bGPZ9qYZQFHMYCnJ
profil.db.sdv1.params.dbname=extranet
profil.db.sdv1.params.driver_options.MYSQLI_INIT_COMMAND = "SET NAMES utf8"
[staging : production]
resources.frontController.params.displayExceptions = 0
phpSettings.soap.wsdl_cache_enabled = 1
[development : production]
phpSettings.display_startup_errors = 1
phpSettings.display_errors = 1
phpSettings.soap.wsdl_cache_enabled = 0
resources.frontController.params.displayExceptions = 1
[testing : production]
phpSettings.display_startup_errors = 1
phpSettings.display_errors = 1