mirror of
https://github.com/webmin/webmin.git
synced 2026-05-04 22:30:33 +01:00
Auto-select DB name fields when clicked
This commit is contained in:
@@ -574,14 +574,17 @@ if ($access{'perms'} == 2 && $access{'dbs'} ne '*') {
|
||||
else {
|
||||
# Can select any databases
|
||||
local $ind = &indexof($_[0],@dbs) >= 0;
|
||||
local $js1 = "onChange='form.db_def[1].checked = true'";
|
||||
local $js2 = "onClick='form.db_def[2].checked = true'";
|
||||
$rv = &ui_radio("db_def", $_[0] eq '%' || $_[0] eq '' ? 1 :
|
||||
$ind ? 2 : 0,
|
||||
[ [ 1, $text{'host_any'} ],
|
||||
[ 2, $text{'host_sel'}." ".
|
||||
&ui_select("dbs", $_[0], \@dbs) ],
|
||||
&ui_select("dbs", $_[0], \@dbs, 1, 0, 0, 0, $js1) ],
|
||||
[ 0, $text{'host_otherdb'}." ".
|
||||
&ui_textbox("db", $_[0] eq '%' || $_[0] eq '' ||
|
||||
$ind ? '' : $_[0], 30) ] ]);
|
||||
$ind ? '' : $_[0], 30, 0,
|
||||
undef, $js2) ] ]);
|
||||
}
|
||||
return $rv;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user