Skip to content
Snippets Groups Projects
Commit a81de207 authored by 1437862981's avatar 1437862981
Browse files

样式修改

parent e20633f8
Branches
Tags
1 merge request!1合并请求
......@@ -24,7 +24,7 @@ const IndustryWiget = ({
onClick={() => {
setWayModalOpt({
open: true,
title: data?.parentData?.typeName,
title: data?.typeName,
...data,
});
}}
......
......@@ -212,7 +212,7 @@ const MeetSafeguard = () => {
key: 'name',
width: 80,
ellipsis: true,
render: (text, record, index) => {
render: (text:any, record:any, index:number) => {
// 当前页码减1,乘以每页数量,再加上当前行的索引加1
return `${(searchData?.page - 1) * dataSource?.length + (index + 1)}`;
},
......
......@@ -127,7 +127,7 @@ const SecurityCqi = ({ warnLevel }: { warnLevel: number }) => {
<ConfigProvider
theme={{
token: {
/* 这里是你的全局 token */
colorBgElevated: '#163050',
},
}}
......
import services from '@/services';
import { useRequest } from '@umijs/max';
import { Flex } from 'antd';
import { useState } from 'react';
import SafetyMap from '../SafetyMap';
......@@ -20,16 +18,15 @@ export const StateMap = {
};
const SecurityState = () => {
const [warnLevel, setWarnLevel] = useState(2);
return (
<Flex className={styles.container} justify="space-between">
{/* 左侧 */}
<div className={styles.leftWrap}>
<SecurityCqi warnLevel={warnLevel}/>
<IndustryWarn warnLevel={warnLevel} setWarnLevel={setWarnLevel}/>
<FacilityWarn warnLevel={warnLevel} setWarnLevel={setWarnLevel}/>
<SecurityCqi warnLevel={warnLevel} />
<IndustryWarn warnLevel={warnLevel} setWarnLevel={setWarnLevel} />
<FacilityWarn warnLevel={warnLevel} setWarnLevel={setWarnLevel} />
</div>
{/* 地图 */}
<div className={styles.mapCenter}>
......
import services from '@/services';
import { useRequest } from 'ahooks';
import { useRequest, useUpdateEffect } from 'ahooks';
import { ConfigProvider, Select } from 'antd';
import classNames from 'classnames';
import { useEffect, useMemo, useState } from 'react';
......@@ -34,9 +34,10 @@ const TopSearch = ({ onSearch }: { onSearch: (val: any) => void }) => {
},
];
}, [data]);
useEffect(() => {
useUpdateEffect(() => {
onSearch(searchParams);
}, [searchParams]);
return (
<div className={styles.container}>
<div className={styles.searchTab}>
......
......@@ -24,6 +24,7 @@ const RiskWarn = ({ riskModalOpt }: { riskModalOpt: any }) => {
const params = {
page: 1,
count: 10,
};
const [listData, setListData] = useState<any>({
items: [],
......
......@@ -63,7 +63,7 @@ const TheOperationOfCityOverall: React.FC = () => {
<div>城市运行总体情况</div>
<Space>
<span className={styles.updateTime}>
{indutryIndexData?.data[0]?.time} 更新
{indutryIndexData?.data?.[0]?.time} 更新
</span>
<div className={styles.headerText}>城市管理运行日报</div>
<DoubleRightOutlined className={styles.headerIcon} />
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment