X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=blobdiff_plain;f=httemplate%2Felements%2Ftr-select-pkg_class.html;h=28ed5d67df6e24620e7ed0aa034aa56bbd3e0dbc;hp=1c04314edaecb0ebde187fc5c85edda8259f4550;hb=f822e27a1e00594332ffa487a1c284234c5580a6;hpb=0ab5a147a0013e54b42390db0b0ca176b008b40f diff --git a/httemplate/elements/tr-select-pkg_class.html b/httemplate/elements/tr-select-pkg_class.html index 1c04314ed..28ed5d67d 100644 --- a/httemplate/elements/tr-select-pkg_class.html +++ b/httemplate/elements/tr-select-pkg_class.html @@ -1,6 +1,6 @@ -% if ( $count == 0 ) { +% if ( scalar(@{ $opt{'pkg_class'} }) == 0 ) { - + % } else { @@ -22,6 +22,6 @@ my %opt = @_; my $classnum = $opt{'curr_value'} || $opt{'value'}; -my $count = scalar( qsearch( 'pkg_class', {} ) ); +$opt{'pkg_class'} ||= [ qsearch( 'pkg_class', { disabled=>'' } ) ];