将统计和地图点位接口拆分文件

master
LiuJiaNan 2026-07-21 10:00:09 +08:00
parent 84fcbf0260
commit 3176ef7b44
16 changed files with 50 additions and 47 deletions

6
src/api/biMark/index.js Normal file
View File

@ -0,0 +1,6 @@
import { declareRequest } from "@cqsjjb/jjb-dva-runtime";
export const getCorpInfoListAll = declareRequest(
"biFullLoading",
"Post > @/basicInfo/corpInfo/corpListAll",
);

View File

@ -56,10 +56,6 @@ export const getCorpInfoCorpUserStatisticPage = declareRequest(
"portIndexBasicInfoStatisticPageLoading",
"Post > @/basicInfo/corpInfo/corpUserStatisticPage",
);
export const getCorpInfoListAll = declareRequest(
"biFullLoading",
"Post > @/basicInfo/corpInfo/corpListAll",
);
export const getFirePointDeviceList = declareRequest(
"xiaoFangFirePointDeviceListLoading",
"Post > @/fireCheck/firePoint/deviceList",

View File

@ -6,4 +6,5 @@ import { defineNamespace } from "@cqsjjb/jjb-dva-runtime";
export const NS_GLOBAL = defineNamespace("global");
export const NS_BI = defineNamespace("bi");
export const NS_BI_STATISTICS = defineNamespace("biStatistics");
export const NS_BI_MARK = defineNamespace("biMark");

View File

@ -3,7 +3,7 @@ import { Spin } from "antd";
import { useEffect, useState } from "react";
import SeamlessScroll from "zy-react-library/components/SeamlessScroll";
import background from "~/assets/images/public/bigScreen/bg13.png";
import { NS_BI } from "~/enumerate/namespace";
import { NS_BI_STATISTICS } from "~/enumerate/namespace";
import Panel from "../../Panel";
import "./index.less";
@ -23,7 +23,7 @@ function RecordStatsPanel(props) {
title="相关方单位备案与项目执行统计"
className="index-info-bottom__record-stats"
>
<Spin spinning={props.bi.indexInfoXgfManagerProjectLoading}>
<Spin spinning={props.biStatistics.indexInfoXgfManagerProjectLoading}>
<div
className="index-info-record-stats__table"
style={{ backgroundImage: `url(${background})` }}
@ -54,4 +54,4 @@ function RecordStatsPanel(props) {
);
}
export default Connect([NS_BI], true)(RecordStatsPanel);
export default Connect([NS_BI_STATISTICS], true)(RecordStatsPanel);

View File

@ -4,7 +4,7 @@ import { useEffect, useState } from "react";
import AliPlayer from "zy-react-library/components/Video/AliPlayer";
import { randoms } from "zy-react-library/utils";
import background from "~/assets/images/public/bigScreen/bg14.png";
import { NS_BI } from "~/enumerate/namespace";
import { NS_BI_STATISTICS } from "~/enumerate/namespace";
import Panel from "../../Panel";
import "./index.less";
@ -47,7 +47,7 @@ function VideoPatrolPanel(props) {
return (
<Panel title="视频巡屏" className="index-info-bottom__video-patrol">
<div className="index-info-video-patrol__content">
<Spin spinning={props.bi.indexInfoVideoPatrolLoading}>
<Spin spinning={props.biStatistics.indexInfoVideoPatrolLoading}>
<div className="index-info-video-patrol__menu">
{list.map(item => (
<div
@ -66,8 +66,8 @@ function VideoPatrolPanel(props) {
>
<Spin
spinning={
props.bi.indexInfoVideoPatrolLoading
|| props.bi.indexInfoVideoPatrolUrlLoading
props.biStatistics.indexInfoVideoPatrolLoading
|| props.biStatistics.indexInfoVideoPatrolUrlLoading
}
>
{playUrl
@ -84,4 +84,4 @@ function VideoPatrolPanel(props) {
);
}
export default Connect([NS_BI], true)(VideoPatrolPanel);
export default Connect([NS_BI_STATISTICS], true)(VideoPatrolPanel);

View File

@ -4,7 +4,7 @@ import { useEffect, useState } from "react";
import SeamlessScroll from "zy-react-library/components/SeamlessScroll";
import tableHeaderBackground from "~/assets/images/public/bigScreen/tablebg1.png";
import tableRowBackground from "~/assets/images/public/bigScreen/tablebg2.png";
import { NS_BI } from "~/enumerate/namespace";
import { NS_BI_STATISTICS } from "~/enumerate/namespace";
import Panel from "../../Panel";
import "./index.less";
@ -27,7 +27,7 @@ function RectificationPanel(props) {
title="当前各公司隐患整改情况"
className="index-info-left-panel__rectification"
>
<Spin spinning={props.bi.indexInfoHiddenLoading}>
<Spin spinning={props.biStatistics.indexInfoHiddenLoading}>
<div className="index-info-rectification__table">
<div
className="index-info-rectification__header"
@ -62,4 +62,4 @@ function RectificationPanel(props) {
);
}
export default Connect([NS_BI], true)(RectificationPanel);
export default Connect([NS_BI_STATISTICS], true)(RectificationPanel);

View File

@ -6,7 +6,7 @@ import tableHeaderBackground from "~/assets/images/public/bigScreen/tablebg1.png
import tableRowBackground from "~/assets/images/public/bigScreen/tablebg2.png";
import temperatureIcon from "~/assets/images/public/bigScreen/w_ico1.png";
import windIcon from "~/assets/images/public/bigScreen/w_ico2.png";
import { NS_BI } from "~/enumerate/namespace";
import { NS_BI_STATISTICS } from "~/enumerate/namespace";
import { getWeatherIcon } from "~/utils/weather";
import Panel from "../../Panel";
import "./index.less";
@ -33,7 +33,7 @@ function WeatherPanel(props) {
return (
<Panel title="天气预报情况" className="index-info-left-panel__weather">
<Spin spinning={props.bi.indexInfoWeatherLoading}>
<Spin spinning={props.biStatistics.indexInfoWeatherLoading}>
<div className="index-info-weather__summary">
<div className="index-info-weather__condition">
<img src={getWeatherIcon(weather.text)} alt="" />
@ -58,7 +58,7 @@ function WeatherPanel(props) {
{weather.alertTitle || "天气数据加载失败"}
</div>
</Spin>
<Spin spinning={props.bi.indexInfoEmergencyRescueLoading}>
<Spin spinning={props.biStatistics.indexInfoEmergencyRescueLoading}>
<div className="index-info-weather__table">
<div
className="index-info-weather__table-header"
@ -95,4 +95,4 @@ function WeatherPanel(props) {
);
}
export default Connect([NS_BI], true)(WeatherPanel);
export default Connect([NS_BI_STATISTICS], true)(WeatherPanel);

View File

@ -3,7 +3,7 @@ import { useMount } from "ahooks";
import { Spin } from "antd";
import * as echarts from "echarts";
import { useRef } from "react";
import { NS_BI } from "~/enumerate/namespace";
import { NS_BI_STATISTICS } from "~/enumerate/namespace";
import Panel from "../../Panel";
import "./index.less";
@ -150,11 +150,11 @@ function WorkStatusPanel(props) {
title="领域工作情况统计"
className="index-info-left-panel__work-status"
>
<Spin spinning={props.bi.indexInfoDomainLoading}>
<Spin spinning={props.biStatistics.indexInfoDomainLoading}>
<div ref={chartRef} className="index-info-work-status__chart" />
</Spin>
</Panel>
);
}
export default Connect([NS_BI], true)(WorkStatusPanel);
export default Connect([NS_BI_STATISTICS], true)(WorkStatusPanel);

View File

@ -4,7 +4,7 @@ import { useEffect, useState } from "react";
import SeamlessScroll from "zy-react-library/components/SeamlessScroll";
import tableHeaderBackground from "~/assets/images/public/bigScreen/tablebg1.png";
import tableRowBackground from "~/assets/images/public/bigScreen/tablebg2.png";
import { NS_BI } from "~/enumerate/namespace";
import { NS_BI_STATISTICS } from "~/enumerate/namespace";
import Panel from "../../Panel";
import "./index.less";
@ -21,7 +21,7 @@ function AlarmPanel(props) {
}, []);
return (
<Panel title="物联网设备报警情况" className="index-info-right-panel__alarm">
<Spin spinning={props.bi.indexInfoIotalarmLoading}>
<Spin spinning={props.biStatistics.indexInfoIotalarmLoading}>
<div className="index-info-alarm__table">
<div
className="index-info-alarm__header"
@ -56,4 +56,4 @@ function AlarmPanel(props) {
);
}
export default Connect([NS_BI], true)(AlarmPanel);
export default Connect([NS_BI_STATISTICS], true)(AlarmPanel);

View File

@ -4,7 +4,7 @@ import { useEffect, useState } from "react";
import SeamlessScroll from "zy-react-library/components/SeamlessScroll";
import tableHeaderBackground from "~/assets/images/public/bigScreen/tablebg1.png";
import tableRowBackground from "~/assets/images/public/bigScreen/tablebg2.png";
import { NS_BI } from "~/enumerate/namespace";
import { NS_BI_STATISTICS } from "~/enumerate/namespace";
import Panel from "../../Panel";
import "./index.less";
@ -24,7 +24,7 @@ function PartnerPanel(props) {
title="相关方单位情况统计"
className="index-info-right-panel__partner"
>
<Spin spinning={props.bi.indexInfoXgfManagerLoading}>
<Spin spinning={props.biStatistics.indexInfoXgfManagerLoading}>
<div className="index-info-partner__table">
<div
className="index-info-partner__header"
@ -57,4 +57,4 @@ function PartnerPanel(props) {
);
}
export default Connect([NS_BI], true)(PartnerPanel);
export default Connect([NS_BI_STATISTICS], true)(PartnerPanel);

View File

@ -5,7 +5,7 @@ import threePersonIcon from "~/assets/images/public/bigScreen/ico6.png";
import dangerIcon from "~/assets/images/public/bigScreen/ico7.png";
import nightIcon from "~/assets/images/public/bigScreen/ico8.png";
import newWorkIcon from "~/assets/images/public/bigScreen/ico9.png";
import { NS_BI } from "~/enumerate/namespace";
import { NS_BI_STATISTICS } from "~/enumerate/namespace";
import Panel from "../../Panel";
import "./index.less";
@ -52,7 +52,7 @@ function WorkPanel(props) {
}, []);
return (
<Panel title="重点作业管理统计" className="index-info-right-panel__work">
<Spin spinning={props.bi.indexInfoEightWorkLoading}>
<Spin spinning={props.biStatistics.indexInfoEightWorkLoading}>
<div className="index-info-work__list">
{list.map(item => (
<div className="index-info-work__item" key={item.name}>
@ -76,4 +76,4 @@ function WorkPanel(props) {
);
}
export default Connect([NS_BI], true)(WorkPanel);
export default Connect([NS_BI_STATISTICS], true)(WorkPanel);

View File

@ -6,7 +6,7 @@ import branchIcon from "~/assets/images/map_bi/content/img3.png";
import relatedIcon from "~/assets/images/map_bi/content/img4.png";
import userIcon from "~/assets/images/map_bi/content/img5.png";
import oval from "~/assets/images/map_bi/content/oval.png";
import { NS_BI } from "~/enumerate/namespace";
import { NS_BI_STATISTICS } from "~/enumerate/namespace";
import Panel from "~/pages/Container/Map/components/Content/port/Panel";
import { Context } from "~/pages/Container/Map/js/context";
import "./index.less";
@ -44,7 +44,7 @@ function BasicInfoPanel(props) {
return (
<Panel title="单位基础信息" className="port-index__basic-info">
<Spin spinning={props.bi.portIndexBasicInfoSummaryLoading}>
<Spin spinning={props.biStatistics.portIndexBasicInfoSummaryLoading}>
<div className="port-basic-info__options">
{statistics.map(item => (
<div key={item.label} className="port-basic-info__option">
@ -66,4 +66,4 @@ function BasicInfoPanel(props) {
);
}
export default Connect([NS_BI], true)(BasicInfoPanel);
export default Connect([NS_BI_STATISTICS], true)(BasicInfoPanel);

View File

@ -4,7 +4,7 @@ import { useContext, useEffect, useState } from "react";
import SeamlessScroll from "zy-react-library/components/SeamlessScroll";
import activeTabBackground from "~/assets/images/map_bi/content/title.png";
import tabBackground from "~/assets/images/map_bi/content/title_on.png";
import { NS_BI } from "~/enumerate/namespace";
import { NS_BI_STATISTICS } from "~/enumerate/namespace";
import Panel from "~/pages/Container/Map/components/Content/port/Panel";
import { Context } from "~/pages/Container/Map/js/context";
import "./index.less";
@ -64,7 +64,7 @@ function PersonnelStatsPanel(props) {
<div className="port-personnel-stats__cell">人员数</div>
</div>
<div className="port-personnel-stats__table-body">
<Spin spinning={props.bi.portIndexBasicInfoStatisticPageLoading}>
<Spin spinning={props.biStatistics.portIndexBasicInfoStatisticPageLoading}>
{isVisible && (
<SeamlessScroll list={statistics} step={0.5}>
{statistics.map((item, index) => (
@ -90,4 +90,4 @@ function PersonnelStatsPanel(props) {
);
}
export default Connect([NS_BI], true)(PersonnelStatsPanel);
export default Connect([NS_BI_STATISTICS], true)(PersonnelStatsPanel);

View File

@ -8,7 +8,7 @@ import majorIcon from "~/assets/images/map_bi/content/img2ico1.png";
import highIcon from "~/assets/images/map_bi/content/img2ico2.png";
import normalIcon from "~/assets/images/map_bi/content/img2ico3.png";
import lowIcon from "~/assets/images/map_bi/content/img2ico4.png";
import { NS_BI } from "~/enumerate/namespace";
import { NS_BI_STATISTICS } from "~/enumerate/namespace";
import Panel from "~/pages/Container/Map/components/Content/port/Panel";
import { Context } from "~/pages/Container/Map/js/context";
import "./index.less";
@ -69,7 +69,7 @@ function RiskStatsPanel(props) {
return (
<Panel title="风险区域统计" className="port-index__risk-stats">
<Spin spinning={props.bi.portIndexRiskLoading}>
<Spin spinning={props.biStatistics.portIndexRiskLoading}>
<div className="port-risk-stats__options">
{statistics.map(item => (
<div key={item.level} className="port-risk-stats__option">
@ -99,4 +99,4 @@ function RiskStatsPanel(props) {
);
}
export default Connect([NS_BI], true)(RiskStatsPanel);
export default Connect([NS_BI_STATISTICS], true)(RiskStatsPanel);

View File

@ -2,7 +2,7 @@ import { Connect } from "@cqsjjb/jjb-dva-runtime";
import { Spin } from "antd";
import { useContext, useEffect, useState } from "react";
import SeamlessScroll from "zy-react-library/components/SeamlessScroll";
import { NS_BI } from "~/enumerate/namespace";
import { NS_BI_STATISTICS } from "~/enumerate/namespace";
import Panel from "~/pages/Container/Map/components/Content/port/Panel";
import { Context } from "~/pages/Container/Map/js/context";
import "./index.less";
@ -38,7 +38,7 @@ function FireDeviceListPanel(props) {
<div className="port-fire-device-list__cell">数量</div>
</div>
<div className="port-fire-device-list__table-body">
<Spin spinning={props.bi.xiaoFangFirePointDeviceListLoading}>
<Spin spinning={props.biStatistics.xiaoFangFirePointDeviceListLoading}>
{isVisible && (
<SeamlessScroll list={deviceList} step={0.5}>
{deviceList.map((item, index) => (
@ -64,4 +64,4 @@ function FireDeviceListPanel(props) {
);
}
export default Connect([NS_BI], true)(FireDeviceListPanel);
export default Connect([NS_BI_STATISTICS], true)(FireDeviceListPanel);

View File

@ -4,7 +4,7 @@ import { message, Spin } from "antd";
import autoFit from "autofit.js";
import { useEffect, useMemo, useReducer, useRef, useState } from "react";
import useGetUrlQuery from "zy-react-library/hooks/useGetUrlQuery";
import { NS_BI } from "~/enumerate/namespace";
import { NS_BI_MARK } from "~/enumerate/namespace";
import BottomUtils from "./components/BottomUtils";
import CenterUtils from "./components/CenterUtils";
import Content from "./components/Content";
@ -118,7 +118,7 @@ function Map(props) {
<div id="cesiumContainer" />
<div id="contentContainer">
{isRenderContent && (
<Spin spinning={props.bi.biFullLoading}>
<Spin spinning={props.biMark.biFullLoading}>
<Header />
<CenterUtils />
<RightUtils history={props.history} isFullscreen={isFullscreen} toggleFullscreen={toggleFullscreen} />
@ -138,4 +138,4 @@ function Map(props) {
);
}
export default Connect([NS_BI], true)(Map);
export default Connect([NS_BI_MARK], true)(Map);