From 7c0b691a537bc2d5fa9fec93ac790f3d6add11c6 Mon Sep 17 00:00:00 2001 From: Andreas Granig Date: Wed, 6 Nov 2013 10:04:29 +0100 Subject: [PATCH] MT#4017 Fix subscriber->device mapping in config. When fetching the field device config, only select the correct subscribers for the line ranges which actually belong to the field device. --- lib/NGCP/Panel/Controller/Device.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/NGCP/Panel/Controller/Device.pm b/lib/NGCP/Panel/Controller/Device.pm index da627694e1..da56637077 100644 --- a/lib/NGCP/Panel/Controller/Device.pm +++ b/lib/NGCP/Panel/Controller/Device.pm @@ -927,7 +927,7 @@ sub dev_field_config :Chained('/') :PathPart('device/autoprov/config') :Args() { num_lines => $linerange->num_lines, lines => [], }; - foreach my $line($linerange->autoprov_field_device_lines->all) { + foreach my $line($linerange->autoprov_field_device_lines->search({ device_id => $dev->id })->all) { my $sub = $line->provisioning_voip_subscriber; my $display_name = NGCP::Panel::Utils::Preferences::get_usr_preference_rs( c => $c,