Skip to content
Snippets Groups Projects
Commit 9bf441c3 authored by Vytor Calixto's avatar Vytor Calixto :space_invader:
Browse files

Add new filter to school route

Add school building filter
Related: simcaq/SCRUM#430
parent 7ba4aac4
No related branches found
No related tags found
No related merge requests found
......@@ -452,6 +452,16 @@ rqfCount.addField({
type: 'integer',
field: 'ano_censo'
}
}).addValue({
name: 'school_building',
table: 'escola',
tableField: 'local_func_predio_escolar',
resultField: 'school_building',
where: {
relation: '=',
type: 'boolean',
field: 'local_func_predio_escolar'
}
});
schoolApp.get('/', rqf.parse(), rqf.build(), (req, res, next) => {
if(typeof req.filter === 'undefined' || Object.keys(req.filter).length === 0) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment