daniel.zauli 2017-12-14 19:15:32 +00:00
parent 393e884267
commit ceb182b295
3 changed files with 35 additions and 35 deletions

View File

@ -102,7 +102,7 @@ public class RelatorioDemandasDetalhadoNovoLayout extends RelatorioDemandas {
sql.append("group by co.feccorrida, co.fechorsalida, r.descruta, r.numruta, co.corrida_id, ");
sql.append(" case when ((ori.indvisibleinternet is null or ori.indvisibleinternet = 1) ");
sql.append(" and (des.indvisibleinternet is null or des.indvisibleinternet = 1)) then 'SIM' else 'NÃO' end, ");
sql.append(" bo.fechorviaje, ori.descparada, des.descparada, cs.descclase, ");
sql.append(" ori.descparada, des.descparada, cs.descclase, ");
sql.append(" da.cantasientos, ts.descservicio, ct.plataforma, e.nombempresa, r.INDSENTIDOIDA ");
sql.append("order by e.nombempresa, data, linha, servico, origem, destino ");
@ -180,7 +180,7 @@ public class RelatorioDemandasDetalhadoNovoLayout extends RelatorioDemandas {
sql.append(" from ( ");
sql.append(" select * from vendidos v union select * from nao_vendidos ) ");
sql.append(" GROUP BY DATA_CORRIDA, DATA, LINHA, CODLINHA, SERVICO, INTERNET, HORARIO, ORIGEM, DESTINO, CLASSE, CAPACIDADE, OCUPACAO, TIPO_SERVICO, PLATAFORMA, EMPRESA, SENTIDO ");
sql.append(" order by empresa ");
sql.append(" order by empresa, servico ");
NamedParameterStatement stmt = new NamedParameterStatement(conexao, sql.toString());

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<jasperReport xmlns="http://jasperreports.sourceforge.net/jasperreports" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports http://jasperreports.sourceforge.net/xsd/jasperreport.xsd" name="RelatorioDemandasDetalhadoNovoLayout" pageWidth="842" pageHeight="595" orientation="Landscape" whenNoDataType="NoDataSection" columnWidth="842" leftMargin="0" rightMargin="0" topMargin="20" bottomMargin="20" uuid="b92fb063-a827-4619-8a69-5c78e3afbb8c">
<property name="ireport.zoom" value="3.2210200000000144"/>
<property name="ireport.x" value="1721"/>
<property name="ireport.x" value="0"/>
<property name="ireport.y" value="0"/>
<style name="textStyle" isDefault="true" fontSize="6" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false"/>
<style name="table">
@ -48,7 +48,7 @@
<field name="INTERNET" class="java.lang.String"/>
<field name="SENTIDO" class="java.lang.String"/>
<variable name="POR_OCUPACAO" class="java.lang.Double">
<variableExpression><![CDATA[$F{OCUPACAO}.doubleValue() / $F{CAPACIDADE}.doubleValue()]]></variableExpression>
<variableExpression><![CDATA[($F{OCUPACAO}.doubleValue() / $F{CAPACIDADE}.doubleValue() ) * 100]]></variableExpression>
</variable>
<group name="EMPRESA">
<groupExpression><![CDATA[$F{EMPRESA}]]></groupExpression>
@ -175,99 +175,99 @@
</columnHeader>
<detail>
<band height="13" splitType="Stretch">
<textField pattern="dd/MM/yyyy" isBlankWhenNull="true">
<reportElement uuid="bc091860-adab-47d8-8352-982bc8e484a3" x="0" y="0" width="61" height="13"/>
<textField isStretchWithOverflow="true" pattern="dd/MM/yyyy" isBlankWhenNull="true">
<reportElement uuid="bc091860-adab-47d8-8352-982bc8e484a3" stretchType="RelativeToTallestObject" x="0" y="0" width="61" height="13"/>
<textElement textAlignment="Center">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{DATA}]]></textFieldExpression>
</textField>
<textField isBlankWhenNull="true">
<reportElement uuid="82c36c16-1662-4af9-a285-c935ab350e79" x="92" y="0" width="46" height="13"/>
<textField isStretchWithOverflow="true" isBlankWhenNull="true">
<reportElement uuid="82c36c16-1662-4af9-a285-c935ab350e79" stretchType="RelativeToTallestObject" x="92" y="0" width="46" height="13"/>
<textElement textAlignment="Center">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{SERVICO}]]></textFieldExpression>
</textField>
<textField pattern="HH.mm" isBlankWhenNull="true">
<reportElement uuid="ef45dd24-19e8-4e92-9759-f8e7a5c990eb" x="202" y="0" width="46" height="13"/>
<textField isStretchWithOverflow="true" pattern="HH.mm" isBlankWhenNull="true">
<reportElement uuid="ef45dd24-19e8-4e92-9759-f8e7a5c990eb" stretchType="RelativeToTallestObject" x="202" y="0" width="46" height="13"/>
<textElement textAlignment="Center">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{HORARIO}]]></textFieldExpression>
<textFieldExpression><![CDATA[(""+$F{HORARIO}).substring(11,16)]]></textFieldExpression>
</textField>
<textField isBlankWhenNull="true">
<reportElement uuid="17011486-0d4c-4e22-b534-48e0bb025673" x="248" y="0" width="100" height="13"/>
<textField isStretchWithOverflow="true" isBlankWhenNull="true">
<reportElement uuid="17011486-0d4c-4e22-b534-48e0bb025673" stretchType="RelativeToTallestObject" x="248" y="0" width="100" height="13"/>
<textElement textAlignment="Center">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{ORIGEM}]]></textFieldExpression>
</textField>
<textField isBlankWhenNull="true">
<reportElement uuid="a89c84e4-0e13-4e85-a565-9eb0bc6e5423" x="348" y="0" width="100" height="13"/>
<textField isStretchWithOverflow="true" isBlankWhenNull="true">
<reportElement uuid="a89c84e4-0e13-4e85-a565-9eb0bc6e5423" stretchType="RelativeToTallestObject" x="348" y="0" width="100" height="13"/>
<textElement textAlignment="Center">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{DESTINO}]]></textFieldExpression>
</textField>
<textField isBlankWhenNull="true">
<reportElement uuid="7be97f5f-b36b-4679-befb-e5f2b4532963" x="448" y="0" width="90" height="13"/>
<textField isStretchWithOverflow="true" isBlankWhenNull="true">
<reportElement uuid="7be97f5f-b36b-4679-befb-e5f2b4532963" stretchType="RelativeToTallestObject" x="448" y="0" width="90" height="13"/>
<textElement textAlignment="Center">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{CLASSE}]]></textFieldExpression>
</textField>
<textField pattern="###0" isBlankWhenNull="true">
<reportElement uuid="7c1e2d86-f9ce-4730-866c-dc6cbdd0cf2c" x="538" y="0" width="53" height="13"/>
<textField isStretchWithOverflow="true" pattern="###0" isBlankWhenNull="true">
<reportElement uuid="7c1e2d86-f9ce-4730-866c-dc6cbdd0cf2c" stretchType="RelativeToTallestObject" x="538" y="0" width="53" height="13"/>
<textElement textAlignment="Center">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{CAPACIDADE}]]></textFieldExpression>
</textField>
<textField pattern="###0" isBlankWhenNull="true">
<reportElement uuid="7c0246f5-739b-440c-a242-915117bd9fd1" x="591" y="0" width="45" height="13"/>
<textField isStretchWithOverflow="true" pattern="###0" isBlankWhenNull="true">
<reportElement uuid="7c0246f5-739b-440c-a242-915117bd9fd1" stretchType="RelativeToTallestObject" x="591" y="0" width="45" height="13"/>
<textElement textAlignment="Center">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{OCUPACAO}]]></textFieldExpression>
</textField>
<textField pattern="¤ #,##0.00" isBlankWhenNull="true">
<reportElement uuid="dd401917-6047-4e1b-9722-31fe8d096594" x="636" y="0" width="68" height="13"/>
<textField isStretchWithOverflow="true" pattern="¤ #,##0.00" isBlankWhenNull="true">
<reportElement uuid="dd401917-6047-4e1b-9722-31fe8d096594" stretchType="RelativeToTallestObject" x="636" y="0" width="68" height="13"/>
<textElement textAlignment="Center">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{TIPO_SERVICO}]]></textFieldExpression>
</textField>
<textField pattern="¤ #,##0.00" isBlankWhenNull="true">
<reportElement uuid="4dafd61b-ce2b-4690-b029-2a1382113099" x="704" y="0" width="51" height="13"/>
<textField isStretchWithOverflow="true" pattern="¤ #,##0.00" isBlankWhenNull="true">
<reportElement uuid="4dafd61b-ce2b-4690-b029-2a1382113099" stretchType="RelativeToTallestObject" x="704" y="0" width="51" height="13"/>
<textElement textAlignment="Center">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{PLATAFORMA}]]></textFieldExpression>
</textField>
<textField pattern="#,##0.00 %" isBlankWhenNull="true">
<reportElement uuid="8ad565b3-b12c-4fef-a1c7-836e7415436d" x="755" y="0" width="57" height="13"/>
<textField isStretchWithOverflow="true" pattern="" isBlankWhenNull="false">
<reportElement uuid="8ad565b3-b12c-4fef-a1c7-836e7415436d" stretchType="RelativeToTallestObject" x="755" y="0" width="57" height="13"/>
<textElement textAlignment="Center">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$V{POR_OCUPACAO}]]></textFieldExpression>
<textFieldExpression><![CDATA[""+ String.format("%.02f",$V{POR_OCUPACAO}) + "%"]]></textFieldExpression>
</textField>
<textField pattern="dd/MM/yyyy" isBlankWhenNull="true">
<reportElement uuid="bc091860-adab-47d8-8352-982bc8e484a3" x="61" y="0" width="31" height="13"/>
<textField isStretchWithOverflow="true" pattern="dd/MM/yyyy" isBlankWhenNull="true">
<reportElement uuid="bc091860-adab-47d8-8352-982bc8e484a3" stretchType="RelativeToTallestObject" x="61" y="0" width="31" height="13"/>
<textElement textAlignment="Center">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{CODLINHA}]]></textFieldExpression>
</textField>
<textField>
<reportElement uuid="773ac0f6-0c11-430d-8a10-8c62b272b064" x="138" y="0" width="64" height="13"/>
<textElement textAlignment="Center">
<textField isStretchWithOverflow="true">
<reportElement uuid="773ac0f6-0c11-430d-8a10-8c62b272b064" stretchType="RelativeToTallestObject" x="138" y="0" width="64" height="13"/>
<textElement textAlignment="Left">
<font size="8"/>
</textElement>
<textFieldExpression><![CDATA[$F{EMPRESA}]]></textFieldExpression>
</textField>
<textField pattern="¤ #,##0.00" isBlankWhenNull="true">
<reportElement uuid="cce46f47-2fbf-45c2-8347-6d3572f19b92" x="812" y="0" width="30" height="13"/>
<textField isStretchWithOverflow="true" pattern="¤ #,##0.00" isBlankWhenNull="true">
<reportElement uuid="cce46f47-2fbf-45c2-8347-6d3572f19b92" stretchType="RelativeToTallestObject" x="812" y="0" width="30" height="13"/>
<textElement textAlignment="Center">
<font size="8"/>
</textElement>