bug #1681598 [interface] Edit next row

This commit is contained in:
Marc Delisle
2007-03-25 13:06:33 +00:00
parent 429a428ecd
commit 04e26c61a9
3 changed files with 8 additions and 2 deletions

View File

@@ -21,6 +21,7 @@ $HeadURL: https://phpmyadmin.svn.sourceforge.net/svnroot/phpmyadmin/trunk/phpMyA
- [gui] avoid displaying a wide selector in server selection
- bug #1614004 [relation] foreign key spanning multiple columns are
incorrectly displayed
- bug #1681598 [interface] Edit next row
+ [core] added PMA_fatalError() and made use of it
. [core] added PMA_isValid() and PMA_ifSetOr() for variable handling
. [i18n] use generic $strOptions

View File

@@ -33,6 +33,11 @@ if (isset($_REQUEST['dontlimitchars'])) {
if (isset($_REQUEST['primary_key'])) {
$primary_key = $_REQUEST['primary_key'];
}
if (isset($_SESSION['edit_next'])) {
$primary_key = $_SESSION['edit_next'];
unset($_SESSION['edit_next']);
$after_insert = 'edit_next';
}
if (isset($_REQUEST['sql_query'])) {
$sql_query = $_REQUEST['sql_query'];
}
@@ -1005,7 +1010,7 @@ if (isset($primary_key)) {
// in 2.9.0, we are looking for `table_name`.`field_name` = numeric_value
if (preg_match('@^[\s]*`[^`]*`[\.]`[^`]*` = [0-9]+@', $primary_key)) {
?>
<option value="edit_next"><?php echo $strAfterInsertNext; ?></option>
<option value="edit_next" <?php echo ($after_insert == 'edit_next' ? 'selected="selected"' : ''); ?>><?php echo $strAfterInsertNext; ?></option>
<?php
}
}

View File

@@ -98,7 +98,7 @@ if (isset($_REQUEST['after_insert'])
$res = PMA_DBI_query($local_query);
$row = PMA_DBI_fetch_row($res);
$meta = PMA_DBI_get_fields_meta($res);
$url_params['primary_key'][] = PMA_getUniqueCondition($res, count($row), $meta, $row);
$_SESSION['edit_next'] = PMA_getUniqueCondition($res, count($row), $meta, $row);
}
}
}