diff --git a/src/components/CommonTable/index.less b/src/components/CommonTable/index.less index 59ae7775e9cc01c243cdd8ae3b9cb2e8375989ed..fe06606433479aa9d5086ac6c26e6266cc96e5d2 100644 --- a/src/components/CommonTable/index.less +++ b/src/components/CommonTable/index.less @@ -2,7 +2,10 @@ :global { - + + .ant-table-wrapper .ant-table-tbody>tr>td { + padding: 5px 16px !important; + } .ant-table-row { height: 50px !important; @@ -131,24 +134,24 @@ } } } - - + + .tablewrap { .rowStyle { height: 50px !important; border: 0; background-color: rgba(57, 122, 183, 0.241); background-size: 100% 100%; - border-radius: 16px !important; + border-radius: 16px 0 0 16px !important; overflow: hidden !important; } - + .rowStyle:hover { - + background: rgba(57, 122, 183, 0.402) !important; - - + + } } - + } \ No newline at end of file diff --git a/src/components/CooglMap b/src/components/CooglMap index 2e4a7a9a3ca2392e958572526106c4669665b04c..55f687f3c137f6dc37abe2c9dd8c29501e2d02e2 160000 --- a/src/components/CooglMap +++ b/src/components/CooglMap @@ -1 +1 @@ -Subproject commit 2e4a7a9a3ca2392e958572526106c4669665b04c +Subproject commit 55f687f3c137f6dc37abe2c9dd8c29501e2d02e2 diff --git a/src/pages/SecurityServiceOverview/RegionSelect/index.less b/src/pages/SecurityServiceOverview/RegionSelect/index.less index 5966c3c9dd3b98f8a95e41c04c52dadc7ea26bb5..59d4e4d89bf631c061d96189fbe55e84aba8d032 100644 --- a/src/pages/SecurityServiceOverview/RegionSelect/index.less +++ b/src/pages/SecurityServiceOverview/RegionSelect/index.less @@ -2,21 +2,25 @@ :global { .ant-select { - width: 154px; - height: 58px; + width: 114px; + height: 38px; .ant-select-selector { border-radius: 29px; + background: linear-gradient( 139.3deg, - rgba(89, 186, 238, 0.3) 7.117%, - rgba(96, 155, 236, 0.3) 94.806% + rgb(0, 44, 91), + rgb(0, 44, 91) ) !important; color: #a0c7e4; - font-size: 20px; + font-size: 16px; .ant-select-selection-item { font-weight: 700; } } } + .ant-select-outlined:not(.ant-select-customize-input) .ant-select-selector{ + border: 0 !important; + } } } diff --git a/src/pages/SecurityServiceOverview/SafetyMap/index.tsx b/src/pages/SecurityServiceOverview/SafetyMap/index.tsx index d7e1025794fca4222317257c9e3119b2593491ec..bc8ba405a4bfc59062f9dc41c2b23c749d4d6534 100644 --- a/src/pages/SecurityServiceOverview/SafetyMap/index.tsx +++ b/src/pages/SecurityServiceOverview/SafetyMap/index.tsx @@ -190,7 +190,7 @@ const SafetyMap = () => { zoom={9} ref={MapRef} center={{ x: 103.95, y: 30.7 }} - showCustomComponent={false} + showCustomComponent={true} > {facility?.data?.records?.map((item: any, index: number) => { @@ -282,14 +282,14 @@ const SafetyMap = () => { -
+ {/*
{ setSearchParams({ ...searchParams, parentTypeCode: e }); }} checkCode={searchParams.parentTypeCode} /> -
+
*/} {/* 事件详情 */} { count: 10, }); - const { data } = useRequest(services.Information.getArticleList, { - defaultParams: [ - { - pushCategoryName: '气象预警', - 'category.scopeList': '1', - attributeList: '0,1', - current: '1', - size: 3, - }, - ], - }); const items = useMemo(() => { return [ diff --git a/src/pages/SecurityServiceOverview/SecurityState/RightLayout/WeatherCard/index.less b/src/pages/SecurityServiceOverview/SecurityState/RightLayout/WeatherCard/index.less index 44b3ae3113d64400665c630e122bc4914f759670..6fe85fe179faff94cb3f16c6acfcdbceefb28c2f 100644 --- a/src/pages/SecurityServiceOverview/SecurityState/RightLayout/WeatherCard/index.less +++ b/src/pages/SecurityServiceOverview/SecurityState/RightLayout/WeatherCard/index.less @@ -71,6 +71,7 @@ display: flex; align-items: center; margin-bottom: 10px; + cursor: pointer; .img { width: 61px; @@ -144,31 +145,38 @@ width: 100%; height: 710px; overflow: auto; - .weatherItems{ + + .weatherItems { width: 100%; height: 148px; border-radius: 10px; - background: linear-gradient(to left, rgba(44, 153, 255, 0.2),rgba(66, 164, 255, 0)); + background: linear-gradient(to left, rgba(44, 153, 255, 0.2), rgba(66, 164, 255, 0)); display: flex; padding: 18px 18px 21px 10px; margin-bottom: 11px; - .img{ + cursor: pointer; + + .img { width: 133px; height: 109px; } - .rwarp{ + + .rwarp { margin-left: 14px; width: 900px; - .name{ + + .name { color: rgb(202, 223, 252); font-size: 20px; font-weight: 700; } - .desc{ + + .desc { width: 100%; margin-top: 5px; } - .time{ + + .time { font-size: 14px; color: rgb(140, 170, 212); } diff --git a/src/pages/SecurityServiceOverview/SecurityState/RightLayout/WeatherCard/index.tsx b/src/pages/SecurityServiceOverview/SecurityState/RightLayout/WeatherCard/index.tsx index 4e0090ba8dd148d99cffe9ca189208893e8df112..f1ed2718b6eae2ef235d170184682b72f0f23f39 100644 --- a/src/pages/SecurityServiceOverview/SecurityState/RightLayout/WeatherCard/index.tsx +++ b/src/pages/SecurityServiceOverview/SecurityState/RightLayout/WeatherCard/index.tsx @@ -1,10 +1,12 @@ import { RightOutlined } from '@ant-design/icons'; import Modal from '@/components/HncyModal'; +import services from '@/services'; +import { useRequest } from 'ahooks'; +import { Typography } from 'antd'; import { useState } from 'react'; import SafetyModal from '../../SafetyTips/SafetyModal'; import styles from './index.less'; -import { Typography } from 'antd'; const { Paragraph } = Typography; const WeatherCard = () => { @@ -49,11 +51,45 @@ const WeatherCard = () => { desc: '简阳市气象台2024年11月29日06时30分发布大雾黄色预警信号0分发布大雾黄色预警信号:目前我市江源、禾丰已经出现能见度小于500米的大雾,预计未来12小时4年11月29日06时30分发布大雾黄色预警信号0分发布大雾黄色预警信号:目前我市江源、禾丰已经出现能见度小于', }, ]; + const { data: weatherList } = useRequest( + services.Information.getArticleList, + { + defaultParams: [ + { + pushCategoryName: '大屏预警信息发布', + 'category.scopeList': '1', + attributeList: '3', + current: '1', + size: 2, + }, + ], + }, + ); + + const { data: weatherData } = useRequest( + services.Information.getArticleList, + { + defaultParams: [ + { + pushCategoryName: '大屏预警信息发布', + 'category.scopeList': '1', + attributeList: '3', + current: '1', + size: 100, + }, + ], + ready: riskModalOpt?.open, + }, + ); + return (
- 气象预警
11
+ 气象预警 +
+ {weatherList?.data?.total ?? '--'} +
{
- {[ - { - icon: require('@/assets/images/SecurityServiceOverview/tqlsIc.png'), - title: '简阳市 大风蓝色预警大风蓝色预警', - time: '2024-10-10 12:20:20', - }, - { - icon: require('@/assets/images/SecurityServiceOverview/tqlsIc.png'), - title: '简阳市 大风蓝色预警', - time: '2024-10-10 12:20:20', - }, - { - icon: require('@/assets/images/SecurityServiceOverview/tqlsIc.png'), - title: '简阳市 大风蓝色预警', - time: '2024-10-10 12:20:20', - }, - ]?.map((item, index: number) => { + {weatherList?.data?.records?.map((item: any, index: number) => { return (
{ setIsModalOpen(true); }} > - +
{item?.title}
-
{item?.time}
+
{item?.publishTime}
); @@ -122,7 +142,7 @@ const WeatherCard = () => {
{riskModalOpt?.title}
- 当前全市共12个预警 + 当前全市共{weatherList?.data?.total ?? '--'}个预警
); @@ -132,33 +152,35 @@ const WeatherCard = () => { height={858} >
- {list?.map((item) => { + {weatherData?.data?.records?.map((item) => { return ( -
- +
{ + setSelectedCarouselItem(item); + setIsModalOpen(true); + }} + > +
-
{item?.name}
+
{item?.title}
- {item?.desc} + {item?.summary}
-
-{item?.time} -
+
{item?.publishTime}
); diff --git a/src/pages/SecurityServiceOverview/SecurityState/SafetyAccident/AccidentItem/index.less b/src/pages/SecurityServiceOverview/SecurityState/SafetyAccident/AccidentItem/index.less index ba99f8cce655957a25b5ac5a3629f92200326cbc..26574989c70384fb2b459670b0c0988fb781d83c 100644 --- a/src/pages/SecurityServiceOverview/SecurityState/SafetyAccident/AccidentItem/index.less +++ b/src/pages/SecurityServiceOverview/SecurityState/SafetyAccident/AccidentItem/index.less @@ -13,7 +13,7 @@ } .rCont { - width: 190px; + width: 220px; height: 100%; margin-left: 10px; diff --git a/src/pages/SecurityServiceOverview/SecurityState/SafetyAccident/AccidentItem/index.tsx b/src/pages/SecurityServiceOverview/SecurityState/SafetyAccident/AccidentItem/index.tsx index 2fbf180cf9144e012acf966542951f3c530f08a6..216589b64b8234e070ce35e7418424d079426b44 100644 --- a/src/pages/SecurityServiceOverview/SecurityState/SafetyAccident/AccidentItem/index.tsx +++ b/src/pages/SecurityServiceOverview/SecurityState/SafetyAccident/AccidentItem/index.tsx @@ -19,7 +19,7 @@ const AccidentItem = ({ data, onClick }: AccidentItemProps) => { rows: 2, expandable: false, }} - title={data?.subTitle} + title={data?.title} style={{ color: 'rgb(202, 223, 252)', fontSize: 20, @@ -27,7 +27,7 @@ const AccidentItem = ({ data, onClick }: AccidentItemProps) => { marginBottom: 0, }} > - {data?.subTitle} + {data?.title}
@@ -35,12 +35,12 @@ const AccidentItem = ({ data, onClick }: AccidentItemProps) => { ellipsis={{ rows: 2, expandable: false, - suffix: dayjs(data?.publishTime).format('YYYY-MM-DD'), + suffix:` ${dayjs(data?.publishTime).format('YYYY-MM-DD')}`, }} - title={data?.title} + title={data?.summary} style={{color:'rgb(140, 170, 212)',fontSize:16}} > - {data?.title} + {data?.summary}
diff --git a/src/pages/SecurityServiceOverview/components/IndustrySign/index.tsx b/src/pages/SecurityServiceOverview/components/IndustrySign/index.tsx index af20821c6a7158ffd15f2ae494220951cb130ffc..63dc37dc0d7b797905707406bdeee74264e8b2fa 100644 --- a/src/pages/SecurityServiceOverview/components/IndustrySign/index.tsx +++ b/src/pages/SecurityServiceOverview/components/IndustrySign/index.tsx @@ -139,7 +139,8 @@ const IndustrySign = ({ param }: { param: any }) => { render: (text, record, index) => { // 当前页码减1,乘以每页数量,再加上当前行的索引加1 const num = fetchParams?.data?.pageNo || 1; - return `${(num - 1) * fetchParams?.data?.pageSize + (index + 1)}`; + // return `${(num - 1) * fetchParams?.data?.pageSize + (index + 1)}`; + return `${fetchParams?.data?.pageNo * fetchParams?.data?.pageSize + (index + 1)}`; }, }, { @@ -341,7 +342,7 @@ const IndustrySign = ({ param }: { param: any }) => {