Fix: Refresh action was not effecitve immediately

This commit is contained in:
Laurent Destailleur 2008-05-04 15:34:48 +00:00
parent 48f36cdd2d
commit 4c2e6df6cb
2 changed files with 6 additions and 5 deletions

View File

@ -545,9 +545,9 @@ class EcmDirectory // extends CommonObject
}
/**
* \brief refresh cachenboffile
* \brief Refresh value for cachenboffile
* \param directory Directory to scan
* \return int <0 if ko, >0 if OK
* \return int <0 if KO, Nb of files in directory if OK
*/
function refreshcachenboffile()
{
@ -569,7 +569,7 @@ class EcmDirectory // extends CommonObject
if ($resql)
{
$this->cachenbofdoc=sizeof($filelist);
return 1;
return $this->cachenbofdoc;
}
else
{

View File

@ -277,9 +277,10 @@ foreach($rub as $key => $val)
if ($_GET['action'] == 'refreshauto')
{
$result=$ecmdirstatic->fetch($val['id']);
$result=$ecmdirstatic->refreshcachenboffile();
$ecmdirstatic->ref=$ecmdirstatic->label;
$result=$ecmdirstatic->refreshcachenboffile();
$val['cachenbofdoc']=$result;
}