File tree Expand file tree Collapse file tree 2 files changed +15
-2
lines changed Expand file tree Collapse file tree 2 files changed +15
-2
lines changed Original file line number Diff line number Diff line change 5656
5757 $ display_condition = new PluginFieldsContainerDisplayCondition ();
5858 if ($ display_condition ->computeDisplayContainer ($ item , $ containers_id )) {
59+ $ field_options = [
60+ 'label_class ' => 'col-lg-3 ' ,
61+ 'input_class ' => 'col-lg-9 ' ,
62+ ];
63+ echo "<div class='offset-md-1 col-md-8 col-xxl-6'> " ;
5964 PluginFieldsField::showDomContainer (
6065 $ containers_id ,
6166 $ item ,
6267 $ type ,
6368 $ subtype ,
69+ $ field_options ,
6470 );
71+ echo "</div> " ;
6572 } else {
6673 echo '' ;
6774 }
Original file line number Diff line number Diff line change @@ -887,6 +887,12 @@ public static function showForTab($params)
887887 {
888888 $ item = $ params ['item ' ];
889889
890+ if ($ item ->fields ['type ' ] == "" ) {
891+ $ item ->fields ['type ' ] = $ params ['options ' ]['type ' ];
892+ }
893+ if ($ item ->fields ['itilcategories_id ' ] == "" ) {
894+ $ item ->fields ['itilcategories_id ' ] = $ params ['options ' ]['itilcategories_id ' ];
895+ }
890896 $ functions = array_column (debug_backtrace (), 'function ' );
891897 $ subtype = isset ($ _SESSION ['glpi_tabs ' ][strtolower ($ item ::getType ())]) ? $ _SESSION ['glpi_tabs ' ][strtolower ($ item ::getType ())] : '' ;
892898 $ type = substr ($ subtype , -strlen ('$main ' )) === '$main '
@@ -956,7 +962,7 @@ public static function showForTab($params)
956962 }
957963
958964 $ html_id = 'plugin_fields_container_ ' . mt_rand ();
959- if (strpos ($ current_url , 'helpdesk.public.php ' ) !== false ) {
965+ if (strpos ($ current_url , 'helpdesk.public.php ' ) !== false || strpos ( $ current_url , ' tracking.injector.php ' ) !== false ) {
960966 echo "<div id=' {$ html_id }' class='card-body row mx-0' style='border-top:0'> " ;
961967 echo "<div class='offset-md-1 col-md-8 col-xxl-6'> " ;
962968 $ field_options = [
@@ -976,7 +982,7 @@ public static function showForTab($params)
976982 $ field_options ?? [],
977983 );
978984 }
979- if (strpos ($ current_url , 'helpdesk.public.php ' ) !== false ) {
985+ if (strpos ($ current_url , 'helpdesk.public.php ' ) !== false || strpos ( $ current_url , ' tracking.injector.php ' ) !== false ) {
980986 echo '</div> ' ;
981987 }
982988 echo '</div> ' ;
You can’t perform that action at this time.
0 commit comments