Modification de l'interface de odea

This commit is contained in:
Damien LASSERRE 2011-12-20 15:22:09 +00:00
parent 3f7f1cb8b2
commit 0a4bbdb986
17 changed files with 176 additions and 94 deletions

View File

@ -26,9 +26,9 @@ class Bootstrap extends Zend_Application_Bootstrap_Bootstrap
$view->headLink()
->appendStylesheet($pathStyle.'/reset.css', 'all')
->appendStylesheet($pathStyle.'/jquery.qtip.css', 'all')
->appendStylesheet($pathStyle.'/main.css', 'all')
->appendStylesheet('/themes/jstree/default/style.css')
->appendStylesheet('/themes/jqueryui/jquery-ui.css', 'all');
->appendStylesheet('/themes/jqueryui/jquery-ui.css', 'all')
->appendStylesheet($pathStyle.'/main.css', 'all');
$view->headScript()
->appendFile($pathScript.'/jquery.js', 'text/javascript')

View File

@ -63,11 +63,11 @@ class IndexController extends Zend_Controller_Action
}
$this->view->Count = $Count;
$this->view->entreprise = $entreprise;
$this->view->geographique = $geographique;
$this->view->economique = $economique;
$this->view->juridique = $juridique;
$this->view->financier = $financier;
$this->view->entreprise = $this->entreprise;
$this->view->geographique = $this->geographique;
$this->view->economique = $this->economique;
$this->view->juridique = $this->juridique;
$this->view->financier = $this->financier;
}
}

View File

