风险等级占比接口对接
This commit is contained in:
parent
8a8624f705
commit
732c95b506
@ -1269,12 +1269,13 @@ class Home extends React.Component {
|
|||||||
|
|
||||||
riskLevel = () => {
|
riskLevel = () => {
|
||||||
let riskLevel = [];
|
let riskLevel = [];
|
||||||
let showData = [
|
let showData = [];
|
||||||
{ value: 2, name: "一级" },
|
this.state.riskLevelData.forEach((item) => {
|
||||||
{ value: 5, name: "二级" },
|
showData.push({
|
||||||
{ value: 15, name: "三级" },
|
value: item.COUNT,
|
||||||
{ value: 30, name: "四级" },
|
name: item.RISK_LEVEL,
|
||||||
];
|
});
|
||||||
|
})
|
||||||
|
|
||||||
let riskLevels = document.getElementById("riskLevel");
|
let riskLevels = document.getElementById("riskLevel");
|
||||||
if (riskLevels) {
|
if (riskLevels) {
|
||||||
@ -1284,7 +1285,7 @@ class Home extends React.Component {
|
|||||||
title: [
|
title: [
|
||||||
{
|
{
|
||||||
text: "52",
|
text: "52",
|
||||||
x: "26%",
|
x: "27%",
|
||||||
y: "40%",
|
y: "40%",
|
||||||
textStyle: {
|
textStyle: {
|
||||||
fontSize: 26,
|
fontSize: 26,
|
||||||
@ -1294,7 +1295,7 @@ class Home extends React.Component {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
text: "风险总数",
|
text: "风险总数",
|
||||||
x: "24%",
|
x: "26%",
|
||||||
y: "55%",
|
y: "55%",
|
||||||
textStyle: {
|
textStyle: {
|
||||||
color: "#666",
|
color: "#666",
|
||||||
@ -1310,13 +1311,14 @@ class Home extends React.Component {
|
|||||||
icon: "pin",
|
icon: "pin",
|
||||||
orient: "vartical",
|
orient: "vartical",
|
||||||
// x: "right",
|
// x: "right",
|
||||||
top: "18%",
|
// top: "18%",
|
||||||
|
y:'center',
|
||||||
right: "15%",
|
right: "15%",
|
||||||
bottom: "20%",
|
// bottom: "20%",
|
||||||
data: showData,
|
data: showData,
|
||||||
// itemWidth: 20,
|
// itemWidth: 20,
|
||||||
// itemHeight: 14,
|
// itemHeight: 14,
|
||||||
itemGap: 25,
|
// itemGap: 25,
|
||||||
formatter: function (name) {
|
formatter: function (name) {
|
||||||
//通过name获取到数组对象中的单个对象
|
//通过name获取到数组对象中的单个对象
|
||||||
let singleData = showData.filter(function (item) {
|
let singleData = showData.filter(function (item) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user