Revert "Order by auto_increment column by default"

This reverts commit 79b61855e5.
This commit is contained in:
Jakub Vrana 2013-04-03 10:10:15 -07:00
parent 0cd85c1ce9
commit b14a2a5330
2 changed files with 1 additions and 13 deletions

View file

@ -277,7 +277,7 @@ username.form['auth[driver]'].onchange();
* @return null * @return null
*/ */
function selectOrderPrint($order, $columns, $indexes) { function selectOrderPrint($order, $columns, $indexes) {
print_fieldset("sort", lang('Sort'), $order && $_GET["order"]); print_fieldset("sort", lang('Sort'), $order);
$i = 0; $i = 0;
foreach ((array) $_GET["order"] as $key => $val) { foreach ((array) $_GET["order"] as $key => $val) {
if (isset($columns[$val])) { if (isset($columns[$val])) {
@ -440,17 +440,6 @@ username.form['auth[driver]'].onchange();
$return[] = (isset($fields[$val]) ? idf_escape($val) : $val) . (isset($_GET["desc"][$key]) ? " DESC" : ""); $return[] = (isset($fields[$val]) ? idf_escape($val) : $val) . (isset($_GET["desc"][$key]) ? " DESC" : "");
} }
} }
if (!$_GET["order"]) {
foreach ($fields as $name => $field) {
if ($field["auto_increment"]) {
foreach ($indexes as $index) {
if ($index["columns"] == array($name)) {
return array(idf_escape($name) . " DESC");
}
}
}
}
}
return $return; return $return;
} }

View file

@ -1,6 +1,5 @@
Adminer 3.6.4-dev: Adminer 3.6.4-dev:
Display pagination on a fixed position Display pagination on a fixed position
Order by auto_increment column by default
Display select SQL edit form inline Display select SQL edit form inline
Compatibility with MySQL 5.6 Compatibility with MySQL 5.6
Recover original view, trigger, routine if creating fails Recover original view, trigger, routine if creating fails