doc
[freeside.git] / httemplate / elements / tr-select-part_referral.html
index cd26c25..a589528 100644 (file)
@@ -1,5 +1,5 @@
 % if ( scalar( @{$opt{'part_referrals'}} ) == 0 ) {
-%     eidiot "You have not created any advertising sources.  You must create at least one advertising source before adding a customer.  Go to ". popurl(2). "browse/part_referral.html and create one or more advertising sources.";
+    <P><FONT SIZE="+1" COLOR="#ff0000">You have not created any advertising sources.  You must create at least one advertising source before adding a customer.  Go to <A HREF="<% popurl(2) %>browse/part_referral.html">advertising source listing</A> and create one or more advertising sources.</FONT>
 %   } elsif ( scalar( @{$opt{'part_referrals'}} ) == 1 ) {
 
      <INPUT TYPE="hidden" NAME="<% $opt{'element_name'} || $opt{'field'} || 'refnum' %>" VALUE="<% $opt{'part_referrals'}->[0]->refnum %>">
@@ -12,7 +12,7 @@
 %      } else {
          <TH ALIGN="right"><%$r%>Advertising source</TH>
 %      }
-       <TD>
+       <TD COLSPAN="<% $colspan %>">
          <% include( '/elements/select-part_referral.html',
                        'curr_value' => $refnum,
                        %opt
@@ -30,6 +30,8 @@ my $refnum = $opt{'curr_value'} || $opt{'value'};
 $opt{'part_referrals'} ||=
   [ FS::part_referral->all_part_referral( 1 ) ]; #1: include global
 
+my $colspan = delete($opt{'colspan'}) || 1;
+
 my $r = qq!<font color="#ff0000">*</font>&nbsp;!;
 
 </%init>