dolgrap.class.php with frederic34 advices 2

This commit is contained in:
lmarcouiller 2021-01-19 09:43:06 +01:00
parent d69e36c110
commit afab5a977a
2 changed files with 12 additions and 15 deletions

View File

@ -230,18 +230,18 @@ class box_funnel_of_prospection extends ModeleBoxes
$dolgraph->SetMinValue(0);
$dolgraph->SetData($dataseries);
$dolgraph->SetLegend($liststatus);
$dolgraph->SetHideXValues(true);
$dolgraph->setHideXValues(true);
$dolgraph->SetDataColor(array_values($colorseriesstat));
$dolgraph->SetBorderColor(array_values($bordercolorseries));
$dolgraph->setBorderColor(array_values($bordercolorseries));
$dolgraph->setShowLegend(2);
$dolgraph->setShowPercent(1);
$dolgraph->SetMirrorGraphValues(true);
$dolgraph->SetBorderWidth(2);
$dolgraph->setMirrorGraphValues(true);
$dolgraph->setBorderWidth(2);
$dolgraph->SetType(array('horizontalbars'));
$dolgraph->SetHeight('200');
$dolgraph->SetWidth('600');
$dolgraph->SetTooltipsTitles($liststatus);
$dolgraph->SetTooltipsLabels($customlabels);
$dolgraph->setTooltipsTitles($liststatus);
$dolgraph->setTooltipsLabels($customlabels);
$dolgraph->mode = 'depth';
$dolgraph->draw('idgraphleadfunnel');
$stringtoprint .= $dolgraph->show($totaloppnb ? 0 : 1);

View File

@ -189,9 +189,8 @@ class DolGraph
* @param boolean $bool XValues or not
* @return boolean true
*/
public function SetHideXValues($bool)
public function setHideXValues($bool)
{
// phpcs:enable
$this->hideXValues = $bool;
return true;
}
@ -282,7 +281,7 @@ class DolGraph
* @param array $bordercolor Border Color array(array(R,G,B),array(R,G,B)...) or array('#FFFFFF','#......'...)
* @return void
*/
public function SetBorderColor($bordercolor)
public function setBorderColor($bordercolor)
{
$this->bordercolor = $bordercolor;
}
@ -293,7 +292,7 @@ class DolGraph
* @param int $borderwidth Border Width
* @return void
*/
public function SetBorderWidth($borderwidth)
public function setBorderWidth($borderwidth)
{
$this->borderwidth = $borderwidth;
}
@ -304,9 +303,8 @@ class DolGraph
* @param array $tooltipsLabels Tooltips Labels array('...','...'...)
* @return void
*/
public function SetTooltipsLabels($tooltipsLabels)
public function setTooltipsLabels($tooltipsLabels)
{
// phpcs:enable
$this->tooltipsLabels = $tooltipsLabels;
}
@ -316,9 +314,8 @@ class DolGraph
* @param array $tooltipsTitles Tooltips Titles array('...','...'...)
* @return void
*/
public function SetTooltipsTitles($tooltipsTitles)
public function setTooltipsTitles($tooltipsTitles)
{
// phpcs:enable
$this->tooltipsTitles = $tooltipsTitles;
}
@ -481,7 +478,7 @@ class DolGraph
* @param boolean $mirrorGraphValues Mirror Values if true and doesn't if false
* @return void
*/
public function SetMirrorGraphValues($mirrorGraphValues)
public function setMirrorGraphValues($mirrorGraphValues)
{
$this->mirrorGraphValues = $mirrorGraphValues;
}