How To Publish FineReport Template In FineBI

  • Last update:January 10, 2025
  • Overview

    Version

    FineBI Server VersionFunctional Change

    6.0

    /

    Problem

    How can FineReport templates be mounted/used when the FineBI project is not integrated with the FineReport project?

    Implementation Method

    Two application scenarios are available:

    1. Mount FineReport templates to the project directory of FineBI.

    2. Mount FineReport templates through the hyperlinks of the web component in FineBI dashboard.

    iconNote:
    You can mount the hyperlinks of FineReport templates directly to the project directory of FineBI if the FineBI project and the FineReport project are interconnected. In this document, the scenario is not introduced further.

    Example One: Mounting a FineReport Template to the Directory of FineBI

    In this example, display the FineReport template Paragraphed Detail Report in the system directory of FineBI.

    Uploading the FineReport Template

    Copy the template Paragraphed Detail Report and paste it to %FineBI%\webapps\webroot\WEB-INF\reportlets, as shown in the following figure.

    Setting the Data Connection

    In the FineBI system, you need to add a new data connection that matches exactly with the one used in the FineReport template Paragraphed Detail Report. (The data connection name should also be the same as that used in FineReport.)

    Log in to FineBI as the admin, choose System Management > Data Connection > Data Connection Management, and click New Data Connection to create a data connection that is exactly the same as the one used by the template Paragraphed Detail Report in FineReport.

    Adding a Directory

    Log in to FineBI as the admin, choose System Management > Directory Management, select the directory to be mounted, and click Add Template, as shown in the following figure.

    Enter the template setting page where all FineReport templates in the current project are displayed, select the template Paragraphed Detail Report, and click Next.

    Set the items the template to be published including the name, description, and type, and click OK. Through these steps, the FineReport template Paragraphed Detail Report will be successfully published, as shown in the following figure.

    iconNote:
    If the preview type is data entry, you must have purchased the Data Entry function point in the FineBI project. Otherwise, data entry cannot be performed. For details, see Registration Management.

    Effect Display

    Open the directory and refresh it. The added Finereoprt template Paragraphed Detail Report is displayed in the left directory tree, as shown in the following figure.

    Example Two: Referencing the Hyperlink of a FineReport Template in the FineBI Component

    In this example, display the FineReport template Paragraphed Detail Report in the Web component of FineBI.

    Uploading the FineReport Template

    Copy the template Paragraphed Detail Report and paste it to %FineBI%\webapps\webroot\WEB-INF\reportlets, as shown in the following figure.

    Setting the Data Connection

    In the FineBI system, you need to add a new data connection that matches exactly with the one used in the FineReport template Paragraphed Detail Report. (The data connection name should also be the same as that used in FineReport.)

    Log in to FineBI as the admin, choose System Management > Data Connection > Data Connection Management, and click New Data Connection to create a data connection that is exactly the same as the one used by the template Paragraphed Detail Report in FineReport.

    Dashboard Creation

    1. Log in to FineBI, click My Analysis, select a folder, and click New Subject, as shown in the following figure.

    You do not need to select any data. Simply click Cancel. Add a dashboard, choose Other > Web Component, and drag the component into the dashboard, as shown in the following figure.

    Add a hyperlink /webroot/decision/view/report?viewlet=xxxxx.cpt to this Web component. (The hyperlink corresponds to the selected FineReport template.)

    xxxxx.cpt corresponds to the name of the CPT file stored in the reportlets folder.

    For example, if the FineReport template CPT file is named Paragraphed Detail Report.cpt, the hyperlink to this template is /webroot/decision/view/report?viewlet=Paragraphed Detail Report.cpt, as shown in the following figure.

    • If the CPT file is in a subfolder in reportlets, for example, the template Paragraphed Detail Report located in \webapps\webroot\WEB-INF\reportlets\demo, the link is /webroot/decision/view/report?viewlet=demo/Paragraphed Detail Report.cpt.

    • If you add a FineReport dashboard, suffix the hyperlink with &op=write. For example, if the Customer Tracking Records is a FineReport dashboard, the hyperlink is /webroot/decision/view/report?viewlet=demo%252FData%2BEntry%252FCustomer%2BTracking%2BRecords.cpt&op=write.

    • When adding a hyperlink in report A that links to another report B in FineBI, for example, the Customer Tracking Records dashboard with a hyperlink to the Big Data template, you need to copy the Customer Tracking Records dashboard and paste the dashboard to \webapps\webroot\WEB-INF\reportlets, and copy the Big Data template and paste the template to \reportlets\demo\chart, as shown in the following figure. In this way, the hyperlink in the Customer Tracking Records template will function properly after successful addition.

    Effect Display

    Save the dashboard, and Click Preview to view the FineReport template Paragraphed Detail Report in the Web component of the dashboard, as shown in the following figure.

    Notes

    Scenario: The template is stored in a different project rather than the current FineBI project.

    When the current project uses directory hyperlinks or Web component hyperlinks to access templates from other projects, you need to disable Prevent Clickjacking under System Management > Security Management > Security > Security Headers in the project where the template is stored.

    For details, see Security Protection.

    附件列表


    主题: System Management
    Previous
    Next
    • Helpful
    • Not helpful
    • Only read

    滑鼠選中內容,快速回饋問題

    滑鼠選中存在疑惑的內容,即可快速回饋問題,我們將會跟進處理。

    不再提示

    9s后關閉

    Get
    Help
    Online Support
    Professional technical support is provided to quickly help you solve problems.
    Online support is available from 9:00-12:00 and 13:30-17:30 on weekdays.
    Page Feedback
    You can provide suggestions and feedback for the current web page.
    Pre-Sales Consultation
    Business Consultation
    Business: international@fanruan.com
    Support: support@fanruan.com
    Page Feedback
    *Problem Type
    Cannot be empty
    Problem Description
    0/1000
    Cannot be empty

    Submitted successfully

    Network busy