diff options
Diffstat (limited to 'httemplate/elements')
-rw-r--r-- | httemplate/elements/menu.html | 4 | ||||
-rw-r--r-- | httemplate/elements/select-cust-fields.html | 23 | ||||
-rw-r--r-- | httemplate/elements/select-cust_pkg-status.html | 19 | ||||
-rw-r--r-- | httemplate/elements/tr-select-cust-fields.html | 14 | ||||
-rw-r--r-- | httemplate/elements/tr-select-cust_pkg-status.html | 13 |
5 files changed, 71 insertions, 2 deletions
diff --git a/httemplate/elements/menu.html b/httemplate/elements/menu.html index c09fcee8c..8da197f34 100644 --- a/httemplate/elements/menu.html +++ b/httemplate/elements/menu.html @@ -85,7 +85,7 @@ 'All customer packages' => [ $fsurl.'search/cust_pkg.cgi?pkgnum', 'List all customer packages', ], 'Suspended customer packages' => [ $fsurl.'search/cust_pkg.cgi?magic=suspended', 'List suspended packages' ], 'Customer packages with unconfigured services' => [ $fsurl.'search/cust_pkg.cgi?APKG_pkgnum', 'List packages which have provisionable services' ], - 'By next bill date' => [ $fsurl.'search/cust_pkg_report.cgi', 'Search packages by next bill date' ], + 'Advanced package reports' => [ $fsurl.'search/report_cust_pkg.html', 'by agent, date range, status, package definition' ], ; tie my %report_financial, 'Tie::IxHash', @@ -264,7 +264,7 @@ if ( ref($url_or_submenu) ) { - warn $item; + #warn $item; my( $subhtml, $submenuname ) = submenu($url_or_submenu, $item); diff --git a/httemplate/elements/select-cust-fields.html b/httemplate/elements/select-cust-fields.html new file mode 100644 index 000000000..4d47fbe40 --- /dev/null +++ b/httemplate/elements/select-cust-fields.html @@ -0,0 +1,23 @@ +<% + my( $cust_fields, %opt ) = @_; + + use FS::ConfDefaults; + $opt{'avail_fields'} ||= [ FS::ConfDefaults->cust_fields_avail() ]; + + tie my %hash, 'Tie::IxHash', @{ $opt{'avail_fields'} }; + +%> + +<SELECT NAME="cust_fields"> + + <OPTION VALUE="">(configured default) + + <% + foreach my $value ( keys %hash ) { %> + + <OPTION VALUE="<%= $value %>"><%= $hash{$value} %> + + <% } %> + +</SELECT> + diff --git a/httemplate/elements/select-cust_pkg-status.html b/httemplate/elements/select-cust_pkg-status.html new file mode 100644 index 000000000..5da93fe79 --- /dev/null +++ b/httemplate/elements/select-cust_pkg-status.html @@ -0,0 +1,19 @@ +<% + my( $status, %opt ) = @_; + + $opt{'statuses'} ||= [ FS::cust_pkg->statuses() ]; # { disabled=>'' } ) + +%> + +<SELECT NAME="status"> + + <OPTION VALUE="">all + + <% foreach my $status ( @{ $opt{'statuses'} } ) { %> + + <OPTION VALUE="<%= $status %>"><%= $status %> + + <% } %> + +</SELECT> + diff --git a/httemplate/elements/tr-select-cust-fields.html b/httemplate/elements/tr-select-cust-fields.html new file mode 100644 index 000000000..ca37e4276 --- /dev/null +++ b/httemplate/elements/tr-select-cust-fields.html @@ -0,0 +1,14 @@ +<% + my( $cust_fields, %opt ) = @_; + + use FS::ConfDefaults; + $opt{'avail_fields'} ||= [ FS::ConfDefaults->cust_fields_avail() ]; + +%> + +<TR> + <TD ALIGN="right"><%= $opt{'label'} || 'Customer fields' %></TD> + <TD> + <%= include( '/elements/select-cust-fields.html', $cust_fields, %opt ) %> + </TD> +</TR> diff --git a/httemplate/elements/tr-select-cust_pkg-status.html b/httemplate/elements/tr-select-cust_pkg-status.html new file mode 100644 index 000000000..17768517d --- /dev/null +++ b/httemplate/elements/tr-select-cust_pkg-status.html @@ -0,0 +1,13 @@ +<% + my( $status, %opt ) = @_; + + $opt{'statuses'} ||= [ FS::cust_pkg->statuses() ]; # { disabled=>'' } ) + +%> + +<TR> + <TD ALIGN="right"><%= $opt{'label'} || 'Status' %></TD> + <TD> + <%= include( '/elements/select-cust_pkg-status.html', $status, %opt ) %> + </TD> +</TR> |