[freeside-commits] freeside/FS/FS cust_pay_void.pm,1.8,1.9

Ivan,,, ivan at wavetail.420.am
Sun Apr 4 16:37:35 PDT 2010


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

Modified Files:
	cust_pay_void.pm 
Log Message:
fix otaker upgrade

Index: cust_pay_void.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/cust_pay_void.pm,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -w -d -r1.8 -r1.9
--- cust_pay_void.pm	29 Mar 2010 00:23:07 -0000	1.8
+++ cust_pay_void.pm	4 Apr 2010 23:37:33 -0000	1.9
@@ -2,7 +2,7 @@
 
 use strict;
 use base qw( FS::otaker_Mixin FS::payinfo_Mixin FS::Record );
-use vars qw( @encrypted_fields );
+use vars qw( @encrypted_fields $otaker_upgrade_kludge );
 use Business::CreditCard;
 use FS::UID qw(getotaker);
 use FS::Record qw(qsearchs dbh fields); # qsearch );
@@ -14,6 +14,7 @@
 use FS::cust_pkg;
 
 @encrypted_fields = ('payinfo');
+$otaker_upgrade_kludge = 0;
 
 =head1 NAME
 
@@ -160,7 +161,8 @@
 =cut
 
 sub replace {
-   return "Can't modify voided payments!";
+   return "Can't modify voided payments!" unless $otaker_upgrade_kludge;
+   shift->SUPER::replace(@_);
 }
 
 =item check
@@ -238,6 +240,7 @@
 # Used by FS::Upgrade to migrate to a new database.
 sub _upgrade_data {  # class method
   my ($class, %opts) = @_;
+  local($otaker_upgrade_kludge) = 1;
   $class->_upgrade_otaker(%opts);
 }
 



More information about the freeside-commits mailing list