summaryrefslogtreecommitdiff
path: root/httemplate/view/svc_pbx.cgi
diff options
context:
space:
mode:
authorMark Wells <mark@freeside.biz>2012-03-08 13:37:53 -0800
committerMark Wells <mark@freeside.biz>2012-03-08 13:38:33 -0800
commita5fba19707ec1a01db18fa55862e742170feccdf (patch)
tree66eb6e525959474e3392c12924ba95bad98b6a6e /httemplate/view/svc_pbx.cgi
parent2e7f1e27ead9a8837b5516e2cd2e1795d51e5ee1 (diff)
match CDRs to services by IP address, #16723
Diffstat (limited to 'httemplate/view/svc_pbx.cgi')
-rw-r--r--httemplate/view/svc_pbx.cgi6
1 files changed, 4 insertions, 2 deletions
diff --git a/httemplate/view/svc_pbx.cgi b/httemplate/view/svc_pbx.cgi
index 79cafed4d..a1afeb22c 100644
--- a/httemplate/view/svc_pbx.cgi
+++ b/httemplate/view/svc_pbx.cgi
@@ -1,6 +1,6 @@
<% include('elements/svc_Common.html',
'table' => 'svc_pbx',
- 'edit_url' => $p."edit/svc_Common.html?svcdb=svc_pbx;svcnum=",
+ 'edit_url' => $p."edit/svc_Common.html?svcdb=svc_pbx;svcnum=",
'labels' => \%labels,
'html_foot' => $html_foot,
)
@@ -43,12 +43,14 @@ my $html_foot = sub {
my $cdr_svc_method = $voip_pkg->option('cdr_svc_method')
|| 'svc_phone.phonenum';
- return '' unless $cdr_svc_method =~ /^svc_pbx\.(\w+)$/;
+ return '' unless $cdr_svc_method =~ /^svc_pbx\.(.*)$/;
my $field = $1;
my $search;
if ( $field eq 'title' ) {
$search = 'charged_party='. uri_escape($svc_pbx->title);
+ } elsif ( $field =~ /^ip\.(\w+)$/ ) {
+ $search = "$1_ip_addr=". uri_escape($svc_pbx->title);
} elsif ( $field eq 'svcnum' ) {
$search = 'svcnum='. $svc_pbx->svcnum;
} else {