. */ /** * @brief Choose a collection * * @file * @author Claire Figueras * @date $date$ * @version $Revision$ * @ingroup admin */ require_once("core".DIRECTORY_SEPARATOR."class".DIRECTORY_SEPARATOR."class_security.php"); $_SESSION['m_admin']['group']['show_check'] = false; $sec = new security(); $tabdiff = array(); $tab1 = array(); for($cpt_0=0; $cpt_0 < count($_SESSION['collections']); $cpt_0++) { array_push($tab1, $_SESSION['collections'][$cpt_0]['id']); } $tab2 = array(); for($cpt_1=0; $cpt_1 < count($_SESSION['m_admin']['groups']['security']); $cpt_1++) { array_push($tab2, $_SESSION['m_admin']['groups']['security'][$cpt_1]['COLL_ID']); } for($cpt_2=0; $cpt_2 < count($tab1); $cpt_2++) { if(!in_array($tab1[$cpt_2], $tab2)) { array_push($tabdiff, $tab1[$cpt_2]); } } $tmp = array(); for($cpt_3=0; $cpt_3 < count($tabdiff); $cpt_3++) { $j = $sec->get_ind_collection($tabdiff[$cpt_3]); if(!isset($_SESSION['collections'][$j]['table'])|| empty($_SESSION['collections'][$j]['table'])) { $show_checkbox = false; } array_push($tmp, array('id' => $tabdiff[$cpt_3], 'label' => $_SESSION['collections'][$j]['label'])); } $tabdiff = $tmp; if(isset($tab_diff) && count($tab_diff) == 1) { $_SESSION['m_admin']['group']['coll_id'] = $tabdiff[0]; $_SESSION['m_admin']['group']['show_check'] = true; } if(isset($_REQUEST['collselect']) && !empty($_REQUEST['collselect'])) { $_SESSION['m_admin']['group']['coll_id'] = $_REQUEST['collselect']; $ind = $sec->get_ind_collection($_SESSION['m_admin']['group']['coll_id']); if(isset($_SESSION['collections'][$ind]['table']) && !empty($_SESSION['collections'][$ind]['table'])) { $_SESSION['m_admin']['group']['show_check'] = true; } ?> load_lang(); $core_tools->test_admin('admin_groups', 'apps'); $core_tools->load_html(); //here we building the header $core_tools->load_header('', true, false); ?>

load_js();?>