summaryrefslogtreecommitdiff
path: root/LedgerSMB
diff options
context:
space:
mode:
authoreinhverfr <einhverfr@4979c152-3d1c-0410-bac9-87ea11338e46>2006-11-13 00:36:55 +0000
committereinhverfr <einhverfr@4979c152-3d1c-0410-bac9-87ea11338e46>2006-11-13 00:36:55 +0000
commit4916d89c8b2e4436a9d017616a98382085316b19 (patch)
treefd374ca86a79636d67f0470ad7a161b50032a39b /LedgerSMB
parentd8e2262143ab259acafa27fc88c61ddcff7df42d (diff)
Fixing a few db connection bugs
git-svn-id: https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/trunk@539 4979c152-3d1c-0410-bac9-87ea11338e46
Diffstat (limited to 'LedgerSMB')
-rwxr-xr-xLedgerSMB/CT.pm10
-rwxr-xr-xLedgerSMB/IS.pm3
2 files changed, 6 insertions, 7 deletions
diff --git a/LedgerSMB/CT.pm b/LedgerSMB/CT.pm
index c3dcdf29..be768503 100755
--- a/LedgerSMB/CT.pm
+++ b/LedgerSMB/CT.pm
@@ -205,7 +205,7 @@ sub save_customer {
my ($self, $myconfig, $form) = @_;
# connect to database
- my $dbh = $form->dbconnect_noauto($myconfig);
+ my $dbh = $form->{dbh};
my $query;
my $sth;
my $null;
@@ -575,7 +575,7 @@ sub search {
my ($self, $myconfig, $form) = @_;
# connect to database
- my $dbh = $form->dbconnect($myconfig);
+ my $dbh = $form->{dbh};
my $where = "1 = 1";
$form->{sort} = ($form->{sort}) ? $form->{sort} : "name";
@@ -867,7 +867,7 @@ sub get_history {
my ($self, $myconfig, $form) = @_;
# connect to database
- my $dbh = $form->dbconnect($myconfig);
+ my $dbh = $form->{dbh};
my $query;
my $where = "1 = 1";
@@ -1114,7 +1114,7 @@ sub save_pricelist {
my ($self, $myconfig, $form) = @_;
- my $dbh = $form->dbconnect_noauto($myconfig);
+ my $dbh = $form->{dbh};
my $query = qq|
DELETE FROM parts$form->{db}
@@ -1187,7 +1187,7 @@ sub retrieve_item {
my ($self, $myconfig, $form) = @_;
# connect to database
- my $dbh = $form->dbconnect($myconfig);
+ my $dbh = $form->{dbh};
my $i = $form->{rowcount};
my $var;
diff --git a/LedgerSMB/IS.pm b/LedgerSMB/IS.pm
index dd293759..39bcfe7c 100755
--- a/LedgerSMB/IS.pm
+++ b/LedgerSMB/IS.pm
@@ -1862,8 +1862,7 @@ sub retrieve_invoice {
sub retrieve_item {
my ($self, $myconfig, $form) = @_;
- # connect to database
- my $dbh = $form->dbconnect($myconfig);
+ my $dbh = $form->{dbh};
my $i = $form->{rowcount};
my $null;