From 3ff9f3c5876c1c2f15b9368fc03240d310458d3e Mon Sep 17 00:00:00 2001 From: Oliver Gorwits Date: Sun, 2 Mar 2014 21:03:06 +0000 Subject: [PATCH] Unknown device page has pre-filled Discover IP --- Netdisco/Changes | 1 + Netdisco/lib/App/Netdisco/Web/Device.pm | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Netdisco/Changes b/Netdisco/Changes index 44ea9a39..1dafb6a3 100644 --- a/Netdisco/Changes +++ b/Netdisco/Changes @@ -7,6 +7,7 @@ * User Reports appear in "My Reports" menu if no category is given * Permit clipboard copy of device IP from Job Queue rows * Failed Job Device IPs link to Discover form with pre-filled Discover IP + * Unknown device page has pre-filled Discover IP * Set form focus to Username field on login form 2.024003 - 2014-02-27 diff --git a/Netdisco/lib/App/Netdisco/Web/Device.pm b/Netdisco/lib/App/Netdisco/Web/Device.pm index 9ab1badf..89e97cfe 100644 --- a/Netdisco/lib/App/Netdisco/Web/Device.pm +++ b/Netdisco/lib/App/Netdisco/Web/Device.pm @@ -167,7 +167,7 @@ get '/device' => require_login sub { }); if ($dev->count == 0) { - return redirect uri_for('/', {nosuchdevice => 1})->path_query; + return redirect uri_for('/', {nosuchdevice => 1, device => $q})->path_query; } # if passed dns, need to check for duplicates