From 429a48b18a54917b73b3add468d930f60bcdb2fe Mon Sep 17 00:00:00 2001 From: Mark Wells Date: Tue, 7 Jan 2014 12:19:59 -0800 Subject: [PATCH] fix method name conflicts, related to #13971 --- FS/FS/cust_bill.pm | 2 +- FS/FS/cust_bill_event.pm | 2 +- FS/FS/cust_credit.pm | 2 +- FS/FS/cust_event.pm | 2 +- FS/FS/cust_pay.pm | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/FS/FS/cust_bill.pm b/FS/FS/cust_bill.pm index 1569ef48c..9a971dd3a 100644 --- a/FS/FS/cust_bill.pm +++ b/FS/FS/cust_bill.pm @@ -158,7 +158,7 @@ sub notice_name { $self->conf->config('notice_name') || 'Invoice' } -sub cust_linked { $_[0]->cust_main_custnum; } +sub cust_linked { $_[0]->cust_main_custnum || $_[0]->custnum } sub cust_unlinked_msg { my $self = shift; "WARNING: can't find cust_main.custnum ". $self->custnum. diff --git a/FS/FS/cust_bill_event.pm b/FS/FS/cust_bill_event.pm index 36afed040..c91283b69 100644 --- a/FS/FS/cust_bill_event.pm +++ b/FS/FS/cust_bill_event.pm @@ -83,7 +83,7 @@ points to. You can ask the object for a copy with the I method. sub table { 'cust_bill_event'; } -sub cust_linked { $_[0]->cust_main_custnum; } +sub cust_linked { $_[0]->cust_main_custnum || $_[0]->custnum } sub cust_unlinked_msg { my $self = shift; "WARNING: can't find cust_main.custnum ". $self->custnum. diff --git a/FS/FS/cust_credit.pm b/FS/FS/cust_credit.pm index 7845a205a..df59950ea 100644 --- a/FS/FS/cust_credit.pm +++ b/FS/FS/cust_credit.pm @@ -123,7 +123,7 @@ Creates a new credit. To add the credit to the database, see L<"insert">. =cut sub table { 'cust_credit'; } -sub cust_linked { $_[0]->cust_main_custnum; } +sub cust_linked { $_[0]->cust_main_custnum || $_[0]->custnum } sub cust_unlinked_msg { my $self = shift; "WARNING: can't find cust_main.custnum ". $self->custnum. diff --git a/FS/FS/cust_event.pm b/FS/FS/cust_event.pm index 78d421770..b29ab71bb 100644 --- a/FS/FS/cust_event.pm +++ b/FS/FS/cust_event.pm @@ -73,7 +73,7 @@ points to. You can ask the object for a copy with the I method. sub table { 'cust_event'; } -sub cust_linked { $_[0]->cust_main_custnum; } +sub cust_linked { $_[0]->cust_main_custnum || $_[0]->custnum } sub cust_unlinked_msg { my $self = shift; "WARNING: can't find cust_main.custnum ". $self->custnum; diff --git a/FS/FS/cust_pay.pm b/FS/FS/cust_pay.pm index a7b91083f..ed765593a 100644 --- a/FS/FS/cust_pay.pm +++ b/FS/FS/cust_pay.pm @@ -169,7 +169,7 @@ Creates a new payment. To add the payment to the databse, see L<"insert">. =cut sub table { 'cust_pay'; } -sub cust_linked { $_[0]->cust_main_custnum; } +sub cust_linked { $_[0]->cust_main_custnum || $_[0]->custnum; } sub cust_unlinked_msg { my $self = shift; "WARNING: can't find cust_main.custnum ". $self->custnum. -- 2.11.0