Skip to content
Snippets Groups Projects
Commit 58b0fe68 authored by Fernando Erd's avatar Fernando Erd :ok_hand:
Browse files

Merge remote-tracking branch 'origin/v1.11.14'

parents 88cc8831 ce30a2e3
No related branches found
No related tags found
1 merge request!233[v1.11.14]OCDE updated
Pipeline #21547 failed
......@@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](http://keepachangelog.com/)
and this project adheres to [Semantic Versioning](http://semver.org/).
## 1.11.14 - 2019-10-13
## Changed
- OCDE updated
## 1.11.13 - 2019-09-11
## Changed
- Classroom with dim location and city filter, will always return both locations
......
......@@ -345,32 +345,32 @@ rqf.addField({
}).addValue({
name:'ocde_specific',
table: 'aluno_ens_superior',
tableField: 'cod_ocde_area_especifica',
tableField: 'par_cod_ocde_area_especifica',
resultField: 'ocde_specific_id',
where: {
relation: '=',
type: 'integer',
field: 'cod_ocde_area_especifica'
field: 'par_cod_ocde_area_especifica'
}
}).addValue({
name:'ocde_geral',
table: 'aluno_ens_superior',
tableField: 'cod_ocde_area_geral',
tableField: 'par_cod_ocde_area_geral',
resultField: 'ocde_geral_id',
where: {
relation: '=',
type: 'integer',
field: 'cod_ocde_area_geral'
field: 'par_cod_ocde_area_geral'
}
}).addValue({
name:'ocde_detailed',
table: 'aluno_ens_superior',
tableField: 'cod_ocde_area_detalhada',
tableField: 'par_cod_ocde_area_detalhada',
resultField: 'ocde_detailed_id',
where: {
relation: '=',
type: 'integer',
field: 'cod_ocde_area_detalhada'
field: 'par_cod_ocde_area_detalhada'
}
}).addValue({
name:'academic_level',
......@@ -465,15 +465,28 @@ rqf.addField({
});
universityEnrollmentApp.get('/', rqf.parse(), (req, res, next) => {
req.sql.field('COUNT(*)', 'total')
.field("'Brasil'", 'name')
.field('aluno_ens_superior.ano_censo', 'year')
.from('aluno_ens_superior')
.where('aluno_ens_superior.matriculado = 1 AND aluno_ens_superior.cod_nivel_academico = 1')
.group('aluno_ens_superior.ano_censo')
.order('aluno_ens_superior.ano_censo')
if ("university" in req.dims) {
req.sql.field('COUNT(*)', 'total')
.field("'Brasil'", 'name')
.field('aluno_ens_superior.ano_censo', 'year')
.from('aluno_ens_superior')
.where('aluno_ens_superior.matriculado = 1 AND aluno_ens_superior.cod_nivel_academico = 1')
.group('aluno_ens_superior.cod_ies')
.group('aluno_ens_superior.ano_censo')
.order('aluno_ens_superior.cod_ies')
.order('aluno_ens_superior.ano_censo')
} else {
req.sql.field('COUNT(*)', 'total')
.field("'Brasil'", 'name')
.field('aluno_ens_superior.ano_censo', 'year')
.from('aluno_ens_superior')
.where('aluno_ens_superior.matriculado = 1 AND aluno_ens_superior.cod_nivel_academico = 1')
.group('aluno_ens_superior.ano_censo')
.order('aluno_ens_superior.ano_censo')
}
next();
}, rqf.build(), query, addMissing(rqf), id2str.transform(false), response('universityEnrollment'));
module.exports = universityEnrollmentApp;
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