projects
/
kivitendo-erp.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
02d2708
)
CT: single-dbh disconnects
author
Sven Schöling
<s.schoeling@linet-services.de>
Thu, 8 Sep 2016 14:49:36 +0000
(16:49 +0200)
committer
Sven Schöling
<s.schoeling@linet-services.de>
Thu, 8 Sep 2016 14:49:36 +0000
(16:49 +0200)
SL/CT.pm
patch
|
blob
|
history
diff --git
a/SL/CT.pm
b/SL/CT.pm
index
d8497d0
..
e4b1ee0
100644
(file)
--- a/
SL/CT.pm
+++ b/
SL/CT.pm
@@
-40,6
+40,7
@@
package CT;
use SL::Common;
use SL::CVar;
use SL::DBUtils;
+use SL::DB;
use Text::ParseWords;
use strict;
@@
-341,7
+342,7
@@
sub get_contact {
die 'Missing argument: cp_id' unless $::form->{cp_id};
- my $dbh =
$form->dbconnect($myconfig)
;
+ my $dbh =
SL::DB->client->dbh
;
my $query =
qq|SELECT * FROM contacts c | .
qq|WHERE cp_id = ? ORDER BY cp_id limit 1|;
@@
-359,7
+360,6
@@
sub get_contact {
($form->{cp_used}) = selectfirst_array_query($form, $dbh, $query, ($form->{cp_id})x2);
$sth->finish;
- $dbh->disconnect;
$main::lxdebug->leave_sub();
}