Move all modules into includes/modules directory

This commit is contained in:
Laurent Destailleur 2008-10-25 23:19:30 +00:00
parent 5424704757
commit d4fdb23618
13 changed files with 40 additions and 127 deletions

View File

@ -60,7 +60,7 @@ if ($_GET["action"] == 'specimen')
$commande->initAsSpecimen();
// Charge le modele
$dir = DOL_DOCUMENT_ROOT . "/fourn/commande/modules/pdf/";
$dir = DOL_DOCUMENT_ROOT . "/includes/modules/supplier_order/pdf/";
$file = "pdf_".$modele.".modules.php";
if (file_exists($dir.$file))
{
@ -152,17 +152,21 @@ if ($_POST["action"] == 'setNumRestart') dolibarr_set_const($db, "COMMANDE_FOURN
/*
* View
*/
llxHeader();
$dir = "../fourn/commande/modules/pdf/";
$html=new Form($db);
llxHeader();
$linkback='<a href="'.DOL_URL_ROOT.'/admin/modules.php">'.$langs->trans("BackToModuleList").'</a>';
print_fiche_titre($langs->trans("SuppliersSetup"),$linkback,'setup');
print "<br>";
// Supplier order numbering module
$dir = DOL_DOCUMENT_ROOT."/includes/modules/supplier_order/";
print_titre($langs->trans("OrdersNumberingModules"));
print '<table class="noborder" width="100%">';
@ -176,7 +180,6 @@ print "</tr>\n";
clearstatcache();
$dir = "../fourn/commande/modules/";
$handle = opendir($dir);
if ($handle)
{
@ -188,7 +191,7 @@ if ($handle)
{
$file = substr($file, 0, strlen($file)-4);
require_once(DOL_DOCUMENT_ROOT ."/fourn/commande/modules/".$file.".php");
require_once(DOL_DOCUMENT_ROOT ."/includes/modules/supplier_order/".$file.".php");
$module = new $file;
@ -251,9 +254,13 @@ if ($handle)
print '</table><br>';
/*
* Modeles de documents
* Modeles documents for supplier orders
*/
$dir = DOL_DOCUMENT_ROOT.'/includes/modules/supplier_order/pdf/';
print_titre($langs->trans("OrdersModelModule"));
// Defini tableau def de modele
@ -279,8 +286,6 @@ else
dolibarr_print_error($db);
}
$dir = "../fourn/commande/modules/pdf/";
print "<table class=\"noborder\" width=\"100%\">\n";
print "<tr class=\"liste_titre\">\n";
print ' <td width="100">'.$langs->trans("Name")."</td>\n";

View File

@ -27,7 +27,7 @@
*/
require('./pre.inc.php');
require_once(DOL_DOCUMENT_ROOT.'/fourn/commande/modules/modules_commandefournisseur.php');
require_once(DOL_DOCUMENT_ROOT.'/includes/modules/supplier_order/modules_commandefournisseur.php');
require_once(DOL_DOCUMENT_ROOT."/product/stock/entrepot.class.php");
if ($conf->projet->enabled) require_once(DOL_DOCUMENT_ROOT.'/project.class.php');

View File

@ -28,7 +28,7 @@
require('./pre.inc.php');
require_once(DOL_DOCUMENT_ROOT."/html.formfile.class.php");
require_once(DOL_DOCUMENT_ROOT.'/fourn/commande/modules/modules_commandefournisseur.php');
require_once(DOL_DOCUMENT_ROOT.'/includes/modules/supplier_order/modules_commandefournisseur.php');
require_once DOL_DOCUMENT_ROOT."/fourn/fournisseur.product.class.php";
if ($conf->projet->enabled) require_once(DOL_DOCUMENT_ROOT.'/project.class.php');

View File

@ -1,23 +0,0 @@
<?php
/* Copyright (C) 2005 Rodolphe Quiedeville <rodolphe@quiedeville.org>
*
* 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.
*
* $Id$
* $Source$
*/
Header("Location: ../index.php");
?>

View File

@ -1,23 +0,0 @@
<?php
/* Copyright (C) 2005 Rodolphe Quiedeville <rodolphe@quiedeville.org>
*
* 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.
*
* $Id$
* $Source$
*/
Header("Location: ../index.php");
?>

View File

@ -1,23 +0,0 @@
<?php
/* Copyright (C) 2005 Rodolphe Quiedeville <rodolphe@quiedeville.org>
*
* 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.
*
* $Id$
* $Source$
*/
Header("Location: ../index.php");
?>

View File

@ -1,23 +0,0 @@
<?php
/* Copyright (C) 2005 Rodolphe Quiedeville <rodolphe@quiedeville.org>
*
* 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.
*
* $Id$
* $Source$
*/
Header("Location: ../index.php");
?>

View File

@ -451,7 +451,7 @@ class CommandeFournisseur extends Commande
global $db, $langs, $conf;
$langs->load("orders");
$dir = DOL_DOCUMENT_ROOT .'/fourn/commande/modules';
$dir = DOL_DOCUMENT_ROOT .'/includes/modules/supplier_order/';
$modelisok=0;
$liste=array();

View File

@ -228,7 +228,7 @@ class FormFile
if (is_array($genallowed)) $modellist=$genallowed;
else
{
include_once(DOL_DOCUMENT_ROOT.'/fourn/commande/modules/modules_commandefournisseur.php');
include_once(DOL_DOCUMENT_ROOT.'/includes/modules/supplier_order/modules_commandefournisseur.php');
$model=new ModelePDFSuppliersOrders();
$modellist=$model->liste_modeles($this->db);
}

View File

@ -19,13 +19,13 @@
*/
/**
\file htdocs/fourn/commande/modules/mod_commande_fournisseur_muguet.php
\ingroup commande
\brief Fichier contenant la classe du mod<EFBFBD>le de num<EFBFBD>rotation de r<EFBFBD>f<EFBFBD>rence de commande fournisseur Muguet
\version $Id$
*/
* \file htdocs/includes/modules/supplier_order/mod_commande_fournisseur_muguet.php
* \ingroup commande
* \brief Fichier contenant la classe du mod<EFBFBD>le de num<EFBFBD>rotation de r<EFBFBD>f<EFBFBD>rence de commande fournisseur Muguet
* \version $Id$
*/
require_once(DOL_DOCUMENT_ROOT ."/fourn/commande/modules/modules_commandefournisseur.php");
require_once(DOL_DOCUMENT_ROOT ."/includes/modules/supplier_order/modules_commandefournisseur.php");
/** \class mod_commande_fournisseur_muguet

View File

@ -20,13 +20,13 @@
*/
/**
\file htdocs/fourn/commande/modules/mod_commande_fournisseur_orchidee.php
\ingroup commande
\brief Fichier contenant la classe du modèle de numérotation de référence de commande fournisseur Orchidee
\version $Id$
*/
* \file htdocs/includes/modules/supplier_order/mod_commande_fournisseur_orchidee.php
* \ingroup commande
* \brief Fichier contenant la classe du modèle de numérotation de référence de commande fournisseur Orchidee
* \version $Id$
*/
require_once(DOL_DOCUMENT_ROOT ."/fourn/commande/modules/modules_commandefournisseur.php");
require_once(DOL_DOCUMENT_ROOT ."/includes/modules/supplier_order/modules_commandefournisseur.php");
/**

View File

@ -21,12 +21,12 @@
*/
/**
\file htdocs/includes/modules/commande/modules_commandefournisseur.php
\ingroup commande
\brief Fichier contenant la classe mère de generation des commandes fournisseurs en PDF
et la classe mère de numérotation des commandes fournisseurs
\version $Id$
*/
* \file htdocs/includes/modules/supplier_order/modules_commandefournisseur.php
* \ingroup commande
* \brief Fichier contenant la classe mère de generation des commandes fournisseurs en PDF
* et la classe mère de numérotation des commandes fournisseurs
* \version $Id$
*/
require_once(DOL_DOCUMENT_ROOT.'/includes/fpdf/fpdfi/fpdi_protection.php');
@ -158,7 +158,7 @@ function supplier_order_pdf_create($db, $comid, $modele='',$outputlangs='')
global $langs;
$langs->load("suppliers");
$dir = DOL_DOCUMENT_ROOT."/fourn/commande/modules/pdf/";
$dir = DOL_DOCUMENT_ROOT."//includes/modules/supplier_order/pdf/";
// Positionne modele sur le nom du modele de commande fournisseur à utiliser
if (! strlen($modele))

View File

@ -20,14 +20,14 @@
*/
/**
* \file htdocs/fourn/commande/modules/pdf_muscadet.modules.php
* \file htdocs/includes/modules/supplier_order/pdf/pdf_muscadet.modules.php
* \ingroup fournisseur
* \brief Fichier de la classe permettant de g<EFBFBD>n<EFBFBD>rer les commandes fournisseurs au mod<EFBFBD>le Muscadet
* \author Regis Houssin
* \version $Id$
*/
require_once(DOL_DOCUMENT_ROOT."/fourn/commande/modules/modules_commandefournisseur.php");
require_once(DOL_DOCUMENT_ROOT."/includes/modules/supplier_order/modules_commandefournisseur.php");
require_once(DOL_DOCUMENT_ROOT."/fourn/fournisseur.commande.class.php");
require_once(DOL_DOCUMENT_ROOT."/product.class.php");
require_once(DOL_DOCUMENT_ROOT."/lib/company.lib.php");
@ -53,7 +53,7 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
$this->db = $db;
$this->name = "muscadet";
$this->description = "Mod<EFBFBD>le de commandes fournisseur complet (logo...)";
$this->description = "Modele de commandes fournisseur complet (logo...)";
// Dimension page pour format A4
$this->type = 'pdf';