changed by ->db inside ticket.class.php
This commit is contained in:
parent
d1b5fc6bc1
commit
f362c66b28
@ -3038,7 +3038,7 @@ class Ticket extends CommonObject
|
||||
*/
|
||||
public function removeClosedContact($to)
|
||||
{
|
||||
global $db, $langs;
|
||||
global $langs;
|
||||
$langs->load("ticket");
|
||||
|
||||
if (isset($this->id)) {
|
||||
@ -3048,11 +3048,11 @@ class Ticket extends CommonObject
|
||||
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."socpeople sc on (ec.fk_socpeople = sc.rowid AND tc.source = 'external')";
|
||||
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."user u on (ec.fk_socpeople = u.rowid AND tc.source = 'internal')";
|
||||
$sql .= " WHERE IF(tc.source = 'external', sc.statut = 1, u.statut = 1)";
|
||||
$resql = $db->query($sql);
|
||||
$resql = $this->db->query($sql);
|
||||
if ($resql) {
|
||||
$num = $db->num_rows($resql);
|
||||
$num = $this->db->num_rows($resql);
|
||||
for ($i = 0; $num > $i; $i++) {
|
||||
$non_closed_contacts[] = $db->fetch_row($resql);
|
||||
$non_closed_contacts[] = $this->db->fetch_row($resql);
|
||||
}
|
||||
}
|
||||
$to = array_filter($to, function($v, $k) use($non_closed_contacts, $langs) {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user