Commit 972276da753434dcbe150af3ade013d1cc0ff9f7
1 parent
d5f5a29b
Exists in
master
Atualizado relatório "Espelho de notas" para buscar os componentes através da AP…
…I de {{{App_Model_IedFinder}}}
Showing
1 changed file
with
6 additions
and
11 deletions
Show diff stats
ieducar/intranet/educar_relatorio_alunos_nota_semestre_proc.php
@@ -34,6 +34,7 @@ require_once 'include/clsBanco.inc.php'; | @@ -34,6 +34,7 @@ require_once 'include/clsBanco.inc.php'; | ||
34 | require_once 'include/pmieducar/geral.inc.php'; | 34 | require_once 'include/pmieducar/geral.inc.php'; |
35 | require_once 'include/relatorio.inc.php'; | 35 | require_once 'include/relatorio.inc.php'; |
36 | 36 | ||
37 | +require_once 'App/Model/IedFinder.php'; | ||
37 | require_once 'Avaliacao/Service/Boletim.php'; | 38 | require_once 'Avaliacao/Service/Boletim.php'; |
38 | 39 | ||
39 | /** | 40 | /** |
@@ -179,9 +180,10 @@ class indice extends clsCadastro | @@ -179,9 +180,10 @@ class indice extends clsCadastro | ||
179 | $this->ref_cod_curso, $this->ref_cod_escola, $this->ref_cod_instituicao, | 180 | $this->ref_cod_curso, $this->ref_cod_escola, $this->ref_cod_instituicao, |
180 | NULL, NULL, array(1,2,3), NULL, NULL, $this->ano, NULL, NULL, NULL, NULL, TRUE); | 181 | NULL, NULL, array(1,2,3), NULL, NULL, $this->ano, NULL, NULL, NULL, NULL, TRUE); |
181 | 182 | ||
182 | - $obj_disciplinas = new clsPmieducarEscolaSerieDisciplina(); | ||
183 | - $lst_disciplinas = $obj_disciplinas->lista($this->ref_cod_serie, | ||
184 | - $this->ref_cod_escola, NULL, 1); | 183 | + // Recupera os componentes curriculares da turma |
184 | + $componentes = App_Model_IedFinder::getComponentesTurma( | ||
185 | + $this->ref_cod_serie, $this->ref_cod_escola, $this->ref_cod_turma | ||
186 | + ); | ||
185 | 187 | ||
186 | // Recupera a quantidade de módulos e o nome do módulo da escola/turma | 188 | // Recupera a quantidade de módulos e o nome do módulo da escola/turma |
187 | $modulo = App_Model_IedFinder::getModulo($this->ref_cod_escola, | 189 | $modulo = App_Model_IedFinder::getModulo($this->ref_cod_escola, |
@@ -198,9 +200,6 @@ class indice extends clsCadastro | @@ -198,9 +200,6 @@ class indice extends clsCadastro | ||
198 | $relatorio->setMargem(20, 20, 20, 20); | 200 | $relatorio->setMargem(20, 20, 20, 20); |
199 | $relatorio->exibe_produzido_por = FALSE; | 201 | $relatorio->exibe_produzido_por = FALSE; |
200 | 202 | ||
201 | - // Mapper para o componente | ||
202 | - $componenteMapper = new ComponenteCurricular_Model_ComponenteDataMapper(); | ||
203 | - | ||
204 | $array_val = array( | 203 | $array_val = array( |
205 | array(40, 'Cód.'), | 204 | array(40, 'Cód.'), |
206 | array(160, 'Nome do Aluno') | 205 | array(160, 'Nome do Aluno') |
@@ -225,10 +224,7 @@ class indice extends clsCadastro | @@ -225,10 +224,7 @@ class indice extends clsCadastro | ||
225 | 224 | ||
226 | $arrFunc = create_function('$data, $index', $arrFuncBody); | 225 | $arrFunc = create_function('$data, $index', $arrFuncBody); |
227 | 226 | ||
228 | - foreach ($lst_disciplinas as $k => $disciplina) { | ||
229 | - $componenteId = $disciplina['ref_cod_disciplina']; | ||
230 | - $componente = $componenteMapper->find($componenteId); | ||
231 | - | 227 | + foreach ($componentes as $componente) { |
232 | $relatorio->novalinha(array($componente->nome), 0, 16, | 228 | $relatorio->novalinha(array($componente->nome), 0, 16, |
233 | TRUE, 'arial', array(400), '#515151', '#D3D3D3', '#FFFFFF', FALSE, TRUE); | 229 | TRUE, 'arial', array(400), '#515151', '#D3D3D3', '#FFFFFF', FALSE, TRUE); |
234 | 230 | ||
@@ -242,7 +238,6 @@ class indice extends clsCadastro | @@ -242,7 +238,6 @@ class indice extends clsCadastro | ||
242 | if (!isset($this->boletim[$codMatricula])) { | 238 | if (!isset($this->boletim[$codMatricula])) { |
243 | $boletim = new Avaliacao_Service_Boletim(array( | 239 | $boletim = new Avaliacao_Service_Boletim(array( |
244 | 'matricula' => $codMatricula, | 240 | 'matricula' => $codMatricula, |
245 | - 'ComponenteDataMapper' => $componenteMapper, | ||
246 | 'RegraDataMapper' => $regraMapper | 241 | 'RegraDataMapper' => $regraMapper |
247 | )); | 242 | )); |
248 | } | 243 | } |