From e01eb96ee0c3cdb1b8d951185a110f44e96a455f Mon Sep 17 00:00:00 2001 From: liujiangyong Date: Tue, 14 Nov 2023 12:08:44 +0800 Subject: [PATCH] =?UTF-8?q?rec=E5=9C=B0=E5=9D=80=E6=94=B9=E4=B8=BAlive?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../sections/water-prevention/components/right-bottom.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/super-screen/client/src/sections/water-prevention/components/right-bottom.js b/super-screen/client/src/sections/water-prevention/components/right-bottom.js index b1267b9..c719d4c 100644 --- a/super-screen/client/src/sections/water-prevention/components/right-bottom.js +++ b/super-screen/client/src/sections/water-prevention/components/right-bottom.js @@ -23,7 +23,7 @@ function DataTop5(props) { // key={Math.random()} defaultValue={videoList[0]?.url} // value={showVideoList} - onChange={(value) => { setShowVideoList(value); }} + onChange={(value) => { setShowVideoList(recUrlToLiveUrl(value)); }} > {videoList.map(s => )} @@ -53,4 +53,9 @@ function DataTop5(props) { export default DataTop5; +function recUrlToLiveUrl(url) { + if (!url) return undefined; + return url.replace('.rec', '.live'); +} +