Skip to content

Commit 363141e

Browse files
committed
fix(form): reimplement submit button conditions
Signed-off-by: Thierry Bugier <tbugier@teclib.com>
1 parent cb9b4c7 commit 363141e

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

inc/question.class.php

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,6 +154,24 @@ public static function showForForm(CommonDBTM $item, $withtemplate = '') {
154154

155155
echo '</ol>';
156156
echo '</div>';
157+
158+
echo '<form name="form" method="post" action="'.PluginFormcreatorForm::getFormURL().'" data-itemtype="' . PluginFormcreatorForm::class . '">';
159+
echo '<table>';
160+
161+
echo '<tr>';
162+
echo '<th colspan="4">';
163+
echo __('Show submit button', 'formcreator');
164+
echo '</th>';
165+
echo '</tr>';
166+
$condition = new PluginFormcreatorCondition();
167+
$condition->showConditionsForItem($item);
168+
169+
echo '</table>';
170+
171+
$item->showFormButtons([
172+
'candel' => false
173+
]);
174+
Html::closeForm();
157175
}
158176

159177
/**

0 commit comments

Comments
 (0)