X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=FS%2FFS%2Fcust_main.pm;h=0a93764c175097500521c8791eb352363b355278;hb=32072dbf59a054529f5304574c0f56f9567d14d0;hp=a1d7d87d0b959c6a9080ff2cb75bad2e38cfca81;hpb=66c235e33563ccd785ff9e0828398f778a75fb9f;p=freeside.git diff --git a/FS/FS/cust_main.pm b/FS/FS/cust_main.pm index a1d7d87d0..0a93764c1 100644 --- a/FS/FS/cust_main.pm +++ b/FS/FS/cust_main.pm @@ -1,10 +1,9 @@ package FS::cust_main; - -require 5.006; -use strict; -use base qw( FS::cust_main::Packages FS::cust_main::Status +use base qw( FS::cust_main::Packages + FS::cust_main::Status FS::cust_main::NationalID - FS::cust_main::Billing FS::cust_main::Billing_Realtime + FS::cust_main::Billing + FS::cust_main::Billing_Realtime FS::cust_main::Billing_Discount FS::cust_main::Billing_ThirdParty FS::cust_main::Location @@ -13,6 +12,9 @@ use base qw( FS::cust_main::Packages FS::cust_main::Status FS::o2m_Common FS::Record ); + +require 5.006; +use strict; use vars qw( $DEBUG $me $conf @encrypted_fields $import @@ -60,7 +62,6 @@ use FS::cust_class; use FS::cust_main_exemption; use FS::cust_tax_adjustment; use FS::cust_tax_location; -use FS::agent; use FS::agent_currency; use FS::cust_main_invoice; use FS::cust_tag; @@ -2100,7 +2101,7 @@ Returns all locations (see L) for this customer. sub cust_location { my $self = shift; - qsearch('cust_location', { 'custnum' => $self->custnum, + qsearch('cust_location', { 'custnum' => $self->custnum, 'prospectnum' => '' } ); } @@ -2330,13 +2331,6 @@ sub notes { Returns the agent (see L) for this customer. -=cut - -sub agent { - my $self = shift; - qsearchs( 'agent', { 'agentnum' => $self->agentnum } ); -} - =item agent_name Returns the agent name (see L) for this customer. @@ -2353,13 +2347,6 @@ sub agent_name { Returns any tags associated with this customer, as FS::cust_tag objects, or an empty list if there are no tags. -=cut - -sub cust_tag { - my $self = shift; - qsearch('cust_tag', { 'custnum' => $self->custnum } ); -} - =item part_tag Returns any tags associated with this customer, as FS::part_tag objects, @@ -2378,17 +2365,6 @@ sub part_tag { Returns the customer class, as an FS::cust_class object, or the empty string if there is no customer class. -=cut - -sub cust_class { - my $self = shift; - if ( $self->classnum ) { - qsearchs('cust_class', { 'classnum' => $self->classnum } ); - } else { - return ''; - } -} - =item categoryname Returns the customer category name, or the empty string if there is no customer @@ -3062,13 +3038,6 @@ sub tax_exemption { =item cust_main_exemption -=cut - -sub cust_main_exemption { - my $self = shift; - qsearch( 'cust_main_exemption', { 'custnum' => $self->custnum } ); -} - =item invoicing_list [ ARRAYREF ] If an arguement is given, sets these email addresses as invoice recipients