Fix: Try to fix expand pb

This commit is contained in:
Laurent Destailleur 2009-05-22 15:06:17 +00:00
parent 61bb79f8ce
commit 47d77ba51b
2 changed files with 8 additions and 8 deletions

View File

@ -164,7 +164,7 @@ foreach($fulltree as $key => $val)
// Update expandedsectionarray in session // Update expandedsectionarray in session
$expandedsectionarray=array(); $expandedsectionarray=array();
if (isset($_SESSION['dol_expandedsectionarray'])) $expandedsectionarray=split(',',$_SESSION['dol_expandedsectionarray']); if (isset($_SESSION['dol_catexpandedsectionarray'.$type])) $expandedsectionarray=split(',',$_SESSION['dol_catexpandedsectionarray'.$type]);
if ($section && $_GET['sectionexpand'] == 'true') if ($section && $_GET['sectionexpand'] == 'true')
{ {
@ -177,7 +177,7 @@ if ($section && $_GET['sectionexpand'] == 'true')
$expandedsectionarray[]=$idcursor; $expandedsectionarray[]=$idcursor;
} }
} }
$_SESSION['dol_expandedsectionarray']=join(',',$expandedsectionarray); $_SESSION['dol_catexpandedsectionarray'.$type]=join(',',$expandedsectionarray);
} }
if ($section && $_GET['sectionexpand'] == 'false') if ($section && $_GET['sectionexpand'] == 'false')
{ {
@ -189,9 +189,9 @@ if ($section && $_GET['sectionexpand'] == 'false')
// is_in_subtree(fulltree,sectionparent,sectionchild) // is_in_subtree(fulltree,sectionparent,sectionchild)
if ($sectioncursor && ! is_in_subtree($fulltree,$section,$sectioncursor)) $expandedsectionarray[]=$sectioncursor; if ($sectioncursor && ! is_in_subtree($fulltree,$section,$sectioncursor)) $expandedsectionarray[]=$sectioncursor;
} }
$_SESSION['dol_expandedsectionarray']=join(',',$expandedsectionarray); $_SESSION['dol_catexpandedsectionarray'.$type]=join(',',$expandedsectionarray);
} }
//print $_SESSION['dol_expandedsectionarray'].'<br>'; //print $_SESSION['dol_catexpandedsectionarray'.$type].'<br>';
$nbofentries=0; $nbofentries=0;
$oldvallevel=0; $oldvallevel=0;

View File

@ -411,7 +411,7 @@ if (empty($action) || $action == 'file_manager' || eregi('refresh',$action) || $
// Update expandedsectionarray in session // Update expandedsectionarray in session
$expandedsectionarray=array(); $expandedsectionarray=array();
if (isset($_SESSION['expandedsectionarray'])) $expandedsectionarray=split(',',$_SESSION['expandedsectionarray']); if (isset($_SESSION['dol_ecmexpandedsectionarray'])) $expandedsectionarray=split(',',$_SESSION['dol_ecmexpandedsectionarray']);
if ($section && $_GET['sectionexpand'] == 'true') if ($section && $_GET['sectionexpand'] == 'true')
{ {
@ -424,7 +424,7 @@ if (empty($action) || $action == 'file_manager' || eregi('refresh',$action) || $
$expandedsectionarray[]=$idcursor; $expandedsectionarray[]=$idcursor;
} }
} }
$_SESSION['expandedsectionarray']=join(',',$expandedsectionarray); $_SESSION['dol_ecmexpandedsectionarray']=join(',',$expandedsectionarray);
} }
if ($section && $_GET['sectionexpand'] == 'false') if ($section && $_GET['sectionexpand'] == 'false')
{ {
@ -436,9 +436,9 @@ if (empty($action) || $action == 'file_manager' || eregi('refresh',$action) || $
// is_in_subtree(fulltree,sectionparent,sectionchild) // is_in_subtree(fulltree,sectionparent,sectionchild)
if ($sectioncursor && ! is_in_subtree($fulltree,$section,$sectioncursor)) $expandedsectionarray[]=$sectioncursor; if ($sectioncursor && ! is_in_subtree($fulltree,$section,$sectioncursor)) $expandedsectionarray[]=$sectioncursor;
} }
$_SESSION['expandedsectionarray']=join(',',$expandedsectionarray); $_SESSION['dol_ecmexpandedsectionarray']=join(',',$expandedsectionarray);
} }
//print $_SESSION['expandedsectionarray'].'<br>'; //print $_SESSION['dol_ecmexpandedsectionarray'].'<br>';
$nbofentries=0; $nbofentries=0;
$oldvallevel=0; $oldvallevel=0;