bulk credit import, RT#26319
[freeside.git] / httemplate / edit / part_export.cgi
index 1450ac3..e152716 100644 (file)
@@ -68,6 +68,15 @@ my $widget = new HTML::Widgets::SelectLayers(
   'html_between'    => "</TD></TR></TABLE>\n",
   'layer_callback'  => sub {
     my $layer = shift;
+    # create 'config_element' to generate the whole layer with a Mason component
+    if ( my $include = $exports->{$layer}{config_element} ) {
+      # might need to adjust the scope of  this at some point
+      return $m->scomp($include, 
+        part_export => $part_export,
+        layer       => $layer,
+        export_info => $exports->{$layer}
+      );
+    }
     my $html = qq!<INPUT TYPE="hidden" NAME="exporttype" VALUE="$layer">!.
                ntable("#cccccc",2);
 
@@ -106,7 +115,8 @@ my $widget = new HTML::Widgets::SelectLayers(
       }
       if ( $type eq 'select' ) {
         my $size = defined($optinfo->{size}) ? " SIZE=" . $optinfo->{size} : '';
-        my $multi = defined($optinfo->{multi}) ? ' MULTIPLE' : '';
+        my $multi = ($optinfo->{multi} || $optinfo->{multiple})
+                      ? ' MULTIPLE' : '';
         $html .= qq!<SELECT NAME="$option"$multi$size>!;
         my @values = split '\s+', $value if $multi;
         my @options;