Explorar el Código

fix: 基础统计饼图

sun-chaochao hace 3 años
padre
commit
a0aac6b01e
Se han modificado 2 ficheros con 5 adiciones y 15 borrados
  1. 3 3
      src/pages/home/components/Pie.tsx
  2. 2 12
      src/pages/home/comprehensive/index.tsx

+ 3 - 3
src/pages/home/components/Pie.tsx

@@ -15,11 +15,11 @@ const Pie = (props: Props) => {
         series: [
           {
             type: 'pie',
-            radius: [30, 50],
+            radius: [20, 40],
             top: 0,
-            height: 80,
+            height: 70,
             left: 'center',
-            width: 80,
+            width: 70,
             itemStyle: {
               borderColor: '#fff',
               borderWidth: 1,

+ 2 - 12
src/pages/home/comprehensive/index.tsx

@@ -1,7 +1,7 @@
 import { PermissionButton } from '@/components';
 import useHistory from '@/hooks/route/useHistory';
 import { getMenuPathByCode, MENUS_CODE } from '@/utils/menu';
-import { Col, message, Progress, Row } from 'antd';
+import { Col, message, Row } from 'antd';
 import Body from '../components/Body';
 import Guide from '../components/Guide';
 import Statistics from '../components/Statistics';
@@ -187,17 +187,7 @@ const Comprehensive = () => {
             {
               name: 'JVM内存',
               value: String(jvmValue) + '%',
-              children: (
-                <Progress
-                  type="circle"
-                  width={80}
-                  strokeColor={'#2F54EB'}
-                  trailColor={'#979AFF'}
-                  style={{ marginBottom: 10 }}
-                  format={() => ''}
-                  percent={jvmValue}
-                />
-              ),
+              children: <Pie value={jvmValue} />,
             },
           ]}
           title="基础统计"