Update admin_functions and common from HESK 2.8.2
This commit is contained in:
parent
e3d4fc89dc
commit
4418a36ccf
@ -222,10 +222,10 @@ function hesk_mergeTickets($merge_these, $merge_into)
|
||||
$total = 0;
|
||||
$staffreplies = 0;
|
||||
|
||||
$res = hesk_dbQuery("SELECT COUNT(*) as `cnt`, `staffid` FROM `" . hesk_dbEscape($hesk_settings['db_pfix']) . "replies` WHERE `replyto`=" . intval($ticket['id']) . " GROUP BY CASE WHEN `staffid` = 0 THEN 0 ELSE 1 END ASC");
|
||||
$res = hesk_dbQuery("SELECT COUNT(*) as `cnt`, (CASE WHEN `staffid` = 0 THEN 0 ELSE 1 END) AS `staffcnt` FROM `" . hesk_dbEscape($hesk_settings['db_pfix']) . "replies` WHERE `replyto`=" . intval($ticket['id']) . " GROUP BY CASE WHEN `staffid` = 0 THEN 0 ELSE 1 END ASC");
|
||||
while ($row = hesk_dbFetchAssoc($res)) {
|
||||
$total += $row['cnt'];
|
||||
$staffreplies += ($row['staffid'] ? $row['cnt'] : 0);
|
||||
$staffreplies += ($row['staffcnt'] ? $row['cnt'] : 0);
|
||||
}
|
||||
|
||||
$replies_sql = " `replies`={$total}, `staffreplies`={$staffreplies} , ";
|
||||
|
@ -390,7 +390,7 @@ function hesk_mb_strlen($in)
|
||||
} // END hesk_mb_strlen()
|
||||
|
||||
function hesk_mb_strtolower($in) {
|
||||
return function_exists('mb_strtolower') ? mb_strtolower($in) : strtolower($in);
|
||||
return function_exists('mb_strtolower') ? mb_strtolower($in, 'UTF-8') : strtolower($in);
|
||||
} // END hesk_mb_strtolower()
|
||||
|
||||
function hesk_ucfirst($in) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user