NetBIOS Node Report

This commit is contained in:
Eric A. Miller
2014-02-08 20:46:07 -05:00
parent 8e8839dd43
commit 79cc9622b2
6 changed files with 157 additions and 5 deletions

View File

@@ -1,18 +1,27 @@
package App::Netdisco::Web::Report;
use Dancer ':syntax';
use Dancer::Plugin::DBIC;
use Dancer::Plugin::Auth::Extensible;
get '/report/*' => require_login sub {
my ($tag) = splat;
# used in the report search sidebar to populate select inputs
my $domain_list
= [
schema('netdisco')->resultset('NodeNbt')->get_distinct_col('domain')
];
# trick the ajax into working as if this were a tabbed page
params->{tab} = $tag;
var(nav => 'reports');
template 'report', {
report => setting('_reports')->{ $tag },
};
var( nav => 'reports' );
template 'report',
{
report => setting('_reports')->{$tag},
domain_list => $domain_list,
};
};
true;