% if ( scalar(@{ $opt{'discount'} }) == 0 ) {
% } else {
<% $opt{'label'} || 'Discount' %> |
<% include( '/elements/select-discount.html',
'curr_value' => $discountnum,
%opt,
)
%>
|
% }
<%init>
my %opt = @_;
my $discountnum = $opt{'curr_value'} || $opt{'value'};
$opt{'discount'} ||= [ qsearch( 'discount', { disabled=>'' } ) ];
%init>