projects
/
freeside.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
initial h2xs
[freeside.git]
/
site_perl
/
cust_main_invoice.pm
diff --git
a/site_perl/cust_main_invoice.pm
b/site_perl/cust_main_invoice.pm
index
61edae9
..
2823294
100644
(file)
--- a/
site_perl/cust_main_invoice.pm
+++ b/
site_perl/cust_main_invoice.pm
@@
-86,7
+86,7
@@
returns the error, otherwise returns false.
sub replace {
my ( $new, $old ) = ( shift, shift );
sub replace {
my ( $new, $old ) = ( shift, shift );
- return "Can't change custnum!" unless $old->custnum
eq
$new->custnum;
+ return "Can't change custnum!" unless $old->custnum
==
$new->custnum;
$new->SUPER::replace;
}
$new->SUPER::replace;
}
@@
-105,13
+105,28
@@
sub check {
my $error = $self->ut_numbern('destnum')
|| $self->ut_number('custnum')
my $error = $self->ut_numbern('destnum')
|| $self->ut_number('custnum')
- || $self->
ut_text('dest')
+ || $self->
checkdest;
;
return $error if $error;
return "Unknown customer"
unless qsearchs('cust_main',{ 'custnum' => $self->custnum });
;
return $error if $error;
return "Unknown customer"
unless qsearchs('cust_main',{ 'custnum' => $self->custnum });
+ ''; #noerror
+}
+
+=item checkdest
+
+Checks the dest field only.
+
+=cut
+
+sub checkdest {
+ my $self = shift;
+
+ my $error = $self->ut_text('dest');
+ return $error if $error;
+
if ( $self->dest eq 'POST' ) {
#contemplate our navel
} elsif ( $self->dest =~ /^(\d+)$/ ) {
if ( $self->dest eq 'POST' ) {
#contemplate our navel
} elsif ( $self->dest =~ /^(\d+)$/ ) {
@@
-152,7
+167,7
@@
sub address {
=head1 VERSION
=head1 VERSION
-$Id: cust_main_invoice.pm,v 1.
4 1999-01-18 09:22:42
ivan Exp $
+$Id: cust_main_invoice.pm,v 1.
6 1999-01-25 12:26:10
ivan Exp $
=head1 BUGS
=head1 BUGS
@@
-168,7
+183,13
@@
added hfields
ivan@sisd.com 97-nov-13
$Log: cust_main_invoice.pm,v $
ivan@sisd.com 97-nov-13
$Log: cust_main_invoice.pm,v $
-Revision 1.4 1999-01-18 09:22:42 ivan
+Revision 1.6 1999-01-25 12:26:10 ivan
+yet more mod_perl stuff
+
+Revision 1.5 1999/01/18 21:58:05 ivan
+esthetic: eq and ne were used in a few places instead of == and !=
+
+Revision 1.4 1999/01/18 09:22:42 ivan
changes to track email addresses for email invoicing
Revision 1.3 1998/12/29 11:59:42 ivan
changes to track email addresses for email invoicing
Revision 1.3 1998/12/29 11:59:42 ivan