From 4ddf9e2e9a5552306c3d95cb85a44586367f58c4 Mon Sep 17 00:00:00 2001 From: ivan Date: Sun, 23 Sep 2007 18:32:28 +0000 Subject: accounts w/time remaining search --- httemplate/elements/menu.html | 5 ++++- httemplate/search/svc_acct.cgi | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) (limited to 'httemplate') diff --git a/httemplate/elements/menu.html b/httemplate/elements/menu.html index 455c7b364..5675c7b17 100644 --- a/httemplate/elements/menu.html +++ b/httemplate/elements/menu.html @@ -115,8 +115,11 @@ foreach my $svcdb ( FS::part_svc->svc_tables() ) { foreach my $sort ( @$sorts ) { + my $field_info = FS::part_svc->svc_table_fields($svcdb)->{$sort}; + my $label = $field_info->{'label_sort'} || 'by '.$field_info->{'label'}; + my $title = "All $lcname"; - $title .= " by ". FS::part_svc->svc_table_fields($svcdb)->{$sort}->{'label'} + $title .= " $label" if scalar(@$sorts) > 1; $report_svc{$title} = diff --git a/httemplate/search/svc_acct.cgi b/httemplate/search/svc_acct.cgi index ee8a5d0a7..9ccac5dd7 100755 --- a/httemplate/search/svc_acct.cgi +++ b/httemplate/search/svc_acct.cgi @@ -71,7 +71,7 @@ if ( $cgi->param('magic') =~ /^(all|unlinked)$/ ) { $sortby = "LOWER($sortby)" if $sortby eq 'username'; push @extra_sql, "$sortby IS NOT NULL" - if $sortby eq 'uid'; + if $sortby eq 'uid' || $sortby eq 'seconds'; $orderby = "ORDER BY $sortby"; } -- cgit v1.2.1