Commit 248e8926446a7efcb43ce44a0c59b146996f7c95
1 parent
90519d64
Exists in
master
Ajustado bug ao buscar CEP;
* Ajustado dados de conexão com o banco; portabilis/ieducar#195
Showing
3 changed files
with
4 additions
and
4 deletions
Show diff stats
ieducar/configuration/ieducar.ini
@@ -54,7 +54,7 @@ | @@ -54,7 +54,7 @@ | ||
54 | ; Configurações de banco de dados | 54 | ; Configurações de banco de dados |
55 | app.database.dbname = ieducar | 55 | app.database.dbname = ieducar |
56 | app.database.username = postgres | 56 | app.database.username = postgres |
57 | -app.database.hostname = postgres95 | 57 | +app.database.hostname = localhost |
58 | app.database.password = postgres | 58 | app.database.password = postgres |
59 | app.database.port = 5432 | 59 | app.database.port = 5432 |
60 | 60 |
ieducar/intranet/educar_pesquisa_cep_log_bairro.php
@@ -165,13 +165,13 @@ class miolo1 extends clsListagem | @@ -165,13 +165,13 @@ class miolo1 extends clsListagem | ||
165 | $paramCount = 1; | 165 | $paramCount = 1; |
166 | 166 | ||
167 | foreach ($params as $name => $value) { | 167 | foreach ($params as $name => $value) { |
168 | - $select .= " AND $name ILIKE '%'||\$$paramCount||'%'"; | 168 | + $select .= " AND $name::varchar ILIKE '%'||\$$paramCount||'%'"; |
169 | $paramCount++; | 169 | $paramCount++; |
170 | } | 170 | } |
171 | 171 | ||
172 | $total = Portabilis_Utils_Database::selectField(' SELECT COUNT(0) '.$select, array('params' => array_values($params))); | 172 | $total = Portabilis_Utils_Database::selectField(' SELECT COUNT(0) '.$select, array('params' => array_values($params))); |
173 | 173 | ||
174 | - $select .= sprintf(' LIMIT %s OFFSET %s', $limite, $iniciolimit); | 174 | + $select .= sprintf(' LIMIT %s OFFSET %s', $limite, $iniciolimit); |
175 | 175 | ||
176 | $result = Portabilis_Utils_Database::fetchPreparedQuery($pre_select.$select, array('params' => array_values($params))); | 176 | $result = Portabilis_Utils_Database::fetchPreparedQuery($pre_select.$select, array('params' => array_values($params))); |
177 | 177 |