noalyss  Version-6.7.2
 All Data Structures Namespaces Files Functions Variables Enumerations
cfgtags.inc.php
Go to the documentation of this file.
00001 <?php
00002 /*
00003  *   This file is part of NOALYSS.
00004  *
00005  *   NOALYSS is free software; you can redistribute it and/or modify
00006  *   it under the terms of the GNU General Public License as published by
00007  *   the Free Software Foundation; either version 2 of the License, or
00008  *   (at your option) any later version.
00009  *
00010  *   NOALYSS is distributed in the hope that it will be useful,
00011  *   but WITHOUT ANY WARRANTY; without even the implied warranty of
00012  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00013  *   GNU General Public License for more details.
00014  *
00015  *   You should have received a copy of the GNU General Public License
00016  *   along with NOALYSS; if not, write to the Free Software
00017  *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00018  */
00019 // Copyright Author Dany De Bontridder danydb@aevalys.eu
00020 if ( !defined ('ALLOWED') )  die('Appel direct ne sont pas permis');
00021 
00022 /**
00023  * @file
00024  * @brief Manage the tags
00025  *
00026  */
00027 require_once 'class_tag.php';
00028 require_once 'class_tool_uos.php';
00029 
00030 $tag=new Tag($cn);
00031 $uos=new Tool_Uos('tag');
00032 if ( isset ($_POST['save_tag_sb']))
00033 {
00034     if ( ! isset ($_POST['remove']))
00035     {
00036         try {
00037             $uos->check();
00038             $tag->save($_POST);
00039             $uos->save();
00040         } catch (Exception $e)
00041         {
00042             alert("déjà sauvé");
00043         }
00044     } else {
00045         $tag->remove($_POST);
00046     }
00047 }
00048 ?>
00049 <div style="margin-left:10%;width:80%">
00050      <p class="notice">
00051         <?php echo _("Vous pouvez utiliser ceci comme des étiquettes pour marquer des documents ou 
00052          comme des dossiers pour rassembler des documents. Un document peut appartenir
00053          à plusieurs dossiers ou avoir plusieurs étiquettes.");?>
00054      </p>
00055     <?php
00056         $tag->show_list();
00057          $js=sprintf("onclick=\"show_tag('%s','%s','%s','p')\"",Dossier::id(),$_REQUEST['ac'],'-1');
00058         echo HtmlInput::button("tag_add", "Ajout d'un tag", $js);
00059     ?>
 All Data Structures Namespaces Files Functions Variables Enumerations