master
parent
7e794e3300
commit
697d825669
Binary file not shown.
|
After Width: | Height: | Size: 2.8 KiB |
|
|
@ -27,7 +27,15 @@ function Header(props) {
|
||||||
const onBack = () => {
|
const onBack = () => {
|
||||||
sessionStorage.removeItem("mapCurrentBranchOfficeId");
|
sessionStorage.removeItem("mapCurrentBranchOfficeId");
|
||||||
mitt.emit(deletePeoplePositionPointMittKey);
|
mitt.emit(deletePeoplePositionPointMittKey);
|
||||||
if (currentPort !== "00003" && currentBranchOffice) {
|
if (!currentPort) {
|
||||||
|
window.close();
|
||||||
|
setTimeout(() => {
|
||||||
|
if (!window.closed && !window.opener) {
|
||||||
|
window.location.href = "https://gbs-gateway.qhdsafety.com/";
|
||||||
|
}
|
||||||
|
}, 500);
|
||||||
|
}
|
||||||
|
else if (currentPort !== "00003" && currentBranchOffice) {
|
||||||
mitt.emit(clickPortPointMittKey, { id: "", name: "秦港股份" });
|
mitt.emit(clickPortPointMittKey, { id: "", name: "秦港股份" });
|
||||||
mitt.emit(clickBranchOfficePointMittKey, { id: "", corpName: "秦港股份" });
|
mitt.emit(clickBranchOfficePointMittKey, { id: "", corpName: "秦港股份" });
|
||||||
mapMethods.current.removeWall();
|
mapMethods.current.removeWall();
|
||||||
|
|
@ -70,7 +78,7 @@ function Header(props) {
|
||||||
className={`${displayedTitle === "秦港股份安全监管平台" ? "port" : "branch_office"}`}
|
className={`${displayedTitle === "秦港股份安全监管平台" ? "port" : "branch_office"}`}
|
||||||
style={{ backgroundImage: `url(${displayedTitle === "秦港股份安全监管平台" ? topImg1 : topImg2})` }}
|
style={{ backgroundImage: `url(${displayedTitle === "秦港股份安全监管平台" ? topImg1 : topImg2})` }}
|
||||||
>
|
>
|
||||||
{(currentPort && displayedTitle === "秦港股份安全监管平台") && (
|
{(displayedTitle === "秦港股份安全监管平台") && (
|
||||||
<div style={{ backgroundImage: `url(${backImg1})` }} className="back" onClick={onBack} />
|
<div style={{ backgroundImage: `url(${backImg1})` }} className="back" onClick={onBack} />
|
||||||
)}
|
)}
|
||||||
{displayedTitle !== "秦港股份安全监管平台" && (
|
{displayedTitle !== "秦港股份安全监管平台" && (
|
||||||
|
|
|
||||||
|
|
@ -65,7 +65,12 @@ function RightUtils(props) {
|
||||||
|
|
||||||
switch (type) {
|
switch (type) {
|
||||||
case "back":
|
case "back":
|
||||||
// router.push("/");
|
window.close();
|
||||||
|
setTimeout(() => {
|
||||||
|
if (!window.closed && !window.opener) {
|
||||||
|
window.location.href = "https://gbs-gateway.qhdsafety.com/";
|
||||||
|
}
|
||||||
|
}, 500);
|
||||||
break;
|
break;
|
||||||
case "full":
|
case "full":
|
||||||
props.toggleFullscreen();
|
props.toggleFullscreen();
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
import { useFullscreen, useMount } from "ahooks";
|
import { useFullscreen, useMount } from "ahooks";
|
||||||
import { message } from "antd";
|
import { message } from "antd";
|
||||||
import autoFit from "autofit.js";
|
import autoFit from "autofit.js";
|
||||||
import { useMemo, useRef, useState } from "react";
|
import { useEffect, useMemo, useRef, useState } from "react";
|
||||||
import useGetUrlQuery from "zy-react-library/hooks/useGetUrlQuery";
|
import useGetUrlQuery from "zy-react-library/hooks/useGetUrlQuery";
|
||||||
import BottomUtils from "./components/BottomUtils";
|
import BottomUtils from "./components/BottomUtils";
|
||||||
import CenterUtils from "./components/CenterUtils";
|
import CenterUtils from "./components/CenterUtils";
|
||||||
|
|
@ -84,6 +84,13 @@ function Map(props) {
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
|
|
||||||
|
useEffect(() => {
|
||||||
|
query.accessTicket && window.sessionStorage.setItem("accessTicket", query.accessTicket);
|
||||||
|
query.clientId && window.sessionStorage.setItem("clientId", query.clientId);
|
||||||
|
query.orgId && window.sessionStorage.setItem("orgId", query.orgId);
|
||||||
|
query.token && window.sessionStorage.setItem("token", query.token);
|
||||||
|
}, []);
|
||||||
|
|
||||||
const providerValues = useMemo(
|
const providerValues = useMemo(
|
||||||
() => ({ viewer, mapMethods, currentPort, currentBranchOffice, area, bottomUtilsCurrentIndex, pureMap }),
|
() => ({ viewer, mapMethods, currentPort, currentBranchOffice, area, bottomUtilsCurrentIndex, pureMap }),
|
||||||
[viewer, mapMethods, currentPort, currentBranchOffice, area, bottomUtilsCurrentIndex, pureMap],
|
[viewer, mapMethods, currentPort, currentBranchOffice, area, bottomUtilsCurrentIndex, pureMap],
|
||||||
|
|
@ -96,7 +103,7 @@ function Map(props) {
|
||||||
<div id="contentContainer">
|
<div id="contentContainer">
|
||||||
<Header headerTitle={headerTitle} />
|
<Header headerTitle={headerTitle} />
|
||||||
<CenterUtils setArea={setArea} />
|
<CenterUtils setArea={setArea} />
|
||||||
<RightUtils isFullscreen={isFullscreen} toggleFullscreen={toggleFullscreen} setPureMap={setPureMap} />
|
<RightUtils history={props.history} isFullscreen={isFullscreen} toggleFullscreen={toggleFullscreen} setPureMap={setPureMap} />
|
||||||
<BottomUtils setBottomUtilsCurrentIndex={setBottomUtilsCurrentIndex} />
|
<BottomUtils setBottomUtilsCurrentIndex={setBottomUtilsCurrentIndex} />
|
||||||
<Content history={props.history} />
|
<Content history={props.history} />
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -106,23 +106,4 @@ export default class InitMap {
|
||||||
}
|
}
|
||||||
}, Cesium.ScreenSpaceEventType.LEFT_CLICK);
|
}, Cesium.ScreenSpaceEventType.LEFT_CLICK);
|
||||||
};
|
};
|
||||||
|
|
||||||
// 外部入口
|
|
||||||
externalEntryPort = (query) => {
|
|
||||||
const { id, corpinfoId, mapType, longitude, latitude, name } = query;
|
|
||||||
setTimeout(() => {
|
|
||||||
this.#pointClickEvent.pointClickEvent({
|
|
||||||
monitorItems: {
|
|
||||||
data: {
|
|
||||||
position: { x: longitude, y: latitude },
|
|
||||||
id,
|
|
||||||
corpinfoId,
|
|
||||||
mapType,
|
|
||||||
name,
|
|
||||||
isExternalEntry: "1",
|
|
||||||
},
|
|
||||||
},
|
|
||||||
});
|
|
||||||
}, 0);
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -7,14 +7,14 @@ import RightPanel from "~/pages/Container/White/BranchOffice/components/RightPan
|
||||||
import Header from "~/pages/Container/White/Share/components/Header";
|
import Header from "~/pages/Container/White/Share/components/Header";
|
||||||
import "./index.less";
|
import "./index.less";
|
||||||
|
|
||||||
function BranchOffice() {
|
function BranchOffice(props) {
|
||||||
useMount(() => {
|
useMount(() => {
|
||||||
autoFit.init({ dw: 1920, dh: 1080, el: ".white_branch_office", resize: true });
|
autoFit.init({ dw: 1920, dh: 1080, el: ".white_branch_office", resize: true });
|
||||||
});
|
});
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="white_branch_office" style={{ backgroundImage: `url(${bg})` }}>
|
<div className="white_branch_office" style={{ backgroundImage: `url(${bg})` }}>
|
||||||
<Header />
|
<Header history={props.history} />
|
||||||
<div className="white_branch_office_container">
|
<div className="white_branch_office_container">
|
||||||
<LeftPanel />
|
<LeftPanel />
|
||||||
<CenterPanel />
|
<CenterPanel />
|
||||||
|
|
|
||||||
|
|
@ -1,12 +1,22 @@
|
||||||
|
import back from "~/assets/images/public/white/back.png";
|
||||||
import more from "~/assets/images/public/white/more.png";
|
import more from "~/assets/images/public/white/more.png";
|
||||||
import title from "~/assets/images/public/white/title.png";
|
import title from "~/assets/images/public/white/title.png";
|
||||||
import bg from "~/assets/images/public/white/titlebg.png";
|
import bg from "~/assets/images/public/white/titlebg.png";
|
||||||
import "./index.less";
|
import "./index.less";
|
||||||
|
|
||||||
function Header() {
|
function Header(props) {
|
||||||
return (
|
return (
|
||||||
<div className="white_share_header" style={{ backgroundImage: `url(${bg})` }}>
|
<div className="white_share_header" style={{ backgroundImage: `url(${bg})` }}>
|
||||||
<div className="left">
|
<div className="left">
|
||||||
|
<div className="back">
|
||||||
|
<img
|
||||||
|
src={back}
|
||||||
|
alt=""
|
||||||
|
onClick={() => {
|
||||||
|
props.history.goBack();
|
||||||
|
}}
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
<div className="list">已安全生产 365 天</div>
|
<div className="list">已安全生产 365 天</div>
|
||||||
<div className="list">10~27℃ 多云 星期三</div>
|
<div className="list">10~27℃ 多云 星期三</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -15,9 +15,18 @@
|
||||||
.left {
|
.left {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 30px;
|
top: 30px;
|
||||||
left: 20px;
|
left: 10px;
|
||||||
display: flex;
|
display: flex;
|
||||||
|
|
||||||
|
.back {
|
||||||
|
cursor: pointer;
|
||||||
|
|
||||||
|
img {
|
||||||
|
width: 35px;
|
||||||
|
height: 39px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.list {
|
.list {
|
||||||
padding: 6px 15px;
|
padding: 6px 15px;
|
||||||
border-radius: 23px;
|
border-radius: 23px;
|
||||||
|
|
@ -85,5 +94,5 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -7,14 +7,14 @@ import Middle from "~/pages/Container/White/Share/components/MiddlePanel";
|
||||||
import Right from "~/pages/Container/White/Share/components/RightPanel";
|
import Right from "~/pages/Container/White/Share/components/RightPanel";
|
||||||
import "./index.less";
|
import "./index.less";
|
||||||
|
|
||||||
function Share() {
|
function Share(props) {
|
||||||
useMount(() => {
|
useMount(() => {
|
||||||
autoFit.init({ dw: 1920, dh: 1080, el: ".white_share_office", resize: true });
|
autoFit.init({ dw: 1920, dh: 1080, el: ".white_share_office", resize: true });
|
||||||
});
|
});
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="white_share_office" style={{ backgroundImage: `url(${bg})` }}>
|
<div className="white_share_office" style={{ backgroundImage: `url(${bg})` }}>
|
||||||
<Header />
|
<Header history={props.history} />
|
||||||
<div className="white_share_office_content">
|
<div className="white_share_office_content">
|
||||||
<div className="left">
|
<div className="left">
|
||||||
<Left />
|
<Left />
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue