summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--httemplate/elements/tr-select-part_svc.html29
1 files changed, 29 insertions, 0 deletions
diff --git a/httemplate/elements/tr-select-part_svc.html b/httemplate/elements/tr-select-part_svc.html
new file mode 100644
index 000000000..0274ef12a
--- /dev/null
+++ b/httemplate/elements/tr-select-part_svc.html
@@ -0,0 +1,29 @@
+% if ( scalar(@{ $opt{'part_svc'} }) == 0 ) {
+
+ <INPUT TYPE="hidden" NAME="<% $opt{'field'} || 'svcpart' %>" VALUE="">
+
+% } else {
+
+ <TR>
+ <TD ALIGN="right"><% $opt{'label'} || 'Package definition' %></TD>
+ <TD>
+ <% include( '/elements/select-table.html',
+ 'table' => 'part_svc',
+ 'name_col' => 'svc',
+ 'multiple' => 1,
+ #N/A 'empty_label' => '(none)',
+ %opt,
+ )
+ %>
+ </TD>
+ </TR>
+
+% }
+
+<%init>
+
+my( %opt ) = @_;
+
+$opt{'part_svc'} ||= [ qsearch( 'part_svc', {} ) ]; # { disabled=>'' } )
+
+</%init>