From ee398a1de0d6fca9479dc510271ebfcf3d5dad5f Mon Sep 17 00:00:00 2001 From: Madhura Jayaratne Date: Fri, 3 Jan 2014 21:25:52 +0530 Subject: [PATCH 1/8] Doc comment improvements Signed-off-by: Madhura Jayaratne --- libraries/pmd_common.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/libraries/pmd_common.php b/libraries/pmd_common.php index 8538fbb48c..8b2dfdb2a1 100644 --- a/libraries/pmd_common.php +++ b/libraries/pmd_common.php @@ -4,7 +4,7 @@ * @package PhpMyAdmin-Designer */ /** - * block attempts to directly run this script + * Block attempts to directly run this script */ if (getcwd() == dirname(__FILE__)) { die('Attack stopped'); @@ -22,7 +22,7 @@ $GLOBALS['PMD']['STYLE'] = 'default'; $cfgRelation = PMA_getRelationsParam(); /** - * retrieves table info and stores it in $GLOBALS['PMD'] + * Retrieves table info and stores it in $GLOBALS['PMD'] * * @return array with table info */ @@ -74,7 +74,7 @@ function PMA_getTablesInfo() } /** - * retrieves table column info + * Retrieves table column info * * @return array table column nfo */ @@ -107,7 +107,7 @@ function PMA_getColumnsInfo() } /** - * returns JavaScript code for initializing vars + * Returns JavaScript code for initializing vars * * @return string JavaScript code */ @@ -186,7 +186,7 @@ function PMA_getPKOrUniqueKeys() } /** - * returns all indices + * Returns all indices * * @param bool $unique_only whether to include only unique ones * From 4279871e8e2670876a9d983f777dff74b9a3b33a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20=C4=8Ciha=C5=99?= Date: Fri, 3 Jan 2014 14:17:56 +0100 Subject: [PATCH 2/8] Translated using Weblate (Afrikaans) Currently translated at 12.0% (331 of 2749) --- po/af.po | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/po/af.po b/po/af.po index 38effc20bb..0267b967fa 100644 --- a/po/af.po +++ b/po/af.po @@ -4,10 +4,9 @@ msgstr "" "Project-Id-Version: phpMyAdmin 4.1.3-dev\n" "Report-Msgid-Bugs-To: phpmyadmin-devel@lists.sourceforge.net\n" "POT-Creation-Date: 2013-12-27 10:57-0500\n" -"PO-Revision-Date: 2013-11-19 08:15+0200\n" -"Last-Translator: Gottlieb Gauche \n" -"Language-Team: Afrikaans \n" +"PO-Revision-Date: 2014-01-03 14:17+0200\n" +"Last-Translator: Michal Čihař \n" +"Language-Team: Afrikaans \n" "Language: af\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -4036,7 +4035,7 @@ msgstr "So" #: libraries/Util.class.php:1638 #: libraries/plugins/transformations/abstract/DateFormatTransformationsPlugin.class.php:69 msgid "%B %d, %Y at %I:%M %p" -msgstr "%B %d, %Y at %I:%M %p" +msgstr "" #: libraries/Util.class.php:1985 #, php-format From dac00972262c5c5580a7333631e6a87d5a2dee65 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20=C4=8Ciha=C5=99?= Date: Fri, 3 Jan 2014 14:17:52 +0100 Subject: [PATCH 3/8] Translated using Weblate (Bengali) Currently translated at 90.6% (2492 of 2749) --- po/bn.po | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/po/bn.po b/po/bn.po index d076b95daa..2b459bf647 100644 --- a/po/bn.po +++ b/po/bn.po @@ -4,7 +4,7 @@ msgstr "" "Project-Id-Version: phpMyAdmin 4.1.3-dev\n" "Report-Msgid-Bugs-To: phpmyadmin-devel@lists.sourceforge.net\n" "POT-Creation-Date: 2013-12-27 10:57-0500\n" -"PO-Revision-Date: 2013-11-25 15:40+0200\n" +"PO-Revision-Date: 2014-01-03 14:17+0200\n" "Last-Translator: Michal Čihař \n" "Language-Team: Bengali \n" "Language: bn\n" @@ -3906,7 +3906,7 @@ msgstr "রবিবার" #: libraries/Util.class.php:1638 #: libraries/plugins/transformations/abstract/DateFormatTransformationsPlugin.class.php:69 msgid "%B %d, %Y at %I:%M %p" -msgstr "%B %d, %Y at %I:%M %p" +msgstr "" #: libraries/Util.class.php:1985 #, php-format From 9f94fe1701c5aad0712ab5b2748114afc5f57c7d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20=C4=8Ciha=C5=99?= Date: Fri, 3 Jan 2014 14:18:31 +0100 Subject: [PATCH 4/8] Translated using Weblate (Kurdish Sorani) Currently translated at 19.2% (530 of 2749) --- po/ckb.po | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/po/ckb.po b/po/ckb.po index b95c8953e7..9838e5908f 100644 --- a/po/ckb.po +++ b/po/ckb.po @@ -8,10 +8,10 @@ msgstr "" "Project-Id-Version: phpMyAdmin 4.1.3-dev\n" "Report-Msgid-Bugs-To: phpmyadmin-devel@lists.sourceforge.net\n" "POT-Creation-Date: 2013-12-27 10:57-0500\n" -"PO-Revision-Date: 2013-11-25 15:04+0200\n" +"PO-Revision-Date: 2014-01-03 14:18+0200\n" "Last-Translator: Michal Čihař \n" -"Language-Team: Kurdish Sorani \n" +"Language-Team: Kurdish Sorani " +"\n" "Language: ckb\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -3907,7 +3907,7 @@ msgstr "" #: libraries/browse_foreigners.lib.php:43 msgid "Search:" -msgstr "گەڕان" +msgstr "گەڕان:" #: libraries/browse_foreigners.lib.php:63 #: libraries/browse_foreigners.lib.php:65 From d2714f4fa5652f84f9dd8f1f41665c46567b036f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20=C4=8Ciha=C5=99?= Date: Fri, 3 Jan 2014 14:18:00 +0100 Subject: [PATCH 5/8] Translated using Weblate (Malay) Currently translated at 13.7% (378 of 2749) --- po/ms.po | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/po/ms.po b/po/ms.po index f56903f5c8..7c24aac1a0 100644 --- a/po/ms.po +++ b/po/ms.po @@ -4,15 +4,15 @@ msgstr "" "Project-Id-Version: phpMyAdmin 4.1.3-dev\n" "Report-Msgid-Bugs-To: phpmyadmin-devel@lists.sourceforge.net\n" "POT-Creation-Date: 2013-12-27 10:57-0500\n" -"PO-Revision-Date: 2013-08-30 15:47+0200\n" +"PO-Revision-Date: 2014-01-03 14:17+0200\n" "Last-Translator: Michal Čihař \n" -"Language-Team: Malay \n" +"Language-Team: Malay \n" "Language: ms\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=1; plural=0;\n" -"X-Generator: Weblate 1.7-dev\n" +"X-Generator: Weblate 1.9-dev\n" #: changelog.php:36 license.php:28 #, php-format @@ -4048,7 +4048,7 @@ msgstr "Aha" #: libraries/Util.class.php:1638 #: libraries/plugins/transformations/abstract/DateFormatTransformationsPlugin.class.php:69 msgid "%B %d, %Y at %I:%M %p" -msgstr "%B %d, %Y at %I:%M %p" +msgstr "" #: libraries/Util.class.php:1985 #, php-format From 3a66ea77355cece7d6d3a2b4f775bcc99126642a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20=C4=8Ciha=C5=99?= Date: Fri, 3 Jan 2014 14:17:49 +0100 Subject: [PATCH 6/8] Translated using Weblate (Telugu) Currently translated at 12.1% (335 of 2749) --- po/te.po | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/po/te.po b/po/te.po index 0cce667e64..4fcabebe26 100644 --- a/po/te.po +++ b/po/te.po @@ -7,16 +7,15 @@ msgstr "" "Project-Id-Version: phpMyAdmin 4.1.3-dev\n" "Report-Msgid-Bugs-To: phpmyadmin-devel@lists.sourceforge.net\n" "POT-Creation-Date: 2013-12-27 10:57-0500\n" -"PO-Revision-Date: 2013-08-30 15:46+0200\n" +"PO-Revision-Date: 2014-01-03 14:17+0200\n" "Last-Translator: Michal Čihař \n" -"Language-Team: Telugu \n" +"Language-Team: Telugu \n" "Language: te\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=n != 1;\n" -"X-Generator: Weblate 1.7-dev\n" +"X-Generator: Weblate 1.9-dev\n" #: changelog.php:36 license.php:28 #, php-format @@ -4003,7 +4002,7 @@ msgstr "ఆది" #: libraries/Util.class.php:1638 #: libraries/plugins/transformations/abstract/DateFormatTransformationsPlugin.class.php:69 msgid "%B %d, %Y at %I:%M %p" -msgstr "%B %d, %Y at %I:%M %p" +msgstr "" #: libraries/Util.class.php:1985 #, php-format From 062437dfbe2f0f93098d3730bd9905062cdfaabf Mon Sep 17 00:00:00 2001 From: Berikbol Zharylkassyn Date: Fri, 3 Jan 2014 21:11:28 +0100 Subject: [PATCH 7/8] Translated using Weblate (Kazakh) Currently translated at 12.5% (345 of 2749) --- po/kk.po | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/po/kk.po b/po/kk.po index dcd8c398a7..1e20b1b335 100644 --- a/po/kk.po +++ b/po/kk.po @@ -8,16 +8,15 @@ msgstr "" "Project-Id-Version: phpMyAdmin 4.1.3-dev\n" "Report-Msgid-Bugs-To: phpmyadmin-devel@lists.sourceforge.net\n" "POT-Creation-Date: 2013-12-27 10:57-0500\n" -"PO-Revision-Date: 2013-07-15 11:25+0200\n" -"Last-Translator: Michal Čihař \n" -"Language-Team: Kazakh \n" +"PO-Revision-Date: 2014-01-03 21:11+0200\n" +"Last-Translator: Berikbol Zharylkassyn \n" +"Language-Team: Kazakh \n" "Language: kk\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=n != 1;\n" -"X-Generator: Weblate 1.6-dev\n" +"X-Generator: Weblate 1.9-dev\n" #: changelog.php:36 license.php:28 #, php-format @@ -25,8 +24,8 @@ msgid "" "The %s file is not available on this system, please visit www.phpmyadmin.net " "for more information." msgstr "" -"%s файлы табылмады. Барлық қосымша ақпараттар, www.phpmyadmin.net сайтында " -"орналасқан." +"%s файлы табылмады. Барлық қосымша ақпараттарды, www.phpmyadmin.net сайтынан " +"таба аласыздар." #: db_create.php:61 #, php-format From ab693b3c5dc521843f279ad3d9dc9dade7691364 Mon Sep 17 00:00:00 2001 From: Madhura Jayaratne Date: Sat, 4 Jan 2014 07:59:42 +0530 Subject: [PATCH 8/8] bug #4212 Table "disappears" if it has the same name as its tablegroup --- ChangeLog | 1 + libraries/db_info.inc.php | 40 ++++++++++++++----- libraries/navigation/NavigationTree.class.php | 3 +- 3 files changed, 31 insertions(+), 13 deletions(-) diff --git a/ChangeLog b/ChangeLog index 80a8031b64..6132e4ae57 100644 --- a/ChangeLog +++ b/ChangeLog @@ -4,6 +4,7 @@ phpMyAdmin - ChangeLog 4.1.3.0 (not yet released) - bug #3938 PDFDefaultPageSize doc and easy configurability - bug #4198 Hovering over pie chart gives fatal JS error +- bug #4212 Table "disappears" if it has the same name as its tablegroup 4.1.2.0 (2013-12-23) - bug #4178 Quick edit for BIT type does not work diff --git a/libraries/db_info.inc.php b/libraries/db_info.inc.php index c3d66b7b07..83e5aa654e 100644 --- a/libraries/db_info.inc.php +++ b/libraries/db_info.inc.php @@ -76,11 +76,17 @@ if (true === $cfg['SkipLockedTables'] && ! PMA_DRIZZLE) { $tblGroupSql = ""; $whereAdded = false; if (PMA_isValid($_REQUEST['tbl_group'])) { - $tblGroupSql .= " WHERE " + $group = PMA_Util::escapeMysqlWildcards($_REQUEST['tbl_group']); + $groupWithSeperator = PMA_Util::escapeMysqlWildcards( + $_REQUEST['tbl_group'] + . $GLOBALS['cfg']['NavigationTreeTableSeparator'] + ); + $tblGroupSql .= " WHERE (" . PMA_Util::backquote('Tables_in_' . $db) - . " LIKE '" - . PMA_Util::escapeMysqlWildcards($_REQUEST['tbl_group']) - . "%'"; + . " LIKE '^" . $groupWithSeperator . "%'" + . " OR " + . PMA_Util::backquote('Tables_in_' . $db) + . " LIKE '^" . $group . "$')"; $whereAdded = true; } if (PMA_isValid($_REQUEST['tbl_type'], array('table', 'view'))) { @@ -167,19 +173,28 @@ if (! isset($sot_ready)) { } $tbl_group = false; + $groupWithSeperator = false; $tbl_type = null; $limit_offset = 0; $limit_count = false; + $groupTable = array(); if (! empty($_REQUEST['tbl_group']) || ! empty($_REQUEST['tbl_type'])) { - if (! empty($_REQUEST['tbl_group'])) { - // only tables for selected group - $tbl_group = $_REQUEST['tbl_group']; - } if (! empty($_REQUEST['tbl_type'])) { // only tables for selected type $tbl_type = $_REQUEST['tbl_type']; } + if (! empty($_REQUEST['tbl_group'])) { + // only tables for selected group + $tbl_group = $_REQUEST['tbl_group']; + // include the table with the exact name of the group if such exists + $groupTable = $GLOBALS['dbi']->getTablesFull( + $db, $tbl_group, false, null, $limit_offset, + $limit_count, $sort, $sort_order, $tbl_type + ); + $groupWithSeperator = $tbl_group + . $GLOBALS['cfg']['NavigationTreeTableSeparator']; + } } else { // all tables in db // - get the total number of tables @@ -200,9 +215,12 @@ if (! isset($sot_ready)) { $limit_count = true; } } - $tables = $GLOBALS['dbi']->getTablesFull( - $db, $tbl_group, ($tbl_group != false), null, $limit_offset, - $limit_count, $sort, $sort_order, $tbl_type + $tables = array_merge( + $groupTable, + $GLOBALS['dbi']->getTablesFull( + $db, $groupWithSeperator, ($groupWithSeperator != false), null, + $limit_offset, $limit_count, $sort, $sort_order, $tbl_type + ) ); } diff --git a/libraries/navigation/NavigationTree.class.php b/libraries/navigation/NavigationTree.class.php index 2dcfb7ccd8..710262374e 100644 --- a/libraries/navigation/NavigationTree.class.php +++ b/libraries/navigation/NavigationTree.class.php @@ -584,8 +584,7 @@ class PMA_NavigationTree if ($node instanceof Node_Table_Container || $node instanceof Node_View_Container ) { - $tblGroup = '&tbl_group=' - . urlencode($key . $node->separator); + $tblGroup = '&tbl_group=' . urlencode($key); $groups[$key]->links = array( 'text' => $node->links['text'] . $tblGroup, 'icon' => $node->links['icon'] . $tblGroup