From d9978c332a44d74c6a675f27c8157a19cdf5a8d3 Mon Sep 17 00:00:00 2001 From: season Date: Fri, 13 Mar 2020 20:49:54 +0800 Subject: [PATCH] 修改回放 --- app.json | 5 +++-- pages/video/index.js | 37 +++++++++---------------------------- 2 files changed, 12 insertions(+), 30 deletions(-) diff --git a/app.json b/app.json index 8df6600..41af70f 100644 --- a/app.json +++ b/app.json @@ -1,6 +1,6 @@ { "pages": [ - "pages/video/index", + "pages/index/index/index", "pages/goods/categoryList/categoryList", "pages/cart/cart/cart", @@ -82,7 +82,8 @@ "pages/user/assistance/task_assistance", "pages/user/assistance/friend_assistance", "pages/user/assistance/assistance_success", - "pages/user/assistance/assistance" + "pages/user/assistance/assistance", + "pages/video/index" ], "permission": { diff --git a/pages/video/index.js b/pages/video/index.js index 8ca6993..82614ac 100644 --- a/pages/video/index.js +++ b/pages/video/index.js @@ -1,32 +1,7 @@ -function getRandomColor () { - let rgb = [] - for (let i = 0 ; i < 3; ++i){ - let color = Math.floor(Math.random() * 256).toString(16) - color = color.length == 1 ? '0' + color : color - rgb.push(color) - } - return '#' + rgb.join('') -} - Page({ onReady: function (res) { - this.videoContext = wx.createVideoContext('myVideo') - }, - inputValue: '', - data: { - src: '', - danmuList: [ - { - text: '第 1s 出现的弹幕', - color: '#ff0000', - time: 1 - }, - { - text: '第 3s 出现的弹幕', - color: '#ff00ff', - time: 3 - }] - }, + + }, bindInputBlur: function(e) { this.inputValue = e.detail.value }, @@ -57,9 +32,15 @@ Page({ }, 300) }, + //---------分享配置-------- + onShareAppMessage: function (e) { + return { + title: "直播视频回放", + } + }, //调用视频接口 onLoad:function(e){ - var r_id=e.roomid,th=this; + var r_id=e.id,th=this; if(!r_id) r_id=1; getApp().request.get("/api/wx/weappLiveReplaylist/get?id="+r_id,{ data:{stoid:getApp().globalData.setting.stoid}, -- libgit2 0.21.4