[freeside-commits] freeside/FS/FS cust_pkg.pm, 1.204.2.16, 1.204.2.17

Mark Wells mark at wavetail.420.am
Fri Jan 13 02:15:43 PST 2012


Update of /home/cvs/cvsroot/freeside/FS/FS
In directory wavetail.420.am:/tmp/cvs-serv19011/FS/FS

Modified Files:
      Tag: FREESIDE_2_3_BRANCH
	cust_pkg.pm 
Log Message:
package location change bugfix

Index: cust_pkg.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/cust_pkg.pm,v
retrieving revision 1.204.2.16
retrieving revision 1.204.2.17
diff -u -w -d -r1.204.2.16 -r1.204.2.17
--- cust_pkg.pm	27 Dec 2011 01:07:31 -0000	1.204.2.16
+++ cust_pkg.pm	13 Jan 2012 10:15:41 -0000	1.204.2.17
@@ -1350,12 +1350,16 @@
     $hash{$_} = '' foreach qw(setup bill last_bill);
   }
 
+  # allow $opt->{'locationnum'} = '' to specifically set it to null
+  # (i.e. customer default location)
+  $opt->{'locationnum'} = $self->locationnum if !exists($opt->{'locationnum'});
+
   # Create the new package.
   my $cust_pkg = new FS::cust_pkg {
     custnum      => $self->custnum,
     pkgpart      => ( $opt->{'pkgpart'}     || $self->pkgpart      ),
     refnum       => ( $opt->{'refnum'}      || $self->refnum       ),
-    locationnum  => ( $opt->{'locationnum'} || $self->locationnum  ),
+    locationnum  => ( $opt->{'locationnum'}                        ),
     %hash,
   };
 



More information about the freeside-commits mailing list