Browse Source

Merge branch 'dev_trial' of https://gitea.free-sun.vip/free-sun/FS-IOT into dev_trial

release_0.0.2
巴林闲侠 2 years ago
parent
commit
39fa23c823
  1. 118
      code/VideoAccess-VCMP/web/client/src/sections/equipmentWarehouse/components/sideSheet.jsx
  2. 5
      code/VideoAccess-VCMP/web/client/src/sections/equipmentWarehouse/containers/camera.jsx
  3. 6
      code/VideoAccess-VCMP/web/client/src/sections/equipmentWarehouse/containers/nvr.jsx

118
code/VideoAccess-VCMP/web/client/src/sections/equipmentWarehouse/components/sideSheet.jsx

@ -24,6 +24,9 @@ function SideSheets (props) {
const { equipmentWarehouse } = actions;
const [clickStyle, setclickStyle] = useState();
const [nvrDetails, setNvrDetails] = useState({ station: [] });
const [highStandard, setHighStandard] = useState(true);
const [solid, setSolid] = useState("solid");
const [light, setLight] = useState("light");
const list = ["项目名称", "关联结构物", "关联测点", "关联监测因素"];
const information = {
nvr: [
@ -97,18 +100,18 @@ function SideSheets (props) {
{
name: "复制直播地址",
liveBroadcast: [
{ name: "HLS地址", key: "" },
{ name: "FLV地址", key: "" },
{ name: "RTMP地址", key: "" },
{ name: "EZOPEN地址", key: "" },
{ name: "ONVIF地址", key: "" },
{ name: "HLS地址", key: "hls" },
{ name: "FLV地址", key: "flv" },
{ name: "RTMP地址", key: "rtmp" },
{ name: "EZOPEN地址", key: "ezopen" },
{ name: "ONVIF地址", key: "onvif" },
],
},
{
name: "复制回收地址",
recovery: [
{ name: "云储存地址", value: "" },
{ name: "本地储存地址", value: "" },
{ name: "云储存地址", key: "cloud" },
{ name: "本地储存地址", key: "local" },
],
},
],
@ -295,10 +298,18 @@ function SideSheets (props) {
marginRight: 20,
}}
>
<Button style={{ marginRight: 20 }} theme="solid">
<Button style={{ marginRight: 20 }} theme={solid} onClick={() => {
setHighStandard(true)
setSolid("solid")
setLight("light")
}}>
高清
</Button>
<Button>标清</Button>
<Button theme={light} onClick={() => {
setHighStandard(false)
setSolid("light")
setLight("solid")
}}>标清</Button>
</div>
) : (
""
@ -386,50 +397,56 @@ function SideSheets (props) {
(cameraSetup ? item.liveBroadcast : item.access).map(
(item, index) => {
if (cameraSetup) {
str.push(
<div
key={"liveBroadcast" + index}
style={{
width: 120,
height: 130,
display: "inline-block",
borderRadius: 4,
border: "1px solid #D9D9D9",
margin: "20px 0 0 40px",
textAlign: "center",
color: clickStyle == item.name ? "white" : "",
background:
clickStyle == item.name ? "#1859C1" : "",
}}
onClick={() => {
copy(item.name);
setclickStyle(item.name);
}}
>
<img
src={`/assets/images/background/${clickStyle == item.name
? "sewage_camera2"
: "sewage_camera1"
}.png`}
style={{ margin: "20px 0 8px 0" }}
/>
<div>
{item.name}
nvrDetails.videoUrl ? nvrDetails.videoUrl.liveUrl ?
str.push(
<div
key={"liveBroadcast" + index}
style={{
width: 120,
height: 130,
display: "inline-block",
borderRadius: 4,
border: "1px solid #D9D9D9",
margin: "20px 0 0 40px",
textAlign: "center",
color: clickStyle == item.name ? "white" : "",
background:
clickStyle == item.name ? "#1859C1" : "",
}}
onClick={() => {
if (highStandard) {
copy(nvrDetails.videoUrl.liveUrl.hd[item.key]);
} else {
copy(nvrDetails.videoUrl.liveUrl.sd[item.key]);
}
setclickStyle(item.name);
}}
>
<img
src={`/assets/images/background/${clickStyle == item.name
? "copy2"
: "copy1"
? "sewage_camera2"
: "sewage_camera1"
}.png`}
style={{
paddingBottom: 10,
display: "inline-block",
width: 10,
height: 20,
}}
style={{ margin: "20px 0 8px 0" }}
/>
<div>
{item.name}
<img
src={`/assets/images/background/${clickStyle == item.name
? "copy2"
: "copy1"
}.png`}
style={{
paddingBottom: 10,
display: "inline-block",
width: 10,
height: 20,
}}
/>
</div>
</div>
</div>
);
) : "" : "";
} else {
str.push(
<div
@ -471,6 +488,7 @@ function SideSheets (props) {
(cameraSetup ? item.recovery : nvrDetails.camera ? nvrDetails.camera : []).map(
(item, index) => {
if (cameraSetup) {
nvrDetails.videoUrl?nvrDetails.videoUrl.replayUrl?
str.push(
<div
key={"liveBroadcast" + index}
@ -487,7 +505,7 @@ function SideSheets (props) {
clickStyle == item.name ? "#1859C1" : "",
}}
onClick={() => {
copy(item.name);
copy(nvrDetails.videoUrl.replayUrl[item.key]);
// alert("");
setclickStyle(item.name);
}}
@ -515,7 +533,7 @@ function SideSheets (props) {
/>
</div>
</div>
);
):"":"";
} else {
str.push(
<div

5
code/VideoAccess-VCMP/web/client/src/sections/equipmentWarehouse/containers/camera.jsx

@ -608,10 +608,10 @@ const CameraHeader = (props) => {
}}
onClick={() => {
api.current.validate().then((v) => {
setearch({ ...v, limit: 10, page: 0 });
setearch(v);
setQuery({ limit: 10, page: 0 })
searchb.current = { ...v, limit: 10, page: 0 }
});
equipmentGetCamera();
}}
>
搜素
@ -630,7 +630,6 @@ const CameraHeader = (props) => {
onClick={() => {
api.current.reset();
setearch({});
equipmentGetCamera();
}}
>
重置

6
code/VideoAccess-VCMP/web/client/src/sections/equipmentWarehouse/containers/nvr.jsx

@ -341,7 +341,6 @@ const NvrHeader = (props) => {
const remind = localStorage.getItem(USER);
console.log(remind)
if (!remind) {
console.log(1)
setReminder(true)
}
equipmentGetNvr();
@ -452,9 +451,9 @@ const NvrHeader = (props) => {
}}
onClick={() => {
api.current.validate().then((v) => {
setearch({ ...v, limit: 10, page: 0 });
setearch(v);
setQuery({ limit: 10, page: 0 })
});
equipmentGetNvr();
}}
>
搜素
@ -473,7 +472,6 @@ const NvrHeader = (props) => {
onClick={() => {
api.current.reset();
setearch({});
equipmentGetNvr();
}}
>
重置

Loading…
Cancel
Save