diff --git a/src/controllers/tombos-controller.js b/src/controllers/tombos-controller.js index 3be9709..7c780f4 100644 --- a/src/controllers/tombos-controller.js +++ b/src/controllers/tombos-controller.js @@ -8,6 +8,10 @@ import { converteParaDecimal, converteDecimalParaGraus, converteDecimalParaGMSGrau, converteDecimalParaGMSMinutos, converteDecimalParaGMSSegundos, } from '../helpers/coordenadas'; import pick from '../helpers/pick'; + +const SRID = { + SIRGAS_2000: 4674, +}; import { converteInteiroParaRomano } from '../helpers/tombo'; import models from '../models'; import codigos from '../resources/codigos-http'; @@ -1761,7 +1765,7 @@ export const verificarCoordenada = async (request, response, next) => { const query = ` SELECT ST_Contains( poligono, - ST_SetSRID(ST_POINT($1, $2), 4674) + ST_SetSRID(ST_POINT($1, $2), ${SRID.SIRGAS_2000}) ) AS dentro FROM cidades WHERE id = $3;