@ -6,13 +6,12 @@ Class Zend_View_Helper_Select extends Zend_View_Helper_Abstract
{
$session = new Zend_Session_Namespace('ciblage');
$compar = $session->ciblage[$name][0];
$select = '<option value="tous">Tous</option>';
foreach($liste as $item => $value) {
$select .= '<option '.(($compar != null and $compar == $value)?'selected="selected"':null).' value="'.$value.'">'.$item.'</option>';
$select .= '<option '.(($compar != 't' and $compar == $value)?'selected="selected"':null).' value="'.$value.'">'.$item.'</option>';
}
$champ = '<div id="'.$name.'" style="margin-top:2px;'.((empty($session->ciblage[$name]))?'display:none':'background-color:#97DB70').';padding:5px;'.(($color)?'background-color:#39414A;color:white;':null).'">';
$champ = '<div id="'.$name.'" style="cursor:move;'.((empty($session->ciblage[$name]) or $session->ciblage[$name] == 'tous')?null:'background-color:#CCF8D2').';padding:5px;">';
$champ .= '<div style="float:left;text-align:left;">
<label>'.$libelle.'</label>
</div>';
@ -20,7 +19,6 @@ Class Zend_View_Helper_Select extends Zend_View_Helper_Abstract
<select class="criteres" name="'.$name.'">
'.$select.'
</select>
<img style="float:right" src="/themes/default/images/cross.png" />
</div>';
$champ .= '</div>';

View File

@ -1,19 +1,18 @@
<style>
ul {list-style-type: none;}
.ui-state-default {
margin-top:5px;
}
</style>
<div>
<select class="printCritere" style="width:200px;">
<option>Selectionnez un critère</option>
<?php foreach($this->selectRow['entreprise'] as $elements):?>
<option value="<?php echo $elements; ?>"><?php echo $elements; ?></option>
<?php endforeach;?>
</select>
<br />
Votre selection :
<div style="border:1px solid silver;margin-top:20px;">
<ul id="sortable">
<?php $i=0; foreach($this->champs as $champ){
$valeur = explode(':', $champ['type']);
switch ($valeur[0]) {
case 'select':
echo '<li class="ui-state-default" style="display:block;">';
echo $this->Select($champ['name'], $champ['libelle'], $champ['parametres']);
echo '</li>';
$i++;
break;
case 'interval':
@ -28,9 +27,8 @@
default:
echo $champ['name'].'<br />';*/
}
} ?>
</div>
</ul>
</div>
<div style="text-align:right;margin-top:20px;">

View File

@ -11,8 +11,28 @@
<h1>Odea</h1>
</div>
<div id="message">
Message d'information
<div id="message" style="padding-top:5px;background-image: url('/themes/default/images/ligne.png');background-repeat: no-repeat;padding-left:15px;height:50px;width:365px;">
<div class="comptage" >
Nombre sélectionnées :
<span style="font-weight:800;" id="count"><?php echo ((!empty($this->total))?$this->total:'-');?></span>
(dont <span style="font-weight:800;" id="insee"><?php echo ((!empty($this->insee))?$this->insee:'-');?></span> unité(s) insee)
</div>
<div class="attente" style="text-align:center;display:none;">
<img src="/themes/default/images/ajax.gif" />
</div>
</div>
<script>
$(function() {
$( "#tabs" ).tabs({
cache: true,
cookie: {
expires: 1
},
ajaxOptions: {
error: function( xhr, status, index, anchor ) {
$( anchor.hash ).html("Erreur lors du chargement...");
}
}
});
});
</script>

View File

@ -3,15 +3,35 @@ $elements = array('entreprise' => 'Entreprise',
'economique' => 'Situation economique',
'geographique' => 'Secteur géographique',
'juridique' => 'Situation juridique',
'financier' => 'Situation financiére');
?>
'financier' => 'Situation financiére'
);
$label = array('siege' => array('Siége / Etablissement', 'Vous permet de séléctionner soit les établissement siége ou juste les établissement dépendant d\'un siége'),
'sirenGrp' => array('Siren Groupe','Les société qui ont le même siren'),
'tel' => array('Téléphone', 'Avec ou sans l\'information téléphone'),
'fax' => array('Télécopie', 'Avec ou sans l\'information fax'),
'web' => array('Site Internet', 'Avec ou sans l\'information site internet'),
'mail' => array('Adresse Email', 'Avec ou sans l\'information email'),
'presentRcs' => array('Société Présent RNCS', 'Les sociétés presente ou pas au RNCS'),
'adrDom' => array('Adresse Domicialisation', 'Qui présente une domicialisation'),
'dirNom' => array('Nom du dirigeant', 'Qui le nom du principale dirigeant'),
'lieuAct' => array('Le Lieu Actionnaire', 'Lieu des principaux actionnaires'),
'nbMPubli' => array('Tranche marché Public', 'Nombre de marché public remportés'),
'dateCrea_ent' => array('Date de création Entreprise', 'Date de création de l\'entreprise'),
'dateCrea_etab' => array('Date de création Etablissement' ,'Date de création de l\'établissement'),
'nbAction' => array('Tranche Actions', 'La tranche d\'action souhaité'),
'nbPart' => array('Tranche Parts Sociales', 'La tranche de part sociale souhaité'));
?>
<?php foreach($elements as $variable => $name): ?>
<h3><a href="#"><?php echo $name; ?><span style="font-size:10px">Nombre de critéres : <?php echo $this->Count[$variable]; ?></span></a></h3>
<?php ?>
<h3><a href="#"><?php echo $name; ?></a></h3>
<div>
<?php foreach($this->$variable as $item => $valeur): ?>
<span>
<?php echo '<b>'.$item.' :</b> '.(($valeur=='0' or $valeur == '1')?(($valeur=='0')?'Non':'Oui'):str_replace(',', ' à ', ((is_array($valeur))?implode(' à ', $valeur):$valeur))); ?>
</span><br />
<ul class="critereSelection">
<?php foreach($this->$variable as $item): ?>
<a class="tooltip" title="<?php echo $label[$item][1];?>">
<li class="liHover printCritere" name="<?php echo $item; ?>"><?php echo $label[$item][0];?>
<img src="" style="float:right"/>
</li></a>
<?php endforeach; ?>
</ul>
</div>
<?php endforeach;?>

