X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=FS%2FFS%2FUID.pm;h=d3ee8d81031b40e09abf9741fb55bc91338d1418;hb=368ed08e24400e9d1faf401a1e4e23ea54d2c969;hp=50a9178951315c20fd44838a1ec4fefb9a3ab13a;hpb=f68d7f0bf0dbf710fc0b03408723129a543838a3;p=freeside.git diff --git a/FS/FS/UID.pm b/FS/FS/UID.pm index 50a917895..d3ee8d810 100644 --- a/FS/FS/UID.pm +++ b/FS/FS/UID.pm @@ -5,7 +5,7 @@ use strict; use vars qw( @EXPORT_OK $DEBUG $me $cgi $freeside_uid $conf_dir $cache_dir $secrets $datasrc $db_user $db_pass $schema $dbh $driver_name - $AutoCommit %callback @callback $callback_hack + $AutoCommit $ForceObeyAutoCommit %callback @callback $callback_hack ); use subs qw( getsecrets ); use Carp qw( carp croak cluck confess ); @@ -26,7 +26,17 @@ $freeside_uid = scalar(getpwnam('freeside')); $conf_dir = "%%%FREESIDE_CONF%%%"; $cache_dir = "%%%FREESIDE_CACHE%%%"; +# Code wanting to issue a COMMIT statement to the database is expected to +# obey the convention of checking this flag first. Setting $AutoCommit = 0 +# should (usually) suppress COMMIT statements. $AutoCommit = 1; #ours, not DBI + +# Not all methods obey $AutoCommit, by design choice. Setting +# $ForceObeyAutoCommit = 1 will override that design choice for: +# &FS::cust_main::Billing::collect +# &FS::cust_main::Billing::do_cust_event +$ForceObeyAutoCommit = 0; + $callback_hack = 0; =head1 NAME @@ -210,7 +220,7 @@ sub install_callback { =item cgi -Returns the CGI (see L) object. +(Deprecated) Returns the CGI (see L) object. =cut @@ -220,9 +230,9 @@ sub cgi { $cgi; } -=item cgi CGI_OBJECT +=item setcgi CGI_OBJECT -Sets the CGI (see L) object. +(Deprecated) Sets the CGI (see L) object. =cut