[freeside-commits] branch FREESIDE_2_3_BRANCH updated. 5898947d8d6dd0ef1f6385845f253d4cdb6358ca

Ivan ivan at 420.am
Sun Feb 3 19:45:26 PST 2013


The branch, FREESIDE_2_3_BRANCH has been updated
       via  5898947d8d6dd0ef1f6385845f253d4cdb6358ca (commit)
      from  d77c2c4261d351684b6aec18a2b8e91702320e4a (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 5898947d8d6dd0ef1f6385845f253d4cdb6358ca
Author: Ivan Kohler <ivan at freeside.biz>
Date:   Sun Feb 3 19:45:22 2013 -0800

    add location to credit application detail, RT#21054

diff --git a/FS/FS/cust_main.pm b/FS/FS/cust_main.pm
index b2f93c5..3b2ba33 100644
--- a/FS/FS/cust_main.pm
+++ b/FS/FS/cust_main.pm
@@ -4100,6 +4100,23 @@ sub country_full {
   code2country($self->country);
 }
 
+=item county_state_county [ PREFIX ]
+
+Returns a string consisting of just the county, state and country.
+
+=cut
+
+sub county_state_country {
+  my $self = shift;
+  my $prefix = (@_ && $_[0]) ? shift : '';
+  my $label = $self->get($prefix.'country');
+  $label = $self->get($prefix.'state'). ", $label"
+    if $self->get($prefix.'state');
+  $label = $self->get($prefix.'county')." County, $label"
+    if $self->get($prefix.'county');
+  $label;
+}
+
 =item geocode DATA_VENDOR
 
 Returns a value for the customer location as encoded by DATA_VENDOR.

-----------------------------------------------------------------------

Summary of changes:
 FS/FS/cust_main.pm |   17 +++++++++++++++++
 1 files changed, 17 insertions(+), 0 deletions(-)




More information about the freeside-commits mailing list