2003-03-11 16:33:17 +01:00
|
|
|
|
<?PHP
|
|
|
|
|
|
/* Copyright (C) 2003 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
2004-02-22 21:27:20 +01:00
|
|
|
|
* Copyright (C) 2004 Laurent Destailleur <eldy@users.sourceforge.net>
|
2003-03-11 16:33:17 +01:00
|
|
|
|
*
|
|
|
|
|
|
* 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.
|
|
|
|
|
|
* or see http://www.gnu.org/
|
|
|
|
|
|
*
|
|
|
|
|
|
* $Id$
|
|
|
|
|
|
* $Source$
|
|
|
|
|
|
*
|
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
|
|
function venus_get_num_explain()
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
|
|
return '
|
|
|
|
|
|
Renvoie le num<EFBFBD>ro de facture sous la forme, F-PR-030202, o<EFBFBD> PR est le pr<EFBFBD>fixe commercial de la soci<EFBFBD>t<EFBFBD>, et est suivi de la date sur un format de 6 digits avec Ann<EFBFBD>e, Mois et Jour';
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
function pluton_get_num_explain()
|
|
|
|
|
|
{
|
|
|
|
|
|
return '
|
2004-02-22 21:27:20 +01:00
|
|
|
|
Renvoie le num<EFBFBD>ro de facture sous une forme num<EFBFBD>rique simple, la premi<EFBFBD>re facture porte le num<EFBFBD>ro 1, la quinzi<EFBFBD>me facture ayant le num<EFBFBD>ro 15.';
|
2003-03-11 16:33:17 +01:00
|
|
|
|
}
|
|
|
|
|
|
|
2003-09-29 12:04:27 +02:00
|
|
|
|
function neptune_get_num_explain()
|
|
|
|
|
|
{
|
2003-09-29 12:09:36 +02:00
|
|
|
|
$texte = '
|
2003-09-29 12:04:27 +02:00
|
|
|
|
Identique <EFBFBD> pluton, avec un correcteur au moyen de la constante FACTURE_NEPTUNE_DELTA.';
|
2003-09-29 12:09:36 +02:00
|
|
|
|
if (defined("FACTURE_NEPTUNE_DELTA"))
|
|
|
|
|
|
{
|
2004-02-22 21:27:20 +01:00
|
|
|
|
$texte .= "D<EFBFBD>fini et vaut : ".FACTURE_NEPTUNE_DELTA;
|
2003-09-29 12:09:36 +02:00
|
|
|
|
}
|
|
|
|
|
|
else
|
|
|
|
|
|
{
|
2004-02-22 21:27:20 +01:00
|
|
|
|
$texte .= "N'est pas d<>fini";
|
2003-09-29 12:09:36 +02:00
|
|
|
|
}
|
|
|
|
|
|
return $texte;
|
2003-09-29 12:04:27 +02:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
2003-08-02 17:26:11 +02:00
|
|
|
|
function jupiter_get_num_explain()
|
|
|
|
|
|
{
|
|
|
|
|
|
return '
|
2004-02-22 21:27:20 +01:00
|
|
|
|
Syst<EFBFBD>me de num<EFBFBD>rotation mensuel sous la forme F20030715, qui correspond <EFBFBD> la 15<EFBFBD>me facture du mois de Juillet 2003';
|
2003-08-02 17:26:11 +02:00
|
|
|
|
}
|
2003-04-13 16:48:38 +02:00
|
|
|
|
|
|
|
|
|
|
function facture_pdf_create($db, $facid)
|
|
|
|
|
|
{
|
|
|
|
|
|
|
2003-06-22 12:11:39 +02:00
|
|
|
|
$dir = DOL_DOCUMENT_ROOT . "/includes/modules/facture/";
|
2003-04-13 16:48:38 +02:00
|
|
|
|
|
|
|
|
|
|
if (defined("FACTURE_ADDON_PDF"))
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
|
|
$file = "pdf_".FACTURE_ADDON_PDF.".modules.php";
|
|
|
|
|
|
|
|
|
|
|
|
$classname = "pdf_".FACTURE_ADDON_PDF;
|
|
|
|
|
|
require_once($dir.$file);
|
|
|
|
|
|
|
|
|
|
|
|
$obj = new $classname($db);
|
|
|
|
|
|
|
2003-09-09 19:05:47 +02:00
|
|
|
|
if ( $obj->write_pdf_file($facid) > 0)
|
|
|
|
|
|
{
|
|
|
|
|
|
return 1;
|
|
|
|
|
|
}
|
|
|
|
|
|
else
|
|
|
|
|
|
{
|
|
|
|
|
|
print "Erreur";
|
|
|
|
|
|
return 0;
|
|
|
|
|
|
}
|
2003-04-13 16:48:38 +02:00
|
|
|
|
}
|
|
|
|
|
|
else
|
|
|
|
|
|
{
|
2003-06-22 12:11:39 +02:00
|
|
|
|
print "Erreur FACTURE_ADDON_PDF non d<>finit !";
|
2003-09-09 19:05:47 +02:00
|
|
|
|
return 0;
|
2003-04-13 16:48:38 +02:00
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2003-03-11 16:33:17 +01:00
|
|
|
|
?>
|