$id = mysql_fetch_array($queryVerif)['id']; /********************************* MOSTRAR INFORMAÇÕES DO RELATÓRIO *********************************/ $uo = new Unidade($id); $tpl->UOSIGLA = $uo->getSigla(); $tpl->UONOME = $uo->getNome(); $uoTipoServicos = $uo->getTiposServicos(); $tpl->UOUCQTD = $uo->getQtdUc(); $tpl->ANO_ATU = $anoAtual; $tpl->TIPOSSERVICOS = ""; $z = 0; if (count($uoTipoServicos) > 0) { foreach ($uoTipoServicos as $tipo) { $ucTipo = new UnidadeConsumidora(0, null, null, null, null, null, null, null, null, null, null, $tipo); $mesmoTipo = $uo->getUcPorTipo($tipo); $tpl->TIPOSSERVICOS .= "<br /> - <b><font color='navy'>" . $ucTipo->getTipoNome() . "</font></b>: <a href='udd_uoCharts.php?chave=" . $_GET['chave'] . "&svc={$tipo}&start=" . $anoAtual . "'>"; $tpl->TIPOSSERVICOS .= "Relatório " . $anoAtual . " de " . count($mesmoTipo) . " UC(s)</a>"; $tpl->TIPOSERVICO = $ucTipo->getTipoNome(); $tpl->CHART_VALOR = $uo->getTotalPorTipo($tipo, $anoAtual); if ($z < count($uoTipoServicos)) { $tpl->COMA1 = ","; } else { $tpl->COMA1 = ""; } $z++; $tpl->block('EACH_CHART_SERVICO'); $tipoVal[$tipo]['nome'] = $ucTipo->getTipoNome(); $tipoVal[$tipo]['mes'][1] = 0; $tipoVal[$tipo]['mes'][2] = 0; $tipoVal[$tipo]['mes'][3] = 0;