From 3279bdff168272ad9f34bfb5789c549f58144466 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=99=9A=E9=A3=8E=E6=8B=82=E6=9F=B3=E9=A2=9C?= <434857005@qq.com> Date: Thu, 11 May 2023 12:03:16 +0800 Subject: [PATCH] =?UTF-8?q?=E5=B0=9D=E8=AF=95=E5=A2=9E=E5=8A=A0=E6=92=AD?= =?UTF-8?q?=E6=94=BE=E9=A1=B5=E9=9D=A2=E3=80=82=E5=A6=82=E6=9E=9C=E6=BA=90?= =?UTF-8?q?=E4=B8=8D=E5=AD=98=E5=9C=A8=E4=BC=9A=E6=9C=89bug,=E5=90=8E?= =?UTF-8?q?=E9=9D=A2=E9=9C=80=E8=A6=81=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- templates/cms/mxpro/css/commonUI.css | 5 +++++ templates/cms/mxpro/detailContent.html | 29 +++++++++++++++++++++++--- templates/cms/mxpro/homeContent.html | 6 ++++-- templates/cms/mxpro/js/commonUI.js | 6 +++--- 4 files changed, 38 insertions(+), 8 deletions(-) diff --git a/templates/cms/mxpro/css/commonUI.css b/templates/cms/mxpro/css/commonUI.css index a559302..573821e 100644 --- a/templates/cms/mxpro/css/commonUI.css +++ b/templates/cms/mxpro/css/commonUI.css @@ -1,3 +1,8 @@ a.links{ margin-right: 5px; +} + +.stui-content__thumb .pic iframe{ +max-width: 100%; +border-radius: 2px;height:155px; } \ No newline at end of file diff --git a/templates/cms/mxpro/detailContent.html b/templates/cms/mxpro/detailContent.html index 1b43703..423015c 100644 --- a/templates/cms/mxpro/detailContent.html +++ b/templates/cms/mxpro/detailContent.html @@ -37,14 +37,16 @@
-
+
+
@@ -78,7 +80,7 @@

{[vod_tab]}

@@ -228,7 +230,26 @@ const app = createApp({ items.value = JSON.parse(sessionStorage.getItem('items'))||items.value; hotsuggs.value = JSON.parse(sessionStorage.getItem('hotsuggs'))||hotsuggs.value; }catch (e) {} + + const iframeSrc = ref(''); + const iframeShow = ref(false); + + const methods = { + async lazyPlay(url){ + iframeShow.value = true; + console.log('准备处理播放地址:'+url); + try { + const res = await axios.get(url,{maxRedirects: 0}); + console.log(res.data); + }catch (e) { + console.log('抓到了错误:'+e.message); + console.log('iframeSrc.value:',iframeSrc.value); + iframeSrc.value = url; + } + }, + }; return { + ...methods, ctx:ctx, items:items, is_home:is_home, @@ -243,6 +264,8 @@ const app = createApp({ vod_tabs:vod_tabs, vod_urls:vod_urls, fast_play:fast_play, + iframeSrc:iframeSrc, + iframeShow:iframeShow, } }, }); diff --git a/templates/cms/mxpro/homeContent.html b/templates/cms/mxpro/homeContent.html index 69819dd..070e317 100644 --- a/templates/cms/mxpro/homeContent.html +++ b/templates/cms/mxpro/homeContent.html @@ -157,7 +157,7 @@ const app = createApp({ const ctx_str = "ctxObj={{ctx|safe}}"; eval(ctx_str); - // console.log(ctxObj) + console.log(ctxObj) const ctx = ref(ctxObj); const items = ref({ @@ -175,7 +175,9 @@ const app = createApp({ try { items.value = JSON.parse(sessionStorage.getItem('items'))||items.value; hotsuggs.value = JSON.parse(sessionStorage.getItem('hotsuggs'))||hotsuggs.value; - }catch (e) {} + }catch (e) { + console.log(e.message) + } return { ctx:ctx, items:items, diff --git a/templates/cms/mxpro/js/commonUI.js b/templates/cms/mxpro/js/commonUI.js index 8814cda..f3fa53a 100644 --- a/templates/cms/mxpro/js/commonUI.js +++ b/templates/cms/mxpro/js/commonUI.js @@ -171,7 +171,7 @@ const stuHeaderComponent = { const stuCategoryComponent = { template: ` - +
更多

@@ -193,7 +193,7 @@ const stuCategoryComponent = {

- +
`, setup(props, context) { console.log('stuCategory组件加载完毕'); @@ -317,7 +317,7 @@ const stuLinksComponent = { // console.log(props); }, props:{ - links:[], + links:Array, }, //配置需要传入的属性 delimiters: ['{[', ']}'],//delimiters:改变默认的插值符号 };