The branch, QA_3_4 has been updated via c17add38ed40312f934451e1d1cf1f0b0ef8240e (commit) from 11ad4fd992e51b86c127c95112ee313bdaaa9757 (commit)
- Log ----------------------------------------------------------------- commit c17add38ed40312f934451e1d1cf1f0b0ef8240e Author: Rouslan Placella rouslan@placella.com Date: Fri Jul 22 14:52:07 2011 +0100
Fixed bug #3374802 - Comment on a column breaks inline editing
-----------------------------------------------------------------------
Summary of changes: ChangeLog | 1 + js/sql.js | 16 ++++++++-------- 2 files changed, 9 insertions(+), 8 deletions(-)
diff --git a/ChangeLog b/ChangeLog index 9a2360a..dbcc2ad 100644 --- a/ChangeLog +++ b/ChangeLog @@ -4,6 +4,7 @@ phpMyAdmin - ChangeLog 3.4.5.0 (not yet released) - bug #3375325 [interface] Page list in navigation frame looks odd - bug #3313235 [interface] Error div misplaced +- bug #3374802 [interface] Comment on a column breaks inline editing
3.4.4.0 (not yet released) - bug #3323060 [parser] SQL parser breaks AJAX requests if query has unclosed quotes diff --git a/js/sql.js b/js/sql.js index b185b69..dbba441 100644 --- a/js/sql.js +++ b/js/sql.js @@ -33,10 +33,10 @@ function PMA_urlencode(str) { function getFieldName($this_field, disp_mode) {
if(disp_mode == 'vertical') { - var field_name = $this_field.siblings('th').find('a').text(); + var $field = $this_field.siblings('th').find('a').clone(); // happens when just one row (headings contain no a) - if ("" == field_name) { - field_name = $this_field.siblings('th').text(); + if ($field.length == 0) { + $field = $this_field.siblings('th').clone(); } } else { @@ -44,14 +44,14 @@ function getFieldName($this_field, disp_mode) { // ltr or rtl direction does not impact how the DOM was generated // // 5 columns to account for the checkbox, edit, appended inline edit, copy and delete anchors but index is zero-based so substract 4 - var field_name = $('#table_results').find('thead').find('th:nth('+ (this_field_index-4 )+') a').text(); + var $field = $('#table_results').find('thead').find('th:nth('+ (this_field_index-4 )+') a').clone(); // happens when just one row (headings contain no a) - if ("" == field_name) { - field_name = $('#table_results').find('thead').find('th:nth('+ (this_field_index-4 )+')').text(); + if ($field.length == 0) { + $field = $('#table_results').find('thead').find('th:nth('+ (this_field_index-4 )+')').clone(); } } - - field_name = $.trim(field_name); + $field.children().remove(); + var field_name = $.trim($field.text());
return field_name; }
hooks/post-receive