diff options
author | Kristian Lyngstol <kly@kly.no> | 2016-07-01 18:48:56 +0200 |
---|---|---|
committer | Kristian Lyngstol <kly@kly.no> | 2016-07-01 18:48:56 +0200 |
commit | 31aa8dc0e14ff22d1f1492be0fdd0922027d7fcb (patch) | |
tree | d8e164d085c0c24790f6fa3536d62d92be2695a5 /web | |
parent | 8b32a6fc1f4e3dcc8b7feb29281602a625e6f5f1 (diff) |
Remove debug output and fix linknet-adding in nightmode
Diffstat (limited to 'web')
-rwxr-xr-x | web/api/public/switch-state | 2 | ||||
-rw-r--r-- | web/index.html | 10 |
2 files changed, 7 insertions, 5 deletions
diff --git a/web/api/public/switch-state b/web/api/public/switch-state index d1495d5..8e98205 100755 --- a/web/api/public/switch-state +++ b/web/api/public/switch-state @@ -7,7 +7,6 @@ use strict; use warnings; use Data::Dumper; -print "Content-type: text/plain\n\n"; my $target = $ENV{REQUEST_URI}; $target =~ s/$ENV{SCRIPT_NAME}//; $target =~ s/^\///; @@ -20,7 +19,6 @@ if (!defined($switch)) { $q = $nms::web::dbh->prepare('select sysname,extract(epoch from date_trunc(\'second\',time)) as time,data from snmp natural join switches where id in (select max(id) from snmp where ' . $nms::web::when . 'group by switch) and sysname = ' . $nms::web::dbh->quote($switch) . ';'); } -print "s: $switch, p: $port\n"; $q->execute(); while ( my $ref = $q->fetchrow_hashref() ) { my $sysname = $ref->{'sysname'}; diff --git a/web/index.html b/web/index.html index 655204e..bcc1d76 100644 --- a/web/index.html +++ b/web/index.html @@ -113,9 +113,13 @@ <div class="row-fluid" id="admin-row"> <div> <p>Add linknet</p> - <input id="admin-input-linknet1" type="text" placeholder="Switch 1" /> - <input id="admin-input-linknet2" type="text" placeholder="Switch 2" /> - <button class="btn btn-primary" onclick="nmsAdmin.addLinknet()">Add</button> + <div class="form-inline"> + <div class="form-group"> + <input id="admin-input-linknet1" class="form-control" type="text" placeholder="Switch 1" /> + <input id="admin-input-linknet2" class="form-control" type="text" placeholder="Switch 2" /> + <button class="btn btn-primary" onclick="nmsAdmin.addLinknet()">Add</button> + </div> + </div> </div> <hr> </div> |