'Agent | Agent Cust# or Cust# | Cust. Status | Customer' =>
'Agent | Agent Cust# | Status | Last, First or Company (Last, First)',
- "Customer | Day phone | Night phone | Mobile phone | Fax number | Contact phone(s)" =>
+ 'Customer | Day phone | Night phone | Mobile phone | Fax number | Contact phone(s)' =>
'Customer | (all phones)',
'Cust# | Customer | Day phone | Night phone | Mobile phone | Fax number | Contact phone(s)' =>
'custnum | Customer | (all phones)',
}
}
- foreach my $field (qw(daytime night mobile fax )) {
+ foreach my $field (qw(daytime night mobile fax)) {
push @fields, $field if (grep { $_ eq $field } @cust_fields);
}
push @fields, 'agent_custid';
# phones
##
- foreach my $phonet (qw(daytime night mobile)) {
+ foreach my $phonet (qw(daytime night mobile fax)) {
if ($params->{$phonet}) {
$params->{$phonet} =~ s/\D//g;
$params->{$phonet} =~ /^(\d{3})(\d{3})(\d{4})(\d*)$/
=cut
sub get_phone_types {
- ## only using mobile(3) and work(1) right now.
- my @phone_types = qsearch({table=>'phone_type', order_by=>'ORDER BY weight DESC', extra_sql => " WHERE phonetypenum IN ('1','3')"});
+ ## not using Home and Fax right now. false laziness with /elements/contact.html
+ my @phone_types = qsearch({table=>'phone_type', order_by=>'ORDER BY weight DESC', extra_sql => " WHERE typename NOT IN ('Home','Fax')"});
return @phone_types;
}
foreach my $phone_type ( FS::phone_type->get_phone_types() ) {
$contact_phone_list .= " | Contact ".$phone_type->typename." phone(s)";
}
- @fields = map {s/\| Contact phone\(s\)/$contact_phone_list/g; $_; } @fields;
+ @fields = map {s/ \| Contact phone\(s\)/$contact_phone_list/g; $_; } @fields;
$opt{'avail_fields'} ||= [ @fields ];
foreach my $phone_type ( FS::phone_type->get_phone_types() ) {
$contact_phone_list .= " | Contact ".$phone_type->typename." phone(s)";
}
-@fields = map {s/\| Contact phone\(s\)/$contact_phone_list/g; $_; } @fields;
+@fields = map {s/ \| Contact phone\(s\)/$contact_phone_list/g; $_; } @fields;
$opt{'avail_fields'} ||= [ @fields ];
my @scalars = qw (
agentnum salesnum status
address city county state zip country location_history
- daytime night mobile
+ daytime night mobile fax
invoice_terms
no_censustract with_geocode with_email tax no_tax POST no_POST
custbatch usernum
<TD COLSPAN=6>
<TABLE CELLSPACING=0 CELLPADDING=0>
<TR>
-% foreach my $phone (qw(daytime night mobile)) {
+% foreach my $phone (qw(daytime night mobile fax)) {
<TD>
<INPUT TYPE="text"
NAME="<% $phone %>"
daytime => 'Day Phone',
night => 'Night Phone',
mobile => 'Mobile Phone',
+ fax => 'Fax Number',
);
</%init>
\ No newline at end of file
<%$th%>Send messages</TH>
<%$th%>Self-service</TH>
% foreach my $phone_type (@phone_type) {
- <%$th%><% $phone_type->typename |h %></TH>
+ <%$th%><% $phone_type->typename |h %> phone</TH>
% }
<%$th%>Comment</TH>
</TR>