bug #3403165 [interface] Collation not displayed for long enum fields
This commit is contained in:
@@ -4,6 +4,7 @@ phpMyAdmin - ChangeLog
|
||||
3.4.6.0 (not yet released)
|
||||
- patch #3404173 InnoDB comment display with tooltips/aliases
|
||||
- bug #3404886 [navi] Edit SQL statement after error
|
||||
- bug #3403165 [interface] Collation not displayed for long enum fields
|
||||
|
||||
3.4.5.0 (not yet released)
|
||||
- bug #3375325 [interface] Page list in navigation frame looks odd
|
||||
|
@@ -245,6 +245,7 @@ while ($row = PMA_DBI_fetch_assoc($fields_rs)) {
|
||||
$type = $row['Type'];
|
||||
$extracted_fieldspec = PMA_extractFieldSpec($row['Type']);
|
||||
|
||||
$truncated = false;
|
||||
if ('set' == $extracted_fieldspec['type'] || 'enum' == $extracted_fieldspec['type']) {
|
||||
$type = $extracted_fieldspec['type'] . '(' .
|
||||
str_replace("','", "', '", $extracted_fieldspec['spec_in_brackets']) . ')';
|
||||
@@ -252,6 +253,7 @@ while ($row = PMA_DBI_fetch_assoc($fields_rs)) {
|
||||
// for the case ENUM('–','“')
|
||||
$type = htmlspecialchars($type);
|
||||
if(strlen($type) > $GLOBALS['cfg']['LimitChars']) {
|
||||
$truncated = true;
|
||||
$type = '<abbr title="' . $type . '">' . substr($type, 0, $GLOBALS['cfg']['LimitChars']) . '</abbr>';
|
||||
}
|
||||
|
||||
@@ -292,6 +294,7 @@ while ($row = PMA_DBI_fetch_assoc($fields_rs)) {
|
||||
|| substr($type, 0, 8) == 'longtext'
|
||||
|| substr($type, 0, 3) == 'set'
|
||||
|| substr($type, 0, 4) == 'enum'
|
||||
|| ($truncated && substr($type, 13, 4) == 'enum')
|
||||
) && !$binary) {
|
||||
if (strpos($type, ' character set ')) {
|
||||
$type = substr($type, 0, strpos($type, ' character set '));
|
||||
|
Reference in New Issue
Block a user