diff --git a/web/client/src/sections/quanju/containers/footer/build/Rightbottom.js b/web/client/src/sections/quanju/containers/footer/build/Rightbottom.js
index 2c8107f0..d18477ed 100644
--- a/web/client/src/sections/quanju/containers/footer/build/Rightbottom.js
+++ b/web/client/src/sections/quanju/containers/footer/build/Rightbottom.js
@@ -53,12 +53,34 @@ function Rightbottom(props) {
orient: "vertical",
itemWidth: 10,
itemHeight: 10,
- right: '30%',
+ // right: '30%',
+ left: '50%',
top: 'center',
align: 'left',
- textStyle: {
- color: "#fff",
+ data: name,
+ formatter: (name) => {
+ for (let i = 0; i < option.series[1].data.length; i += 1) {
+ if (name === option.series[1].data[i].name) {
+ let arr = [`{a|${name}}`, `{b|${option.series[1].data[i].value}}`]
+ return arr.join('\t');
+ }
+ }
},
+ textStyle: {
+ rich: {
+ a: {
+ color: '#E9F7FF',
+ fontSize: 14,
+ padding:[0,10]
+ },
+ b: {
+ fontSize: 16,
+ fontFamily: 'YouSheBiaoTiHei',
+ color: '#fff',
+ padding:[0,0,0,15]
+ },
+ }
+ }
},
grid: {
left: '10%'
@@ -133,14 +155,14 @@ function Rightbottom(props) {
// }
myChart.setOption(option);
return ()=>{
- clearInterval(changePieInterval)
+ // clearInterval(changePieInterval)
}
-}, []);
+}, [data]);
return (
-
3234.23
+ {total||0}
道路总公里
diff --git a/web/client/src/sections/quanju/containers/footer/build/Rightcenter.js b/web/client/src/sections/quanju/containers/footer/build/Rightcenter.js
index 0c716667..e5cbeb9c 100644
--- a/web/client/src/sections/quanju/containers/footer/build/Rightcenter.js
+++ b/web/client/src/sections/quanju/containers/footer/build/Rightcenter.js
@@ -1,32 +1,33 @@
import React from 'react'
import './style.less'
import AutoRollComponent from './AutoRollComponent'
-export default function Rightcenter() {
- const data =[ {name: '莲塘镇', total: 12739},
- {name: '向塘镇', total: 2445},
- {name: '蒋巷镇', total: 2035},
- {name: '幽兰镇', total: 1999},
- {name: '塘南镇', total: 1915},
- {name: '武阳镇', total: 1842},
- {name: '冈上镇', total: 1446},
- {name: '广福镇', total: 1063},
- {name: '三江镇', total: 851},
- {name: '泾口乡', total: 657},
- {name: '南新镇', total: 640},
- {name: '八一乡', total: 569},
- {name: '黄马乡', total: 541},
- {name: '塔城乡', total: 534},
- {name: '富山乡', total: 515},
- {name: '东新乡', total: 513},
- {name: '银三角', total: 513},
- {name: '八月湖街道', total: 513},]
- const province = undefined
+export default function Rightcenter({data,sundata}) {
+ // const data =[ {name: '莲塘镇', total: 12739},
+ // {name: '向塘镇', total: 2445},
+ // {name: '蒋巷镇', total: 2035},
+ // {name: '幽兰镇', total: 1999},
+ // {name: '塘南镇', total: 1915},
+ // {name: '武阳镇', total: 1842},
+ // {name: '冈上镇', total: 1446},
+ // {name: '广福镇', total: 1063},
+ // {name: '三江镇', total: 851},
+ // {name: '泾口乡', total: 657},
+ // {name: '南新镇', total: 640},
+ // {name: '八一乡', total: 569},
+ // {name: '黄马乡', total: 541},
+ // {name: '塔城乡', total: 534},
+ // {name: '富山乡', total: 515},
+ // {name: '东新乡', total: 513},
+ // {name: '银三角', total: 513},
+ // {name: '八月湖街道', total: 513},]
+ // const province = undefined
const FIRST = "linear-gradient(360deg, rgba(43, 180, 211, 0.1) 0%, rgba(43, 180, 211, 0.4) 100%)"
const SECOND = "linear-gradient(360deg, rgba(255, 209, 86, 0.1) 0%, rgba(255, 209, 86, 0.4) 100%)"
const THIRD = "linear-gradient(360deg, rgba(148, 148, 255, 0.1) 0%, rgba(148, 148, 255, 0.4) 100%)"
const OTHER = "linear-gradient(360deg, rgba(28, 96, 253, 0) 0%, rgba(28, 96, 253, 0.2) 100%)"
let TOTALS = data?.map(({ name, total }, index) => {
- let max = province ? data.length * 30 + 100 : data.length * 500 + 100
+ let max = Math.max(...data.map(item=>item.total))
+ console.log(data.map(item=>item.total),'好朋友吗')
return {
name,
value: total,
@@ -35,7 +36,7 @@ let TOTALS = data?.map(({ name, total }, index) => {
})
let new_TOTALS = TOTALS && TOTALS.length > 10 ? TOTALS.slice(0, 10) : TOTALS
function Cell(props) {
- const { name, rank, value, percent, style = {} } = props
+ const { name, rank, value, percent, style = {},cebg } = props
let bg = RNAKS[rank] || OTHER
console.log(percent,'百分比')
return
+ background: cebg || "linear-gradient(270deg, #1C60FE 0%, rgba(28, 96, 254, 0) 100%)"
+ }} >{cebg?
:""}
+
{value}
@@ -68,11 +71,11 @@ function Cell(props) {
+
+ return new_TOTALS?.map(({ name, value, percent }, index) => {
+ return
+ })
+
}
const RNAKS = [FIRST, SECOND, THIRD]
@@ -81,7 +84,7 @@ const RNAKS = [FIRST, SECOND, THIRD]