fix : warning error if no graphfiles
append when we have no element present (start from new)
This commit is contained in:
parent
3fb80d9678
commit
f54bc367a4
@ -244,7 +244,7 @@ if (! empty($id) || ! empty($ref) || GETPOST('id') == 'all')
|
|||||||
|
|
||||||
$px = new DolGraph();
|
$px = new DolGraph();
|
||||||
|
|
||||||
if (! $error)
|
if (! $error && count($graphfiles)>0)
|
||||||
{
|
{
|
||||||
$mesg = $px->isGraphKo();
|
$mesg = $px->isGraphKo();
|
||||||
if (! $mesg)
|
if (! $mesg)
|
||||||
@ -301,6 +301,8 @@ if (! empty($id) || ! empty($ref) || GETPOST('id') == 'all')
|
|||||||
|
|
||||||
// Show graphs
|
// Show graphs
|
||||||
$i=0;
|
$i=0;
|
||||||
|
if ( count($graphfiles)>0)
|
||||||
|
{
|
||||||
foreach($graphfiles as $key => $val)
|
foreach($graphfiles as $key => $val)
|
||||||
{
|
{
|
||||||
if (! $graphfiles[$key]['file']) continue;
|
if (! $graphfiles[$key]['file']) continue;
|
||||||
@ -360,6 +362,7 @@ if (! empty($id) || ! empty($ref) || GETPOST('id') == 'all')
|
|||||||
|
|
||||||
$i++;
|
$i++;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
// div not closed
|
// div not closed
|
||||||
if ($i % 2 == 1)
|
if ($i % 2 == 1)
|
||||||
{
|
{
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user