View File

@ -1,4 +1,4 @@
<div id="tabs">
<div id="tabs" class="portlet">
<ul>
<li><a href="#tabs-1">Critères Entreprise</a></li>
<li><a href="<?=$this->url(array('controller'=>'criteres', 'action'=>'economique'))?>">Situation économique</a></li>
@ -11,27 +11,11 @@
</div>
</div>
<div id="result">
<div id="critères">
<div id="accordion">
<h3><a href="">Résultats</a></h3>
<div style="padding:0px;height:100px;">
<div class="comptage" style="margin-bottom:40px;">
Nombre sélectionnées :
<span style="font-weight:800;" id="count"><?php echo ((!empty($this->total))?$this->total:'-');?></span>
<br/>
(dont <span style="font-weight:800;" id="insee"><?php echo ((!empty($this->insee))?$this->insee:'-');?></span> unité(s) insee)
</div>
<div class="attente" style="text-align:center;display:none;">
<img width="15%" src="/themes/default/images/ajax.gif" /><br />
Chargement...
</div>
</div>
<?php echo $this->action('criteres', 'index');?>
</div>
<div id="result" class="portlet">
<div id="accordion">
<?php echo $this->action('criteres', 'index');?>
</div>
</div>
<script>
$(function() {
var icons = {
@ -47,18 +31,4 @@ $(function() {
$( "#accordion" ).accordion( "option", "icons", icons );
});
});
$(function() {
$( "#tabs" ).tabs({
cache: true,
cookie: {
expires: 1
},
ajaxOptions: {
error: function( xhr, status, index, anchor ) {
$( anchor.hash ).html("Erreur lors du chargement...");
}
}
});
});
</script>
</script>

View File

@ -12,9 +12,8 @@
<div id="header" class="clearfix">
<?php echo $this->render('header.phtml') ?>
</div>
<div id="content" class="clearfix">
<div id="content" class="clearfix column">
<?php echo $this->layout()->content; ?>
<div class="attente" style="display:none" id="wrapper"><img width="10%" src="/themes/default/images/ajax.gif" /></div>
</div>
<div id="footer">
<?php echo $this->render('footer.phtml'); ?>

View File

@ -0,0 +1,16 @@
<?php
function Connexion_base()
{
$db = @mysql_connect('localhost','root','') or die('Erreur de connexion au MYSQL local');
$select_base=@mysql_selectdb('geo', $db);
}
function Deconnexion_base()
{
@mysql_close;
}
?>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 19 KiB

After

Width:  |  Height:  |  Size: 404 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 655 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 316 B

View File

@ -1,7 +1,7 @@
$(document).ready(function(){
$(".tooltip").qtip();
$('.tooltip').each(function(){
$(".tooltip").each(function(){
var title = $(this).attr('title');
var width = $(this).attr('wdth');
$(this).attr('title', '');
@ -10,7 +10,7 @@ $(document).ready(function(){
content: title,
style: {
width: width,
classes: "ui-tooltip-cream"
classes: "ui-tooltip-dark"
},
position: {
at: $('#at').val(),
@ -34,19 +34,62 @@ $(document).ready(function(){
$( ".datepicker" ).datepicker( "option", "dateFormat", "yymmdd" );
});
$('.printCritere').change(function(){
$('#'+$(this, ':selected').val()).css('display', 'block');
$('.printCritere').click(function(){
var name = $(this).attr('name');
var block = $('#'+$(this).attr('name')).css('display');
if(block == 'block') {
$(this).css('background-image', 'url(/themes/default/images/ajouter.png)');
$('#'+name).css('display', 'none');
}
else {
$(this).css('background-image', 'url(/themes/default/images/moins.png)');
$('#'+name).css('display', 'block');
}
})
$('.accordion .head').click(function() {
$(this).next().toggle('slow');
return false;
}).next().hide();
$(function() {
$( "#accordion" ).accordion({
autoHeight: false,
navigation: true
});
});
$(function() {
$( "#sortable" ).sortable({
placeholder: "ui-state-highlight"
});
$( "#sortable" ).disableSelection();
});
$(function() {
$( ".column" ).sortable({
connectWith: ".column"
});
$( ".portlet" ).addClass( "ui-widget ui-widget-content ui-helper-clearfix ui-corner-all" )
.find( ".portlet-header" )
.addClass( "ui-widget-header ui-corner-all" )
.prepend( "<span class='ui-icon ui-icon-minusthick'></span>")
.end()
.find( ".portlet-content" );
$( ".portlet-header .ui-icon" ).click(function() {
$( this ).toggleClass( "ui-icon-minusthick" ).toggleClass( "ui-icon-plusthick" );
$( this ).parents( ".portlet:first" ).find( ".portlet-content" ).toggle();
});
$( ".column" ).disableSelection();
});
$('#tabs').delegate('select.criteres', 'change', function(e){
var valeur = $(this, ':selected').val();
e.stopPropagation();
if(valeur == 'tous') {
$('#'+$(this).attr('name')).css('background-color', '');
} else {
$('#'+$(this).attr('name')).css('background-color', '#CCF8D2'); }
set($(this).attr('name'), $(this, ':selected').val());
$('#'+$(this).attr('name')).css('background-color', '#97DB70');
});
$('#tabs').delegate('input[type=checkbox].criteres', 'click', function(e){

View File

@ -5,10 +5,10 @@ body {
margin: 0;
padding: 0;
}
#comptage
.critereSelection li
{
padding:5px;
font-size:11px;
list-style: none;
}
select {
width:150px;
@ -30,13 +30,6 @@ ul, ul li {
margin-left: auto;
}
.printCritere
{
height:35px;
font-weight:800;
margin-left:40%;
}
#header {
height: 156px;
@ -45,7 +38,6 @@ ul, ul li {
}
#header #message {
background: #ffffff;
color: #000000;
clear: right;
float: right;
@ -54,7 +46,29 @@ ul, ul li {
line-height: 25px;
margin-bottom: 2px;
padding: 0 1em;
min-width:300px;
width:350px;
}
.liHover {
border:1px solid silver;
padding:5px;
margin:1px;
background-image: url('/themes/default/images/moins.png');
background-repeat: no-repeat;
background-position:2px;
padding-left:25px;
cursor:move;
}
.portlet
{
background-color:none;
}
.ui-state-highlight {margin-top:5px; height: 2.5em; line-height: 1.2em; }
.liHover:hover {
background-color: #E2E6E5;
cursor:pointer;
}
#header h1 {
@ -223,4 +237,8 @@ h3 {
#naf li { width:650px; }
#naf a { }
#naf a ins { }
#naf a ins { }
#first
{
height:200px;
}

View File

@ -333,7 +333,7 @@
.ui-accordion .ui-accordion-header a { display: block; font-size: 1em; padding: .5em .5em .5em .7em; }
.ui-accordion-icons .ui-accordion-header a { padding-left: 2.2em; }
.ui-accordion .ui-accordion-header .ui-icon { position: absolute; left: .5em; top: 50%; margin-top: -8px; }
.ui-accordion .ui-accordion-content { padding: 1em 2.2em; border-top: 0; margin-top: -2px; position: relative; top: 1px; margin-bottom: 2px; overflow: auto; display: none; zoom: 1; }
.ui-accordion .ui-accordion-content { /*padding: 1em 2.2em;*/ border-top: 0; margin-top: -2px; position: relative; top: 1px; margin-bottom: 2px; overflow: auto; display: none; zoom: 1; }
.ui-accordion .ui-accordion-content-active { display: block; }
/*
* jQuery UI Autocomplete 1.8.14