Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

What does the key1 field code refer to

2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >

Share

Shulou(Shulou.com)06/03 Report--

This article will explain in detail what the key1 field code refers to. The editor thinks it is very practical, so I share it for you as a reference. I hope you can get something after reading this article.

Data loading in Echarts and the use of varmap= {'key1':a1,'key2':a2,}, IT newcomer, just encountered the problem of multi-field display of data in Echarts during his internship, and finally found that this problem can be used in KMurv format.

What is the key1 field?

You often encounter the same display field in Echarts.js that contains two fields.

What is passed over in the background is that there are many two fields in a List,list. It's time to use Map in js to deal with this situation.

Key1 field code

Varjson1= []; / / is used to store mapped list data. Json1.push (map), where map is the newly created map

VardataAxis= []; / / is used to store legend label data

$.ajax ({

Type:'get', should be the driving force of controller and access function

ContentType: "application/json;charset=utf-8", / / data transfer format json, utf-8

DataType:'json'

Error:function () {

Alert ("cuowu"); / / the backend entered this function in response to an error

}

Success:function (json) {/ / background response successfully entered this function

/ / 1-get the data phase required by the function from json

VarlabelOption= {

Normal: {

Show:true

Rotate:90

Align:'left'

VerticalAlign:'middle'

Position:'insideBottom'

Distance:15

Formatter:' {c} {name | {a}}', / / the table needs to display even fields

FontSize:16

Rich: {

Name: {

TextBorderColor:'#fff'

}

}

}

This is the end of this article on "what the key1 field code refers to". I hope the above content can be of some help to you, so that you can learn more knowledge. if you think the article is good, please share it out for more people to see.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Development

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report