dolibarr/htdocs/includes/modules/societe/mod_codecompta_panicum.php

84 lines
2.4 KiB
PHP
Raw Normal View History

2004-12-07 17:39:59 +01:00
<?php
/* Copyright (C) 2004 Rodolphe Quiedeville <rodolphe@quiedeville.org>
2010-02-25 00:29:46 +01:00
* Copyright (C) 2010 Laurent Destailleur <eldy@users.sourceforge.net>
2004-12-07 17:39:59 +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
2011-08-01 01:24:38 +02:00
* along with this program. If not, see <http://www.gnu.org/licenses/>.
2004-12-07 17:39:59 +01:00
* or see http://www.gnu.org/
*/
/**
2010-07-21 14:35:56 +02:00
* \file htdocs/includes/modules/societe/mod_codecompta_panicum.php
2010-02-25 00:29:46 +01:00
* \ingroup societe
* \brief File of class to manage accountancy code of thirdparties with Panicum rules
2010-02-25 00:29:46 +01:00
*/
require_once(DOL_DOCUMENT_ROOT."/includes/modules/societe/modules_societe.class.php");
/**
2010-02-25 00:29:46 +01:00
* \class mod_codecompta_panicum
* \brief Class to manage accountancy code of thirdparties with Panicum rules
2010-02-25 00:29:46 +01:00
*/
class mod_codecompta_panicum extends ModeleAccountancyCode
2004-12-07 17:39:59 +01:00
{
var $nom='Panicum';
var $version='dolibarr'; // 'development', 'experimental', 'dolibarr'
2009-10-19 21:54:27 +02:00
/**
* Constructor
*/
function mod_codecompta_panicum()
{
}
2009-10-19 21:54:27 +02:00
/** Return description of module
*
* @param $langs Object langs
* @return string Description of module
*/
function info($langs)
{
return $langs->trans("ModuleCompanyCode".$this->nom);
}
2009-10-19 21:54:27 +02:00
/** Return an example of result returned by getNextValue
*
* @param $langs Object langs
* @param $objsoc Object thirdparty
* @param $type Type of third party (1:customer, 2:supplier, -1:autodetect)
2010-02-25 00:29:46 +01:00
*/
function getExample($langs,$objsoc=0,$type=-1)
2010-02-25 00:29:46 +01:00
{
return '';
}
/**
* Set accountancy account code for a third party into this->code
*
* @param db Database handler
* @param societe Third party object
* @param type 'customer' or 'supplier'
* @return int >=0 if OK, <0 if KO
2010-02-25 00:29:46 +01:00
*/
function get_code($db, $societe, $type='')
2010-02-25 00:29:46 +01:00
{
// Renvoie toujours ok
$this->code = $societe->code_compta;
return 0;
}
2004-12-07 17:39:59 +01:00
}
?>