From 47d9a08595ac66db1ae543d2d4b93d5bcb650c22 Mon Sep 17 00:00:00 2001 From: sparkyx Date: Sat, 31 Oct 2020 00:32:24 +0100 Subject: [PATCH] Balise Document_Type --- include/class/document.class.php | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/include/class/document.class.php b/include/class/document.class.php index 1f9ed7508..64641f8c1 100644 --- a/include/class/document.class.php +++ b/include/class/document.class.php @@ -554,7 +554,7 @@ class Document $p_tag=str_replace('=','',$p_tag); $r="Tag inconnu"; static $aComment=NULL; - static $counter_comment =0 ; /*db,$p_array["ag_id"]); $aRelatedAction=array(); $aParent=$followup->get_parent(); + if ($aParent == -1 )return ""; $nb_parent=count($aParent); $sql_related_action = " select ag_id, @@ -1434,6 +1435,16 @@ class Document return $status; } return ""; + // type of document + case 'DOCUMENT_TYPE': + $ret=""; + if ( isset($p_array['ag_id'])){ + $ret=$this->db->get_value("select dt_value + from action_gestion + join document_type dt on (ag_type=dt.dt_id) + where ag_id=$1",array($p_array["ag_id"])); + } + return $ret; } // end switch