diff options
author | Mark Wells <mark@freeside.biz> | 2012-09-06 11:47:02 -0700 |
---|---|---|
committer | Mark Wells <mark@freeside.biz> | 2012-09-06 11:47:02 -0700 |
commit | f8c8b9782ff5400790c2fb6dae017ce01790e56e (patch) | |
tree | ed4abe678b2ba0ebe5cc4289a2f76e0019943b40 /httemplate/search/report_477.html | |
parent | b7ce9a95a6fa002d0d537c950f11f8a23d3dfc25 (diff) |
separate all 477 reports by state, #18503
Diffstat (limited to 'httemplate/search/report_477.html')
-rwxr-xr-x | httemplate/search/report_477.html | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/httemplate/search/report_477.html b/httemplate/search/report_477.html index c9d97c5eb..f593a94d8 100755 --- a/httemplate/search/report_477.html +++ b/httemplate/search/report_477.html @@ -17,6 +17,18 @@ ) %> +% # not tr-select-state, we only want to choose from among those that +% # have customers + <& /elements/tr-select-table.html, + 'label' => 'State', + 'field' => 'state', + 'table' => 'cust_location', + 'name_col' => 'state', + 'value_col' => 'state', + 'disable_empty' => 1, + 'records' => \@states, + &> + <% include( '/elements/tr-select-pkg_class.html', 'multiple' => 1, 'empty_label' => '(empty class)', @@ -252,4 +264,10 @@ die "access denied" unless $FS::CurrentUser::CurrentUser->access_right('List packages'); +my @states = qsearch({ + 'table' => 'cust_location', + 'select' => 'DISTINCT(state)', + 'hashref' => { 'country' => 'US' }, # 477 report isn't relevant elsewhere +}); + </%init> |