From 4bd9d3d9dc5325f0d7bd498e457140b15d01866c Mon Sep 17 00:00:00 2001 From: ivan Date: Fri, 12 Mar 2010 03:36:47 +0000 Subject: add location to svc_phone, RT#7047 --- httemplate/view/svc_phone.cgi | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) (limited to 'httemplate/view') diff --git a/httemplate/view/svc_phone.cgi b/httemplate/view/svc_phone.cgi index 76ee7397d..ebde42228 100644 --- a/httemplate/view/svc_phone.cgi +++ b/httemplate/view/svc_phone.cgi @@ -16,6 +16,7 @@ <%init> my $conf = new FS::Conf; +my $countrydefault = $conf->config('countrydefault') || 'US'; my @fields = qw( countrycode phonenum ); push @fields, 'domain' if $conf->exists('svc_phone-domain'); @@ -24,6 +25,27 @@ push @fields, qw( pbx_title sip_password pin phone_name ); my $html_foot = sub { my $svc_phone = shift; + ### + # E911 Info + ### + + my $loc = $svc_phone->cust_location_or_main; + + my $e911 = + 'E911 Information'. + &ntable("#cccccc"). ''. ntable("#cccccc",2). + 'Location'. + ''. + $loc->location_label( 'join_string' => '
', + 'double_space' => '   ', + 'escape_function' => \&encode_entities, + 'countrydefault' => $countrydefault, + ). + ''. + ''. + '
' + ; + ### # Devices ### @@ -123,6 +145,7 @@ my $html_foot = sub { # concatenate & return ### + $e911. $devices. join(' | ', @links ). '
'. join(' | ', @ilinks). '
'; -- cgit v1.2.1