Custom TileLayer

  • Last update:November 07, 2023
  • Overview

    Version

    Report Server Version

    Functional Change

    11.0

    /

    11.0.6

    Supported two more projection methods for the custom TileLayer. For details, see section "Notes."

    Functions

    Third-party maps may limit the number of accesses. If the access volume exceeds the limit, the layers may not be displayed correctly.

    In this case, you can use the custom TileLayer function.

    FineReport allows you to customize the TileLayer only for the current template map in the designer. It also allows you to customize the TileLayer under Map Configuration > Custom GIS Layer in the decision-making platform, which can be applied to all templates in the current report server.

    FineReport provides eight types of TileLayer for use, as shown in the following figure.

    Note:
    If the built-in Satellite layer fails to load, you can modify the URL to http://{s}.tiles.mapbox.com/v4/mapbox.satellite/{z}/{x}/{y}{r}.png?access_token=pk.eyJ1Ijoid2FuZ2p1bjEzMDMiLCJhIjoiY2l4OHBscnYwMDAwdTJ5cWY5cnRrZGM0ZSJ9.FQy75sTd5x1dujqvTsLzvA.


    Example

    You can generate a layer URL on the official website of Mapbox, a map supplier, and copy it to the URL editing box of TileLayer on the Custom GIS Layer tab page.

    Generating a URL Link

    Note:
    The generated URL is just an example. You can refer to relevant materials for detailed configuration.


    1. Open the official website of Mapbox. If you do not have an account, click the button to register. If you already have an account, log in to the website.

    2. After login, click the dropdown button in the upper right corner of the personal center and select Studio.

    3. Click New style on the newly opened page to create a custom layer.

    4. Select any layer template, such as Outdoors, and click Customize Outdoors to go to the layer editing page.

    5. You can set layer attributes as needed on the left side of the layer editing page.

    6. Follow the steps in the following figure to generate a third-party sharing URL. Click  to copy the URL.

    Creating a Custom Amap Layer

    1. In the designer, choose Server > Map Configuration, log in to the decision-making system, and you are redirected to the map configuration page.

    2. Select Custom GIS Layer, create a directory, and name it. Select the created directory, click TileLayer, and paste the prepared URL.

    URL in this example: https://api.mapbox.com/styles/v1/leotsai/ckdskdlj810ve19nvkvkbpdig/tiles/256/{z}/{x}/{y}@2x?access_token=pk.eyJ1IjoibGVvdHNhaSIsImEiOiJja2RzaTQzNG8wZjE2MnJxczh0b2xnM2djIn0.-VMQ4r1GsulAVcZS9nM7rQ

    Note:
    Enter the map layer label in the input box of Attribute. You are advised to enter the content according to the actual map supplier.


    Click Load Layer. Then the customized map layer style appears on the right.

    Click Save in the upper right corner. Then the customized TileLayer takes effect in the designer.

    Applying GIS Layer to Template Map

    After synchronizing geographic files, you can select the created TileLayer layer under Type > Basic > GIS Layer > Custom in any template of the designer.

    The map layer effect during preview is shown in the following figure.

    The template can be previewed on the app/HTML5 terminal. The map layer effect is shown in the following figure.

    Customizing TileLayer in a Single Template

    You can set the custom TileLayer separately for the current template.

    In GIS Layer, choose Custom > Custom TileLayer, and paste the prepared URL.

    Notes

    1. The {r} parameter is not supported in the URL of custom layers. If this parameter exists in the URL, the layer is not displayed during frontend preview. To solve this problem, simply remove the {r} parameter from the URL.

    2. In FineReport versions before V11.0.6, only the projection method EPSG:3857 is supported by the custom TileLayer. In FineReport versions after V11.0.6, three projection methods (EPSG:3857, EPSG:4326, and EPSG:3395) are supported.

    Attachment List


    Theme: Chart
    • Helpful
    • Not helpful
    • Only read

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

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

    不再提示

    10s後關閉

    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