rename devgrp to hgroup in netmap

This commit is contained in:
Oliver Gorwits
2018-03-10 14:05:12 +00:00
parent fe14a30261
commit ffc3f21533
5 changed files with 32 additions and 24 deletions

View File

@@ -41,7 +41,7 @@ hook 'before_template' => sub {
}
# used in the device search sidebar template to set selected items
foreach my $opt (qw/devgrp/) {
foreach my $opt (qw/hgroup location/) {
my $p = (ref [] eq ref param($opt) ? param($opt)
: (param($opt) ? [param($opt)] : []));
$tokens->{"${opt}_lkp"} = { map { $_ => 1 } @$p };
@@ -82,7 +82,7 @@ get '/device' => require_login sub {
params->{'tab'} ||= 'details';
template 'device', {
display_name => ($others ? $first->ip : ($first->dns || $first->ip)),
devgrp_list => setting('host_group_displaynames'),
hgroup_list => setting('host_group_displaynames'),
device => params->{'tab'},
};
};