Merge remote-tracking branch 'origin/master'

This commit is contained in:
Weblate 2014-05-22 14:17:35 +02:00
commit 737df91c37
2 changed files with 6 additions and 4 deletions

View File

@ -496,7 +496,7 @@ function browseForeignDialog($this_a)
$input = $this_a.closest('.edit_area').prev('.edit_box');
}
// Set selected value as input value
$input.val($(this).text());
$input.val($(this).data('key'));
$dialog.dialog('close');
});
$(formId).on('click', showAllId, function () {

View File

@ -154,7 +154,7 @@ function PMA_getHtmlForRelationalFieldSelection($db, $table, $field, $foreignDat
. ' width="1" height="1" /></td>';
$output .= PMA_getHtmlForColumnElement(
'', $rightKeynameIsSelected, $leftKeyname,
'', $rightKeynameIsSelected, $rightKeyname,
$rightDescription, $rightDescriptionTitle, $field
);
@ -216,15 +216,17 @@ function PMA_getDescriptionAndTitle($description)
function PMA_getHtmlForColumnElement($cssClass, $isSelected, $keyname,
$description, $title, $field
) {
$keyname = htmlspecialchars($keyname);
$output = '<td ' . $cssClass . '>'
. ($isSelected ? '<strong>' : '')
. '<a class="foreign_value" href="#" title="' . __('Use this value')
. '<a class="foreign_value" data-key="' . $keyname . '" '
. 'href="#" title="' . __('Use this value')
. ($title != ''
? ': ' . $title
: '')
. '">';
if ($cssClass !== '') {
$output .= htmlspecialchars($keyname);
$output .= $keyname;
} else {
$output .= $description;
}