From 1f9f335e44371fc33399d8dfb1af98cfd8c86574 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 12 Feb 2019 19:09:27 +0100 Subject: [PATCH 1/2] FIX creation of menu entry with parent id not int Conflicts: htdocs/admin/menus/edit.php --- htdocs/admin/menus/edit.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/admin/menus/edit.php b/htdocs/admin/menus/edit.php index b16e9047b26..33a73147251 100644 --- a/htdocs/admin/menus/edit.php +++ b/htdocs/admin/menus/edit.php @@ -144,9 +144,9 @@ if ($action == 'add') } $leftmenu=''; $mainmenu=''; - if (GETPOST('menuId','int') && ! is_numeric(GETPOST('menuId','int'))) + if (GETPOST('menuId', 'alpha') && ! is_numeric(GETPOST('menuId', 'alpha'))) { - $tmp=explode('&',GETPOST('menuId','int')); + $tmp=explode('&', GETPOST('menuId', 'alpha')); foreach($tmp as $s) { if (preg_match('/fk_mainmenu=/',$s)) From 6a8504e1f812dee73075fac8407679a0242775b8 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 12 Feb 2019 19:44:12 +0100 Subject: [PATCH 2/2] Fix missing constant --- htdocs/don/class/don.class.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/htdocs/don/class/don.class.php b/htdocs/don/class/don.class.php index c3941059e64..e7296e2e157 100644 --- a/htdocs/don/class/don.class.php +++ b/htdocs/don/class/don.class.php @@ -91,6 +91,11 @@ class Don extends CommonObject public $labelstatut; public $labelstatutshort; + /** + * Draft + */ + const STATUS_DRAFT = 0; + /** * Constructor