Package ar.com.fdvs.dj.domain

Examples of ar.com.fdvs.dj.domain.DynamicReport


  }

  public void doPrint() throws JRException, ColumnBuilderException, ClassNotFoundException, IOException {

    FastReportBuilder drb = new FastReportBuilder();
    DynamicReport dr;

    /**
     * Set the styles. In a report created with DynamicReportBuilder we do
     * this in an other way.
     */
 
View Full Code Here


    DynamicReportBuilder drbContent = new DynamicReportBuilder();

    // get the styles
    DJReportStyles djrst = getDjReportStyles();

    DynamicReport drHeaderSubreport = new DJLetterHead();
    drbContent.addSubreportInGroupHeader(1, drHeaderSubreport, new ClassicLayoutManager(), "", DJConstants.DATA_SOURCE_ORIGIN_FIELD, DJConstants.DATA_SOURCE_TYPE_COLLECTION);

    // Sets the Report Columns, header, Title, Groups, Etc Formats
    // DynamicJasper documentation
    drbContent.setTitle(zksample2title);
    drbContent.setTitleStyle(djrst.getTitleStyle());
    drbContent.setWhenNoDataAllSectionNoDetail();
    // drb.setSubtitle("DynamicJasper Sample");
    drbContent.setSubtitleStyle(djrst.getSubtitleStyle());

    drbContent.setHeaderHeight(20);
    drbContent.setDetailHeight(15);
    drbContent.setFooterVariablesHeight(10);
    drbContent.setMargins(20, 20, 30, 15);

    drbContent.setDefaultStyles(djrst.getTitleStyle(), djrst.getSubtitleStyle(), djrst.getHeaderStyleText(), djrst.getColumnStyleText());
    drbContent.setPrintBackgroundOnOddRows(true);

    /**
     * Columns Definitions. A new ColumnBuilder instance for each column.
     */
    // Right name
    AbstractColumn colRightName = ColumnBuilder.getNew().setColumnProperty("rigName", String.class.getName()).build();
    colRightName.setTitle(rigName);
    colRightName.setWidth(60);
    colRightName.setHeaderStyle(djrst.getHeaderStyleText());
    colRightName.setStyle(djrst.getColumnStyleText());
    // Right type
    AbstractColumn colRightType = ColumnBuilder.getNew().setCustomExpression(getMyRightTypExpression()).build();
    colRightType.setTitle(rigType);
    colRightType.setWidth(40);
    colRightType.setHeaderStyle(djrst.getHeaderStyleText());
    colRightType.setStyle(djrst.getColumnStyleText());

    // Add the columns to the report in the whished order
    drbContent.addColumn(colRightName);
    drbContent.addColumn(colRightType);

    // // TEST
    // Style atStyle = new
    // StyleBuilder(true).setFont(Font.COMIC_SANS_SMALL).setTextColor(Color.red).build();
    // /**
    // * Adding many autotexts in the same position (header/footer and
    // * aligment) makes them to be one on top of the other
    // */
    //
    // AutoText created = new AutoText(Labels.getLabel("common.Created") +
    // ": " + ZksampleDateFormat.getDateTimeFormater().format(new Date()),
    // AutoText.POSITION_HEADER, HorizontalBandAlignment.RIGHT);
    // created.setWidth(new Integer(120));
    // created.setStyle(atStyle);
    // drb.addAutoText(created);
    //
    // AutoText autoText = new AutoText(AutoText.AUTOTEXT_PAGE_X_SLASH_Y,
    // AutoText.POSITION_HEADER, HorizontalBandAlignment.RIGHT);
    // autoText.setWidth(new Integer(20));
    // autoText.setStyle(atStyle);
    // drb.addAutoText(autoText);
    //
    // AutoText name1 = new AutoText("The Zksample2 Ltd.",
    // AutoText.POSITION_HEADER, HorizontalBandAlignment.LEFT);
    // name1.setPrintWhenExpression(ExpressionHelper.printInFirstPage());
    // AutoText name2 = new AutoText("Software Consulting",
    // AutoText.POSITION_HEADER, HorizontalBandAlignment.LEFT);
    // name2.setPrintWhenExpression(ExpressionHelper.printInFirstPage());
    // AutoText street = new AutoText("256, ZK Direct RIA Street ",
    // AutoText.POSITION_HEADER, HorizontalBandAlignment.LEFT);
    // street.setPrintWhenExpression(ExpressionHelper.printInFirstPage());
    // AutoText city = new AutoText("ZKoss City", AutoText.POSITION_HEADER,
    // HorizontalBandAlignment.LEFT);
    // city.setPrintWhenExpression(ExpressionHelper.printInFirstPage());
    // drb.addAutoText(name1).addAutoText(name2).addAutoText(street).addAutoText(city);
    // // Footer
    // AutoText footerText = new
    // AutoText("Help to prevent the global warming by writing cool software.",
    // AutoText.POSITION_FOOTER, HorizontalBandAlignment.CENTER);
    // footerText.setStyle(djrst.getFooterStyle());
    // drb.addAutoText(footerText);

    // ADD ALL USED FIELDS to the report.
    drbContent.addField("rigType", Integer.class.getName());

    drbContent.setUseFullPageWidth(true); // use full width of the page

    DynamicReport drContent;
    drContent = drbContent.build(); // build the report

    // Get information from database
    List<SecRight> resultList = getSecurityService().getAllRights();

View Full Code Here

    Style columnDetailStyleNumbers = new Style();
    columnDetailStyleNumbers.setFont(Font.VERDANA_SMALL);
    columnDetailStyleNumbers.setHorizontalAlign(HorizontalAlign.RIGHT);

    DynamicReportBuilder drb = new DynamicReportBuilder();
    DynamicReport dr;

    // Sets the Report Columns, header, Title, Groups, Etc Formats
    // DynamicJasper documentation
    drb.setTitle(zksample2title);
    // drb.setSubtitle("DynamicJasper Sample");
View Full Code Here

  }

  public void doPrint() throws JRException, ColumnBuilderException, ClassNotFoundException, IOException {

    FastReportBuilder drb = new FastReportBuilder();
    DynamicReport dr;

    /**
     * Set the styles. In a report created with DynamicReportBuilder we do
     * this in an other way.
     */
 
View Full Code Here

  }

  public void doPrint() throws JRException, ColumnBuilderException, ClassNotFoundException, IOException {

    final FastReportBuilder drb = new FastReportBuilder();
    DynamicReport dr;

    /**
     * Set the styles. In a report created with DynamicReportBuilder we do
     * this in an other way.
     */
 
View Full Code Here

    // Footer
    AutoText footerText = new AutoText("Help to prevent the global warming by writing cool software.", AutoText.POSITION_FOOTER, HorizontalBandAlignment.CENTER);
    footerText.setStyle(getDjReportStyles().getFooterStyle());
    rb.addAutoText(footerText);

    DynamicReport dr = new DynamicReport();
    dr = rb.build();

    return dr;

  }
