From 1f2493f361f89f5bf5f69088952b8872d92c0060 Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Mon, 24 Sep 2018 11:45:34 +0200 Subject: [PATCH 1/4] Standardize and update code --- htdocs/core/class/dolgraph.class.php | 54 ++++++++++++++-------------- 1 file changed, 27 insertions(+), 27 deletions(-) diff --git a/htdocs/core/class/dolgraph.class.php b/htdocs/core/class/dolgraph.class.php index 618716ce0e4..ad7b900b033 100644 --- a/htdocs/core/class/dolgraph.class.php +++ b/htdocs/core/class/dolgraph.class.php @@ -39,46 +39,46 @@ */ class DolGraph { - var $type=array(); // Array with type of each series. Example: array('bars', 'lines', ...) - var $mode='side'; // Mode bars graph: side, depth + public $type=array(); // Array with type of each series. Example: array('bars', 'lines', ...) + public $mode='side'; // Mode bars graph: side, depth private $_library='jflot'; // Graphic library to use (jflot, artichow) //! Array of data - var $data; // Data of graph: array(array('abs1',valA1,valB1), array('abs2',valA2,valB2), ...) - var $title; // Title of graph - var $cssprefix=''; // To add into css styles - var $width=380; - var $height=200; - var $MaxValue=0; - var $MinValue=0; - var $SetShading=0; + public $data; // Data of graph: array(array('abs1',valA1,valB1), array('abs2',valA2,valB2), ...) + public $title; // Title of graph + public $cssprefix=''; // To add into css styles + public $width=380; + public $height=200; + public $MaxValue=0; + public $MinValue=0; + public $SetShading=0; - var $PrecisionY=-1; + public $PrecisionY=-1; - var $horizTickIncrement=-1; - var $SetNumXTicks=-1; - var $labelInterval=-1; + public $horizTickIncrement=-1; + public $SetNumXTicks=-1; + public $labelInterval=-1; - var $hideXGrid=false; - var $hideYGrid=false; + public $hideXGrid=false; + public $hideYGrid=false; - var $Legend=array(); - var $LegendWidthMin=0; - var $showlegend=1; - var $showpointvalue=1; - var $showpercent=0; - var $combine=0; // 0.05 if you want to combine records < 5% into "other" - var $graph; // Objet Graph (Artichow, Phplot...) + public $Legend=array(); + public $LegendWidthMin=0; + public $showlegend=1; + public $showpointvalue=1; + public $showpercent=0; + public $combine=0; // 0.05 if you want to combine records < 5% into "other" + public $graph; // Objet Graph (Artichow, Phplot...) /** * @var string Error code (or message) */ public $error=''; - var $bordercolor; // array(R,G,B) - var $bgcolor; // array(R,G,B) - var $bgcolorgrid=array(255,255,255); // array(R,G,B) - var $datacolor; // array(array(R,G,B),...) + public $bordercolor; // array(R,G,B) + public $bgcolor; // array(R,G,B) + public $bgcolorgrid=array(255,255,255); // array(R,G,B) + public $datacolor; // array(array(R,G,B),...) private $stringtoshow; // To store string to output graph into HTML page From ac31b79d9dd3a1312bb4d706af1eccccf9fd55a0 Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Mon, 24 Sep 2018 11:58:01 +0200 Subject: [PATCH 2/4] Standardize and update code --- htdocs/core/class/antivir.class.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/htdocs/core/class/antivir.class.php b/htdocs/core/class/antivir.class.php index d18501d54d9..c67e3f5f59d 100644 --- a/htdocs/core/class/antivir.class.php +++ b/htdocs/core/class/antivir.class.php @@ -40,7 +40,10 @@ class AntiVir */ public $errors = array(); - var $output; + /** + * @var string Used to return message + */ + public $output; /** * @var DoliDB Database handler. From d7df74656e7c0fff6866f71a762cec9e4a775513 Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Mon, 24 Sep 2018 12:03:49 +0200 Subject: [PATCH 3/4] Standardize and update code --- htdocs/core/class/canvas.class.php | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/htdocs/core/class/canvas.class.php b/htdocs/core/class/canvas.class.php index a4665701661..cf830048cc0 100644 --- a/htdocs/core/class/canvas.class.php +++ b/htdocs/core/class/canvas.class.php @@ -43,15 +43,15 @@ class Canvas */ public $errors = array(); - var $actiontype; + public $actiontype; - var $dirmodule; // Module directory - var $targetmodule; // Module concerned by canvas (ex: thirdparty, contact, ...) - var $canvas; // Name of canvas (ex: company, individual, product, service, ...) - var $card; // Tab (sub-canvas) + public $dirmodule; // Module directory + public $targetmodule; // Module concerned by canvas (ex: thirdparty, contact, ...) + public $canvas; // Name of canvas (ex: company, individual, product, service, ...) + public $card; // Tab (sub-canvas) - var $template_dir; // Initialized by getCanvas with templates directory - var $control; // Initialized by getCanvas with controller instance + public $template_dir; // Initialized by getCanvas with templates directory + public $control; // Initialized by getCanvas with controller instance /** From 3f2f903e6f3d605b43df2c9d17fa68e59bb4f140 Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Mon, 24 Sep 2018 12:22:41 +0200 Subject: [PATCH 4/4] Specifics comments --- htdocs/multicurrency/class/multicurrency.class.php | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/htdocs/multicurrency/class/multicurrency.class.php b/htdocs/multicurrency/class/multicurrency.class.php index ab72aabaee0..549f0fd411a 100644 --- a/htdocs/multicurrency/class/multicurrency.class.php +++ b/htdocs/multicurrency/class/multicurrency.class.php @@ -20,15 +20,14 @@ */ /** - * \file dev/skeletons/skeleton_class.class.php - * \ingroup mymodule othermodule1 othermodule2 - * \brief This file is an example for a CRUD class file (Create/Read/Update/Delete) - * Put some comments here + * \file htdocs/multicurrency/class/multicurrency.class.php + * \ingroup multicurrency + * \brief This file is a CRUD class file (Create/Read/Update/Delete) for multicurrency */ // Put here all includes required by your class file -require_once DOL_DOCUMENT_ROOT . '/core/class/commonobject.class.php'; -require_once DOL_DOCUMENT_ROOT ."/core/class/commonobjectline.class.php"; +require_once DOL_DOCUMENT_ROOT .'/core/class/commonobject.class.php'; +require_once DOL_DOCUMENT_ROOT .'/core/class/commonobjectline.class.php'; /** * Class Currency