What do map reports do?

Source: Internet
Author: User

On the map to show the geographical data, is in the public facilities management, transportation, telecommunications, urban construction, energy, electricity, agriculture and other national economy-related application system is a more common visual chart form. Previously, if you needed to display map-related information in a report application, developers might think of GIS for the first time (Geographic information software Geographic information software), but the larger GIS system requires developers to define the various tasks that are performed in the GIS , and develop the appropriate handlers. Skilled operators even need to overcome the shortcomings of GIS software functions. In fact, if you just want to do a map to display data, do not have to use such a large sledgehammer Oh!
Now echarts this little whale. Map data rendering can help us to easily make map data presentation, while the dry report integrates the Echarts script into the designer, after selecting the map template to be done according to the category, a data map is easily completed by setting the next few parameters.
Let's take a look at some of the echarts built-in map effects!

What about the

, isn't it cool? Let's go through an example to see if such a cool map is going to need that complicated step ...
1. Data preparation
Connect to a data source, create a new report, and add a dataset. Regardless of the way the data set is obtained, the final collated data should be in the following format. Haha, don't be nervous, the field name can be different yo.

Note: The name of the second field in the city, the name of the province must not appear provinces and cities, such as: Beijing, do not write to the Beijing; Heilongjiang, do not write in Heilongjiang province, otherwise, the corresponding provinces and cities will appear in the statistical chart can not correspond to the situation.
2. Add the Echarts chart template to the cell.
(1) Select the Chart JS template
Check the cells that need to be set as a chart, click on the "Report-third party graphics" menu item, or Right-click "menu-third-party graphics" in the Graphics editing window, clicking the Open Template button, the lack of capital directly to the "Installation root directory"/chart directory, Users can also switch to the template's storage path themselves.

(2) sets the parameter values required for the chart. The parameter values in the
parameter list can refer to the dataset data, which is a JSON string that converts the dataset to a two-dimensional array using the [email protected] () function provided by the dry report. Refer to the JSON function description in the tutorial for specific reference.


After clicking OK, we can publish the report on the web side to see how the chart works.
3. Introduced the Chinese map JS in the echarts.jsp.
Echarts.jsp in the demo/reportjsp directory, the page already has the Chinese JS, as shown in.
If the map for another province is to be added on that page.

4.Web End View effect.
With the built-in Tomcat launcher, click on the IE icon and in the browser you can see the map we made directly from the template.

Do the province map and country map, the steps are the same, now I expand, simply say:
1. The directory where JS is located in the province is: raqsoft_180514_2\report\web\webapps\demo\raqsoft\echarts3\map\js\province.
This directory under the province's JS file names are the corresponding provinces of the full spell, such as: Ningxia Hui Autonomous Region corresponding to the "Ningxia". This will appear Shanxi and Shaanxi, the same name of the situation, shanxi.js corresponds to Shanxi, shanxi1.js corresponds to Shaanxi.
2. Introduce the JS script of the corresponding province in the echartjs.jsp.
Published in the dry Dry college, the address is: Http://c.raqsoft.com.cn/article/1533395519437?r=shiguang

What do map reports do?

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.