View Full Code Here

    Style columnDetailStyleNumbers = new Style();
    columnDetailStyleNumbers.setFont(Font.VERDANA_SMALL);
    columnDetailStyleNumbers.setHorizontalAlign(HorizontalAlign.RIGHT);

    DynamicReportBuilder drb = new DynamicReportBuilder();
    DynamicReport dr;

    // Sets the Report Columns, header, Title, Groups, Etc Formats
    // DynamicJasper documentation
    drb.setTitle(this.zksample2title);
    drb.setSubtitle("List of Users: " + ZksampleDateFormat.getDateFormater().format(new Date()));
View Full Code Here

    footerStyleTotalSumValue.setFont(Font.VERDANA_MEDIUM_BOLD);
    footerStyleTotalSumValue.setHorizontalAlign(HorizontalAlign.RIGHT);
    footerStyleTotalSumValue.setBorderTop(Border.PEN_1_POINT);

    DynamicReportBuilder drb = new DynamicReportBuilder();
    DynamicReport dr;

    // Sets the Report Columns, header, Title, Groups, Etc Formats
    // DynamicJasper documentation
    drb.setTitle(this.zksample2title);
    // drb.setSubtitle("DynamicJasper Sample");
View Full Code Here

  }

  public void doPrint() throws JRException, ColumnBuilderException, ClassNotFoundException, IOException {

    FastReportBuilder drb = new FastReportBuilder();
    DynamicReport dr;

    /**
     * Set the styles. In a report created with DynamicReportBuilder we do
     * this in an other way.
     */
 
View Full Code Here

  }

  public void doPrint() throws JRException, ColumnBuilderException, ClassNotFoundException, IOException {

    FastReportBuilder drb = new FastReportBuilder();
    DynamicReport dr;

    // get the styles
    DJReportStyles djrst = getDjReportStyles();

    /**
 
View Full Code Here

TOP

Related Classes of ar.com.fdvs.dj.domain.DynamicReport

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.