From 94073a2ca7301cf51db05df779c36a3064c2d6cc Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 5 Aug 2006 18:21:19 +0000 Subject: [PATCH] =?UTF-8?q?R=E9ecriture=20gestion=20des=20notifications=20?= =?UTF-8?q?pour=20=EAtre=20g=E9r=E9es=20par=20un=20module=20ind=E9pendant?= =?UTF-8?q?=20et=20via=20le=20m=E9canisme=20des=20triggers.=20Ceci=20afin?= =?UTF-8?q?=20de=20simplifier=20le=20code=20et=20de=20permettre=20le=20not?= =?UTF-8?q?ifications=20sur=20n'importe=20quel=20=E9vennement=20Dolibarr.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- htdocs/admin/notification.php | 90 +++++++++++++++++++++++++++++++++++ 1 file changed, 90 insertions(+) create mode 100644 htdocs/admin/notification.php diff --git a/htdocs/admin/notification.php b/htdocs/admin/notification.php new file mode 100644 index 00000000000..9ae8b473ee6 --- /dev/null +++ b/htdocs/admin/notification.php @@ -0,0 +1,90 @@ + + * Copyright (C) 2005-2006 Laurent Destailleur + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + * + * $Id$ + * $Source$ + */ + +/** + \file htdocs/admin/notification.php + \ingroup notification + \brief Page d'administration/configuration du module notification + \version $Revision$ +*/ + +require("./pre.inc.php"); + +$langs->load("admin"); + +if (!$user->admin) + accessforbidden(); + + +if ($_POST["action"] == 'setvalue' && $user->admin) +{ + $result=dolibarr_set_const($db, "NOTIFICATION_EMAIL_FROM",$_POST["email_from"]); + if ($result >= 0) + { + $mesg='
'.$langs->trans("Success").'
'; + } + else + { + dolibarr_print_error($db); + } +} + + + +/* + * + * + */ + +llxHeader(); + +print_titre($langs->trans("NotificationSetup")); + +if ($mesg) print '
'.$mesg; + +print '
'; +print '
'; +print ''; + +$var=true; + +print ''; +print ''; +print ''; +print ''; +print "\n"; +$var=!$var; +print ''; + +print ''; +print '
'.$langs->trans("Parameter").''.$langs->trans("Value").'
'; +print $langs->trans("NotificationEMailFrom").''; +print ''; +print '
'; + + +$db->close(); + + +llxFooter('$Date$ - $Revision$'); + +?>