Atualização Companies.class.php

This commit is contained in:
Kenio 2025-07-29 15:25:34 -03:00
parent 32028500cc
commit 006ae4b70f

View file

@ -121,7 +121,7 @@ class Companies
$this->start = $start;
$this->max = $max;
$this->typeSearch = $typeSearch;
$this->search = $search;
$this->search = '%'.$search.'%';
/** Verifico se há paginação */
if($this->max){
@ -166,7 +166,7 @@ class Companies
if($this->typeSearch && $this->search){
/** Preencho os parâmetros do SQL */
$this->stmt->bindParam(':search', '%' . $this->search . '%');
$this->stmt->bindParam(':search', $this->search);
}
@ -182,7 +182,7 @@ class Companies
public function Count(?int $typeSearch, ?string $search)
{
$this->typeSearch = $typeSearch;
$this->search = $search;
$this->search = '%'.$search.'%';
/** Consulta SQL */
$this->sql = 'select count(c.company_id) as qtde
@ -221,7 +221,7 @@ class Companies
if($this->typeSearch && $this->search){
/** Preencho os parâmetros do SQL */
$this->stmt->bindParam(':search', '%' . $this->search . '%' );
$this->stmt->bindParam(':search', $this->search);
}