% if ( scalar( @{$opt{'part_referrals'}} ) == 0 ) {

You have not created any advertising sources. You must create at least one advertising source before adding a customer. Go to advertising source listing and create one or more advertising sources. % } elsif ( scalar( @{$opt{'part_referrals'}} ) == 1 ) { % } else { % if ( $opt{'label'} ) { <% $opt{'label'} %> % } else { <%$r%>Advertising source % } <% include( '/elements/select-part_referral.html', 'curr_value' => $refnum, %opt ) %> % } <%init> my %opt = @_; 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!* !;