| @ -0,0 +1,125 @@ | |||
| -- Create table | |||
| create table BSC_FATURAMENTO | |||
| ( | |||
| chave_faturamento NUMBER(15) not null, | |||
| chave_empresa NUMBER(15) not null, | |||
| categoria_pai VARCHAR2(200) not null, | |||
| categoria VARCHAR2(300), | |||
| chave_produto NUMBER(15), | |||
| descricao_produto VARCHAR2(300), | |||
| chave_familia NUMBER(15), | |||
| quantidade NUMBER(15,2), | |||
| valor_venda NUMBER(15,2), | |||
| valor_bruto NUMBER(15,2), | |||
| referencia DATE, | |||
| chave_categoria_pai NUMBER(10), | |||
| chave_categoria NUMBER(10) | |||
| ) | |||
| tablespace C5DADOS | |||
| pctfree 10 | |||
| initrans 1 | |||
| maxtrans 255 | |||
| storage | |||
| ( | |||
| initial 128K | |||
| next 128K | |||
| minextents 1 | |||
| maxextents unlimited | |||
| pctincrease 0 | |||
| ); | |||
| -- Add comments to the columns | |||
| comment on column BSC_FATURAMENTO.chave_faturamento | |||
| is 'Chave da tabela'; | |||
| comment on column BSC_FATURAMENTO.chave_empresa | |||
| is 'Código da loja'; | |||
| comment on column BSC_FATURAMENTO.categoria_pai | |||
| is 'Descrição da categoria pai'; | |||
| comment on column BSC_FATURAMENTO.categoria | |||
| is 'Descrição da categoria'; | |||
| comment on column BSC_FATURAMENTO.chave_produto | |||
| is 'Código do produto'; | |||
| comment on column BSC_FATURAMENTO.descricao_produto | |||
| is 'Descrição do Produto'; | |||
| comment on column BSC_FATURAMENTO.chave_familia | |||
| is 'Código da família do produto'; | |||
| comment on column BSC_FATURAMENTO.quantidade | |||
| is 'Quanitdade vendida'; | |||
| comment on column BSC_FATURAMENTO.valor_venda | |||
| is 'Valor toral vendido'; | |||
| comment on column BSC_FATURAMENTO.valor_bruto | |||
| is 'Valor bruto vendido'; | |||
| comment on column BSC_FATURAMENTO.referencia | |||
| is 'Mês de referência do faturamento'; | |||
| comment on column BSC_FATURAMENTO.chave_categoria_pai | |||
| is 'Código da categoria pai'; | |||
| comment on column BSC_FATURAMENTO.chave_categoria | |||
| is 'Código da categoria'; | |||
| -- Create/Recreate indexes | |||
| create index BSC_FATURAMENTO_IDX on BSC_FATURAMENTO (CHAVE_CATEGORIA) | |||
| tablespace C5DADOS | |||
| pctfree 10 | |||
| initrans 2 | |||
| maxtrans 255 | |||
| storage | |||
| ( | |||
| initial 128K | |||
| next 128K | |||
| minextents 1 | |||
| maxextents unlimited | |||
| pctincrease 0 | |||
| ); | |||
| create index BSC_FATURAMENTO_IDX1 on BSC_FATURAMENTO (REFERENCIA) | |||
| tablespace C5DADOS | |||
| pctfree 10 | |||
| initrans 2 | |||
| maxtrans 255 | |||
| storage | |||
| ( | |||
| initial 128K | |||
| next 128K | |||
| minextents 1 | |||
| maxextents unlimited | |||
| pctincrease 0 | |||
| ); | |||
| create index BSC_FATURAMENTO_IDX2 on BSC_FATURAMENTO (REFERENCIA, CHAVE_CATEGORIA) | |||
| tablespace C5DADOS | |||
| pctfree 10 | |||
| initrans 2 | |||
| maxtrans 255 | |||
| storage | |||
| ( | |||
| initial 128K | |||
| next 128K | |||
| minextents 1 | |||
| maxextents unlimited | |||
| pctincrease 0 | |||
| ); | |||
| create index BSC_FATURAMENTO_IDX3 on BSC_FATURAMENTO (REFERENCIA, CHAVE_EMPRESA) | |||
| tablespace C5DADOS | |||
| pctfree 10 | |||
| initrans 2 | |||
| maxtrans 255 | |||
| storage | |||
| ( | |||
| initial 128K | |||
| next 128K | |||
| minextents 1 | |||
| maxextents unlimited | |||
| pctincrease 0 | |||
| ); | |||
| -- Create/Recreate primary, unique and foreign key constraints | |||
| alter table BSC_FATURAMENTO | |||
| add constraint BSC_FATURAMENTO_PK primary key (CHAVE_FATURAMENTO) | |||
| using index | |||
| tablespace C5DADOS | |||
| pctfree 10 | |||
| initrans 2 | |||
| maxtrans 255 | |||
| storage | |||
| ( | |||
| initial 128K | |||
| next 128K | |||
| minextents 1 | |||
| maxextents unlimited | |||
| pctincrease 0 | |||
| ); | |||
| @ -0,0 +1,119 @@ | |||
| -- Create table | |||
| create table BSC_FATURAMENTO_METAS | |||
| ( | |||
| chave_meta NUMBER(10) not null, | |||
| chave_empresa NUMBER(10) not null, | |||
| categoria VARCHAR2(300) not null, | |||
| meta_faturamento NUMBER(25,10), | |||
| meta_markdown NUMBER(25,10), | |||
| referencia DATE not null, | |||
| total_faturamento NUMBER(25,10), | |||
| total_markdown NUMBER(25,10), | |||
| categoria_pai VARCHAR2(200), | |||
| chave_categoria_pai NUMBER(10), | |||
| chave_categoria NUMBER(10) | |||
| ) | |||
| tablespace C5DADOS | |||
| pctfree 10 | |||
| initrans 1 | |||
| maxtrans 255 | |||
| storage | |||
| ( | |||
| initial 128K | |||
| next 128K | |||
| minextents 1 | |||
| maxextents unlimited | |||
| pctincrease 0 | |||
| ); | |||
| -- Add comments to the columns | |||
| comment on column BSC_FATURAMENTO_METAS.chave_meta | |||
| is 'Chave da meta'; | |||
| comment on column BSC_FATURAMENTO_METAS.chave_empresa | |||
| is 'Código da Loja'; | |||
| comment on column BSC_FATURAMENTO_METAS.categoria | |||
| is 'Categoria do fatumento'; | |||
| comment on column BSC_FATURAMENTO_METAS.meta_faturamento | |||
| is 'Meta para faturamento na referência'; | |||
| comment on column BSC_FATURAMENTO_METAS.meta_markdown | |||
| is 'Meta para makdown na referência'; | |||
| comment on column BSC_FATURAMENTO_METAS.referencia | |||
| is 'Mês de referência da meta'; | |||
| comment on column BSC_FATURAMENTO_METAS.total_faturamento | |||
| is 'Valor total a ser faturado'; | |||
| comment on column BSC_FATURAMENTO_METAS.total_markdown | |||
| is 'Valor Markdown'; | |||
| comment on column BSC_FATURAMENTO_METAS.categoria_pai | |||
| is 'Categoria pai do faturamento'; | |||
| comment on column BSC_FATURAMENTO_METAS.chave_categoria_pai | |||
| is 'Chave da categoria pai'; | |||
| comment on column BSC_FATURAMENTO_METAS.chave_categoria | |||
| is 'Chave da categoria'; | |||
| -- Create/Recreate indexes | |||
| create index BCS_FATURAMENTO_METAS_IDX on BSC_FATURAMENTO_METAS (CHAVE_CATEGORIA) | |||
| tablespace C5DADOS | |||
| pctfree 10 | |||
| initrans 2 | |||
| maxtrans 255 | |||
| storage | |||
| ( | |||
| initial 128K | |||
| next 128K | |||
| minextents 1 | |||
| maxextents unlimited | |||
| pctincrease 0 | |||
| ); | |||
| create index BSC_FATURAMENTO_METAS_IDX1 on BSC_FATURAMENTO_METAS (REFERENCIA) | |||
| tablespace C5DADOS | |||
| pctfree 10 | |||
| initrans 2 | |||
| maxtrans 255 | |||
| storage | |||
| ( | |||
| initial 128K | |||
| next 128K | |||
| minextents 1 | |||
| maxextents unlimited | |||
| pctincrease 0 | |||
| ); | |||
| create index BSC_FATURAMENTO_METAS_IDX2 on BSC_FATURAMENTO_METAS (REFERENCIA, CHAVE_EMPRESA) | |||
| tablespace C5DADOS | |||
| pctfree 10 | |||
| initrans 2 | |||
| maxtrans 255 | |||
| storage | |||
| ( | |||
| initial 128K | |||
| next 128K | |||
| minextents 1 | |||
| maxextents unlimited | |||
| pctincrease 0 | |||
| ); | |||
| create index BSC_FATURAMENTO_METAS_IDX3 on BSC_FATURAMENTO_METAS (REFERENCIA, CHAVE_EMPRESA, CHAVE_CATEGORIA) | |||
| tablespace C5DADOS | |||
| pctfree 10 | |||
| initrans 2 | |||
| maxtrans 255 | |||
| storage | |||
| ( | |||
| initial 128K | |||
| next 128K | |||
| minextents 1 | |||
| maxextents unlimited | |||
| pctincrease 0 | |||
| ); | |||
| -- Create/Recreate primary, unique and foreign key constraints | |||
| alter table BSC_FATURAMENTO_METAS | |||
| add constraint BSC_FATURAMENTO_METAS_PK primary key (CHAVE_META) | |||
| using index | |||
| tablespace C5DADOS | |||
| pctfree 10 | |||
| initrans 2 | |||
| maxtrans 255 | |||
| storage | |||
| ( | |||
| initial 128K | |||
| next 128K | |||
| minextents 1 | |||
| maxextents unlimited | |||
| pctincrease 0 | |||
| ); | |||
| @ -0,0 +1,48 @@ | |||
| -- Create table | |||
| create table BSC_USUARIO_CATEGORIA | |||
| ( | |||
| chave_usuario_categoria NUMBER(15) not null, | |||
| chave_usuario NUMBER(15), | |||
| chave_empresa NUMBER(15), | |||
| categoria_pai VARCHAR2(200), | |||
| categoria VARCHAR2(300) | |||
| ) | |||
| tablespace C5DADOS | |||
| pctfree 10 | |||
| initrans 1 | |||
| maxtrans 255 | |||
| storage | |||
| ( | |||
| initial 128K | |||
| next 128K | |||
| minextents 1 | |||
| maxextents unlimited | |||
| pctincrease 0 | |||
| ); | |||
| -- Add comments to the columns | |||
| comment on column BSC_USUARIO_CATEGORIA.chave_usuario_categoria | |||
| is 'Código da tabela'; | |||
| comment on column BSC_USUARIO_CATEGORIA.chave_usuario | |||
| is 'Código do usuário'; | |||
| comment on column BSC_USUARIO_CATEGORIA.chave_empresa | |||
| is 'Código da Empresa'; | |||
| comment on column BSC_USUARIO_CATEGORIA.categoria_pai | |||
| is 'Categoria pai vinculado'; | |||
| comment on column BSC_USUARIO_CATEGORIA.categoria | |||
| is 'Categoria vinculado'; | |||
| -- Create/Recreate primary, unique and foreign key constraints | |||
| alter table BSC_USUARIO_CATEGORIA | |||
| add constraint BSC_USUARIO_CATEGORIA_PK primary key (CHAVE_USUARIO_CATEGORIA) | |||
| using index | |||
| tablespace C5DADOS | |||
| pctfree 10 | |||
| initrans 2 | |||
| maxtrans 255 | |||
| storage | |||
| ( | |||
| initial 128K | |||
| next 128K | |||
| minextents 1 | |||
| maxextents unlimited | |||
| pctincrease 0 | |||
| ); | |||
| @ -0,0 +1,3 @@ | |||
| Sigla: gerente_loja | |||
| Nome: Gerentes de Loja | |||
| Descrição: Grupo que define os gerentes das lojas. | |||
| @ -0,0 +1,3 @@ | |||
| Sigla: diretoria | |||
| Nome: Diretoria | |||
| Descrição: Grupo de diretores. | |||
| @ -0,0 +1,33 @@ | |||
| <?xml version="1.0" encoding="UTF-8"?> | |||
| <panel-form xmlns="http://www.davinti.com.br/vitruvio/form/mobile/panel" | |||
| xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |||
| xsi:schemaLocation="http://www.davinti.com.br/vitruvio/form/mobile/panel https://bitbucket.org/davinTI/vitruvio-xds/raw/master/vitruvio-mobile-panel-form.xsd"> | |||
| <form formKey="mobile1"> | |||
| <name>Form mobile</name> | |||
| <initScript language="JavaScript"> | |||
| <![CDATA[ | |||
| function run() { | |||
| engine.getDesktopPanel("faturamentoLoja").addFieldId("parTipo", 'Loja'); | |||
| engine.getDesktopPanel("faturamentoCategoria").addFieldId("parTipo", 'Categoria'); | |||
| engine.getDesktopPanel("faturamentoLoja").reload(); | |||
| engine.getDesktopPanel("faturamentoCategoria").reload(); | |||
| } | |||
| ]]> | |||
| </initScript> | |||
| <components> | |||
| <VerticalLayout> | |||
| <TabLayout id="tabLayout"> | |||
| <Tab caption="Faturamento por lojas"> | |||
| <DesktopPanel id="faturamentoLoja" panelKey="indFaturamento" layoutId="mostrarLoja" forceFieldsRender="parTipo,filtroReferencia,dataRef,dataApurado,loja,modo,condicao,topdown,categoria" /> | |||
| </Tab> | |||
| <Tab caption="Faturamento por categoria"> | |||
| <DesktopPanel id="faturamentoCategoria" panelKey="indFaturamento" layoutId="mostrarCategoria" forceFieldsRender="parTipo,filtroReferencia,dataRef,dataApurado,categoria,loja,topdown,modo,condicao" /> | |||
| </Tab> | |||
| </TabLayout> | |||
| </VerticalLayout> | |||
| </components> | |||
| </form> | |||
| </panel-form> | |||
| @ -0,0 +1,77 @@ | |||
| <?xml version="1.0" encoding="UTF-8"?> | |||
| <report-form xmlns="http://www.davinti.com.br/vitruvio/form/report" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.davinti.com.br/vitruvio/form/report vitruvio-report-form.xsd"> | |||
| <form formKey="formDadosPassagem" width="100%"> | |||
| <name>Auditoria</name> | |||
| <description>Auditoria</description> | |||
| <components> | |||
| <VerticalLayout width="100%" margin="true" spacing="true"> | |||
| <Panel width="100%" caption="Parâmetros do relatório"> | |||
| <VerticalLayout width="100%" spacing="true" margin="true"> | |||
| <HorizontalLayout spacing="true" width="100%"> | |||
| <DBSearchField id="auditoria" caption="Auditoria" required="true" requiredMessage="É obrigatório informar uma auditoria" type="number" width="100%" searchViewRows="10" searchViewWidth="95%" searchViewHeight="90%"> | |||
| <datasource> | |||
| <freeQuery connection-key="Vitruvio"> | |||
| SELECT distinct E.CHAVE_EXECUCAO, E.DATAHORAABERTURA, C.TITULO, ne.razao_social FROM AUDITORIA_EXECUCAO E | |||
| INNER JOIN AUDITORIA C ON C.CHAVE_AUDITORIA = E.CHAVE_AUDITORIA | |||
| inner join auditoria_coleta cc on cc.chave_processo = e.chave_execucao | |||
| inner join nauth.empresa ne on ne.empresa_id = cc.empresa | |||
| ORDER BY CHAVE_EXECUCAO DESC | |||
| </freeQuery> | |||
| </datasource> | |||
| <key-field>CHAVE_EXECUCAO</key-field> | |||
| <caption-field>TITULO</caption-field> | |||
| <columns> | |||
| <column name="CHAVE_EXECUCAO" caption="Código" expand-ratio="0.2"/> | |||
| <column name="TITULO" caption="Descrição" expand-ratio="1.0"/> | |||
| <column name="DATAHORAABERTURA" caption="Data de cadastro" expand-ratio="0.2"/> | |||
| <column name="RAZAO_SOCIAL" caption="Loja" expand-ratio="0.2"/> | |||
| </columns> | |||
| <events> | |||
| <valueChange> | |||
| <script language="JavaScript"> | |||
| <![CDATA[ | |||
| function run() { | |||
| var id = String(engine.getField('auditoria').getValue()); | |||
| var s = 'Select distinct prop.usuario_fk usuario, prop.valor_string, ccl.chave_processo from nauth.empresa emp inner join nauth.usuario_propriedade prop on prop.valor_string = cast(emp.id_sistema_externo as "varchar"(10)) inner join auditoria_coleta ccl on ccl.empresa = emp.empresa_id where prop.propriedade_fk = 1 and ccl.chave_processo = ' + id; | |||
| var ds = vQueryService.executeQuery('Vitruvio', s); | |||
| if (ds.next()) { | |||
| var usuario = ds.getNumber('USUARIO'); | |||
| } | |||
| if (usuario) { | |||
| var sql = "SELECT U.NOME NOME FROM NAUTH.USUARIO_PROPRIEDADE UP INNER JOIN NAUTH.USUARIO US ON US.USUARIO_ID = UP.USUARIO_FK INNER JOIN NAUTH.USUARIO U ON U.USUARIO_ID = UP.USUARIO_FK WHERE UP.PROPRIEDADE_FK = 61 AND CAST(UP.VALOR_STRING AS VARCHAR(20)) = 'gerente' AND UP.USUARIO_FK = " + Number(usuario); | |||
| var d = vQueryService.executeQuery('Vitruvio', sql); | |||
| if (d.next()) { | |||
| var gerente = d.getString('NOME'); | |||
| } | |||
| engine.getField('gerente').setValue(gerente); | |||
| } else { | |||
| engine.getField('gerente').setValue('Não definido'); | |||
| } | |||
| } | |||
| ]]> | |||
| </script> | |||
| </valueChange> | |||
| </events> | |||
| <filterProperties> | |||
| <value>CHAVE_EXECUCAO</value> | |||
| <value>TITULO</value> | |||
| <value>DATAHORAABERTURA</value> | |||
| <value>RAZAO_SOCIAL</value> | |||
| </filterProperties> | |||
| </DBSearchField> | |||
| </HorizontalLayout> | |||
| <TextArea type="string" id="sqlinv" caption="SQL Inventario" width="100%" rows="6" required="false" | |||
| requiredMessage="Código Produto" visible="false" /> | |||
| <TextField type="string" id="gerente" visible="false" /> | |||
| </VerticalLayout> | |||
| </Panel> | |||
| </VerticalLayout> | |||
| </components> | |||
| </form> | |||
| </report-form> | |||
| @ -0,0 +1,533 @@ | |||
| <?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="Auditoria" pageWidth="842" pageHeight="595" orientation="Landscape" columnWidth="802" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" uuid="e4b6a11f-cfdc-4666-bae2-75464500b5ef"> | |||
| <property name="ireport.zoom" value="1.0"/> | |||
| <property name="ireport.x" value="16"/> | |||
| <property name="ireport.y" value="0"/> | |||
| <style name="Zebrado"> | |||
| <conditionalStyle> | |||
| <conditionExpression><![CDATA[new Boolean(($V{COLUMN_COUNT}.intValue() % 2) == 0)]]></conditionExpression> | |||
| <style backcolor="#CCCCCC"/> | |||
| </conditionalStyle> | |||
| <conditionalStyle> | |||
| <conditionExpression><![CDATA[new Boolean(($V{COLUMN_COUNT}.intValue() % 2) != 0)]]></conditionExpression> | |||
| <style/> | |||
| </conditionalStyle> | |||
| </style> | |||
| <style name="ResultadoFinal"> | |||
| <conditionalStyle> | |||
| <conditionExpression><![CDATA[(($V{variable8}/$V{variable9})/100) < ($F{ruim} / 100)]]></conditionExpression> | |||
| <style forecolor="#FF0000"/> | |||
| </conditionalStyle> | |||
| <conditionalStyle> | |||
| <conditionExpression><![CDATA[(($V{variable8}/$V{variable9})/100) > ($F{bommaior} / 100) && (($V{variable8}/$V{variable9})/100) < ($F{bommenor} / 100)]]></conditionExpression> | |||
| <style forecolor="#FFFF00"/> | |||
| </conditionalStyle> | |||
| <conditionalStyle> | |||
| <conditionExpression><![CDATA[((($V{variable8}/$V{variable9})/100) > ($F{mbommaior} / 100)) && ((($V{variable8}/$V{variable9})/100) < ($F{mbommenor} / 100))]]></conditionExpression> | |||
| <style forecolor="#009900"/> | |||
| </conditionalStyle> | |||
| <conditionalStyle> | |||
| <conditionExpression><![CDATA[(($V{variable8}/$V{variable9})/100) >= ($F{excelente} / 100)]]></conditionExpression> | |||
| <style forecolor="#0033FF"/> | |||
| </conditionalStyle> | |||
| </style> | |||
| <parameter name="auditoria" class="java.lang.Long"> | |||
| <defaultValueExpression><![CDATA[342]]></defaultValueExpression> | |||
| </parameter> | |||
| <queryString> | |||
| <![CDATA[Select c.titulo, cc.empresa, e.datahoraabertura, cc.observacoes, | |||
| (Select razao_social from nauth.empresa where empresa_id = cc.empresa) razao_social, | |||
| (Select ponto_avaliado from auditoria_execucao_questoes where chave_item = cc.chave_questao) ponto_avaliado, | |||
| (Select tag_id from auditoria_execucao_questoes where chave_item = cc.chave_questao) tag, | |||
| (Select tag_id2 from auditoria_execucao_questoes where chave_item = cc.chave_questao) tag2, | |||
| (Select tag_id3 from auditoria_execucao_questoes where chave_item = cc.chave_questao) tag3, | |||
| (Select tipo_questao from auditoria_execucao_questoes where chave_item = cc.chave_questao) tipoQuestao, | |||
| (Select pontuacao from auditoria_execucao_questoes where chave_item = cc.chave_questao) peso, | |||
| case when cast((Select tipo_questao from auditoria_execucao_questoes where chave_item = cc.chave_questao) as varchar(50)) in ('Lista','Sim/Não','Satisfação') then cast((Select texto from auditoria_execucao_lista where cast(chave_item_lista AS varchar(50)) = cc.resposta) as varchar(50)) | |||
| else cast(cc.resposta as varchar(50)) end resposta, | |||
| case when cast((Select tipo_questao from auditoria_execucao_questoes where chave_item = cc.chave_questao) as varchar(50)) in ('Lista','Sim/Não','Satisfação') then (Select pontuacao from auditoria_execucao_lista where cast(chave_item_lista as varchar(50)) = cc.resposta) | |||
| end pontoslista, | |||
| case when cast((Select tipo_questao from auditoria_execucao_questoes where chave_item = cc.chave_questao) as varchar(50)) in ('Lista','Sim/Não','Satisfação') then cast((Select naoaplicavel from auditoria_execucao_lista where cast(chave_item_lista as varchar(50)) = cc.resposta) as varchar(50)) | |||
| end naoaplicavel, | |||
| (Select nome from nauth.usuario where login = cc.executor) executor, | |||
| (Select ordem from auditoria_execucao_questoes where chave_item = cc.chave_questao) ordem, | |||
| (Select percruim from auditoria where chave_auditoria = c.chave_auditoria) ruim, | |||
| (Select percbommaior from auditoria where chave_auditoria = c.chave_auditoria) bommaior, | |||
| (Select percbommenor from auditoria where chave_auditoria = c.chave_auditoria) bommenor, | |||
| (Select percmbommaior from auditoria where chave_auditoria = c.chave_auditoria) mbommaior, | |||
| (Select percmbommenor from auditoria where chave_auditoria = c.chave_auditoria) mbommenor, | |||
| (Select percexcelente from auditoria where chave_auditoria = c.chave_auditoria) excelente, | |||
| (select coalesce(pesoag1,0) from auditoria_execucao_questoes where chave_item = cc.chave_questao) pesoag1, | |||
| (select coalesce(pesoag2,0) + coalesce(pesoag3,0) from auditoria_execucao_questoes where chave_item = cc.chave_questao) pesoag2_3, | |||
| (Select max(pontuacao) from auditoria_execucao_lista where chave_item = cc.chave_questao) as pontopadrao | |||
| from auditoria_coleta cc inner join auditoria_execucao e on cc.chave_processo = e.chave_execucao inner join auditoria c on c.chave_auditoria = e.chave_auditoria where e.chave_execucao = $P{auditoria} group by cc.empresa,c.titulo,cc.chave_questao, cc.resposta, e.datahoraabertura, cc.observacoes, cc.executor, c.chave_auditoria order by 7,8]]> | |||
| </queryString> | |||
| <field name="titulo" class="java.lang.String"/> | |||
| <field name="empresa" class="java.lang.Integer"/> | |||
| <field name="datahoraabertura" class="java.sql.Date"/> | |||
| <field name="observacoes" class="java.lang.String"/> | |||
| <field name="razao_social" class="java.lang.String"/> | |||
| <field name="ponto_avaliado" class="java.lang.String"/> | |||
| <field name="tag" class="java.lang.String"/> | |||
| <field name="tipoquestao" class="java.lang.String"/> | |||
| <field name="peso" class="java.math.BigDecimal"/> | |||
| <field name="resposta" class="java.lang.String"/> | |||
| <field name="pontoslista" class="java.lang.Float"/> | |||
| <field name="naoaplicavel" class="java.lang.String"/> | |||
| <field name="tag2" class="java.lang.String"/> | |||
| <field name="tag3" class="java.lang.String"/> | |||
| <field name="executor" class="java.lang.String"/> | |||
| <field name="ruim" class="java.lang.Float"/> | |||
| <field name="bommaior" class="java.lang.Float"/> | |||
| <field name="bommenor" class="java.lang.Float"/> | |||
| <field name="mbommaior" class="java.lang.Float"/> | |||
| <field name="mbommenor" class="java.lang.Float"/> | |||
| <field name="excelente" class="java.lang.Float"/> | |||
| <field name="pesoag1" class="java.math.BigDecimal"/> | |||
| <field name="pesoag2_3" class="java.math.BigDecimal"/> | |||
| <field name="pontopadrao" class="java.math.BigDecimal"/> | |||
| <variable name="somaPontos" class="java.lang.Float" resetType="Group" resetGroup="Tag" calculation="Sum"> | |||
| <variableExpression><![CDATA[$F{tipoquestao}.equals("NPS") ? ((Double.valueOf($F{resposta}) * $F{peso}.doubleValue()) * $F{pesoag2_3}.doubleValue()) : | |||
| $F{tipoquestao}.equals("Lista") || $F{tipoquestao}.equals("Sim/Não") || $F{tipoquestao}.equals("Satisfação") ? (($F{pontoslista}.doubleValue() * $F{peso}.doubleValue()) * $F{pesoag2_3}.doubleValue()) : | |||
| 0]]></variableExpression> | |||
| <initialValueExpression><![CDATA[0]]></initialValueExpression> | |||
| </variable> | |||
| <variable name="pesotag" class="java.lang.Float" resetType="Group" resetGroup="Tag" calculation="Sum"> | |||
| <variableExpression><![CDATA[$F{tipoquestao}.equals("Lista") || $F{tipoquestao}.equals("Sim/Não") ? $F{naoaplicavel}.equals("Não") ? (($F{pontopadrao}.doubleValue() * $F{peso}.doubleValue()) * $F{pesoag2_3}.doubleValue()) : 0 : (($F{pontopadrao}.doubleValue() * $F{peso}.doubleValue()) * $F{pesoag2_3}.doubleValue())]]></variableExpression> | |||
| <initialValueExpression><![CDATA[0]]></initialValueExpression> | |||
| </variable> | |||
| <variable name="totalPontos" class="java.lang.Float" resetType="Group" resetGroup="Empresa" calculation="Sum"> | |||
| <variableExpression><![CDATA[$F{tipoquestao}.equals("NPS") ? ((Double.valueOf($F{resposta}) * $F{peso}.doubleValue()) * $F{pesoag2_3}.doubleValue()) * $F{pesoag1}.doubleValue() : | |||
| $F{tipoquestao}.equals("Lista") || $F{tipoquestao}.equals("Sim/Não") || $F{tipoquestao}.equals("Satisfação") ? ((($F{pontoslista}.doubleValue() * $F{peso}.doubleValue()) * $F{pesoag2_3}.doubleValue())) * $F{pesoag1}.doubleValue() : | |||
| 0]]></variableExpression> | |||
| <initialValueExpression><![CDATA[0]]></initialValueExpression> | |||
| </variable> | |||
| <variable name="pesoTotal" class="java.lang.Float" resetType="Group" resetGroup="Empresa" calculation="Sum"> | |||
| <variableExpression><![CDATA[$F{naoaplicavel}.equals("Não") ? ((($F{pontopadrao}.doubleValue() * $F{peso}.doubleValue()) * $F{pesoag2_3}.doubleValue())) * $F{pesoag1}.doubleValue() : 0]]></variableExpression> | |||
| <initialValueExpression><![CDATA[0]]></initialValueExpression> | |||
| </variable> | |||
| <variable name="ag" class="java.lang.Float" resetType="Group" resetGroup="Tag2"> | |||
| <variableExpression><![CDATA[$F{pesoag2_3}.doubleValue()]]></variableExpression> | |||
| <initialValueExpression><![CDATA[Float.valueOf(0)]]></initialValueExpression> | |||
| </variable> | |||
| <variable name="variable1" class="java.lang.Float" resetType="Group" resetGroup="Tag" calculation="Sum"> | |||
| <variableExpression><![CDATA[$F{pontoslista}]]></variableExpression> | |||
| <initialValueExpression><![CDATA[0]]></initialValueExpression> | |||
| </variable> | |||
| <variable name="variable2" class="java.lang.Float" resetType="Group" resetGroup="Tag" calculation="Sum"> | |||
| <variableExpression><![CDATA[$F{peso}]]></variableExpression> | |||
| <initialValueExpression><![CDATA[0]]></initialValueExpression> | |||
| </variable> | |||
| <variable name="variable3" class="java.lang.Float" resetType="Group" resetGroup="Tag2" calculation="Sum"> | |||
| <variableExpression><![CDATA[$F{resposta}.equals("Não") ? 0 : $F{peso}]]></variableExpression> | |||
| <initialValueExpression><![CDATA[0]]></initialValueExpression> | |||
| </variable> | |||
| <variable name="variable4" class="java.lang.Double" resetType="Group" resetGroup="Tag2"> | |||
| <variableExpression><![CDATA[$V{variable3} * $F{pesoag2_3}.doubleValue()]]></variableExpression> | |||
| <initialValueExpression><![CDATA[0]]></initialValueExpression> | |||
| </variable> | |||
| <variable name="variable5" class="java.lang.Double" resetType="Group" resetGroup="Tag" incrementType="Group" incrementGroup="Tag2" calculation="Sum"> | |||
| <variableExpression><![CDATA[$V{variable4}]]></variableExpression> | |||
| <initialValueExpression><![CDATA[0]]></initialValueExpression> | |||
| </variable> | |||
| <variable name="TotalPercentual" class="java.lang.Float" resetType="Group" resetGroup="Tag" incrementType="Group" incrementGroup="Tag2" calculation="Sum"> | |||
| <variableExpression><![CDATA[$F{pesoag2_3}.doubleValue()]]></variableExpression> | |||
| <initialValueExpression><![CDATA[0]]></initialValueExpression> | |||
| </variable> | |||
| <variable name="variable6" class="java.lang.Float" resetType="Group" resetGroup="Tag" incrementType="Group" incrementGroup="Tag" calculation="Sum"> | |||
| <variableExpression><![CDATA[($V{variable5}/$V{TotalPercentual})]]></variableExpression> | |||
| </variable> | |||
| <variable name="variable7" class="java.lang.Double" resetType="Group" resetGroup="Tag" incrementType="Group" incrementGroup="Tag"> | |||
| <variableExpression><![CDATA[$V{variable6}*$F{pesoag1}.doubleValue()]]></variableExpression> | |||
| <initialValueExpression><![CDATA[0]]></initialValueExpression> | |||
| </variable> | |||
| <variable name="variable8" class="java.lang.Double" resetType="Group" resetGroup="Empresa" incrementType="Group" incrementGroup="Tag" calculation="Sum"> | |||
| <variableExpression><![CDATA[$V{variable7}]]></variableExpression> | |||
| <initialValueExpression><![CDATA[0]]></initialValueExpression> | |||
| </variable> | |||
| <variable name="variable9" class="java.lang.Double" resetType="Group" resetGroup="Empresa" incrementType="Group" incrementGroup="Tag" calculation="Sum"> | |||
| <variableExpression><![CDATA[$F{pesoag1}.doubleValue()]]></variableExpression> | |||
| <initialValueExpression><![CDATA[0]]></initialValueExpression> | |||
| </variable> | |||
| <group name="Empresa" isStartNewPage="true"> | |||
| <groupExpression><![CDATA[$F{empresa}]]></groupExpression> | |||
| <groupHeader> | |||
| <band height="147"> | |||
| <rectangle> | |||
| <reportElement x="0" y="117" width="802" height="26" uuid="6d401b0b-2a4b-46a5-9bff-6a753aa89335"/> | |||
| </rectangle> | |||
| <rectangle> | |||
| <reportElement x="0" y="91" width="802" height="26" uuid="723774cd-c87b-480c-91d6-d289cdaf1002"/> | |||
| </rectangle> | |||
| <staticText> | |||
| <reportElement mode="Opaque" x="8" y="94" width="100" height="20" backcolor="#FFFFFF" uuid="338a617f-4f34-4b23-94ec-efad5d381b13"/> | |||
| <textElement verticalAlignment="Middle"> | |||
| <font fontName="Arial" size="12" isBold="true"/> | |||
| </textElement> | |||
| <text><![CDATA[Estabelecimento]]></text> | |||
| </staticText> | |||
| <staticText> | |||
| <reportElement mode="Opaque" x="8" y="121" width="100" height="20" backcolor="#FFFFFF" uuid="1c77aa9b-7a45-4f00-9b59-ecefa3c88d1d"/> | |||
| <textElement verticalAlignment="Middle"> | |||
| <font fontName="Arial" size="12" isBold="true"/> | |||
| </textElement> | |||
| <text><![CDATA[Data]]></text> | |||
| </staticText> | |||
| <textField> | |||
| <reportElement x="125" y="94" width="640" height="20" uuid="305e2d20-dd62-439f-aed9-fac4885c7a94"/> | |||
| <textElement verticalAlignment="Middle"> | |||
| <font fontName="Arial" size="12"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[$F{razao_social}]]></textFieldExpression> | |||
| </textField> | |||
| <textField pattern="dd/MM/yyyy"> | |||
| <reportElement x="125" y="120" width="640" height="20" uuid="a319faba-b59d-424f-a3fa-6158bdd62b2e"/> | |||
| <textElement verticalAlignment="Middle"> | |||
| <font fontName="Arial" size="12"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[$F{datahoraabertura}]]></textFieldExpression> | |||
| </textField> | |||
| <image onErrorType="Blank"> | |||
| <reportElement x="0" y="0" width="134" height="65" uuid="ba582c8d-385a-4dbe-9d42-f53922d47fcb"/> | |||
| <imageExpression><![CDATA[new String("http://vitruvio.davinti.com.br/VAADIN/themes/vitruvio/images/logo_davinti_horizontal.jpg")]]></imageExpression> | |||
| </image> | |||
| <textField isStretchWithOverflow="true" isBlankWhenNull="true"> | |||
| <reportElement x="144" y="0" width="460" height="52" uuid="2d559c2c-c497-4399-b709-bce358d62f8d"/> | |||
| <textElement textAlignment="Center" verticalAlignment="Top"> | |||
| <font fontName="Arial" size="16" isBold="true"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[$F{titulo}]]></textFieldExpression> | |||
| </textField> | |||
| <line> | |||
| <reportElement x="114" y="91" width="1" height="52" uuid="7ea26dfd-b5ba-45b4-8d60-449289edccdb"/> | |||
| </line> | |||
| <staticText> | |||
| <reportElement x="665" y="1" width="100" height="16" uuid="14ec0b94-2e93-4d4c-9a79-fddf49a55d0d"/> | |||
| <textElement verticalAlignment="Middle"> | |||
| <font fontName="Arial"/> | |||
| </textElement> | |||
| <text><![CDATA[Legenda:]]></text> | |||
| </staticText> | |||
| <staticText> | |||
| <reportElement mode="Opaque" x="307" y="120" width="65" height="20" backcolor="#FFFFFF" uuid="0debd94f-455d-486e-aa2f-1d3cbefb861c"/> | |||
| <textElement verticalAlignment="Middle"> | |||
| <font fontName="Arial" size="12" isBold="true"/> | |||
| </textElement> | |||
| <text><![CDATA[Executor:]]></text> | |||
| </staticText> | |||
| <textField> | |||
| <reportElement x="372" y="123" width="393" height="20" uuid="185d27ee-267c-4613-9477-abd0761711a3"/> | |||
| <textElement> | |||
| <font fontName="Arial" size="12"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[$F{executor}]]></textFieldExpression> | |||
| </textField> | |||
| <textField> | |||
| <reportElement mode="Opaque" x="604" y="17" width="161" height="16" backcolor="#FF3333" uuid="b8d15b29-e2da-42ca-a112-afc81d3dc115"/> | |||
| <textElement verticalAlignment="Middle"/> | |||
| <textFieldExpression><![CDATA["<= " + $F{ruim} + "% - Ruim"]]></textFieldExpression> | |||
| </textField> | |||
| <textField> | |||
| <reportElement mode="Opaque" x="604" y="33" width="161" height="16" backcolor="#FFFF00" uuid="3e5ee933-f0a0-4065-9040-3f18852e9027"/> | |||
| <textElement verticalAlignment="Middle"/> | |||
| <textFieldExpression><![CDATA["> " + $F{bommaior} + "% < " + $F{bommenor} + "% - Bom"]]></textFieldExpression> | |||
| </textField> | |||
| <textField> | |||
| <reportElement mode="Opaque" x="604" y="49" width="161" height="16" backcolor="#339900" uuid="a57ec0b1-a68b-4002-b9d9-6db038257571"/> | |||
| <textElement verticalAlignment="Middle"/> | |||
| <textFieldExpression><![CDATA["> " + $F{mbommaior} + "% < " + $F{mbommenor} + "% - Muito Bom"]]></textFieldExpression> | |||
| </textField> | |||
| <textField> | |||
| <reportElement mode="Opaque" x="604" y="65" width="161" height="16" backcolor="#0099FF" uuid="be24bafc-afd1-42ba-8513-92bb7091c35d"/> | |||
| <textElement verticalAlignment="Middle"/> | |||
| <textFieldExpression><![CDATA[">= " + $F{excelente} + "% - Excelente"]]></textFieldExpression> | |||
| </textField> | |||
| </band> | |||
| </groupHeader> | |||
| <groupFooter> | |||
| <band height="49"> | |||
| <rectangle> | |||
| <reportElement x="0" y="0" width="802" height="48" backcolor="#CCCCCC" uuid="8b6f57aa-25c8-4181-839a-d50a8d79d242"/> | |||
| <graphicElement> | |||
| <pen lineWidth="0.0"/> | |||
| </graphicElement> | |||
| </rectangle> | |||
| <textField> | |||
| <reportElement x="8" y="7" width="682" height="18" uuid="985d8990-ca08-4283-807f-94be88d4b1ea"/> | |||
| <textElement> | |||
| <font fontName="Arial" size="12" isBold="true"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[$F{titulo} + " - " + $F{razao_social}]]></textFieldExpression> | |||
| </textField> | |||
| <staticText> | |||
| <reportElement x="8" y="28" width="126" height="20" uuid="4cc062f6-e3c6-4d5e-a376-be418ba5209d"/> | |||
| <textElement> | |||
| <font fontName="Arial" size="12" isBold="true"/> | |||
| </textElement> | |||
| <text><![CDATA[Aproveitamento total:]]></text> | |||
| </staticText> | |||
| <textField pattern="#,##0.00 %"> | |||
| <reportElement style="ResultadoFinal" x="151" y="28" width="100" height="20" uuid="9446b98a-9113-4005-aadb-9f0c91e5d55d"/> | |||
| <textElement verticalAlignment="Top"> | |||
| <font fontName="Arial" size="12" isBold="true"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[($V{variable8}/$V{variable9})/100]]></textFieldExpression> | |||
| </textField> | |||
| </band> | |||
| </groupFooter> | |||
| </group> | |||
| <group name="Tag" isReprintHeaderOnEachPage="true"> | |||
| <groupExpression><![CDATA[$F{tag}]]></groupExpression> | |||
| <groupHeader> | |||
| <band height="38"> | |||
| <rectangle> | |||
| <reportElement x="1" y="18" width="802" height="20" backcolor="#999999" uuid="76c8d6d9-bf36-4b85-88a1-6e90ced84a9b"/> | |||
| <graphicElement> | |||
| <pen lineWidth="0.0"/> | |||
| </graphicElement> | |||
| </rectangle> | |||
| <textField isStretchWithOverflow="true"> | |||
| <reportElement stretchType="RelativeToTallestObject" x="4" y="18" width="787" height="20" uuid="681c373a-6a6f-4c4e-970e-0374f3e2f3ee"> | |||
| <printWhenExpression><![CDATA[$F{tag} != null]]></printWhenExpression> | |||
| </reportElement> | |||
| <textElement textAlignment="Center" verticalAlignment="Middle"> | |||
| <font fontName="Arial" size="12" isBold="true"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA["Agrupador I: " + $F{tag}]]></textFieldExpression> | |||
| </textField> | |||
| <textField> | |||
| <reportElement x="702" y="18" width="100" height="20" uuid="85e1f428-a9b6-42ee-b123-86e109c0a9d6"/> | |||
| <textElement> | |||
| <font fontName="Arial" size="12" isBold="true"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[$F{pesoag1}]]></textFieldExpression> | |||
| </textField> | |||
| </band> | |||
| </groupHeader> | |||
| <groupFooter> | |||
| <band height="30"> | |||
| <rectangle> | |||
| <reportElement stretchType="RelativeToBandHeight" x="0" y="0" width="802" height="30" backcolor="#0099FF" uuid="ddcf7f2b-359e-49f7-bf32-dc8aed82ec14"> | |||
| <printWhenExpression><![CDATA[(($V{variable5}/$V{TotalPercentual})/100) >= ($F{excelente} / 100)]]></printWhenExpression> | |||
| </reportElement> | |||
| <graphicElement> | |||
| <pen lineWidth="0.0"/> | |||
| </graphicElement> | |||
| </rectangle> | |||
| <rectangle> | |||
| <reportElement stretchType="RelativeToBandHeight" x="1" y="0" width="802" height="30" backcolor="#FF3300" uuid="f84e3e1b-e64a-45c2-a326-8bb7f1a38801"> | |||
| <printWhenExpression><![CDATA[(($V{variable5}/$V{TotalPercentual})/100) == 0]]></printWhenExpression> | |||
| </reportElement> | |||
| <graphicElement> | |||
| <pen lineWidth="0.0"/> | |||
| </graphicElement> | |||
| </rectangle> | |||
| <rectangle> | |||
| <reportElement stretchType="RelativeToBandHeight" x="0" y="0" width="802" height="30" backcolor="#00CC00" uuid="d1410353-9737-452a-9453-cbf9865d13ae"> | |||
| <printWhenExpression><![CDATA[((($V{variable5}/$V{TotalPercentual})/100) > ($F{mbommaior} / 100)) && ((($V{variable5}/$V{TotalPercentual})/100) < ($F{mbommenor} / 100))]]></printWhenExpression> | |||
| </reportElement> | |||
| <graphicElement> | |||
| <pen lineWidth="0.0"/> | |||
| </graphicElement> | |||
| </rectangle> | |||
| <rectangle> | |||
| <reportElement stretchType="RelativeToBandHeight" x="0" y="0" width="802" height="30" backcolor="#FFFF00" uuid="c4b994bb-63f2-41c3-a119-ca05a3094b92"> | |||
| <printWhenExpression><![CDATA[((($V{variable5}/$V{TotalPercentual})/100) > ($F{bommaior} / 100)) && ((($V{variable5}/$V{TotalPercentual})/100) < ($F{bommenor} / 100))]]></printWhenExpression> | |||
| </reportElement> | |||
| <graphicElement> | |||
| <pen lineWidth="0.0"/> | |||
| </graphicElement> | |||
| </rectangle> | |||
| <rectangle> | |||
| <reportElement stretchType="RelativeToBandHeight" x="0" y="0" width="802" height="30" backcolor="#FF3300" uuid="a90b0e3a-1d49-41e3-ac83-c62b8118198b"> | |||
| <printWhenExpression><![CDATA[(($V{variable5}/$V{TotalPercentual})/100) < ($F{ruim} / 100)]]></printWhenExpression> | |||
| </reportElement> | |||
| <graphicElement> | |||
| <pen lineWidth="0.0"/> | |||
| </graphicElement> | |||
| </rectangle> | |||
| <textField> | |||
| <reportElement x="4" y="4" width="368" height="20" uuid="fcc11049-032d-4777-abe0-5a7944a4c8fd"/> | |||
| <textElement verticalAlignment="Middle"> | |||
| <font fontName="Arial" size="12" isBold="true"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA["Pontuação " + $F{tag}]]></textFieldExpression> | |||
| </textField> | |||
| <staticText> | |||
| <reportElement x="634" y="6" width="93" height="20" uuid="fb1b0601-d877-4609-a579-38932b6c3af3"/> | |||
| <textElement verticalAlignment="Middle"> | |||
| <font fontName="Arial" size="11" isBold="true"/> | |||
| </textElement> | |||
| <text><![CDATA[Aproveitamento:]]></text> | |||
| </staticText> | |||
| <textField pattern="#,##0.00 %" isBlankWhenNull="true"> | |||
| <reportElement x="733" y="6" width="58" height="20" uuid="e4e53b27-59a7-46e6-a556-64dc1ec0fa05"/> | |||
| <textElement verticalAlignment="Middle"> | |||
| <font fontName="Arial" size="12" isBold="true"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[($V{variable5}/$V{TotalPercentual})/100]]></textFieldExpression> | |||
| </textField> | |||
| </band> | |||
| </groupFooter> | |||
| </group> | |||
| <group name="Tag2"> | |||
| <groupExpression><![CDATA[$F{tag2}]]></groupExpression> | |||
| <groupHeader> | |||
| <band height="67"> | |||
| <rectangle> | |||
| <reportElement x="1" y="-1" width="802" height="24" backcolor="#999999" uuid="76cd3977-1921-4617-accb-537cc5c68e20"/> | |||
| <graphicElement> | |||
| <pen lineWidth="0.0"/> | |||
| </graphicElement> | |||
| </rectangle> | |||
| <rectangle> | |||
| <reportElement mode="Opaque" x="1" y="47" width="802" height="20" backcolor="#FF9900" uuid="779e4803-2962-41ca-a034-bc34dcf3775e"/> | |||
| <graphicElement> | |||
| <pen lineWidth="0.0"/> | |||
| </graphicElement> | |||
| </rectangle> | |||
| <staticText> | |||
| <reportElement x="10" y="46" width="132" height="20" uuid="afdf713b-7896-48c9-ad9a-e2ba6fe59bbd"/> | |||
| <textElement verticalAlignment="Middle"> | |||
| <font fontName="Arial" isBold="true"/> | |||
| </textElement> | |||
| <text><![CDATA[Ponto avaliado]]></text> | |||
| </staticText> | |||
| <staticText> | |||
| <reportElement x="374" y="46" width="100" height="20" uuid="d7a35127-2a1e-42c6-b372-455bf3d032b0"/> | |||
| <textElement verticalAlignment="Middle"> | |||
| <font fontName="Arial" isBold="true"/> | |||
| </textElement> | |||
| <text><![CDATA[Resposta]]></text> | |||
| </staticText> | |||
| <staticText> | |||
| <reportElement x="639" y="47" width="100" height="20" uuid="46e722a3-a332-4fd8-b610-cd4bfa21a2e9"/> | |||
| <textElement verticalAlignment="Middle"> | |||
| <font fontName="Arial" isBold="true"/> | |||
| </textElement> | |||
| <text><![CDATA[Observações]]></text> | |||
| </staticText> | |||
| <textField isStretchWithOverflow="true"> | |||
| <reportElement stretchType="RelativeToTallestObject" x="35" y="2" width="627" height="20" backcolor="#999999" uuid="b2d0d063-8afa-4f0e-9f48-1dda14a4cacd"> | |||
| <printWhenExpression><![CDATA[$F{tag2} != null]]></printWhenExpression> | |||
| </reportElement> | |||
| <textElement verticalAlignment="Middle"> | |||
| <font fontName="Arial" size="12" isBold="true"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA["Agrupador II: " + $F{tag2}]]></textFieldExpression> | |||
| </textField> | |||
| <rectangle> | |||
| <reportElement x="1" y="23" width="802" height="24" backcolor="#999999" uuid="987b2e7e-a674-4ee0-9221-6ba6fc09f30a"/> | |||
| <graphicElement> | |||
| <pen lineWidth="0.0"/> | |||
| </graphicElement> | |||
| </rectangle> | |||
| <textField isStretchWithOverflow="true"> | |||
| <reportElement stretchType="RelativeToTallestObject" x="66" y="26" width="757" height="20" backcolor="#999999" uuid="12dbf431-97d4-496c-a72e-9e64022d1c3c"> | |||
| <printWhenExpression><![CDATA[$F{tag3} != null]]></printWhenExpression> | |||
| </reportElement> | |||
| <textElement verticalAlignment="Middle"> | |||
| <font fontName="Arial" size="12" isBold="true"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA["Agrupador III: " + $F{tag3}]]></textFieldExpression> | |||
| </textField> | |||
| <staticText> | |||
| <reportElement x="545" y="47" width="100" height="20" uuid="ea418daa-74cb-41d9-aad1-f8dec9d71791"/> | |||
| <textElement verticalAlignment="Middle"> | |||
| <font fontName="Arial" isBold="true"/> | |||
| </textElement> | |||
| <text><![CDATA[Pontos]]></text> | |||
| </staticText> | |||
| <textField> | |||
| <reportElement x="702" y="3" width="100" height="20" uuid="01853d78-3b22-4fc4-9d14-5c15025cc2f6"/> | |||
| <textElement> | |||
| <font fontName="Arial" size="12" isBold="true"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[$F{pesoag2_3}]]></textFieldExpression> | |||
| </textField> | |||
| </band> | |||
| </groupHeader> | |||
| <groupFooter> | |||
| <band height="20"> | |||
| <textField> | |||
| <reportElement x="545" y="0" width="85" height="20" uuid="c3cb83da-c3e6-42a3-b523-7c967fa3a776"/> | |||
| <textElement> | |||
| <font fontName="Arial" isBold="true"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[$V{variable3}]]></textFieldExpression> | |||
| </textField> | |||
| <staticText> | |||
| <reportElement x="373" y="0" width="167" height="20" uuid="064c9fc2-2541-4d24-bec9-8b57573d1a21"/> | |||
| <textElement> | |||
| <font fontName="Arial" size="10" isBold="true"/> | |||
| </textElement> | |||
| <text><![CDATA[Total.............................................:]]></text> | |||
| </staticText> | |||
| </band> | |||
| </groupFooter> | |||
| </group> | |||
| <background> | |||
| <band splitType="Stretch"/> | |||
| </background> | |||
| <title> | |||
| <band splitType="Stretch"/> | |||
| </title> | |||
| <pageHeader> | |||
| <band splitType="Stretch"/> | |||
| </pageHeader> | |||
| <columnHeader> | |||
| <band splitType="Stretch"/> | |||
| </columnHeader> | |||
| <detail> | |||
| <band height="29" splitType="Stretch"> | |||
| <rectangle> | |||
| <reportElement style="Zebrado" stretchType="RelativeToBandHeight" x="0" y="0" width="802" height="29" uuid="1a312610-9126-4335-89dd-6da3015692cd"/> | |||
| <graphicElement> | |||
| <pen lineWidth="0.0"/> | |||
| </graphicElement> | |||
| </rectangle> | |||
| <textField isStretchWithOverflow="true"> | |||
| <reportElement stretchType="RelativeToTallestObject" isPrintRepeatedValues="false" x="15" y="5" width="336" height="20" uuid="80e611e0-6e7f-4a06-b127-33d73343d7a0"/> | |||
| <textElement textAlignment="Justified" verticalAlignment="Top"> | |||
| <font fontName="Arial"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[$F{ponto_avaliado}]]></textFieldExpression> | |||
| </textField> | |||
| <textField isStretchWithOverflow="true"> | |||
| <reportElement stretchType="RelativeToTallestObject" x="372" y="5" width="168" height="20" uuid="823c9277-6dc9-472f-a1a7-25fc955804bb"/> | |||
| <textElement verticalAlignment="Top"> | |||
| <font fontName="Arial"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[$F{resposta}]]></textFieldExpression> | |||
| </textField> | |||
| <textField isStretchWithOverflow="true" isBlankWhenNull="true"> | |||
| <reportElement stretchType="RelativeToTallestObject" x="637" y="5" width="155" height="20" uuid="093be4ce-d0bf-4bf1-bf24-556142a3a3eb"/> | |||
| <textElement verticalAlignment="Top"> | |||
| <font fontName="Arial"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[$F{observacoes}]]></textFieldExpression> | |||
| </textField> | |||
| <textField pattern="###0.00" isBlankWhenNull="true"> | |||
| <reportElement x="545" y="5" width="85" height="20" uuid="b150bf60-054b-441d-bd04-73ddee918f00"/> | |||
| <textElement> | |||
| <font fontName="Arial" isBold="false"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[$F{resposta}.equals("Não") ? 0 : $F{peso}]]></textFieldExpression> | |||
| </textField> | |||
| </band> | |||
| </detail> | |||
| <columnFooter> | |||
| <band splitType="Stretch"/> | |||
| </columnFooter> | |||
| <pageFooter> | |||
| <band height="50" splitType="Stretch"> | |||
| <image> | |||
| <reportElement x="651" y="0" width="140" height="50" uuid="9c042d00-6351-4972-9f9e-eda386f69b4e"/> | |||
| <imageExpression><![CDATA[new String("http://vitruvio.davinti.com.br/VAADIN/themes/vitruvio/images/logo_davinti_horizontal.jpg")]]></imageExpression> | |||
| </image> | |||
| </band> | |||
| </pageFooter> | |||
| <summary> | |||
| <band splitType="Stretch"/> | |||
| </summary> | |||
| </jasperReport> | |||
| @ -0,0 +1,78 @@ | |||
| <?xml version="1.0" encoding="UTF-8"?> | |||
| <report-form xmlns="http://www.davinti.com.br/vitruvio/form/report" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.davinti.com.br/vitruvio/form/report vitruvio-report-form.xsd"> | |||
| <form formKey="formDadosPassagem" width="100%"> | |||
| <name>Auditoria</name> | |||
| <description>Auditoria</description> | |||
| <components> | |||
| <VerticalLayout width="100%" margin="true" spacing="true"> | |||
| <Panel width="100%" caption="Parâmetros do relatório"> | |||
| <VerticalLayout width="100%" spacing="true" margin="true"> | |||
| <HorizontalLayout spacing="true" width="100%"> | |||
| <DBSearchField id="auditoria" caption="Auditoria" required="true" requiredMessage="É obrigatório informar uma auditoria" type="number" width="100%" searchViewRows="10" searchViewWidth="95%" searchViewHeight="90%"> | |||
| <datasource> | |||
| <freeQuery connection-key="Vitruvio"> | |||
| SELECT distinct E.CHAVE_EXECUCAO, E.DATAHORAABERTURA, C.TITULO, ne.razao_social FROM AUDITORIA_EXECUCAO E | |||
| INNER JOIN AUDITORIA C ON C.CHAVE_AUDITORIA = E.CHAVE_AUDITORIA | |||
| inner join auditoria_coleta cc on cc.chave_processo = e.chave_execucao | |||
| inner join nauth.empresa ne on ne.empresa_id = cc.empresa | |||
| inner join processo_instancia pi on pi.instancia_id = e.chave_execucao | |||
| where pi.status not in (3,5,6) | |||
| ORDER BY CHAVE_EXECUCAO DESC | |||
| </freeQuery> | |||
| </datasource> | |||
| <key-field>CHAVE_EXECUCAO</key-field> | |||
| <caption-field>TITULO</caption-field> | |||
| <columns> | |||
| <column name="CHAVE_EXECUCAO" caption="Código" expand-ratio="0.2"/> | |||
| <column name="TITULO" caption="Descrição" expand-ratio="1.0"/> | |||
| <column name="DATAHORAABERTURA" caption="Data de cadastro" expand-ratio="0.2"/> | |||
| <column name="RAZAO_SOCIAL" caption="Loja" expand-ratio="0.2"/> | |||
| </columns> | |||
| <events> | |||
| <valueChange> | |||
| <script language="JavaScript"> | |||
| <![CDATA[ | |||
| function run() { | |||
| /*var id = engine.getField('checklist').getValue(); | |||
| var s = 'Select distinct prop.usuario_fk usuario, cast(prop.valor_string as varchar(10)), ccl.chave_processo from nauth.empresa emp inner join nauth.usuario_propriedade prop on cast(prop.valor_string as varchar2(10)) = emp.id_sistema_externo inner join checklist_coleta ccl on ccl.empresa = emp.empresa_id where prop.propriedade_fk = 1 and ccl.chave_processo = ' + id; | |||
| var ds = vQueryService.executeQuery('Vitruvio', s); | |||
| if (ds.next()) { | |||
| var usuario = ds.getNumber('USUARIO'); | |||
| } | |||
| if (usuario) { | |||
| var sql = "SELECT U.NOME NOME FROM NAUTH.USUARIO_PROPRIEDADE UP INNER JOIN NAUTH.USUARIO US ON US.USUARIO_ID = UP.USUARIO_FK INNER JOIN NAUTH.USUARIO U ON U.USUARIO_ID = UP.USUARIO_FK WHERE UP.PROPRIEDADE_FK = 61 AND CAST(UP.VALOR_STRING AS VARCHAR(20)) = 'gerente' AND UP.USUARIO_FK = " + usuario; | |||
| var d = vQueryService.executeQuery('Vitruvio', sql); | |||
| if (d.next()) { | |||
| var gerente = d.getString('NOME'); | |||
| } | |||
| engine.getField('gerente').setValue(gerente); | |||
| } else { | |||
| engine.getField('gerente').setValue('Não definido'); | |||
| }*/ | |||
| } | |||
| ]]> | |||
| </script> | |||
| </valueChange> | |||
| </events> | |||
| <filterProperties> | |||
| <value>CHAVE_EXECUCAO</value> | |||
| <value>TITULO</value> | |||
| <value>DATAHORAABERTURA</value> | |||
| <value>RAZAO_SOCIAL</value> | |||
| </filterProperties> | |||
| </DBSearchField> | |||
| </HorizontalLayout> | |||
| <TextArea type="string" id="sqlinv" caption="SQL Inventario" width="100%" rows="6" required="false" | |||
| requiredMessage="Código Produto" visible="false" /> | |||
| <TextField type="string" id="gerente" visible="false" /> | |||
| </VerticalLayout> | |||
| </Panel> | |||
| </VerticalLayout> | |||
| </components> | |||
| </form> | |||
| </report-form> | |||
| @ -0,0 +1,377 @@ | |||
| <?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="Auditoria" pageWidth="842" pageHeight="595" orientation="Landscape" columnWidth="802" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" uuid="e4b6a11f-cfdc-4666-bae2-75464500b5ef"> | |||
| <property name="ireport.zoom" value="1.5"/> | |||
| <property name="ireport.x" value="0"/> | |||
| <property name="ireport.y" value="0"/> | |||
| <style name="Zebrado"> | |||
| <conditionalStyle> | |||
| <conditionExpression><![CDATA[new Boolean(($V{COLUMN_COUNT}.intValue() % 2) == 0)]]></conditionExpression> | |||
| <style backcolor="#CCCCCC"/> | |||
| </conditionalStyle> | |||
| <conditionalStyle> | |||
| <conditionExpression><![CDATA[new Boolean(($V{COLUMN_COUNT}.intValue() % 2) != 0)]]></conditionExpression> | |||
| <style/> | |||
| </conditionalStyle> | |||
| </style> | |||
| <style name="ResultadoFinal"> | |||
| <conditionalStyle> | |||
| <conditionExpression><![CDATA[($V{somaPontos} / $V{pesotag}) < 0.6]]></conditionExpression> | |||
| <style forecolor="#FF0000"/> | |||
| </conditionalStyle> | |||
| <conditionalStyle> | |||
| <conditionExpression><![CDATA[(($V{somaPontos} / $V{pesotag}) > 0.59) && (($V{somaPontos} / $V{pesotag}) < 0.8)]]></conditionExpression> | |||
| <style forecolor="#FFFF00"/> | |||
| </conditionalStyle> | |||
| <conditionalStyle> | |||
| <conditionExpression><![CDATA[($V{somaPontos} / $V{pesotag}) > 0.79]]></conditionExpression> | |||
| <style forecolor="#009900"/> | |||
| </conditionalStyle> | |||
| </style> | |||
| <style name="table"> | |||
| <box> | |||
| <pen lineWidth="1.0" lineColor="#000000"/> | |||
| </box> | |||
| </style> | |||
| <style name="table_TH" mode="Opaque" backcolor="#F0F8FF"> | |||
| <box> | |||
| <pen lineWidth="0.5" lineColor="#000000"/> | |||
| </box> | |||
| </style> | |||
| <style name="table_CH" mode="Opaque" backcolor="#BFE1FF"> | |||
| <box> | |||
| <pen lineWidth="0.5" lineColor="#000000"/> | |||
| </box> | |||
| </style> | |||
| <style name="table_TD" mode="Opaque" backcolor="#FFFFFF"> | |||
| <box> | |||
| <pen lineWidth="0.5" lineColor="#000000"/> | |||
| </box> | |||
| </style> | |||
| <style name="tag" mode="Opaque" backcolor="#999999"/> | |||
| <style name="cabecalho" mode="Opaque" backcolor="#CCCCCC"/> | |||
| <style name="tag2" mode="Opaque" backcolor="#CCCCCC"/> | |||
| <style name="ponto"/> | |||
| <subDataset name="Tabela" uuid="0e159536-d986-4489-b471-bdb5c6975772"> | |||
| <parameter name="auditoria" class="java.lang.Long"> | |||
| <defaultValueExpression><![CDATA[$P{auditoria}]]></defaultValueExpression> | |||
| </parameter> | |||
| <queryString> | |||
| <![CDATA[Select (select titulo from auditoria where chave_auditoria = $P{auditoria}) titulo, | |||
| tag_id,tag_id2, ponto_avaliado, pontuacao, | |||
| (Select nome from nauth.grupo where sigla = cq.usrespostanao) as grupoexec, | |||
| descrespostanao, | |||
| cq.pesoag1, | |||
| cq.pesoag2, | |||
| cq.pesoag3, | |||
| ordem | |||
| from auditoria_questoes cq where chave_auditoria = $P{auditoria} order by ordem,tag_id,tag_id2]]> | |||
| </queryString> | |||
| <field name="tag_id" class="java.lang.String"/> | |||
| <field name="tag_id2" class="java.lang.String"/> | |||
| <field name="titulo" class="java.lang.String"/> | |||
| <field name="ponto_avaliado" class="java.lang.String"/> | |||
| <field name="pontuacao" class="java.lang.Float"/> | |||
| <field name="grupoexec" class="java.lang.String"/> | |||
| <field name="descrespostanao" class="java.lang.String"/> | |||
| <field name="pesoag1" class="java.lang.Float"/> | |||
| <field name="pesoag2" class="java.lang.Float"/> | |||
| <variable name="totalTag" class="java.lang.Integer" incrementType="Group" incrementGroup="Tag" calculation="Count"> | |||
| <variableExpression><![CDATA[new Integer($V{totalTag})]]></variableExpression> | |||
| <initialValueExpression><![CDATA[new Integer(0)]]></initialValueExpression> | |||
| </variable> | |||
| <variable name="totalTag2" class="java.lang.Integer" resetType="Group" resetGroup="Tag" incrementType="Group" incrementGroup="Tag2" calculation="Count"> | |||
| <variableExpression><![CDATA[new Integer($V{totalTag2})]]></variableExpression> | |||
| <initialValueExpression><![CDATA[new Integer(0)]]></initialValueExpression> | |||
| </variable> | |||
| <variable name="totalItens" class="java.lang.Integer" resetType="Group" resetGroup="Tag2"> | |||
| <variableExpression><![CDATA[new Integer($V{totalItens}) + new Integer(1)]]></variableExpression> | |||
| <initialValueExpression><![CDATA[new Integer(0)]]></initialValueExpression> | |||
| </variable> | |||
| <variable name="totalAG1" class="java.lang.Double" resetType="Group" resetGroup="Tag" calculation="Sum"> | |||
| <variableExpression><![CDATA[new Double($F{pontuacao})]]></variableExpression> | |||
| <initialValueExpression><![CDATA[new Double(0)]]></initialValueExpression> | |||
| </variable> | |||
| <variable name="totalAG2" class="java.lang.Integer" resetType="Group" resetGroup="Tag2" calculation="Sum"> | |||
| <variableExpression><![CDATA[$V{totalAG2}]]></variableExpression> | |||
| </variable> | |||
| <variable name="pont1" class="java.lang.Float" resetType="Group" resetGroup="Tag" calculation="Sum"> | |||
| <variableExpression><![CDATA[$F{pontuacao}]]></variableExpression> | |||
| </variable> | |||
| <group name="group1"/> | |||
| <group name="Tag"> | |||
| <groupExpression><![CDATA[$F{tag_id}]]></groupExpression> | |||
| </group> | |||
| <group name="Tag2"> | |||
| <groupExpression><![CDATA[$F{tag_id2}]]></groupExpression> | |||
| </group> | |||
| </subDataset> | |||
| <parameter name="auditoria" class="java.lang.Long"> | |||
| <defaultValueExpression><![CDATA[342]]></defaultValueExpression> | |||
| </parameter> | |||
| <queryString> | |||
| <![CDATA[Select (select titulo from auditoria where chave_auditoria = $P{auditoria}) titulo, | |||
| tag_id,tag_id2, ponto_avaliado, pontuacao, | |||
| (Select nome from nauth.grupo where sigla = cq.usrespostanao) as grupoexec, | |||
| descrespostanao from auditoria_questoes cq where chave_auditoria = $P{auditoria} order by tag_id, tag_id2, ordem]]> | |||
| </queryString> | |||
| <field name="tag_id" class="java.lang.String"/> | |||
| <field name="tag_id2" class="java.lang.String"/> | |||
| <field name="titulo" class="java.lang.String"/> | |||
| <field name="ponto_avaliado" class="java.lang.String"/> | |||
| <field name="pontuacao" class="java.lang.Float"/> | |||
| <field name="grupoexec" class="java.lang.String"/> | |||
| <field name="descrespostanao" class="java.lang.String"/> | |||
| <variable name="totalTag" class="java.lang.Integer" incrementType="Group" incrementGroup="Tag" calculation="Count"> | |||
| <variableExpression><![CDATA[new Integer($V{totalTag})]]></variableExpression> | |||
| <initialValueExpression><![CDATA[new Integer(0)]]></initialValueExpression> | |||
| </variable> | |||
| <variable name="totalTag2" class="java.lang.Integer" resetType="Group" resetGroup="Tag" incrementType="Group" incrementGroup="Tag2" calculation="Count"> | |||
| <variableExpression><![CDATA[new Integer($V{totalTag2})]]></variableExpression> | |||
| <initialValueExpression><![CDATA[new Integer(0)]]></initialValueExpression> | |||
| </variable> | |||
| <variable name="totalItens" class="java.lang.Integer" resetType="Group" resetGroup="Tag2"> | |||
| <variableExpression><![CDATA[new Integer($V{totalItens}) + new Integer(1)]]></variableExpression> | |||
| <initialValueExpression><![CDATA[new Integer(0)]]></initialValueExpression> | |||
| </variable> | |||
| <variable name="totalAG1" class="java.lang.Double" resetType="Group" resetGroup="Tag" calculation="Sum"> | |||
| <variableExpression><![CDATA[new Double($F{pontuacao})]]></variableExpression> | |||
| <initialValueExpression><![CDATA[new Double(0)]]></initialValueExpression> | |||
| </variable> | |||
| <variable name="totalAG2" class="java.lang.Integer" resetType="Group" resetGroup="Tag2" calculation="Sum"> | |||
| <variableExpression><![CDATA[$V{totalAG2}]]></variableExpression> | |||
| </variable> | |||
| <variable name="pontuacao_1" class="java.lang.Float" resetType="Group" resetGroup="Tag" calculation="Sum"> | |||
| <variableExpression><![CDATA[$F{pontuacao}]]></variableExpression> | |||
| </variable> | |||
| <variable name="pontuacao_2" class="java.lang.Float" resetType="Group" resetGroup="Tag2" calculation="Sum"> | |||
| <variableExpression><![CDATA[$F{pontuacao}]]></variableExpression> | |||
| </variable> | |||
| <group name="Tag"> | |||
| <groupExpression><![CDATA[$F{tag_id}]]></groupExpression> | |||
| <groupHeader> | |||
| <band/> | |||
| </groupHeader> | |||
| </group> | |||
| <group name="Tag2"> | |||
| <groupExpression><![CDATA[$F{tag_id2}]]></groupExpression> | |||
| <groupHeader> | |||
| <band/> | |||
| </groupHeader> | |||
| </group> | |||
| <background> | |||
| <band splitType="Stretch"/> | |||
| </background> | |||
| <title> | |||
| <band splitType="Stretch"/> | |||
| </title> | |||
| <pageHeader> | |||
| <band splitType="Stretch"/> | |||
| </pageHeader> | |||
| <columnHeader> | |||
| <band splitType="Stretch"/> | |||
| </columnHeader> | |||
| <detail> | |||
| <band splitType="Stretch"/> | |||
| </detail> | |||
| <columnFooter> | |||
| <band splitType="Stretch"/> | |||
| </columnFooter> | |||
| <pageFooter> | |||
| <band splitType="Stretch"/> | |||
| </pageFooter> | |||
| <summary> | |||
| <band height="202" splitType="Stretch"> | |||
| <componentElement> | |||
| <reportElement key="table" style="table" x="0" y="0" width="788" height="202" uuid="430a0e18-6ebc-4d4f-9e86-509fa6c8bdbc"/> | |||
| <jr:table xmlns:jr="http://jasperreports.sourceforge.net/jasperreports/components" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports/components http://jasperreports.sourceforge.net/xsd/components.xsd"> | |||
| <datasetRun subDataset="Tabela" uuid="f33de750-63ef-4e06-a658-b9766ed242f6"> | |||
| <datasetParameter name="auditoria"> | |||
| <datasetParameterExpression><![CDATA[$P{auditoria}]]></datasetParameterExpression> | |||
| </datasetParameter> | |||
| <connectionExpression><![CDATA[$P{REPORT_CONNECTION}]]></connectionExpression> | |||
| </datasetRun> | |||
| <jr:columnGroup width="788" uuid="a24bcea4-27ac-441c-98b4-82a95cad087c"> | |||
| <jr:tableHeader height="29" rowSpan="1"> | |||
| <textField> | |||
| <reportElement mode="Opaque" x="0" y="0" width="788" height="29" backcolor="#999999" uuid="eecf1be5-758e-4ac4-8ece-e32d1ec3317b"/> | |||
| <textElement textAlignment="Center" verticalAlignment="Middle"> | |||
| <font fontName="Arial" size="16" isBold="true"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[$F{titulo}]]></textFieldExpression> | |||
| </textField> | |||
| </jr:tableHeader> | |||
| <jr:column width="457" uuid="58c79fd9-8845-473a-9ea7-9d040466cb7b"> | |||
| <jr:tableHeader style="cabecalho" height="24" rowSpan="1"> | |||
| <staticText> | |||
| <reportElement x="79" y="0" width="185" height="24" uuid="26a9ffa7-f1bb-48b6-bdc9-de22447569b5"/> | |||
| <textElement verticalAlignment="Middle"> | |||
| <font fontName="Arial" isBold="true"/> | |||
| </textElement> | |||
| <text><![CDATA[Ponto Avaliado]]></text> | |||
| </staticText> | |||
| </jr:tableHeader> | |||
| <jr:groupHeader groupName="group1"> | |||
| <jr:cell style="cabecalho" height="32" rowSpan="1"/> | |||
| </jr:groupHeader> | |||
| <jr:groupHeader groupName="Tag"> | |||
| <jr:cell style="tag" height="20" rowSpan="1"> | |||
| <textField> | |||
| <reportElement x="21" y="0" width="420" height="18" uuid="98c83601-0bbc-41b2-a711-746a3246b136"/> | |||
| <textElement verticalAlignment="Middle"> | |||
| <font fontName="Arial" size="8" isBold="true"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[$V{totalTag} + new Integer(1) + " - " + $F{tag_id}]]></textFieldExpression> | |||
| </textField> | |||
| </jr:cell> | |||
| </jr:groupHeader> | |||
| <jr:groupHeader groupName="Tag2"> | |||
| <jr:cell style="tag2" height="15" rowSpan="1"> | |||
| <textField> | |||
| <reportElement x="48" y="0" width="393" height="14" uuid="dab639d3-65ce-424d-94d6-503863090c8d"/> | |||
| <textElement verticalAlignment="Middle"> | |||
| <font fontName="Arial" size="8" isBold="true"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[new Integer(new Integer($V{totalTag2}) + new Integer(1)).toString().equals("1") ? (new Integer($V{totalTag})) + new Integer(1) + "." + (new Integer($V{totalTag2}) + new Integer(1)) + " - " + $F{tag_id2} : (new Integer($V{totalTag})) + "." + (new Integer($V{totalTag2}) + new Integer(1)) + " - " + $F{tag_id2}]]></textFieldExpression> | |||
| </textField> | |||
| </jr:cell> | |||
| </jr:groupHeader> | |||
| <jr:detailCell height="30" rowSpan="1"> | |||
| <textField isStretchWithOverflow="true"> | |||
| <reportElement x="79" y="0" width="362" height="30" uuid="eee2671a-1943-42a4-8c96-7fe07eca1174"/> | |||
| <textElement verticalAlignment="Middle"> | |||
| <font fontName="Arial" size="8"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[new Integer(new Integer($V{totalItens}) + new Integer(1)).toString().equals("1") ? | |||
| (new Integer($V{totalTag})) + new Integer(1) + "." + (new Integer($V{totalTag2}) + new Integer(1)) + $V{totalItens} + " - " + $F{ponto_avaliado} | |||
| : (new Integer($V{totalTag})) + "." + (new Integer($V{totalTag2})) + "." + (new Integer($V{totalItens})) + " - " + | |||
| $F{ponto_avaliado}]]></textFieldExpression> | |||
| </textField> | |||
| </jr:detailCell> | |||
| </jr:column> | |||
| <jr:column width="114" uuid="d9617f11-d44c-48ac-ba46-d21d5ff4da3b"> | |||
| <jr:tableHeader style="cabecalho" height="24" rowSpan="1"> | |||
| <staticText> | |||
| <reportElement x="0" y="0" width="111" height="24" uuid="17bd0ed4-c531-4f09-a7be-696413112e4f"/> | |||
| <textElement textAlignment="Center" verticalAlignment="Middle"> | |||
| <font fontName="Arial" isBold="true"/> | |||
| </textElement> | |||
| <text><![CDATA[Tarefa]]></text> | |||
| </staticText> | |||
| </jr:tableHeader> | |||
| <jr:groupHeader groupName="group1"> | |||
| <jr:cell style="cabecalho" height="32" rowSpan="1"> | |||
| <staticText> | |||
| <reportElement x="0" y="0" width="111" height="30" uuid="65ccb26c-557c-484a-9344-100d6404b16e"/> | |||
| <textElement> | |||
| <font fontName="Arial" size="8"/> | |||
| </textElement> | |||
| <text><![CDATA[Caso a resposta seja "n�o" qual tarefa ir� para o executor ou grupo executor]]></text> | |||
| </staticText> | |||
| </jr:cell> | |||
| </jr:groupHeader> | |||
| <jr:groupHeader groupName="Tag"> | |||
| <jr:cell style="tag" height="20" rowSpan="1"/> | |||
| </jr:groupHeader> | |||
| <jr:groupHeader groupName="Tag2"> | |||
| <jr:cell style="tag2" height="15" rowSpan="1"/> | |||
| </jr:groupHeader> | |||
| <jr:detailCell style="table_TD" height="30" rowSpan="1"> | |||
| <textField isStretchWithOverflow="true"> | |||
| <reportElement x="0" y="0" width="111" height="30" uuid="eef15f5b-8b18-41c7-852a-47f438f6fd61"/> | |||
| <textElement verticalAlignment="Middle"> | |||
| <font fontName="Arial" size="8"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[$F{descrespostanao}]]></textFieldExpression> | |||
| </textField> | |||
| </jr:detailCell> | |||
| </jr:column> | |||
| <jr:columnGroup width="66" uuid="f9be1184-a78c-4204-80e4-f9b5817a4870"> | |||
| <jr:column width="66" uuid="35e810be-3c2b-4585-af0e-41681415a01f"> | |||
| <jr:tableHeader style="cabecalho" height="24" rowSpan="1"> | |||
| <staticText> | |||
| <reportElement x="0" y="0" width="63" height="24" uuid="d8ab6505-8d07-4eb4-9a89-5c1544650d07"/> | |||
| <textElement textAlignment="Center" verticalAlignment="Middle"> | |||
| <font fontName="Arial" isBold="true"/> | |||
| </textElement> | |||
| <text><![CDATA[Pontos]]></text> | |||
| </staticText> | |||
| </jr:tableHeader> | |||
| <jr:groupHeader groupName="group1"> | |||
| <jr:cell style="cabecalho" height="32" rowSpan="1"/> | |||
| </jr:groupHeader> | |||
| <jr:groupHeader groupName="Tag"> | |||
| <jr:cell style="tag" height="20" rowSpan="1"> | |||
| <textField> | |||
| <reportElement x="0" y="0" width="63" height="20" uuid="b831b322-4541-4303-b904-6017a64df7d9"/> | |||
| <textElement textAlignment="Center" verticalAlignment="Middle"> | |||
| <font fontName="Arial" size="8" isBold="true"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[$F{pesoag1}]]></textFieldExpression> | |||
| </textField> | |||
| </jr:cell> | |||
| </jr:groupHeader> | |||
| <jr:groupHeader groupName="Tag2"> | |||
| <jr:cell style="tag2" height="15" rowSpan="1"> | |||
| <textField> | |||
| <reportElement x="0" y="0" width="63" height="15" uuid="37063f3d-12d9-4170-a842-979b802ae982"/> | |||
| <textElement textAlignment="Center" verticalAlignment="Middle"> | |||
| <font fontName="Arial" size="8" isBold="true"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[$F{pesoag2}]]></textFieldExpression> | |||
| </textField> | |||
| </jr:cell> | |||
| </jr:groupHeader> | |||
| <jr:detailCell style="table_TD" height="30" rowSpan="1"> | |||
| <textField isStretchWithOverflow="true"> | |||
| <reportElement x="0" y="0" width="63" height="30" uuid="bd965dae-2b4c-4cb2-a3a6-846ad7d182e9"/> | |||
| <textElement textAlignment="Center" verticalAlignment="Middle"> | |||
| <font fontName="Arial" size="8"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[$F{pontuacao}]]></textFieldExpression> | |||
| </textField> | |||
| </jr:detailCell> | |||
| </jr:column> | |||
| </jr:columnGroup> | |||
| <jr:column width="151" uuid="cffdde69-9658-49dd-a706-17941decd8ca"> | |||
| <jr:tableHeader style="cabecalho" height="24" rowSpan="1"> | |||
| <staticText> | |||
| <reportElement x="0" y="0" width="84" height="24" uuid="274416e2-0e19-4c40-85c0-1ae8d37423a3"/> | |||
| <textElement textAlignment="Center" verticalAlignment="Middle"> | |||
| <font fontName="Arial" isBold="true"/> | |||
| </textElement> | |||
| <text><![CDATA[Grupo executor]]></text> | |||
| </staticText> | |||
| </jr:tableHeader> | |||
| <jr:groupHeader groupName="group1"> | |||
| <jr:cell style="cabecalho" height="32" rowSpan="1"> | |||
| <staticText> | |||
| <reportElement x="0" y="0" width="81" height="30" uuid="b0181cec-6021-4e98-a167-b1cf46f6334f"/> | |||
| <textElement> | |||
| <font fontName="Arial" size="8"/> | |||
| </textElement> | |||
| <text><![CDATA[Caso a resposta seja "n�o" quem ir� realizar a tarefa]]></text> | |||
| </staticText> | |||
| </jr:cell> | |||
| </jr:groupHeader> | |||
| <jr:groupHeader groupName="Tag"> | |||
| <jr:cell style="tag" height="20" rowSpan="1"/> | |||
| </jr:groupHeader> | |||
| <jr:groupHeader groupName="Tag2"> | |||
| <jr:cell style="tag2" height="15" rowSpan="1"/> | |||
| </jr:groupHeader> | |||
| <jr:detailCell style="table_TD" height="30" rowSpan="1"> | |||
| <textField> | |||
| <reportElement x="0" y="0" width="81" height="30" uuid="8c785e03-6b67-4a17-890a-fcd8ece10620"/> | |||
| <textElement textAlignment="Center" verticalAlignment="Middle"> | |||
| <font fontName="Arial" size="8" isBold="false"/> | |||
| </textElement> | |||
| <textFieldExpression><![CDATA[$F{grupoexec}]]></textFieldExpression> | |||
| </textField> | |||
| </jr:detailCell> | |||
| </jr:column> | |||
| </jr:columnGroup> | |||
| </jr:table> | |||
| </componentElement> | |||
| </band> | |||
| </summary> | |||
| </jasperReport> | |||
| @ -0,0 +1,41 @@ | |||
| <?xml version="1.0" encoding="UTF-8"?> | |||
| <report-form xmlns="http://www.davinti.com.br/vitruvio/form/report" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.davinti.com.br/vitruvio/form/report vitruvio-report-form.xsd"> | |||
| <form formKey="formDadosPassagem" width="100%"> | |||
| <name>Auditoria</name> | |||
| <description>Auditoria</description> | |||
| <components> | |||
| <VerticalLayout width="100%" margin="true" spacing="true"> | |||
| <Panel width="100%" caption="Parâmetros do relatório"> | |||
| <VerticalLayout width="100%" spacing="true" margin="true"> | |||
| <HorizontalLayout spacing="true" width="100%"> | |||
| <DBSearchField id="auditoria" caption="Auditoria" required="true" requiredMessage="É obrigatório informar uma auditoria" type="number" width="100%" searchViewRows="10" searchViewWidth="95%" searchViewHeight="90%"> | |||
| <datasource> | |||
| <freeQuery connection-key="Vitruvio"> | |||
| Select chave_auditoria, titulo from auditoria | |||
| </freeQuery> | |||
| </datasource> | |||
| <key-field>CHAVE_AUDITORIA</key-field> | |||
| <caption-field>TITULO</caption-field> | |||
| <columns> | |||
| <column name="CHAVE_AUDITORIA" caption="Código" expand-ratio="0.2"/> | |||
| <column name="TITULO" caption="Descrição" expand-ratio="1.0"/> | |||
| </columns> | |||
| <filterProperties> | |||
| <value>CHAVE_AUDITORIA</value> | |||
| <value>TITULO</value> | |||
| </filterProperties> | |||
| </DBSearchField> | |||
| </HorizontalLayout> | |||
| <TextArea type="string" id="sqlinv" caption="SQL Inventario" width="100%" rows="6" required="false" | |||
| requiredMessage="Código Produto" visible="false" /> | |||
| </VerticalLayout> | |||
| </Panel> | |||
| </VerticalLayout> | |||
| </components> | |||
| </form> | |||
| </report-form> | |||
| @ -0,0 +1,843 @@ | |||
| <?xml version="1.0" encoding="UTF-8"?> | |||
| <transformation> | |||
| <info> | |||
| <name>Faturamento</name> | |||
| <description/> | |||
| <extended_description/> | |||
| <trans_version/> | |||
| <trans_type>Normal</trans_type> | |||
| <directory>/</directory> | |||
| <parameters> | |||
| </parameters> | |||
| <log> | |||
| <trans-log-table> | |||
| <connection/> | |||
| <schema/> | |||
| <table/> | |||
| <size_limit_lines/> | |||
| <interval/> | |||
| <timeout_days/> | |||
| <field> | |||
| <id>ID_BATCH</id> | |||
| <enabled>Y</enabled> | |||
| <name>ID_BATCH</name> | |||
| </field> | |||
| <field> | |||
| <id>CHANNEL_ID</id> | |||
| <enabled>Y</enabled> | |||
| <name>CHANNEL_ID</name> | |||
| </field> | |||
| <field> | |||
| <id>TRANSNAME</id> | |||
| <enabled>Y</enabled> | |||
| <name>TRANSNAME</name> | |||
| </field> | |||
| <field> | |||
| <id>STATUS</id> | |||
| <enabled>Y</enabled> | |||
| <name>STATUS</name> | |||
| </field> | |||
| <field> | |||
| <id>LINES_READ</id> | |||
| <enabled>Y</enabled> | |||
| <name>LINES_READ</name> | |||
| <subject/> | |||
| </field> | |||
| <field> | |||
| <id>LINES_WRITTEN</id> | |||
| <enabled>Y</enabled> | |||
| <name>LINES_WRITTEN</name> | |||
| <subject/> | |||
| </field> | |||
| <field> | |||
| <id>LINES_UPDATED</id> | |||
| <enabled>Y</enabled> | |||
| <name>LINES_UPDATED</name> | |||
| <subject/> | |||
| </field> | |||
| <field> | |||
| <id>LINES_INPUT</id> | |||
| <enabled>Y</enabled> | |||
| <name>LINES_INPUT</name> | |||
| <subject/> | |||
| </field> | |||
| <field> | |||
| <id>LINES_OUTPUT</id> | |||
| <enabled>Y</enabled> | |||
| <name>LINES_OUTPUT</name> | |||
| <subject/> | |||
| </field> | |||
| <field> | |||
| <id>LINES_REJECTED</id> | |||
| <enabled>Y</enabled> | |||
| <name>LINES_REJECTED</name> | |||
| <subject/> | |||
| </field> | |||
| <field> | |||
| <id>ERRORS</id> | |||
| <enabled>Y</enabled> | |||
| <name>ERRORS</name> | |||
| </field> | |||
| <field> | |||
| <id>STARTDATE</id> | |||
| <enabled>Y</enabled> | |||
| <name>STARTDATE</name> | |||
| </field> | |||
| <field> | |||
| <id>ENDDATE</id> | |||
| <enabled>Y</enabled> | |||
| <name>ENDDATE</name> | |||
| </field> | |||
| <field> | |||
| <id>LOGDATE</id> | |||
| <enabled>Y</enabled> | |||
| <name>LOGDATE</name> | |||
| </field> | |||
| <field> | |||
| <id>DEPDATE</id> | |||
| <enabled>Y</enabled> | |||
| <name>DEPDATE</name> | |||
| </field> | |||
| <field> | |||
| <id>REPLAYDATE</id> | |||
| <enabled>Y</enabled> | |||
| <name>REPLAYDATE</name> | |||
| </field> | |||
| <field> | |||
| <id>LOG_FIELD</id> | |||
| <enabled>Y</enabled> | |||
| <name>LOG_FIELD</name> | |||
| </field> | |||
| <field> | |||
| <id>EXECUTING_SERVER</id> | |||
| <enabled>N</enabled> | |||
| <name>EXECUTING_SERVER</name> | |||
| </field> | |||
| <field> | |||
| <id>EXECUTING_USER</id> | |||
| <enabled>N</enabled> | |||
| <name>EXECUTING_USER</name> | |||
| </field> | |||
| <field> | |||
| <id>CLIENT</id> | |||
| <enabled>N</enabled> | |||
| <name>CLIENT</name> | |||
| </field> | |||
| </trans-log-table> | |||
| <perf-log-table> | |||
| <connection/> | |||
| <schema/> | |||
| <table/> | |||
| <interval/> | |||
| <timeout_days/> | |||
| <field> | |||
| <id>ID_BATCH</id> | |||
| <enabled>Y</enabled> | |||
| <name>ID_BATCH</name> | |||
| </field> | |||
| <field> | |||
| <id>SEQ_NR</id> | |||
| <enabled>Y</enabled> | |||
| <name>SEQ_NR</name> | |||
| </field> | |||
| <field> | |||
| <id>LOGDATE</id> | |||
| <enabled>Y</enabled> | |||
| <name>LOGDATE</name> | |||
| </field> | |||
| <field> | |||
| <id>TRANSNAME</id> | |||
| <enabled>Y</enabled> | |||
| <name>TRANSNAME</name> | |||
| </field> | |||
| <field> | |||
| <id>STEPNAME</id> | |||
| <enabled>Y</enabled> | |||
| <name>STEPNAME</name> | |||
| </field> | |||
| <field> | |||
| <id>STEP_COPY</id> | |||
| <enabled>Y</enabled> | |||
| <name>STEP_COPY</name> | |||
| </field> | |||
| <field> | |||
| <id>LINES_READ</id> | |||
| <enabled>Y</enabled> | |||
| <name>LINES_READ</name> | |||
| </field> | |||
| <field> | |||
| <id>LINES_WRITTEN</id> | |||
| <enabled>Y</enabled> | |||
| <name>LINES_WRITTEN</name> | |||
| </field> | |||
| <field> | |||
| <id>LINES_UPDATED</id> | |||
| <enabled>Y</enabled> | |||
| <name>LINES_UPDATED</name> | |||
| </field> | |||
| <field> | |||
| <id>LINES_INPUT</id> | |||
| <enabled>Y</enabled> | |||
| <name>LINES_INPUT</name> | |||
| </field> | |||
| <field> | |||
| <id>LINES_OUTPUT</id> | |||
| <enabled>Y</enabled> | |||
| <name>LINES_OUTPUT</name> | |||
| </field> | |||
| <field> | |||
| <id>LINES_REJECTED</id> | |||
| <enabled>Y</enabled> | |||
| <name>LINES_REJECTED</name> | |||
| </field> | |||
| <field> | |||
| <id>ERRORS</id> | |||
| <enabled>Y</enabled> | |||
| <name>ERRORS</name> | |||
| </field> | |||
| <field> | |||
| <id>INPUT_BUFFER_ROWS</id> | |||
| <enabled>Y</enabled> | |||
| <name>INPUT_BUFFER_ROWS</name> | |||
| </field> | |||
| <field> | |||
| <id>OUTPUT_BUFFER_ROWS</id> | |||
| <enabled>Y</enabled> | |||
| <name>OUTPUT_BUFFER_ROWS</name> | |||
| </field> | |||
| </perf-log-table> | |||
| <channel-log-table> | |||
| <connection/> | |||
| <schema/> | |||
| <table/> | |||
| <timeout_days/> | |||
| <field> | |||
| <id>ID_BATCH</id> | |||
| <enabled>Y</enabled> | |||
| <name>ID_BATCH</name> | |||
| </field> | |||
| <field> | |||
| <id>CHANNEL_ID</id> | |||
| <enabled>Y</enabled> | |||
| <name>CHANNEL_ID</name> | |||
| </field> | |||
| <field> | |||
| <id>LOG_DATE</id> | |||
| <enabled>Y</enabled> | |||
| <name>LOG_DATE</name> | |||
| </field> | |||
| <field> | |||
| <id>LOGGING_OBJECT_TYPE</id> | |||
| <enabled>Y</enabled> | |||
| <name>LOGGING_OBJECT_TYPE</name> | |||
| </field> | |||
| <field> | |||
| <id>OBJECT_NAME</id> | |||
| <enabled>Y</enabled> | |||
| <name>OBJECT_NAME</name> | |||
| </field> | |||
| <field> | |||
| <id>OBJECT_COPY</id> | |||
| <enabled>Y</enabled> | |||
| <name>OBJECT_COPY</name> | |||
| </field> | |||
| <field> | |||
| <id>REPOSITORY_DIRECTORY</id> | |||
| <enabled>Y</enabled> | |||
| <name>REPOSITORY_DIRECTORY</name> | |||
| </field> | |||
| <field> | |||
| <id>FILENAME</id> | |||
| <enabled>Y</enabled> | |||
| <name>FILENAME</name> | |||
| </field> | |||
| <field> | |||
| <id>OBJECT_ID</id> | |||
| <enabled>Y</enabled> | |||
| <name>OBJECT_ID</name> | |||
| </field> | |||
| <field> | |||
| <id>OBJECT_REVISION</id> | |||
| <enabled>Y</enabled> | |||
| <name>OBJECT_REVISION</name> | |||
| </field> | |||
| <field> | |||
| <id>PARENT_CHANNEL_ID</id> | |||
| <enabled>Y</enabled> | |||
| <name>PARENT_CHANNEL_ID</name> | |||
| </field> | |||
| <field> | |||
| <id>ROOT_CHANNEL_ID</id> | |||
| <enabled>Y</enabled> | |||
| <name>ROOT_CHANNEL_ID</name> | |||
| </field> | |||
| </channel-log-table> | |||
| <step-log-table> | |||
| <connection/> | |||
| <schema/> | |||
| <table/> | |||
| <timeout_days/> | |||
| <field> | |||
| <id>ID_BATCH</id> | |||
| <enabled>Y</enabled> | |||
| <name>ID_BATCH</name> | |||
| </field> | |||
| <field> | |||
| <id>CHANNEL_ID</id> | |||
| <enabled>Y</enabled> | |||
| <name>CHANNEL_ID</name> | |||
| </field> | |||
| <field> | |||
| <id>LOG_DATE</id> | |||
| <enabled>Y</enabled> | |||
| <name>LOG_DATE</name> | |||
| </field> | |||
| <field> | |||
| <id>TRANSNAME</id> | |||
| <enabled>Y</enabled> | |||
| <name>TRANSNAME</name> | |||
| </field> | |||
| <field> | |||
| <id>STEPNAME</id> | |||
| <enabled>Y</enabled> | |||
| <name>STEPNAME</name> | |||
| </field> | |||
| <field> | |||
| <id>STEP_COPY</id> | |||
| <enabled>Y</enabled> | |||
| <name>STEP_COPY</name> | |||
| </field> | |||
| <field> | |||
| <id>LINES_READ</id> | |||
| <enabled>Y</enabled> | |||
| <name>LINES_READ</name> | |||
| </field> | |||
| <field> | |||
| <id>LINES_WRITTEN</id> | |||
| <enabled>Y</enabled> | |||
| <name>LINES_WRITTEN</name> | |||
| </field> | |||
| <field> | |||
| <id>LINES_UPDATED</id> | |||
| <enabled>Y</enabled> | |||
| <name>LINES_UPDATED</name> | |||
| </field> | |||
| <field> | |||
| <id>LINES_INPUT</id> | |||
| <enabled>Y</enabled> | |||
| <name>LINES_INPUT</name> | |||
| </field> | |||
| <field> | |||
| <id>LINES_OUTPUT</id> | |||
| <enabled>Y</enabled> | |||
| <name>LINES_OUTPUT</name> | |||
| </field> | |||
| <field> | |||
| <id>LINES_REJECTED</id> | |||
| <enabled>Y</enabled> | |||
| <name>LINES_REJECTED</name> | |||
| </field> | |||
| <field> | |||
| <id>ERRORS</id> | |||
| <enabled>Y</enabled> | |||
| <name>ERRORS</name> | |||
| </field> | |||
| <field> | |||
| <id>LOG_FIELD</id> | |||
| <enabled>N</enabled> | |||
| <name>LOG_FIELD</name> | |||
| </field> | |||
| </step-log-table> | |||
| <metrics-log-table> | |||
| <connection/> | |||
| <schema/> | |||
| <table/> | |||
| <timeout_days/> | |||
| <field> | |||
| <id>ID_BATCH</id> | |||
| <enabled>Y</enabled> | |||
| <name>ID_BATCH</name> | |||
| </field> | |||
| <field> | |||
| <id>CHANNEL_ID</id> | |||
| <enabled>Y</enabled> | |||
| <name>CHANNEL_ID</name> | |||
| </field> | |||
| <field> | |||
| <id>LOG_DATE</id> | |||
| <enabled>Y</enabled> | |||
| <name>LOG_DATE</name> | |||
| </field> | |||
| <field> | |||
| <id>METRICS_DATE</id> | |||
| <enabled>Y</enabled> | |||
| <name>METRICS_DATE</name> | |||
| </field> | |||
| <field> | |||
| <id>METRICS_CODE</id> | |||
| <enabled>Y</enabled> | |||
| <name>METRICS_CODE</name> | |||
| </field> | |||
| <field> | |||
| <id>METRICS_DESCRIPTION</id> | |||
| <enabled>Y</enabled> | |||
| <name>METRICS_DESCRIPTION</name> | |||
| </field> | |||
| <field> | |||
| <id>METRICS_SUBJECT</id> | |||
| <enabled>Y</enabled> | |||
| <name>METRICS_SUBJECT</name> | |||
| </field> | |||
| <field> | |||
| <id>METRICS_TYPE</id> | |||
| <enabled>Y</enabled> | |||
| <name>METRICS_TYPE</name> | |||
| </field> | |||
| <field> | |||
| <id>METRICS_VALUE</id> | |||
| <enabled>Y</enabled> | |||
| <name>METRICS_VALUE</name> | |||
| </field> | |||
| </metrics-log-table> | |||
| </log> | |||
| <maxdate> | |||
| <connection/> | |||
| <table/> | |||
| <field/> | |||
| <offset>0.0</offset> | |||
| <maxdiff>0.0</maxdiff> | |||
| </maxdate> | |||
| <size_rowset>10000</size_rowset> | |||
| <sleep_time_empty>50</sleep_time_empty> | |||
| <sleep_time_full>50</sleep_time_full> | |||
| <unique_connections>N</unique_connections> | |||
| <feedback_shown>Y</feedback_shown> | |||
| <feedback_size>50000</feedback_size> | |||
| <using_thread_priorities>Y</using_thread_priorities> | |||
| <shared_objects_file/> | |||
| <capture_step_performance>N</capture_step_performance> | |||
| <step_performance_capturing_delay>1000</step_performance_capturing_delay> | |||
| <step_performance_capturing_size_limit>100</step_performance_capturing_size_limit> | |||
| <dependencies> | |||
| </dependencies> | |||
| <partitionschemas> | |||
| </partitionschemas> | |||
| <slaveservers> | |||
| </slaveservers> | |||
| <clusterschemas> | |||
| </clusterschemas> | |||
| <created_user>-</created_user> | |||
| <created_date>2018/06/08 13:55:30.436</created_date> | |||
| <modified_user>-</modified_user> | |||
| <modified_date>2018/06/08 13:55:30.436</modified_date> | |||
| <key_for_session_key>H4sIAAAAAAAAAAMAAAAAAAAAAAA=</key_for_session_key> | |||
| <is_key_private>N</is_key_private> | |||
| </info> | |||
| <notepads> | |||
| </notepads> | |||
| <connection> | |||
| <name>GF - Consinco</name> | |||
| <server>10.0.0.7</server> | |||
| <type>ORACLE</type> | |||
| <access>Native</access> | |||
| <database>DBGF</database> | |||
| <port>1521</port> | |||
| <username>consinco</username> | |||
| <password>Encrypted 2be98afc86aa7f2e4a816a063d79cacd5</password> | |||
| <servername/> | |||
| <data_tablespace/> | |||
| <index_tablespace/> | |||
| <attributes> | |||
| <attribute> | |||
| <code>FORCE_IDENTIFIERS_TO_LOWERCASE</code> | |||
| <attribute>N</attribute> | |||
| </attribute> | |||
| <attribute> | |||
| <code>FORCE_IDENTIFIERS_TO_UPPERCASE</code> | |||
| <attribute>N</attribute> | |||
| </attribute> | |||
| <attribute> | |||
| <code>IS_CLUSTERED</code> | |||
| <attribute>N</attribute> | |||
| </attribute> | |||
| <attribute> | |||
| <code>PORT_NUMBER</code> | |||
| <attribute>1521</attribute> | |||
| </attribute> | |||
| <attribute> | |||
| <code>PRESERVE_RESERVED_WORD_CASE</code> | |||
| <attribute>Y</attribute> | |||
| </attribute> | |||
| <attribute> | |||
| <code>QUOTE_ALL_FIELDS</code> | |||
| <attribute>N</attribute> | |||
| </attribute> | |||
| <attribute> | |||
| <code>STRICT_NUMBER_38_INTERPRETATION</code> | |||
| <attribute>N</attribute> | |||
| </attribute> | |||
| <attribute> | |||
| <code>SUPPORTS_BOOLEAN_DATA_TYPE</code> | |||
| <attribute>Y</attribute> | |||
| </attribute> | |||
| <attribute> | |||
| <code>SUPPORTS_TIMESTAMP_DATA_TYPE</code> | |||
| <attribute>Y</attribute> | |||
| </attribute> | |||
| <attribute> | |||
| <code>USE_POOLING</code> | |||
| <attribute>N</attribute> | |||
| </attribute> | |||
| </attributes> | |||
| </connection> | |||
| <connection> | |||
| <name>GF - Vitruvio</name> | |||
| <server>10.0.0.7</server> | |||
| <type>ORACLE</type> | |||
| <access>Native</access> | |||
| <database>DBGF</database> | |||
| <port>1521</port> | |||
| <username>vitruvio</username> | |||
| <password>Encrypted 2be98afc86aa7f2e4cb79ce63db9ca7db</password> | |||
| <servername/> | |||
| <data_tablespace/> | |||
| <index_tablespace/> | |||
| <attributes> | |||
| <attribute> | |||
| <code>FORCE_IDENTIFIERS_TO_LOWERCASE</code> | |||
| <attribute>N</attribute> | |||
| </attribute> | |||
| <attribute> | |||
| <code>FORCE_IDENTIFIERS_TO_UPPERCASE</code> | |||
| <attribute>N</attribute> | |||
| </attribute> | |||
| <attribute> | |||
| <code>IS_CLUSTERED</code> | |||
| <attribute>N</attribute> | |||
| </attribute> | |||
| <attribute> | |||
| <code>PORT_NUMBER</code> | |||
| <attribute>1521</attribute> | |||
| </attribute> | |||
| <attribute> | |||
| <code>PRESERVE_RESERVED_WORD_CASE</code> | |||
| <attribute>Y</attribute> | |||
| </attribute> | |||
| <attribute> | |||
| <code>QUOTE_ALL_FIELDS</code> | |||
| <attribute>N</attribute> | |||
| </attribute> | |||
| <attribute> | |||
| <code>STRICT_NUMBER_38_INTERPRETATION</code> | |||
| <attribute>N</attribute> | |||
| </attribute> | |||
| <attribute> | |||
| <code>SUPPORTS_BOOLEAN_DATA_TYPE</code> | |||
| <attribute>Y</attribute> | |||
| </attribute> | |||
| <attribute> | |||
| <code>SUPPORTS_TIMESTAMP_DATA_TYPE</code> | |||
| <attribute>Y</attribute> | |||
| </attribute> | |||
| <attribute> | |||
| <code>USE_POOLING</code> | |||
| <attribute>N</attribute> | |||
| </attribute> | |||
| </attributes> | |||
| </connection> | |||
| <order> | |||
| <hop> | |||
| <from>Table input</from> | |||
| <to>Add sequence</to> | |||
| <enabled>Y</enabled> | |||
| </hop> | |||
| <hop> | |||
| <from>Add sequence</from> | |||
| <to>Insert / Update</to> | |||
| <enabled>Y</enabled> | |||
| </hop> | |||
| </order> | |||
| <step> | |||
| <name>Add sequence</name> | |||
| <type>Sequence</type> | |||
| <description/> | |||
| <distribute>Y</distribute> | |||
| <custom_distribution/> | |||
| <copies>1</copies> | |||
| <partitioning> | |||
| <method>none</method> | |||
| <schema_name/> | |||
| </partitioning> | |||
| <valuename>BSC_FATURAMENTO_SEQ</valuename> | |||
| <use_database>Y</use_database> | |||
| <connection>GF - Vitruvio</connection> | |||
| <schema/> | |||
| <seqname>BSC_FATURAMENTO_SEQ</seqname> | |||
| <use_counter>N</use_counter> | |||
| <counter_name/> | |||
| <start_at>1</start_at> | |||
| <increment_by>1</increment_by> | |||
| <max_value>999999999</max_value> | |||
| <cluster_schema/> | |||
| <remotesteps> | |||
| <input> | |||
| </input> | |||
| <output> | |||
| </output> | |||
| </remotesteps> | |||
| <GUI> | |||
| <xloc>256</xloc> | |||
| <yloc>80</yloc> | |||
| <draw>Y</draw> | |||
| </GUI> | |||
| </step> | |||
| <step> | |||
| <name>Insert / Update</name> | |||
| <type>InsertUpdate</type> | |||
| <description/> | |||
| <distribute>Y</distribute> | |||
| <custom_distribution/> | |||
| <copies>1</copies> | |||
| <partitioning> | |||
| <method>none</method> | |||
| <schema_name/> | |||
| </partitioning> | |||
| <connection>GF - Vitruvio</connection> | |||
| <commit>500</commit> | |||
| <update_bypassed>N</update_bypassed> | |||
| <lookup> | |||
| <schema/> | |||
| <table>BSC_FATURAMENTO</table> | |||
| <key> | |||
| <name>NROEMPRESA</name> | |||
| <field>CHAVE_EMPRESA</field> | |||
| <condition>=</condition> | |||
| <name2/> | |||
| </key> | |||
| <key> | |||
| <name>SEQPRODUTO</name> | |||
| <field>CHAVE_PRODUTO</field> | |||
| <condition>=</condition> | |||
| <name2/> | |||
| </key> | |||
| <key> | |||
| <name>SEQFAMILIA</name> | |||
| <field>CHAVE_FAMILIA</field> | |||
| <condition>=</condition> | |||
| <name2/> | |||
| </key> | |||
| <key> | |||
| <name>REFERENCIA</name> | |||
| <field>REFERENCIA</field> | |||
| <condition>=</condition> | |||
| <name2/> | |||
| </key> | |||
| <key> | |||
| <name>CHAVE_CATEGORIA_PAI</name> | |||
| <field>CHAVE_CATEGORIA_PAI</field> | |||
| <condition>=</condition> | |||
| <name2/> | |||
| </key> | |||
| <key> | |||
| <name>CHAVE_CATEGORIA</name> | |||
| <field>CHAVE_CATEGORIA</field> | |||
| <condition>=</condition> | |||
| <name2/> | |||
| </key> | |||
| <value> | |||
| <name>CHAVE_FATURAMENTO</name> | |||
| <rename>BSC_FATURAMENTO_SEQ</rename> | |||
| <update>N</update> | |||
| </value> | |||
| <value> | |||
| <name>CHAVE_EMPRESA</name> | |||
| <rename>NROEMPRESA</rename> | |||
| <update>N</update> | |||
| </value> | |||
| <value> | |||
| <name>CATEGORIA_PAI</name> | |||
| <rename>CATEGORIAPAI</rename> | |||
| <update>N</update> | |||
| </value> | |||
| <value> | |||
| <name>CATEGORIA</name> | |||
| <rename>CATEGORIA</rename> | |||
| <update>N</update> | |||
| </value> | |||
| <value> | |||
| <name>CHAVE_PRODUTO</name> | |||
| <rename>SEQPRODUTO</rename> | |||
| <update>N</update> | |||
| </value> | |||
| <value> | |||
| <name>DESCRICAO_PRODUTO</name> | |||
| <rename>DESCRICAOPRODUTO</rename> | |||
| <update>Y</update> | |||
| </value> | |||
| <value> | |||
| <name>CHAVE_FAMILIA</name> | |||
| <rename>SEQFAMILIA</rename> | |||
| <update>N</update> | |||
| </value> | |||
| <value> | |||
| <name>QUANTIDADE</name> | |||
| <rename>QTDITEM</rename> | |||
| <update>Y</update> | |||
| </value> | |||
| <value> | |||
| <name>VALOR_VENDA</name> | |||
| <rename>VLRITEM</rename> | |||
| <update>Y</update> | |||
| </value> | |||
| <value> | |||
| <name>VALOR_BRUTO</name> | |||
| <rename>CTOBRUTOVDA</rename> | |||
| <update>Y</update> | |||
| </value> | |||
| <value> | |||
| <name>REFERENCIA</name> | |||
| <rename>REFERENCIA</rename> | |||
| <update>N</update> | |||
| </value> | |||
| <value> | |||
| <name>CHAVE_CATEGORIA_PAI</name> | |||
| <rename>CHAVE_CATEGORIA_PAI</rename> | |||
| <update>N</update> | |||
| </value> | |||
| <value> | |||
| <name>CHAVE_CATEGORIA</name> | |||
| <rename>CHAVE_CATEGORIA</rename> | |||
| <update>N</update> | |||
| </value> | |||
| </lookup> | |||
| <cluster_schema/> | |||
| <remotesteps> | |||
| <input> | |||
| </input> | |||
| <output> | |||
| </output> | |||
| </remotesteps> | |||
| <GUI> | |||
| <xloc>400</xloc> | |||
| <yloc>80</yloc> | |||
| <draw>Y</draw> | |||
| </GUI> | |||
| </step> | |||
| <step> | |||
| <name>Table input</name> | |||
| <type>TableInput</type> | |||
| <description/> | |||
| <distribute>Y</distribute> | |||
| <custom_distribution/> | |||
| <copies>1</copies> | |||
| <partitioning> | |||
| <method>none</method> | |||
| <schema_name/> | |||
| </partitioning> | |||
| <connection>GF - Consinco</connection> | |||
| <sql>Select | |||
| V.NROEMPRESA, | |||
| (Select c.seqcategoria | |||
| from map_categoria c | |||
| inner join map_famdivcateg fc | |||
| on fc.seqcategoria = c.seqcategoria | |||
| where c.tipcategoria = 'M' | |||
| and fc.status = 'A' | |||
| and fc.seqfamilia = a.seqfamilia | |||
| AND FC.NRODIVISAO = 2 | |||
| and c.nivelhierarquia = 1 and rownum = 1) chave_categoria_pai, | |||
| (Select c.categoria | |||
| from map_categoria c | |||
| inner join map_famdivcateg fc | |||
| on fc.seqcategoria = c.seqcategoria | |||
| where c.tipcategoria = 'M' | |||
| and fc.status = 'A' | |||
| and fc.seqfamilia = a.seqfamilia | |||
| AND FC.NRODIVISAO = 2 | |||
| and c.nivelhierarquia = 1 and rownum = 1) categoriapai, | |||
| (Select c.seqcategoria | |||
| from map_categoria c | |||
| inner join map_famdivcateg fc | |||
| on fc.seqcategoria = c.seqcategoria | |||
| where c.tipcategoria = 'M' | |||
| and fc.status = 'A' | |||
| and fc.seqfamilia = a.seqfamilia | |||
| AND FC.NRODIVISAO = 2 | |||
| and c.nivelhierarquia = 2 and rownum = 1) chave_categoria, | |||
| (Select c.categoria | |||
| from map_categoria c | |||
| inner join map_famdivcateg fc | |||
| on fc.seqcategoria = c.seqcategoria | |||
| where c.tipcategoria = 'M' | |||
| and fc.status = 'A' | |||
| and fc.seqfamilia = a.seqfamilia | |||
| AND FC.NRODIVISAO = 2 | |||
| and c.nivelhierarquia = 2 and rownum = 1) categoria, | |||
| V.SEQPRODUTO, | |||
| (Select desccompleta from map_produto where seqproduto = v.seqproduto) descricaoproduto, | |||
| A.SEQFAMILIA, | |||
| sum( round(( V.QTDITEM - V.QTDDEVOLITEM ) / K.QTDEMBALAGEM , 6) ) as QTDITEM, | |||
| sum((( case when 'N' in ( 'S', 'V' ) then V.VLRITEMSEMDESC | |||
| else V.VLRITEM | |||
| end ) - ( V.VLRDEVOLITEM )) ) | |||
| as VLRITEM, | |||
| sum( | |||
| ( ( Y.CMDIAVLRNF + Y.CMDIAIPI + Y.CMDIAICMSST + Y.CMDIADESPNF + Y.CMDIADESPFORANF - Y.CMDIADCTOFORANF ) * | |||
| DECODE('S','N',1, NVL( a.propqtdprodutobase, 1) ) | |||
| - ( decode( Y.QTDVERBAVDA, 0, 0, Y.VLRVERBAVDA * | |||
| DECODE('S','N',1, NVL( a.propqtdprodutobase, 1) ) / Y.QTDVDA ) ) ) | |||
| * ( V.QTDITEM - V.QTDDEVOLITEM ) ) | |||
| as CTOBRUTOVDA, | |||
| trunc(sysdate,'MM') referencia | |||
| from MRL_CUSTODIAFAM Y, MAXV_ABCDISTRIBBASE V, MAP_PRODUTO A, MAP_PRODUTO PB, MAP_FAMDIVISAO D, MAP_FAMFORNEC F, MAX_COMPRADOR O, MAP_FAMEMBALAGEM K, MAX_EMPRESA E, MAD_FAMSEGMENTO H, MAP_FAMEMBALAGEM K2, MAP_FAMEMBALAGEM K3 | |||
| where D.SEQFAMILIA = A.SEQFAMILIA | |||
| and D.NRODIVISAO = 2 | |||
| and V.NROEMPRESA in ( 1,2,3,4,6,7,8,9,110,111,112,13,14,17 ,15) | |||
| and V.SEQPRODUTO = A.SEQPRODUTO | |||
| and V.SEQPRODUTOCUSTO = PB.SEQPRODUTO | |||
| AND V.CODGERALOPER IN (502,515) | |||
| and E.NROEMPRESA = V.NROEMPRESA | |||
| and TRUNC(V.DTAVDA) between trunc(sysdate,'MM') and trunc(sysdate) - 1 | |||
| and Y.NROEMPRESA = nvl( E.NROEMPCUSTOABC, E.NROEMPRESA ) | |||
| and Y.DTAENTRADASAIDA = V.DTAVDA | |||
| and K.SEQFAMILIA = A.SEQFAMILIA | |||
| and K.QTDEMBALAGEM = H.PADRAOEMBVENDA | |||
| and K2.SEQFAMILIA = D.SEQFAMILIA | |||
| and K2.QTDEMBALAGEM = fpadraoembcompraprod(A.SEQPRODUTO, D.NRODIVISAO) | |||
| and K3.SEQFAMILIA = D.SEQFAMILIA | |||
| and K3.QTDEMBALAGEM = nvl(fpadraoembtransf( D.SEQFAMILIA, D.NRODIVISAO ),fPadraoEmbVenda( D.SEQFAMILIA, D.NRODIVISAO )) | |||
| and F.SEQFAMILIA = D.SEQFAMILIA | |||
| and F.PRINCIPAL = 'S' | |||
| and D.SEQCOMPRADOR = O.SEQCOMPRADOR | |||
| and Y.SEQFAMILIA = PB.SEQFAMILIA | |||
| and H.SEQFAMILIA = A.SEQFAMILIA | |||
| and H.NROSEGMENTO = V.NROSEGMENTO | |||
| and DECODE(V.TIPTABELA, 'S', V.CGOACMCOMPRAVENDA, 'A', V.CGOACMCOMPRAVENDA, V.ACMCOMPRAVENDA) in ( 'S', 'I' ) | |||
| group by | |||
| V.NROEMPRESA, | |||
| V.SEQPRODUTO, | |||
| A.SEQFAMILIA</sql> | |||
| <limit>0</limit> | |||
| <lookup/> | |||
| <execute_each_row>N</execute_each_row> | |||
| <variables_active>N</variables_active> | |||
| <lazy_conversion_active>N</lazy_conversion_active> | |||
| <cluster_schema/> | |||
| <remotesteps> | |||
| <input> | |||
| </input> | |||
| <output> | |||
| </output> | |||
| </remotesteps> | |||
| <GUI> | |||
| <xloc>128</xloc> | |||
| <yloc>80</yloc> | |||
| <draw>Y</draw> | |||
| </GUI> | |||
| </step> | |||
| <step_error_handling> | |||
| </step_error_handling> | |||
| <slave-step-copy-partition-distribution> | |||
| </slave-step-copy-partition-distribution> | |||
| <slave_transformation>N</slave_transformation> | |||
| </transformation> | |||