diff options
author | levinse <levinse> | 2010-12-28 17:20:16 +0000 |
---|---|---|
committer | levinse <levinse> | 2010-12-28 17:20:16 +0000 |
commit | e5f036c5afa363b228d309ca065c6147f4e90d78 (patch) | |
tree | b930d4370b74f3e5e586db2bf6000289c6a34074 /httemplate/search | |
parent | 4f6f5f8d508b87dfc024533d030792c6422480a5 (diff) |
UI enhancements to phone_avail report, RT10464
Diffstat (limited to 'httemplate/search')
-rw-r--r-- | httemplate/search/phone_avail.html | 33 |
1 files changed, 27 insertions, 6 deletions
diff --git a/httemplate/search/phone_avail.html b/httemplate/search/phone_avail.html index b2b4630ae..3c853efa5 100644 --- a/httemplate/search/phone_avail.html +++ b/httemplate/search/phone_avail.html @@ -31,23 +31,33 @@ }, sub { shift->get('name') }, 'availbatch', - 'exportnum', #XXX - #sub { }, - 'svcnum', #XXX + sub { + my $pa = shift; + return '' unless $pa->part_export; + $pa->part_export->exportname; + }, + sub { + my $pa = shift; + return '' unless $pa->cust_svc; + my($label,$value) = $pa->cust_svc->label; + $label . ": " . $value; + }, \&FS::UI::Web::cust_fields, + '', ], - 'align' => 'rllllll'.FS::UI::Web::cust_aligns(), + 'align' => 'rllllllc'.FS::UI::Web::cust_aligns(), 'links' => [ '', '', '', '', '', - '', #XXX #$export_link - '', #XXX #$svc_link + '', #XXX #$export_link - to what exactly? + $svc_link, ( map { $_ ne 'Cust. Status' ? $link_cust : '' } FS::UI::Web::cust_header() ), + '', ], 'color' => [ '', @@ -58,6 +68,7 @@ '', '', FS::UI::Web::cust_colors(), + '', ], 'style' => [ '', @@ -68,6 +79,7 @@ '', '', FS::UI::Web::cust_styles(), + '', ], ) %> @@ -130,4 +142,13 @@ my $link_cust = sub { ''; }; +my $svc_link = sub { + my $phone_avail = shift; + my $cust_svc = $phone_avail->cust_svc; + if ( $cust_svc ) { + return [ "${p}view/svc_phone.cgi?", 'svcnum']; + } + ''; +}; + </%init> |