Skip to content
Permalink
Browse files

Fix class visibility

  • Loading branch information...
eldy committed Mar 8, 2019
1 parent f0c2b3a commit 73b359c124ab5d6393cc9c5e51ff32bb5a2b64fb
Showing with 11 additions and 11 deletions.
  1. +7 −7 htdocs/core/class/stats.class.php
  2. +4 −4 htdocs/projet/class/projectstats.class.php
@@ -30,7 +30,7 @@
abstract class Stats
{
protected $db;
protected $_lastfetchdate=array(); // Dates of cache file read by methods
protected $lastfetchdate=array(); // Dates of cache file read by methods
public $cachefilesuffix=''; // Suffix to add to name of cache file (to avoid file name conflicts)
/**
@@ -70,7 +70,7 @@ public function getNbByMonthWithPrevYear($endyear, $startyear, $cachedelay = 0,
{
$foundintocache=1;
$this->_lastfetchdate[get_class($this).'_'.__FUNCTION__]=$filedate;
$this->lastfetchdate[get_class($this).'_'.__FUNCTION__]=$filedate;
}
else
{
@@ -117,7 +117,7 @@ public function getNbByMonthWithPrevYear($endyear, $startyear, $cachedelay = 0,
if (! empty($conf->global->MAIN_UMASK)) $newmask=$conf->global->MAIN_UMASK;
@chmod($newpathofdestfile, octdec($newmask));
$this->_lastfetchdate[get_class($this).'_'.__FUNCTION__]=$nowgmt;
$this->lastfetchdate[get_class($this).'_'.__FUNCTION__]=$nowgmt;
}
// return array(array('Month',val1,val2,val3),...)
@@ -164,7 +164,7 @@ public function getAmountByMonthWithPrevYear($endyear, $startyear, $cachedelay =
{
$foundintocache=1;
$this->_lastfetchdate[get_class($this).'_'.__FUNCTION__]=$filedate;
$this->lastfetchdate[get_class($this).'_'.__FUNCTION__]=$filedate;
}
else
{
@@ -215,7 +215,7 @@ public function getAmountByMonthWithPrevYear($endyear, $startyear, $cachedelay =
@chmod($newpathofdestfile, octdec($newmask));
}
else dol_syslog("Failed to write cache file", LOG_ERR);
$this->_lastfetchdate[get_class($this).'_'.__FUNCTION__]=$nowgmt;
$this->lastfetchdate[get_class($this).'_'.__FUNCTION__]=$nowgmt;
}
return $data;
@@ -290,7 +290,7 @@ public function getAllByProductEntry($year, $cachedelay = 0)
{
$foundintocache=1;
$this->_lastfetchdate[get_class($this).'_'.__FUNCTION__]=$filedate;
$this->lastfetchdate[get_class($this).'_'.__FUNCTION__]=$filedate;
}
else
{
@@ -323,7 +323,7 @@ public function getAllByProductEntry($year, $cachedelay = 0)
if (! empty($conf->global->MAIN_UMASK)) $newmask=$conf->global->MAIN_UMASK;
@chmod($newpathofdestfile, octdec($newmask));
}
$this->_lastfetchdate[get_class($this).'_'.__FUNCTION__]=$nowgmt;
$this->lastfetchdate[get_class($this).'_'.__FUNCTION__]=$nowgmt;
}
return $data;
@@ -281,7 +281,7 @@ public function getWeightedAmountByMonthWithPrevYear($endyear, $startyear, $cach
{
$foundintocache=1;
$this->_lastfetchdate[get_class($this).'_'.__FUNCTION__]=$filedate;
$this->lastfetchdate[get_class($this).'_'.__FUNCTION__]=$filedate;
}
else
{
@@ -332,7 +332,7 @@ public function getWeightedAmountByMonthWithPrevYear($endyear, $startyear, $cach
@chmod($newpathofdestfile, octdec($newmask));
}
else dol_syslog("Failed to write cache file", LOG_ERR);
$this->_lastfetchdate[get_class($this).'_'.__FUNCTION__]=$nowgmt;
$this->lastfetchdate[get_class($this).'_'.__FUNCTION__]=$nowgmt;
}
return $data;
@@ -401,7 +401,7 @@ public function getTransformRateByMonthWithPrevYear($endyear, $startyear, $cache
if ($filedate >= ($nowgmt - $cachedelay)) {
$foundintocache = 1;
$this->_lastfetchdate[get_class($this) . '_' . __FUNCTION__] = $filedate;
$this->lastfetchdate[get_class($this) . '_' . __FUNCTION__] = $filedate;
} else {
dol_syslog(get_class($this) . '::' . __FUNCTION__ . " cache file " . $newpathofdestfile . " is not found or older than now - cachedelay (" . $nowgmt . " - " . $cachedelay . ") so we can't use it.");
}
@@ -443,7 +443,7 @@ public function getTransformRateByMonthWithPrevYear($endyear, $startyear, $cache
$newmask = $conf->global->MAIN_UMASK;
@chmod($newpathofdestfile, octdec($newmask));
$this->_lastfetchdate[get_class($this) . '_' . __FUNCTION__] = $nowgmt;
$this->lastfetchdate[get_class($this) . '_' . __FUNCTION__] = $nowgmt;
}
return $data;

0 comments on commit 73b359c

Please sign in to comment.
You can’t perform that action at this time.