diff options
author | Ivan Kohler <ivan@freeside.biz> | 2016-12-21 18:26:04 -0800 |
---|---|---|
committer | Ivan Kohler <ivan@freeside.biz> | 2016-12-21 18:26:04 -0800 |
commit | db970fa27e376cfe3321c91d25dd047652e650c6 (patch) | |
tree | f1c6e1184be5a84aef9e24522ebdd91611fd2175 /FS/FS/UI/Web | |
parent | 5a97f3f545d11966801077b9740e5f91fb2bbf6a (diff) |
Add mobile number to ticketing view, RT#73861
Diffstat (limited to 'FS/FS/UI/Web')
-rw-r--r-- | FS/FS/UI/Web/small_custview.pm | 25 |
1 files changed, 17 insertions, 8 deletions
diff --git a/FS/FS/UI/Web/small_custview.pm b/FS/FS/UI/Web/small_custview.pm index e82e332..85bee7d 100644 --- a/FS/FS/UI/Web/small_custview.pm +++ b/FS/FS/UI/Web/small_custview.pm @@ -142,16 +142,25 @@ sub small_custview { } $html .= '</TD></TR><TR><TD></TD><TD BGCOLOR="#ffffff">'; - if ( $cust_main->daytime && $cust_main->night ) { - $html .= ( FS::Msgcat::_gettext('daytime') || 'Day' ). - ' '. $cust_main->daytime. - '<BR>'. ( FS::Msgcat::_gettext('night') || 'Night' ). - ' '. $cust_main->night; - } elsif ( $cust_main->daytime || $cust_main->night ) { - $html .= $cust_main->daytime || $cust_main->night; + + my $num_numbers = 0; + $num_numbers++ foreach grep $cust_main->$_(), qw( daytime night mobile ); + if ( $num_numbers > 1 ) { + $html .= ucfirst( FS::Msgcat::_gettext('daytime') ). + ' '. $cust_main->daytime. '<BR>' + if $cust_main->daytime; + $html .= ucfirst( FS::Msgcat::_gettext('night') ). + ' '. $cust_main->night. '<BR>' + if $cust_main->night; + $html .= ucfirst( FS::Msgcat::_gettext('mobile') ). + ' '. $cust_main->mobile. '<BR>' + if $cust_main->night; + } elsif ( $num_numbers ) { # == 1 ) { + $html .= ( $cust_main->daytime || $cust_main->night || $cust_main->mobile ). + '<BR>'; } if ( $cust_main->fax ) { - $html .= '<BR>Fax '. $cust_main->fax; + $html .= 'Fax '. $cust_main->fax; } $html .= '</TD></TR></TABLE></TD>'; |