Skip to content

Commit

Permalink
fix(form_language): display problems when translating
Browse files Browse the repository at this point in the history
  • Loading branch information
btry committed Jan 30, 2023
1 parent fd3d309 commit 93073e6
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 2 additions & 2 deletions inc/translation.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -174,12 +174,12 @@ public static function getEditorFieldsHtml(PluginFormcreatorForm_Language $formL
switch ($type) {
case 'itemlink':
case 'string':
$out .= '<td>' . $original . Html::hidden("id", ['value' => $id]) . '</td>';
$out .= '<td width="50%">' . $original . Html::hidden("id", ['value' => $id]) . '</td>';
$out .= '<td>' . Html::input("value", ['value' => $translatedString]) . '</td>';
break;

case 'text':
$out .= '<td>' . Html::entity_decode_deep($original) . Html::hidden("id", ['value' => $id]) . '</td>';
$out .= '<td width="50%">' . Html::entity_decode_deep($original) . Html::hidden("id", ['value' => $id]) . '</td>';
$out .= '<td>' . Html::textarea([
'name' => "value",
'value' => $translatedString,
Expand Down
1 change: 1 addition & 0 deletions js/scripts.js
Original file line number Diff line number Diff line change
Expand Up @@ -1154,6 +1154,7 @@ var plugin_formcreator = new function() {
var translationId = $(element.closest('[data-itemtype="PluginFormcreatorTranslation"]')).attr('data-id');
var modal;
modal = glpi_ajax_dialog({
dialogclass: 'modal-xl',
url: '../ajax/form_language.php',
params: {
action: 'translation',
Expand Down

0 comments on commit 93073e6

Please sign in to comment.