* @version $Id$ * @access public * @license http://opensource.org/licenses/gpl-3.0.html */ ?> isSuperAdmin()) ReloadIndex('admin'); //////////// ?>
AddLevel($data_table, $sql_object); $link_confirm="confirm.php?rub=".$rub."&todo=".$todo; if(is_numeric($result)) header("Location: ".$link_confirm); else system_error(); } if(isset($_POST['valider'])) { $a['name']=$_POST['name']; $a['code']=$_POST['code']; $a['label']=$_POST['label']; $a['parent']=$_POST['parent']; if($_POST['description']=='ALL') { $a['desc_det_project']=$_POST['desc_for_all']; $a['desc_det_dashboard']=$_POST['desc_for_all']; $a['desc_det_publication']=$_POST['desc_for_all']; $a['desc_det_news']=$_POST['desc_for_all']; $a['desc_det_workshop']=$_POST['desc_for_all']; } if($_POST['description']=='DET') { $a['desc_det_project']=$_POST['desc_det_project']; $a['desc_det_dashboard']=$_POST['desc_det_dashboard']; $a['desc_det_publication']=$_POST['desc_det_publication']; $a['desc_det_news']=$_POST['desc_det_news']; $a['desc_det_workshop']=$_POST['desc_det_workshop']; } // Rang des niveaux par catégorie $a['range']=0; $a['status']=$_POST['status']; $integrity=$level_object->CheckDataIntegrity($a); if(is_string($integrity)) $format_text='2FIELD'; else $format_text='2HTML'; $form_name=formatText($_POST['name'], $format_text); $form_code=formatText($_POST['code'], $format_text); $form_label=formatText($_POST['label'], $format_text); $form_parent=$_POST['parent']; if($_POST['description']=='ALL') { $form_description_all=formatText($_POST['desc_for_all'], $format_text); $layer_all_style= "style=\"display:block;\""; $layer_det_style= "style=\"display:none;\""; $mask_desc_ALL="checked=\"checked\""; $mask_desc_DET=''; } if($_POST['description']=='DET') { if(isset($_POST['desc_det_project'])) $form_desc_project=formatText($_POST['desc_det_project'], $format_text); if(isset($_POST['desc_det_dashboard'])) $form_desc_dashboard=formatText($_POST['desc_det_dashboard'], $format_text); if(isset($_POST['desc_det_publication'])) $form_desc_publication=formatText($_POST['desc_det_publication'], $format_text); if(isset($_POST['desc_det_news'])) $form_desc_news=formatText($_POST['desc_det_news'], $format_text); if(isset($_POST['desc_det_workshop'])) $form_desc_workshop=formatText($_POST['desc_det_workshop'], $format_text); $layer_all_style= "style=\"display:none;\""; $layer_det_style= "style=\"display:block;\""; $mask_desc_ALL=''; $mask_desc_DET="checked=\"checked\""; } if($_POST['status']=='D') $mask_statut_D="checked=\"checked\""; else $mask_statut_D=''; if($_POST['status']=='P') $mask_statut_P="checked=\"checked\""; else $mask_statut_P=''; $a=urlencode(serialize($a)); } // preparation affichage detaillé $description_detail_form=''; if(defined('MOD_PROJECT')) { $description_detail_form.= "\n"; $description_detail_form.= "\n"; $description_detail_form.= "\n"; $description_detail_form.= "
\n"; } if(defined('MOD_SDI')) { $description_detail_form.= "\n"; $description_detail_form.= "\n"; $description_detail_form.= "\n"; $description_detail_form.= "
\n"; } if(defined('MOD_PUBLICATION')) { $description_detail_form.= "\n"; $description_detail_form.= "\n"; $description_detail_form.= "\n"; $description_detail_form.= "
\n"; } if(defined('MOD_NEWS')) { $description_detail_form.= "\n"; $description_detail_form.= "\n"; $description_detail_form.= "\n"; $description_detail_form.= "
\n"; } if(defined('MOD_WORKSHOP')) { $description_detail_form.= "\n"; $description_detail_form.= "\n"; $description_detail_form.= "\n"; $description_detail_form.= "
\n"; } $js = "$('#description_ALL').click(function() { $('#det').fadeOut(); $('#all').fadeIn(); }); $('#description_DET').click(function() { $('#all').fadeOut(); $('#det').fadeIn(); });"; footerAddInlineJS($js); include_once("../lib/input_helpers.php"); // select-box des niveaux $data=$sql_object->DBSelect(SQL_getLevelsList()); $select_parent=LevelSelectBox($data, "parent", $form_parent); ?>