Skip to content

Commit

Permalink
Changes in customer search tickets: uvdesk#195
Browse files Browse the repository at this point in the history
  • Loading branch information
Abhi12-gupta committed Jun 19, 2023
1 parent 3cd0716 commit c692d2f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Repository/TicketRepository.php
Original file line number Diff line number Diff line change
Expand Up @@ -156,9 +156,9 @@ public function getAllCustomerTickets(ParameterBag $obj = null, $container, $act
if(!in_array($key,$this->safeFields)) {
if(isset($data['search']) && $key == 'search') {
$qb->andwhere("t.subject LIKE :subject OR a.email LIKE :agentName OR t.id LIKE :ticketId");
$qb->setParameter('subject', '%'.urldecode($value).'%');
$qb->setParameter('agentName', '%'.urldecode($value).'%');
$qb->setParameter('ticketId', '%'.urldecode($value).'%');
$qb->setParameter('subject', '%'.urldecode(trim($value)).'%');
$qb->setParameter('agentName', '%'.urldecode(trim($value)).'%');
$qb->setParameter('ticketId', '%'.urldecode(trim($value)).'%');
} elseif($key == 'status') {
$qb->andwhere('t.status = '.intval($value));
}
Expand Down Expand Up @@ -216,7 +216,7 @@ public function getAllCustomerTickets(ParameterBag $obj = null, $container, $act
}

$json['tickets'] = $data;

$json['pagination'] = $paginationData;

return $json;
Expand Down

0 comments on commit c692d2f

Please sign in to comment.