diff --git a/ChangeLog b/ChangeLog index e7e93af89d..ad8c7a7acd 100644 --- a/ChangeLog +++ b/ChangeLog @@ -26,6 +26,7 @@ phpMyAdmin - ChangeLog + rfe #801 Builtin transformations and relations + rfe #767 USING BTREE support for HEAP/MEMORY tables + rfe #1596 Make "Options > Relational" configurable ++ rfe #719 more details in PDF relation view 4.3.9.0 (not yet released) - bug #4728 Incorrect headings in routine editor @@ -34,6 +35,7 @@ phpMyAdmin - ChangeLog - bug #4734 Default values for binary fields do not support binary values - bug #4736 Changing display options breaks query highlighting - bug Undefined index submit_type +- bug #4738 Header lose align when scrolling in Firefox 4.3.8.0 (2015-01-24) - bug Undefined constant PMA_DRIZZLE diff --git a/js/sql.js b/js/sql.js index 2b2c4815c9..8f5d2bbaa8 100644 --- a/js/sql.js +++ b/js/sql.js @@ -767,7 +767,12 @@ function rearrangeStickyColumns($sticky_columns, $table_results) { var $clonedHeader = $originalHeader.clone(); // clone width per cell $clonedHeader.find("tr:first").children().width(function(i,val) { - return Math.floor($originalColumns.eq(i).width()) + 1; + var width = $originalColumns.eq(i).width(); + var is_firefox = navigator.userAgent.indexOf('Firefox') > -1; + if (! is_firefox) { + width += 1; + } + return width; }); $sticky_columns.empty().append($clonedHeader); } diff --git a/libraries/plugins/schema/pdf/Pdf_Relation_Schema.class.php b/libraries/plugins/schema/pdf/Pdf_Relation_Schema.class.php index 126367f3b2..55afe3b7f7 100644 --- a/libraries/plugins/schema/pdf/Pdf_Relation_Schema.class.php +++ b/libraries/plugins/schema/pdf/Pdf_Relation_Schema.class.php @@ -1018,19 +1018,32 @@ class PMA_Pdf_Relation_Schema extends PMA_Export_Relation_Schema $pdf->Bookmark($field_name, 1, -1); $pdf->SetLink($pdf->PMA_links['doc'][$table][$field_name], -1); $foreigner = PMA_searchColumnInForeigners($res_rel, $field_name); + + $linksTo = ''; + if ($foreigner) { + $linksTo = '-> '; + if ($foreigner['foreign_db'] != $GLOBALS['db']) { + $linksTo .= $foreigner['foreign_db'] . '.'; + } + $linksTo .= $foreigner['foreign_table'] + . '.' . $foreigner['foreign_field']; + + if (isset($foreigner['on_update'])) { // not set for internal + $linksTo .= "\n" . 'ON UPDATE ' . $foreigner['on_update']; + $linksTo .= "\n" . 'ON DELETE ' . $foreigner['on_delete']; + } + } + $pdf_row = array( $field_name, $type, $attribute, - ($row['Null'] == '' || $row['Null'] == 'NO') - ? __('No') - : __('Yes'), + (($row['Null'] == '' || $row['Null'] == 'NO') + ? __('No') + : __('Yes')), (isset($row['Default']) ? $row['Default'] : ''), $row['Extra'], - ($foreigner - ? $foreigner['foreign_table'] . ' -> ' - . $foreigner['foreign_field'] - : ''), + $linksTo, (isset($comments[$field_name]) ? $comments[$field_name] : ''), diff --git a/libraries/relation.lib.php b/libraries/relation.lib.php index b7aa5fbc0e..e3e7bd4c17 100644 --- a/libraries/relation.lib.php +++ b/libraries/relation.lib.php @@ -1824,6 +1824,12 @@ function PMA_searchColumnInForeigners($foreigners, $column) : $GLOBALS['db']; $foreigner['foreign_table'] = $one_key['ref_table_name']; $foreigner['constraint'] = $one_key['constraint']; + $foreigner['on_update'] = isset($one_key['on_update']) + ? $one_key['on_update'] + : 'RESTRICT'; + $foreigner['on_delete'] = isset($one_key['on_delete']) + ? $one_key['on_delete'] + : 'RESTRICT'; return $foreigner; }