GWM : acm name not display issue

This commit is contained in:
Gowtham M 2026-01-03 16:06:21 +05:30
parent 332c412d0f
commit 85017b002e

View File

@ -234,8 +234,24 @@ class ThzController extends BaseController
->where('thz_master.thz_id', $thz_id)
->findAll();
$clientId = $result['master'][0]['client_id'];
$accManagerId = $this->getAcmIdUsingClientId($clientId ?? null);
$accManager = $this->userModel->find($accManagerId);
if (!empty($result['master'])) {
$notes = $this->thzMasterNotesModel->ticketConversationList($thz_id, $returnType);
$accManagerName = $accManager['first_name'] ?? '';
foreach ($notes as &$note) {
if (empty($note['name'])) {
$note['name'] = $accManagerName;
}
}
unset($note);
$result['notes'] = !empty($notes) ? $notes : [];
} else {
$this->myLogger->logme('error', 'No tickets found for ticket id ' . json_encode($thz_id));