Fix: code homogne
This commit is contained in:
parent
71abc830aa
commit
d0606e4945
@ -1,6 +1,7 @@
|
||||
<?php
|
||||
/* Copyright (C) 2007-2008 Jeremie Ollivier <jeremie.o@laposte.net>
|
||||
* Copyright (C) 2008 Laurent Destailleur <eldy@uers.sourceforge.net>
|
||||
/* Copyright (C) 2007-2008 Jeremie Ollivier <jeremie.o@laposte.net>
|
||||
* Copyright (C) 2008 Laurent Destailleur <eldy@uers.sourceforge.net>
|
||||
* Copyright (C) 2009 Régis Houssin <regis@dolibarr.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@ -20,45 +21,40 @@
|
||||
require ('classes/Facturation.class.php');
|
||||
|
||||
// Si nouvelle vente, reinitialisation des donnees (destruction de l'objet et vidage de la table contenant la liste des articles)
|
||||
if ( $_GET['id'] == 'NOUV' ) {
|
||||
|
||||
unset ($_SESSION['serObjFacturation']);
|
||||
|
||||
if ( $_GET['id'] == 'NOUV' )
|
||||
{
|
||||
unset($_SESSION['serObjFacturation']);
|
||||
$sql->query ('DELETE FROM '.MAIN_DB_PREFIX.'tmp_caisse');
|
||||
|
||||
}
|
||||
|
||||
// Recuperation, s'il existe, de l'objet contenant les infos de la vente en cours ...
|
||||
if ( isset ($_SESSION['serObjFacturation']) ) {
|
||||
|
||||
$obj_facturation = unserialize ($_SESSION['serObjFacturation']);
|
||||
if ( isset ($_SESSION['serObjFacturation']) )
|
||||
{
|
||||
$obj_facturation = unserialize($_SESSION['serObjFacturation']);
|
||||
unset ($_SESSION['serObjFacturation']);
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
// ... sinon, c'est une nouvelle vente
|
||||
} else {
|
||||
|
||||
$obj_facturation = new Facturation;
|
||||
|
||||
}
|
||||
|
||||
?>
|
||||
print '<div class="liste_articles">';
|
||||
include('liste_articles.php');
|
||||
print '</div>';
|
||||
|
||||
<div class="liste_articles"><?php include ('liste_articles.php'); ?></div>
|
||||
|
||||
<div class="principal"><?php
|
||||
|
||||
if ( $_GET['menu'] ) {
|
||||
|
||||
include ($_GET['menu'].'.php');
|
||||
|
||||
} else {
|
||||
print '<div class="principal">';
|
||||
|
||||
if ( $_GET['menu'] )
|
||||
{
|
||||
include($_GET['menu'].'.php');
|
||||
}
|
||||
else
|
||||
{
|
||||
include ('facturation.php');
|
||||
|
||||
}
|
||||
?></div>
|
||||
|
||||
<?php
|
||||
print '</div>';
|
||||
|
||||
$_SESSION['serObjFacturation'] = serialize ($obj_facturation);
|
||||
|
||||
|
||||
@ -1,6 +1,7 @@
|
||||
<?php
|
||||
/* Copyright (C) 2007-2008 Jeremie Ollivier <jeremie.o@laposte.net>
|
||||
* Copyright (C) 2008 Laurent Destailleur <eldy@uers.sourceforge.net>
|
||||
/* Copyright (C) 2007-2008 Jeremie Ollivier <jeremie.o@laposte.net>
|
||||
* Copyright (C) 2008 Laurent Destailleur <eldy@uers.sourceforge.net>
|
||||
* Copyright (C) 2009 Régis Houssin <regis@dolibarr.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@ -23,56 +24,51 @@ if ( $_SESSION['uid'] <= 0 ) {
|
||||
header ('Location: index.php');
|
||||
exit;
|
||||
}
|
||||
?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
||||
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<title>Caisse</title>
|
||||
print '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">';
|
||||
|
||||
<meta name="robots" content="none" />
|
||||
print '<html>';
|
||||
print '<head>';
|
||||
print '<title>Caisse</title>';
|
||||
|
||||
<meta name="author" content="Jeremie Ollivier - jeremie.o@laposte.net" />
|
||||
<meta name="Generator" content="Kwrite, Gimp, Inkscape" />
|
||||
print '<meta name="robots" content="none" />';
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-15" />
|
||||
<meta http-equiv="Content-Language" content="fr" />
|
||||
print '<meta name="author" content="Jeremie Ollivier - jeremie.o@laposte.net" />';
|
||||
print '<meta name="Generator" content="Kwrite, Gimp, Inkscape" />';
|
||||
|
||||
<meta http-equiv="Content-Style-Type" content="text/css" />
|
||||
<link href="style.css" rel="stylesheet" type="text/css" media="screen" />
|
||||
print '<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-15" />';
|
||||
print '<meta http-equiv="Content-Language" content="fr" />';
|
||||
|
||||
<!-- Import des fichiers necessaires a JsCalendar -->
|
||||
<style type="text/css">
|
||||
@import url(include/jscalendar/calendar-blue.css);
|
||||
</style>
|
||||
<script type="text/javascript" src="include/jscalendar/calendar.js"></script>
|
||||
<script type="text/javascript"
|
||||
src="include/jscalendar/lang/calendar-fr.js"></script>
|
||||
<script type="text/javascript"
|
||||
src="include/jscalendar/calendar-setup.js"></script>
|
||||
</head>
|
||||
print '<meta http-equiv="Content-Style-Type" content="text/css" />';
|
||||
print '<link href="style.css" rel="stylesheet" type="text/css" media="screen" />';
|
||||
|
||||
<body>
|
||||
print '<!-- Import des fichiers necessaires a JsCalendar -->';
|
||||
print '<style type="text/css">';
|
||||
print '@import url(include/jscalendar/calendar-blue.css);';
|
||||
print '</style>';
|
||||
print '<script type="text/javascript" src="include/jscalendar/calendar.js"></script>';
|
||||
print '<script type="text/javascript" src="include/jscalendar/lang/calendar-fr.js"></script>';
|
||||
print '<script type="text/javascript" src="include/jscalendar/calendar-setup.js"></script>';
|
||||
print '</head>';
|
||||
|
||||
<div class="conteneur">
|
||||
<div class="conteneur_img_gauche">
|
||||
<div class="conteneur_img_droite">
|
||||
print '<body>';
|
||||
|
||||
<h1 class="entete"><span>CAISSE</span></h1>
|
||||
print '<div class="conteneur">';
|
||||
print '<div class="conteneur_img_gauche">';
|
||||
print '<div class="conteneur_img_droite">';
|
||||
|
||||
<div class="menu_principal"><?php
|
||||
include ('templates/menu.tpl.php');
|
||||
?></div>
|
||||
print '<h1 class="entete"><span>CAISSE</span></h1>';
|
||||
|
||||
<div class="contenu"><?php
|
||||
include ('affContenu.php');
|
||||
?></div>
|
||||
print '<div class="menu_principal">';
|
||||
include('templates/menu.tpl.php');
|
||||
print '</div>';
|
||||
|
||||
<?php include ('affPied.php'); ?></div>
|
||||
</div>
|
||||
</div>
|
||||
print '<div class="contenu">';
|
||||
include('affContenu.php');
|
||||
print '</div>';
|
||||
|
||||
</body>
|
||||
include('affPied.php');
|
||||
|
||||
</html>
|
||||
print '</div></div></div>';
|
||||
print '</body></html>';
|
||||
?>
|
||||
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Copyright (C) 2007-2008 Jeremie Ollivier <jeremie.o@laposte.net>
|
||||
* Copyright (C) 2008 Laurent Destailleur <eldy@uers.sourceforge.net>
|
||||
/* Copyright (C) 2007-2008 Jeremie Ollivier <jeremie.o@laposte.net>
|
||||
* Copyright (C) 2008 Laurent Destailleur <eldy@uers.sourceforge.net>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
||||
@ -1,6 +1,7 @@
|
||||
<?php
|
||||
/* Copyright (C) 2007-2008 Jeremie Ollivier <jeremie.o@laposte.net>
|
||||
* Copyright (C) 2008 Laurent Destailleur <eldy@uers.sourceforge.net>
|
||||
/* Copyright (C) 2007-2008 Jeremie Ollivier <jeremie.o@laposte.net>
|
||||
* Copyright (C) 2008 Laurent Destailleur <eldy@uers.sourceforge.net>
|
||||
* Copyright (C) 2009 Régis Houssin <regis@dolibarr.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@ -19,16 +20,16 @@
|
||||
|
||||
interface intSql {
|
||||
|
||||
// Envoie une requ<EFBFBD>te et retourne le pointeur vers le r<>sultat
|
||||
// Envoie une requete et retourne le pointeur vers le resultat
|
||||
public function query ($aRequete);
|
||||
|
||||
// Renvoie le nombre de r<EFBFBD>sultats contenus dans la ressource
|
||||
// Renvoie le nombre de resultats contenus dans la ressource
|
||||
public function num_rows ($aRes);
|
||||
|
||||
// Parcours tous les r<EFBFBD>sultats de la ressource et les enregistre dans un tableau <20> 2 dimensions : $tab[ligne][nom_champ/indice]
|
||||
// Parcours tous les resultats de la ressource et les enregistre dans un tableau a 2 dimensions : $tab[ligne][nom_champ/indice]
|
||||
public function fetch_array ($aRes);
|
||||
|
||||
// Enregistre seulement le premier r<EFBFBD>sultat de la ressource dans un tableau <20> 1 dimension : $tab[nom_champ/indice]
|
||||
// Enregistre seulement le premier resultat de la ressource dans un tableau a 1 dimension : $tab[nom_champ/indice]
|
||||
public function fetchFirst ($aRes);
|
||||
|
||||
}
|
||||
|
||||
@ -1,33 +1,35 @@
|
||||
<!--Copyright (C) 2007-2008 Jérémie Ollivier <jeremie.o@laposte.net>
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
-->
|
||||
<?php
|
||||
/* Copyright (C) 2007-2008 Jeremie Ollivier <jeremie.o@laposte.net>
|
||||
* Copyright (C) 2008 Laurent Destailleur <eldy@uers.sourceforge.net>
|
||||
* Copyright (C) 2009 Régis Houssin <regis@dolibarr.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
$langs->load("@cashdesk");
|
||||
|
||||
$logout='<img class="login" border="0" src="'.DOL_URL_ROOT.'/theme/'.$conf->theme.'/img/logout.png">';
|
||||
?>
|
||||
|
||||
<div class="menu_bloc">
|
||||
<ul class="menu">
|
||||
<li class="menu_choix1"><a href="affIndex.php?menu=facturation&id=NOUV"><span>Nouvelle vente</span></a></li>
|
||||
<li class="menu_choix2"><a href="<?php echo eregi_replace('/cashdesk','',$conf_url_racine); ?>/"><span>Gestion commerciale</span></a></li>
|
||||
<li class="menu_choix0"><a href="deconnexion.php"><span title="Cliquez pour quitter la session">Utilisateur : <?php echo $_SESSION['prenom'].' '.$_SESSION['nom'].' '.$logout; ?></span></a>
|
||||
<?php echo '<a href="'.DOL_URL_ROOT.'/soc.php?socid='.$conf->global->CASHDESK_ID_THIRDPARTY.'">'.$langs->trans("CashDeskThirdParty").' : '.$conf->global->CASHDESK_ID_THIRDPARTY.'</a>'; ?>
|
||||
<?php echo '<a href="'.DOL_URL_ROOT.'/compta/bank/fiche.php?id='.$conf->global->CASHDESK_ID_BANKACCOUNT.'">'.$langs->trans("CashDeskBank").' : '.$conf->global->CASHDESK_ID_BANKACCOUNT.'</a>'; ?>
|
||||
<?php echo '<a href="'.DOL_URL_ROOT.'/product/stock/fiche.php?id='.$conf->global->CASHDESK_ID_WAREHOUSE.'">'.$langs->trans("CashDeskWarehouse").' : '.$conf->global->CASHDESK_ID_WAREHOUSE.'</a>'; ?>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
print '<div class="menu_bloc">';
|
||||
print '<ul class="menu">';
|
||||
print '<li class="menu_choix1"><a href="affIndex.php?menu=facturation&id=NOUV"><span>Nouvelle vente</span></a></li>';
|
||||
print '<li class="menu_choix2"><a href="'.eregi_replace('cashdesk','',$conf_url_racine).'"><span>Gestion commerciale</span></a></li>';
|
||||
print '<li class="menu_choix0"><a href="deconnexion.php"><span title="Cliquez pour quitter la session">Utilisateur : '.utf8_decode($_SESSION['prenom']).' '.$_SESSION['nom'].' '.$logout.'</span></a>';
|
||||
print '<a href="'.DOL_URL_ROOT.'/soc.php?socid='.$conf->global->CASHDESK_ID_THIRDPARTY.'">'.$langs->trans("CashDeskThirdParty").' : '.$conf->global->CASHDESK_ID_THIRDPARTY.'</a>';
|
||||
print '<a href="'.DOL_URL_ROOT.'/compta/bank/fiche.php?id='.$conf->global->CASHDESK_ID_BANKACCOUNT.'">'.$langs->trans("CashDeskBank").' : '.$conf->global->CASHDESK_ID_BANKACCOUNT.'</a>';
|
||||
print '<a href="'.DOL_URL_ROOT.'/product/stock/fiche.php?id='.$conf->global->CASHDESK_ID_WAREHOUSE.'">'.$langs->trans("CashDeskWarehouse").' : '.$conf->global->CASHDESK_ID_WAREHOUSE.'</a>';
|
||||
print '</li></ul>';
|
||||
print '</div>';
|
||||
?>
|
||||
Loading…
Reference in New Issue
Block a user