blob: 71aaa84b695daa810fde0dede4c39e4f394857a2 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
<SELECT NAME="status" <% $opt{'onchange'} %>>
<OPTION VALUE="">all
% foreach my $option ( @{ $opt{'statuses'} } ) {
<OPTION VALUE="<% $option %>" <% $option eq $status ? 'SELECTED' : '' %>><% $option %>
% }
</SELECT>
<%init>
my( $status, %opt ) = @_;
$opt{'statuses'} ||= [ FS::cust_pkg->statuses() ]; # { disabled=>'' } )
if ( exists $opt{'onchange'} && $opt{'onchange'} ) {
$opt{'onchange'} = ' onChange="' . $opt{'onchange'}. '"';
} else {
$opt{'onchange'} = '';
}
</%init>
|