Removed PHP warnings with E_ALL level
This commit is contained in:
parent
bdfecdc751
commit
7683f0f85e
@ -1,6 +1,6 @@
|
|||||||
<?php
|
<?php
|
||||||
/* Copyright (C) 2001-2004 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
/* Copyright (C) 2001-2004 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||||
* Copyright (C) 2004-2008 Laurent Destailleur <eldy@users.sourceforge.net>
|
* Copyright (C) 2004-2009 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* 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
|
* it under the terms of the GNU General Public License as published by
|
||||||
@ -31,9 +31,11 @@ $langs->load("companies");
|
|||||||
if (!$user->admin)
|
if (!$user->admin)
|
||||||
accessforbidden();
|
accessforbidden();
|
||||||
|
|
||||||
|
$mesg='';
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Affichage page
|
* View
|
||||||
*/
|
*/
|
||||||
|
|
||||||
llxHeader();
|
llxHeader();
|
||||||
@ -46,7 +48,7 @@ print_fiche_titre($langs->trans("SetupArea"),'','setup');
|
|||||||
print "<br>";
|
print "<br>";
|
||||||
print '<center><img src="'.DOL_URL_ROOT.'/theme/dolibarr_logo_2.png" alt="Dolibarr logo"></center><br>';
|
print '<center><img src="'.DOL_URL_ROOT.'/theme/dolibarr_logo_2.png" alt="Dolibarr logo"></center><br>';
|
||||||
|
|
||||||
if ($message) print $message.'<br>';
|
if ($mesg) print $mesg.'<br>';
|
||||||
|
|
||||||
print "<br>";
|
print "<br>";
|
||||||
print $langs->trans("SetupDescription1")."<br>";
|
print $langs->trans("SetupDescription1")."<br>";
|
||||||
|
|||||||
@ -39,7 +39,7 @@ if (!$user->admin)
|
|||||||
* Actions
|
* Actions
|
||||||
*/
|
*/
|
||||||
|
|
||||||
if ($_GET["action"] == 'set' && $user->admin)
|
if (isset($_GET["action"]) && $_GET["action"] == 'set' && $user->admin)
|
||||||
{
|
{
|
||||||
$result=Activate($_GET["value"]);
|
$result=Activate($_GET["value"]);
|
||||||
$mesg='';
|
$mesg='';
|
||||||
@ -48,7 +48,7 @@ if ($_GET["action"] == 'set' && $user->admin)
|
|||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($_GET["action"] == 'reset' && $user->admin)
|
if (isset($_GET["action"]) && $_GET["action"] == 'reset' && $user->admin)
|
||||||
{
|
{
|
||||||
$result=UnActivate($_GET["value"]);
|
$result=UnActivate($_GET["value"]);
|
||||||
$mesg='';
|
$mesg='';
|
||||||
@ -230,8 +230,8 @@ foreach ($conf->dol_document_root as $dirroot)
|
|||||||
$modulequalified=1;
|
$modulequalified=1;
|
||||||
|
|
||||||
// We discard modules that does not respect constraint on menu handlers
|
// We discard modules that does not respect constraint on menu handlers
|
||||||
if ($objMod->needleftmenu && sizeof($objMod->needleftmenu) && ! in_array($conf->left_menu,$objMod->needleftmenu)) $modulequalified=0;
|
if (! empty($objMod->needleftmenu) && sizeof($objMod->needleftmenu) && ! in_array($conf->left_menu,$objMod->needleftmenu)) $modulequalified=0;
|
||||||
if ($objMod->needtopmenu && sizeof($objMod->needtopmenu) && ! in_array($conf->top_menu,$objMod->needtopmenu)) $modulequalified=0;
|
if (! empty($objMod->needtopmenu) && sizeof($objMod->needtopmenu) && ! in_array($conf->top_menu,$objMod->needtopmenu)) $modulequalified=0;
|
||||||
|
|
||||||
// We discard modules according to features level (PS: if module is activated we always show it)
|
// We discard modules according to features level (PS: if module is activated we always show it)
|
||||||
$const_name = 'MAIN_MODULE_'.strtoupper(eregi_replace('^mod','',get_class($objMod)));
|
$const_name = 'MAIN_MODULE_'.strtoupper(eregi_replace('^mod','',get_class($objMod)));
|
||||||
@ -244,7 +244,8 @@ foreach ($conf->dol_document_root as $dirroot)
|
|||||||
$filename[$i]= $modName;
|
$filename[$i]= $modName;
|
||||||
$orders[$i] = $objMod->family."_".$j; // Tri par famille puis numero module
|
$orders[$i] = $objMod->family."_".$j; // Tri par famille puis numero module
|
||||||
//print "x".$modName." ".$orders[$i]."\n<br>";
|
//print "x".$modName." ".$orders[$i]."\n<br>";
|
||||||
$categ[$objMod->special]++; // Array of all different modules categories
|
if (isset($categ[$objMod->special])) $categ[$objMod->special]++; // Array of all different modules categories
|
||||||
|
else $categ[$objMod->special]=1;
|
||||||
$dirmod[$i] = $dirroot;
|
$dirmod[$i] = $dirroot;
|
||||||
$j++;
|
$j++;
|
||||||
$i++;
|
$i++;
|
||||||
@ -272,7 +273,7 @@ print "<br>\n";
|
|||||||
$h = 0;
|
$h = 0;
|
||||||
|
|
||||||
$categidx=0;
|
$categidx=0;
|
||||||
if ($categ[$categidx])
|
if (! empty($categ[$categidx]))
|
||||||
{
|
{
|
||||||
$head[$h][0] = DOL_URL_ROOT."/admin/modules.php?mode=".$categidx;
|
$head[$h][0] = DOL_URL_ROOT."/admin/modules.php?mode=".$categidx;
|
||||||
$head[$h][1] = $langs->trans("ModulesCommon");
|
$head[$h][1] = $langs->trans("ModulesCommon");
|
||||||
@ -281,7 +282,7 @@ if ($categ[$categidx])
|
|||||||
}
|
}
|
||||||
|
|
||||||
$categidx=1;
|
$categidx=1;
|
||||||
if ($categ[$categidx])
|
if (! empty($categ[$categidx]))
|
||||||
{
|
{
|
||||||
$head[$h][0] = DOL_URL_ROOT."/admin/modules.php?mode=".$categidx;
|
$head[$h][0] = DOL_URL_ROOT."/admin/modules.php?mode=".$categidx;
|
||||||
$head[$h][1] = $langs->trans("ModulesInterfaces");
|
$head[$h][1] = $langs->trans("ModulesInterfaces");
|
||||||
@ -290,7 +291,7 @@ if ($categ[$categidx])
|
|||||||
}
|
}
|
||||||
|
|
||||||
$categidx=2;
|
$categidx=2;
|
||||||
if ($categ[$categidx])
|
if (! empty($categ[$categidx]))
|
||||||
{
|
{
|
||||||
$head[$h][0] = DOL_URL_ROOT."/admin/modules.php?mode=".$categidx;
|
$head[$h][0] = DOL_URL_ROOT."/admin/modules.php?mode=".$categidx;
|
||||||
$head[$h][1] = $langs->trans("ModulesOther");
|
$head[$h][1] = $langs->trans("ModulesOther");
|
||||||
@ -299,7 +300,7 @@ if ($categ[$categidx])
|
|||||||
}
|
}
|
||||||
|
|
||||||
$categidx=3;
|
$categidx=3;
|
||||||
if ($categ[$categidx])
|
if (! empty($categ[$categidx]))
|
||||||
{
|
{
|
||||||
$head[$h][0] = DOL_URL_ROOT."/admin/modules.php?mode=".$categidx;
|
$head[$h][0] = DOL_URL_ROOT."/admin/modules.php?mode=".$categidx;
|
||||||
$head[$h][1] = $langs->trans("ModulesJob");
|
$head[$h][1] = $langs->trans("ModulesJob");
|
||||||
@ -327,7 +328,8 @@ print "</tr>\n";
|
|||||||
|
|
||||||
// Affichage liste modules
|
// Affichage liste modules
|
||||||
|
|
||||||
$var=True;
|
$var=true;
|
||||||
|
$oldfamily='';
|
||||||
|
|
||||||
$familylib=array(
|
$familylib=array(
|
||||||
'base'=>$langs->trans("ModuleFamilyBase"),
|
'base'=>$langs->trans("ModuleFamilyBase"),
|
||||||
@ -351,7 +353,7 @@ foreach ($orders as $key => $value)
|
|||||||
$const_name = 'MAIN_MODULE_'.strtoupper(eregi_replace('^mod','',get_class($objMod)));
|
$const_name = 'MAIN_MODULE_'.strtoupper(eregi_replace('^mod','',get_class($objMod)));
|
||||||
|
|
||||||
// Load all lang files of module
|
// Load all lang files of module
|
||||||
if (is_array($objMod->langfiles))
|
if (isset($objMod->langfiles) && is_array($objMod->langfiles))
|
||||||
{
|
{
|
||||||
foreach($objMod->langfiles as $domain)
|
foreach($objMod->langfiles as $domain)
|
||||||
{
|
{
|
||||||
@ -387,7 +389,7 @@ foreach ($orders as $key => $value)
|
|||||||
}
|
}
|
||||||
print "</td>\n";
|
print "</td>\n";
|
||||||
print ' <td valign="top" width="14" align="center">';
|
print ' <td valign="top" width="14" align="center">';
|
||||||
print $objMod->picto?img_object('',$objMod->picto):img_object('','generic');
|
print ! empty($objMod->picto)?img_object('',$objMod->picto):img_object('','generic');
|
||||||
print '</td><td valign="top">'.$objMod->getName();
|
print '</td><td valign="top">'.$objMod->getName();
|
||||||
print "</td>\n <td valign=\"top\">";
|
print "</td>\n <td valign=\"top\">";
|
||||||
print nl2br($objMod->getDesc());
|
print nl2br($objMod->getDesc());
|
||||||
@ -397,7 +399,7 @@ foreach ($orders as $key => $value)
|
|||||||
// print $objMod->getDbVersion();
|
// print $objMod->getDbVersion();
|
||||||
print "</td>\n <td align=\"center\" valign=\"top\">";
|
print "</td>\n <td align=\"center\" valign=\"top\">";
|
||||||
|
|
||||||
if ($conf->global->$const_name)
|
if (! empty($conf->global->$const_name))
|
||||||
{
|
{
|
||||||
print img_tick();
|
print img_tick();
|
||||||
}
|
}
|
||||||
@ -408,13 +410,13 @@ foreach ($orders as $key => $value)
|
|||||||
|
|
||||||
print "</td>\n <td align=\"center\" valign=\"top\">";
|
print "</td>\n <td align=\"center\" valign=\"top\">";
|
||||||
|
|
||||||
if ($conf->global->$const_name)
|
if (! empty($conf->global->$const_name))
|
||||||
{
|
{
|
||||||
// Module actif
|
// Module actif
|
||||||
if ($objMod->always_enabled) print $langs->trans("Required");
|
if (! empty($objMod->always_enabled)) print $langs->trans("Required");
|
||||||
else print "<a href=\"modules.php?id=".$objMod->numero."&action=reset&value=" . $modName . "&mode=" . $mode . "\">" . $langs->trans("Disable") . "</a></td>\n";
|
else print "<a href=\"modules.php?id=".$objMod->numero."&action=reset&value=" . $modName . "&mode=" . $mode . "\">" . $langs->trans("Disable") . "</a></td>\n";
|
||||||
|
|
||||||
if ($objMod->config_page_url)
|
if (! empty($objMod->config_page_url))
|
||||||
{
|
{
|
||||||
if (is_array($objMod->config_page_url))
|
if (is_array($objMod->config_page_url))
|
||||||
{
|
{
|
||||||
@ -450,7 +452,7 @@ foreach ($orders as $key => $value)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if ($objMod->always_enabled)
|
if (! empty($objMod->always_enabled))
|
||||||
{
|
{
|
||||||
// Ne devrait pas arriver.
|
// Ne devrait pas arriver.
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<?php
|
<?php
|
||||||
/* Copyright (C) 2003-2006 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
/* Copyright (C) 2003-2006 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||||
* Copyright (C) 2004-2006 Laurent Destailleur <eldy@users.sourceforge.net>
|
* Copyright (C) 2004-2009 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
* Copyright (C) 2005 Simon Tosser <simon@kornog-computing.com>
|
* Copyright (C) 2005 Simon Tosser <simon@kornog-computing.com>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* This program is free software; you can redistribute it and/or modify
|
||||||
@ -35,7 +35,7 @@ function llxHeader($head = '', $title='', $help_url='')
|
|||||||
{
|
{
|
||||||
global $conf, $user, $langs;
|
global $conf, $user, $langs;
|
||||||
|
|
||||||
top_menu($head, $title, $target);
|
top_menu($head, $title, '');
|
||||||
|
|
||||||
$menuarray=array();
|
$menuarray=array();
|
||||||
|
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<?php
|
<?php
|
||||||
/* Copyright (C) 2003 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
/* Copyright (C) 2003 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||||
* Copyright (C) 2004-2007 Laurent Destailleur <eldy@users.sourceforge.net>
|
* Copyright (C) 2004-2009 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
* Copyright (C) 2004 Sebastien Di Cintio <sdicintio@ressource-toi.org>
|
* Copyright (C) 2004 Sebastien Di Cintio <sdicintio@ressource-toi.org>
|
||||||
* Copyright (C) 2004 Benoit Mortier <benoit.mortier@opensides.be>
|
* Copyright (C) 2004 Benoit Mortier <benoit.mortier@opensides.be>
|
||||||
*
|
*
|
||||||
@ -81,7 +81,6 @@ class modComptabiliteExpert extends DolibarrModules
|
|||||||
$this->dirs[0] = $conf->comptaexpert->dir_output;
|
$this->dirs[0] = $conf->comptaexpert->dir_output;
|
||||||
$this->dirs[1] = $conf->comptaexpert->dir_output."/rapport";
|
$this->dirs[1] = $conf->comptaexpert->dir_output."/rapport";
|
||||||
$this->dirs[2] = $conf->comptaexpert->dir_output."/export";
|
$this->dirs[2] = $conf->comptaexpert->dir_output."/export";
|
||||||
$this->dirs[3] = $conf->comptaexpert->dir_images;
|
|
||||||
|
|
||||||
// Boites
|
// Boites
|
||||||
$this->boxes = array();
|
$this->boxes = array();
|
||||||
|
|||||||
@ -152,7 +152,7 @@ class modProduit extends DolibarrModules
|
|||||||
$r=0;
|
$r=0;
|
||||||
|
|
||||||
$r++;
|
$r++;
|
||||||
$this->import_code[$r]=$this->id.'_'.$r;
|
$this->import_code[$r]=$this->rights_class.'_'.$r;
|
||||||
$this->import_label[$r]="ProductsOrServices"; // Translation key
|
$this->import_label[$r]="ProductsOrServices"; // Translation key
|
||||||
$this->import_fields_array[$r]=array('p.rowid'=>"Id",'p.ref'=>"Ref",'p.fk_product_type'=>"Type",'p.label'=>"Label",'p.description'=>"Description",'p.note'=>"Note",'p.price'=>"SellingPriceHT",'p.price_ttc'=>"SellingPriceTTC",'p.tva_tx'=>'VAT','p.envente'=>"OnSell",'p.duration'=>"Duration");
|
$this->import_fields_array[$r]=array('p.rowid'=>"Id",'p.ref'=>"Ref",'p.fk_product_type'=>"Type",'p.label'=>"Label",'p.description'=>"Description",'p.note'=>"Note",'p.price'=>"SellingPriceHT",'p.price_ttc'=>"SellingPriceTTC",'p.tva_tx'=>'VAT','p.envente'=>"OnSell",'p.duration'=>"Duration");
|
||||||
$this->import_entities_array[$r]=array('p.rowid'=>"product",'p.ref'=>"product",'p.fk_product_type'=>"product",'p.label'=>"product",'p.description'=>"product",'p.note'=>"product",'p.price'=>"product",'p.price_ttc'=>"product",'p.tva_tx'=>'product','p.envente'=>"product",'p.duration'=>"product");
|
$this->import_entities_array[$r]=array('p.rowid'=>"product",'p.ref'=>"product",'p.fk_product_type'=>"product",'p.label'=>"product",'p.description'=>"product",'p.note'=>"product",'p.price'=>"product",'p.price_ttc'=>"product",'p.tva_tx'=>'product','p.envente'=>"product",'p.duration'=>"product");
|
||||||
|
|||||||
@ -57,8 +57,8 @@ else
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Forcage du parametrage PHP error_reporting (Dolibarr non utilisable en mode error E_ALL)
|
// Forcage du parametrage PHP error_reporting (Dolibarr non utilisable en mode error E_ALL)
|
||||||
//error_reporting(E_ALL);
|
|
||||||
error_reporting(E_ALL ^ E_NOTICE);
|
error_reporting(E_ALL ^ E_NOTICE);
|
||||||
|
error_reporting(E_ALL);
|
||||||
|
|
||||||
|
|
||||||
// Include configuration
|
// Include configuration
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user