File tree Expand file tree Collapse file tree 2 files changed +7
-4
lines changed Expand file tree Collapse file tree 2 files changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -730,10 +730,11 @@ public function showForm($ID, $options = []) {
730730 ]);
731731 echo '</td> ' ;
732732
733- echo '<td> ' ;
733+ // Dynamically filled for questions with a itemtype parameter (glpi select field)
734+ echo '<td id="plugin_formcreator_subtype_label"> ' ;
734735 echo '</td> ' ;
735736
736- echo '<td> ' ;
737+ echo '<td id="plugin_formcreator_subtype_value" > ' ;
737738 echo '</td> ' ;
738739 echo '</tr> ' ;
739740
@@ -774,7 +775,7 @@ public function showForm($ID, $options = []) {
774775 echo '</tr> ' ;
775776
776777 // Empty row for question-specific settings
777- // To be replaced bydynamically
778+ // To be replaced dynamically
778779 echo '<tr class="plugin_formcreator_question_specific"> ' ;
779780 echo '<td></td><td></td><td></td><td></td> ' ;
780781 echo '</tr> ' ;
Original file line number Diff line number Diff line change @@ -1401,12 +1401,14 @@ function plugin_formcreator_changeQuestionType(rand) {
14011401
14021402 $('.plugin_formcreator_required').toggle(response.may_be_required);
14031403 $('.plugin_formcreator_mayBeEmpty').toggle(response.may_be_empty);
1404+ $('#plugin_formcreator_subtype_label').html(response.label);
1405+ $('#plugin_formcreator_subtype_value').html(response.field);
14041406 plugin_formcreator_updateQuestionSpecific(response.additions);
14051407 });
14061408}
14071409
14081410function plugin_formcreator_updateQuestionSpecific(html) {
1409- $('.plugin_formcreator_question_specific:gt(0)' ).remove();
1411+ $('.plugin_formcreator_question_specific').slice(1 ).remove();
14101412 if (html == '') {
14111413 $('.plugin_formcreator_question_specific').hide();
14121414 return;
You can’t perform that action at this time.
0 commit comments