diff --git a/htdocs/admin/workflow.php b/htdocs/admin/workflow.php
index 36389fabeea..54a177e6330 100755
--- a/htdocs/admin/workflow.php
+++ b/htdocs/admin/workflow.php
@@ -26,6 +26,7 @@
require("../main.inc.php");
require_once(DOL_DOCUMENT_ROOT."/core/lib/admin.lib.php");
+require_once(DOL_DOCUMENT_ROOT."/core/lib/ajax.lib.php");
$langs->load("admin");
$langs->load("workflow");
@@ -39,13 +40,7 @@ $action = GETPOST('action', 'alpha');
*/
if (preg_match('/set(.*)/',$action,$reg))
{
- $code=$reg[1];
- if (dolibarr_set_const($db, $code, 1, 'chaine', 0, '', $conf->entity) > 0)
- {
- Header("Location: ".$_SERVER["PHP_SELF"]);
- exit;
- }
- else
+ if (! dolibarr_set_const($db, $reg[1], 1, 'chaine', 0, '', $conf->entity) > 0)
{
dol_print_error($db);
}
@@ -53,13 +48,7 @@ if (preg_match('/set(.*)/',$action,$reg))
if (preg_match('/del(.*)/',$action,$reg))
{
- $code=$reg[1];
- if (dolibarr_del_const($db, $code, $conf->entity) > 0)
- {
- Header("Location: ".$_SERVER["PHP_SELF"]);
- exit;
- }
- else
+ if (! dolibarr_del_const($db, $reg[1], $conf->entity) > 0)
{
dol_print_error($db);
}
@@ -70,9 +59,6 @@ if (preg_match('/del(.*)/',$action,$reg))
* View
*/
-$form=new Form($db);
-
-
llxHeader('',$langs->trans("WorkflowSetup"),'');
$linkback=''.$langs->trans("BackToModuleList").'';
@@ -81,13 +67,12 @@ print_fiche_titre($langs->trans("WorkflowSetup"),$linkback,'setup');
print $langs->trans("WorkflowDesc").'
';
print "
";
-// Choix du module de gestion des codes clients / fournisseurs
+// List of workflow we can enable
print '
| '.$langs->trans("Description").' | '; print ''.$langs->trans("Status").' | '; -//print ''.$langs->trans("Infos").' | '; print "'; - //$s=$modCodeTiers->getToolTip($langs,$soc,-1); - //print $form->textwithpicto('',$s,1); - //print ' | '; - print ''; } } @@ -141,8 +120,8 @@ else } print '