X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=blobdiff_plain;f=httemplate%2Felements%2Ftr-select-part_pkg.html;h=400cc5ae8190131d8d362f44b07bd2f8a50d41b7;hp=b6d4d4d9ecc9c96f0f3ab313702603a15634a290;hb=11bbf29de447fe39e9d7155fe280a0df70fa8c3c;hpb=5e05724a635a22776f1b973f5d7e77989da4e048 diff --git a/httemplate/elements/tr-select-part_pkg.html b/httemplate/elements/tr-select-part_pkg.html index b6d4d4d9e..400cc5ae8 100644 --- a/httemplate/elements/tr-select-part_pkg.html +++ b/httemplate/elements/tr-select-part_pkg.html @@ -1,29 +1,35 @@ -% if ( scalar(@{ $opt{'part_pkg'} }) == 0 ) { +% if ( $opt{'part_pkg'} && scalar(@{ $opt{'part_pkg'} }) == 0 ) { +% unless ( $opt{'js_only'} ) { - + +% } +% % } else { +% +% unless ( $opt{'js_only'} ) { - - <% $opt{'label'} || 'Package definition' %> - - <% include( '/elements/select-table.html', - 'table' => 'part_pkg', - 'name_col' => 'pkg', - 'multiple' => 1, - #N/A 'empty_label' => '(none)', - %opt, - ) - %> - - + <& tr-td-label.html, %opt &> + > -% } +% } +% + <& /elements/select-part_pkg.html, %opt &> +% +% unless ( $opt{'js_only'} ) { + + + +% } +% +% } <%init> my( %opt ) = @_; -$opt{'part_pkg'} ||= [ qsearch( 'part_pkg', {} ) ]; # { disabled=>'' } ) +my $cell_style = $opt{'cell_style'} ? 'STYLE="'. $opt{'cell_style'}. '"' : ''; + +$opt{'label'} ||= emt('Package definition');