mirror of
https://github.com/vrana/adminer.git
synced 2025-08-09 08:06:59 +02:00
MySQL: Skip editing generated columns
This commit is contained in:
committed by
Jakub Vrana
parent
92d443dac0
commit
00d36efcf1
@@ -4,7 +4,7 @@ $fields = fields($TABLE);
|
||||
$where = (isset($_GET["select"]) ? ($_POST["check"] && count($_POST["check"]) == 1 ? where_check($_POST["check"][0], $fields) : "") : where($_GET, $fields));
|
||||
$update = (isset($_GET["select"]) ? $_POST["edit"] : $where);
|
||||
foreach ($fields as $name => $field) {
|
||||
if (!isset($field["privileges"][$update ? "update" : "insert"]) || $adminer->fieldName($field) == "") {
|
||||
if (!isset($field["privileges"][$update ? "update" : "insert"]) || $adminer->fieldName($field) == "" || $field["generated"]) {
|
||||
unset($fields[$name]);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user