From decf7e682f965356c12ae98f960e8c4fc0f25993 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Wed, 21 Dec 2011 16:38:56 +0100 Subject: [PATCH] Fix: [ bug #256 ] Delivery order SQL error --- htdocs/admin/confexped.php | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/htdocs/admin/confexped.php b/htdocs/admin/confexped.php index a9088a2b976..24c505a27ef 100644 --- a/htdocs/admin/confexped.php +++ b/htdocs/admin/confexped.php @@ -36,6 +36,7 @@ if (!$user->admin) $action=GETPOST("action"); +// Shipment note if ($action == 'activate_sending') { dolibarr_set_const($db, "MAIN_SUBMODULE_EXPEDITION", "1",'chaine',0,'',$conf->entity); @@ -48,11 +49,13 @@ else if ($action == 'disable_sending') Header("Location: confexped.php"); exit; } +// Delivery note else if ($action == 'activate_delivery') { - dolibarr_set_const($db, "MAIN_SUBMODULE_LIVRAISON", "1",'chaine',0,'',$conf->entity); - Header("Location: confexped.php"); - exit; + dolibarr_set_const($db, "MAIN_SUBMODULE_EXPEDITION", "1",'chaine',0,'',$conf->entity); // We must also enable this + dolibarr_set_const($db, "MAIN_SUBMODULE_LIVRAISON", "1",'chaine',0,'',$conf->entity); + Header("Location: confexped.php"); + exit; } else if ($action == 'disable_delivery') {