fix(staff)

This commit is contained in:
wang_yp 2025-03-17 13:59:07 +08:00
parent 35fcd85046
commit 7415fc8312
2 changed files with 11 additions and 7 deletions

View File

@ -1,6 +1,6 @@
import { Modal } from "antd"; import { Modal } from "antd";
import { inject, observer } from "mobx-react"; import { inject, observer } from "mobx-react";
import { useState } from "react"; import { useEffect, useState } from "react";
import Config from "@/util/config"; import Config from "@/util/config";
import EasyPlayer from "../videoTow"; import EasyPlayer from "../videoTow";
const WhichVideo = (props) => { const WhichVideo = (props) => {
@ -37,12 +37,16 @@ const WhichVideo = (props) => {
console.error("Error fetching video URL:", error); console.error("Error fetching video URL:", error);
} }
}; };
fetchUrl() fetchUrl();
timer = setInterval(() => { timer = setInterval(() => {
fetchUrl(); fetchUrl();
}, 35000); }, 35000);
}; };
useEffect(() => {
return () => {
clearInterval(timer);
};
}, []);
return ( return (
<> <>
<span onClick={openDispatch}> </span> <span onClick={openDispatch}> </span>

View File

@ -1,6 +1,6 @@
class Config { class Config {
// static baseUrl = "/"; static baseUrl = "/";
static baseUrl = "https://www.hswzct.cn:12016/"; // static baseUrl = "https://www.hswzct.cn:12016/";
// static baseUrl = "http://127.0.0.1:12214/"; // static baseUrl = "http://127.0.0.1:12214/";
static ws = "wss://www.hswzct.cn:12016/wsadmin?id=admin"; static ws = "wss://www.hswzct.cn:12016/wsadmin?id=admin";
static userStatic = "https://www.hswzct.cn:12016/api/uploads/user/"; static userStatic = "https://www.hswzct.cn:12016/api/uploads/user/";