From 09dfcc601638c06a47a9d0f4c50af20705642105 Mon Sep 17 00:00:00 2001 From: atm-quentin Date: Fri, 3 Aug 2018 14:54:21 +0200 Subject: [PATCH 1/2] FIX exclude element of the select --- htdocs/projet/element.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/htdocs/projet/element.php b/htdocs/projet/element.php index dd19ceeb263..5952be3264d 100644 --- a/htdocs/projet/element.php +++ b/htdocs/projet/element.php @@ -697,7 +697,9 @@ foreach ($listofreferent as $key => $value) $urlnew=$value['urlnew']; $buttonnew=$value['buttonnew']; $testnew=$value['testnew']; + $exclude_select_element=array('payment_various',$value['exclude_select_element']); + if ($qualified) { // If we want the project task array to have details of users @@ -717,7 +719,7 @@ foreach ($listofreferent as $key => $value) if (! empty($conf->global->PROJECT_OTHER_THIRDPARTY_ID_TO_ADD_ELEMENTS)) $idtofilterthirdparty.=','.$conf->global->PROJECT_OTHER_THIRDPARTY_ID_TO_ADD_ELEMENTS; } - if (empty($conf->global->PROJECT_LINK_ON_OVERWIEW_DISABLED) && $idtofilterthirdparty && !in_array($tablename, array('payment_various'))) + if (empty($conf->global->PROJECT_LINK_ON_OVERWIEW_DISABLED) && $idtofilterthirdparty && !in_array($tablename,$exclude_select_element)) { $selectList=$formproject->select_element($tablename, $idtofilterthirdparty, 'minwidth300'); if (! $selectList || ($selectList<0)) From ec9eeb5201c9c7bc3dfbb85e82a57c2f85f15920 Mon Sep 17 00:00:00 2001 From: atm-quentin Date: Mon, 27 Aug 2018 10:17:18 +0200 Subject: [PATCH 2/2] FIX check !empty exclude select element --- htdocs/projet/element.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/htdocs/projet/element.php b/htdocs/projet/element.php index 5952be3264d..03a5bfc0880 100644 --- a/htdocs/projet/element.php +++ b/htdocs/projet/element.php @@ -697,9 +697,10 @@ foreach ($listofreferent as $key => $value) $urlnew=$value['urlnew']; $buttonnew=$value['buttonnew']; $testnew=$value['testnew']; - $exclude_select_element=array('payment_various',$value['exclude_select_element']); + $exclude_select_element = array('payment_various'); + if (!empty($value['exclude_select_element'])) $exclude_select_element[] = $value['exclude_select_element']; + - if ($qualified) { // If we want the project task array to have details of users