X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Felements%2Fcontact.html;h=3fbcc05187f268b9dd8a1c09adb8d4068227d4b9;hb=d4114381c5d95e8acd0d0fc2bbc2b3528bde2ecf;hp=ef74481c046be2a2b932d800901b5314097ba3e5;hpb=ec7e8155fce544f19f2b6734476ed6db8c200aa9;p=freeside.git diff --git a/httemplate/elements/contact.html b/httemplate/elements/contact.html index ef74481c0..3fbcc0518 100644 --- a/httemplate/elements/contact.html +++ b/httemplate/elements/contact.html @@ -40,7 +40,9 @@ % } % } elsif ( $field eq 'emailaddress' ) { % $value = join(', ', map $_->emailaddress, $contact->contact_email); -% } elsif ( $field eq 'selfservice_access' || $field eq 'comment' ) { +% } elsif ( $field eq 'selfservice_access' +% or $field eq 'comment' +% or $field eq 'invoice_dest' ) { % $value = $X_contact->get($field); % } else { % $value = $contact->get($field); @@ -59,13 +61,22 @@ % } % } - +% } elsif ( $field eq 'invoice_dest' ) { +% my $curr_value = $cgi->param($name . '_' . $field); +% $curr_value = $value if !defined($curr_value); + <& select.html, + field => $name . '_' . $field, + curr_value => $curr_value, + options => [ '', 'Y' ], + option_labels => { '' => 'no', 'Y' => 'yes' }, + style => 'width: 100%', + &> % } else { > @@ -130,12 +141,13 @@ tie my %label, 'Tie::IxHash', 'last' => 'Last name', 'title' => 'Title/Position', 'emailaddress' => 'Email', + 'invoice_dest' => 'Send invoices', 'selfservice_access' => 'Self-service' ; my $first = 0; foreach my $phone_type ( qsearch({table=>'phone_type', order_by=>'weight'}) ) { - next if $phone_type->typename eq 'Home'; + next if $phone_type->typename =~ /^(Home|Fax)$/; my $f = 'phonetypenum'.$phone_type->phonetypenum; $label{$f} = $phone_type->typename. ' phone'; $size{$f} = $first++ ? 10 : 15;