2005-07-07 03:33:51 +02:00
|
|
|
<?php
|
2013-12-10 16:25:27 +01:00
|
|
|
/* Copyright (C) 2005-2013 Laurent Destailleur <eldy@users.sourceforge.net>
|
2005-07-07 03:33:51 +02:00
|
|
|
*
|
|
|
|
|
* 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
|
2013-01-16 15:36:08 +01:00
|
|
|
* the Free Software Foundation; either version 3 of the License, or
|
2005-07-07 03:33:51 +02:00
|
|
|
* (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
|
2011-08-01 00:21:57 +02:00
|
|
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
2005-07-07 03:33:51 +02:00
|
|
|
*/
|
2009-07-26 13:19:11 +02:00
|
|
|
|
2005-07-07 03:33:51 +02:00
|
|
|
/**
|
2008-10-12 13:41:13 +02:00
|
|
|
* \file htdocs/admin/triggers.php
|
2012-01-31 20:32:26 +01:00
|
|
|
* \brief Page to view triggers
|
2008-10-12 13:41:13 +02:00
|
|
|
*/
|
2005-07-07 03:33:51 +02:00
|
|
|
|
2012-08-22 23:24:21 +02:00
|
|
|
require '../main.inc.php';
|
2012-08-22 23:11:24 +02:00
|
|
|
require_once DOL_DOCUMENT_ROOT.'/core/class/interfaces.class.php';
|
2005-07-07 03:33:51 +02:00
|
|
|
|
2010-09-29 12:10:33 +02:00
|
|
|
$langs->load("admin");
|
|
|
|
|
|
2012-01-31 20:32:26 +01:00
|
|
|
if (!$user->admin) accessforbidden();
|
2005-07-07 03:33:51 +02:00
|
|
|
|
2010-04-02 11:59:18 +02:00
|
|
|
/*
|
|
|
|
|
* Action
|
2009-11-09 21:20:23 +01:00
|
|
|
*/
|
2005-07-07 03:33:51 +02:00
|
|
|
|
2012-01-31 20:32:26 +01:00
|
|
|
// None
|
2005-07-07 03:33:51 +02:00
|
|
|
|
|
|
|
|
|
2009-07-26 13:19:11 +02:00
|
|
|
/*
|
|
|
|
|
* View
|
|
|
|
|
*/
|
2005-07-07 03:33:51 +02:00
|
|
|
|
|
|
|
|
llxHeader("","");
|
|
|
|
|
|
2011-11-08 10:18:45 +01:00
|
|
|
$form = new Form($db);
|
2005-07-07 03:33:51 +02:00
|
|
|
|
2006-08-12 17:32:57 +02:00
|
|
|
print_fiche_titre($langs->trans("TriggersAvailable"),'','setup');
|
2005-07-07 03:33:51 +02:00
|
|
|
|
|
|
|
|
print $langs->trans("TriggersDesc")."<br>";
|
|
|
|
|
print "<br>\n";
|
|
|
|
|
|
2010-04-22 20:37:42 +02:00
|
|
|
$template_dir = DOL_DOCUMENT_ROOT.'/core/tpl/';
|
2005-07-07 03:33:51 +02:00
|
|
|
|
2010-04-22 20:37:42 +02:00
|
|
|
$interfaces = new Interfaces($db);
|
2012-01-31 20:32:26 +01:00
|
|
|
$triggers = $interfaces->getTriggersList(0,'priority');
|
2005-07-07 03:33:51 +02:00
|
|
|
|
2013-06-05 16:24:32 +02:00
|
|
|
print '<table class="noborder">
|
|
|
|
|
<tr class="liste_titre">
|
|
|
|
|
<td colspan="2">'.$langs->trans("File").'</td>
|
|
|
|
|
<td align="center">'.$langs->trans("Active").'</td>
|
|
|
|
|
<td align="center"> </td>
|
|
|
|
|
</tr>
|
2013-04-22 19:59:41 +02:00
|
|
|
';
|
2013-06-05 16:24:32 +02:00
|
|
|
|
|
|
|
|
$var=True;
|
|
|
|
|
foreach ($triggers as $trigger)
|
|
|
|
|
{
|
|
|
|
|
$var=!$var;
|
|
|
|
|
print '<tr '.$bc[$var].'>';
|
|
|
|
|
print '<td valign="top" width="14" align="center">'.$trigger['picto'].'</td>';
|
|
|
|
|
print '<td valign="top">'.$trigger['file'].'</td>';
|
|
|
|
|
print '<td valign="top" align="center">'.$trigger['status'].'</td>';
|
|
|
|
|
print '<td valign="top">'.$form->textwithpicto('', $trigger['info']).'</td>';
|
|
|
|
|
print '</tr>';
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
print '</table>';
|
2005-07-07 03:33:51 +02:00
|
|
|
|
2011-08-27 16:24:16 +02:00
|
|
|
llxFooter();
|
2012-01-31 20:32:26 +01:00
|
|
|
|
|
|
|
|
$db->close();
|
2005-07-07 03:33:51 +02:00
|
|
|
?>
|