Commit 5ddb5515 by libai

测试

parent 217c7c84
......@@ -2821,8 +2821,8 @@ input::-webkit-input-placeholder {
.secret-room .secret-shadow {
height: 634px;
width: 360px;
background: rgba(0, 0, 0, 0.7);
backdrop-filter: blur(22px);
background: rgba(0, 0, 0, 0.2);
backdrop-filter: blur(12px);
position: absolute;
}
.secret-face {
......
......@@ -2913,12 +2913,13 @@ input::-webkit-input-placeholder{
.secret-shadow{
height: 634px;
width: 360px;
background: rgba(0,0,0,0.7);
backdrop-filter: blur(22px);
background: rgba(0,0,0,0.2);
backdrop-filter: blur(12px);
position: absolute;
}
}
.secret-face{
position: relative;
z-index: 2;
......
......@@ -563,46 +563,6 @@ $(function () {
$(".description").attr("content",'來自'+data.roomBaseInfo.addr.replace(" 中國大陸","臺北")+'的'+data.roomBaseInfo.work+'-'+data.roomBaseInfo.sign.replace("Firefly Live","Footseen")+'-'+data.room.introduce)
$(".keywords-meta").attr("content",''+mcKeyArr[0]+','+mcKeyArr[1]+','+mcKeyArr[2]+','+data.roomBaseInfo.nickname +'')
if(data.room.liveScope==3&&data.room.selfLock==0&&localStorage.uid!=sessionStorage.roomId){
$(".secret-face img").attr("src",'https://zhibocdn.yabolive.net/comm'+data.room.face.split('?')[0]+'?x-oss-process=image/resize,w_90')
$(".secret-rich-box").html('<img src="images/diamond.png" alt=""> '+data.room.tollPrice+'')
$(".secret-room").show()
$(".secret-bg").attr("src",'https://zhibocdn.yabolive.net/comm'+data.room.face.split('?')[0]+'?x-oss-process=image/resize,w_634')
$(".secret-rich-btn").unbind("click").on("click",function(){
if(localStorage.uid==undefined){
loginLayer()
return;
}
$.ajax({
url:$ip+'room/to/join/buy',
data:{
uid: localStorage.uid,
token: localStorage.token,
roomId: sessionStorage.roomId,
channelId:data.room.channelId,
pageID: localStorage.canvasCode,
},
success:function(data){
// console.log('进入付费房购买资格',data)
if(data.code==-100){
layer.msg(data.msg)
setTimeout(function() {
window.open("../reg/index.html")
}, 500);
return
}
if(data.code==1){
layer.msg("已付費,即將進入直播間")
setTimeout(function(){
window.location.reload()
},1000)
}else{
layer.msg(data.msg)
}
}
})
})
}
var roomList = data.room;
flowUrl=data.pullFlowUrl
......@@ -647,6 +607,79 @@ $(function () {
}
else if(data.room.liveState==0&&data.room.liveScope==3){
// online()
// WebSocketGo()
var promise = document.querySelector('video').play();
if (promise !== undefined) {
promise.then(_ => {
var html = [];
html += '<video controls webkit-playsinline ="true" playsinline ="true" autoplay ="" playsinline="true" class="live-video" src="" id="videoElement" loop="" ></video>';
$(".live-content-box-left-roombox").html(html)
flvPlay(data.pullFlowUrl)
// Autoplay started!
}).catch(error => {
var myVideo=document.querySelector(".live-video")
var html = [];
if(sessionStorage.ref==1) html += '<video controls muted webkit-playsinline ="true" playsinline ="true" autoplay ="" playsinline="true" class="live-video" src="" id="videoElement" loop="" ></video>';
else html += '<video controls webkit-playsinline ="true" playsinline ="true" autoplay ="" playsinline="true" class="live-video" src="" id="videoElement" loop="" ></video>';
$(".live-content-box-left-roombox").html(html)
flvPlay(data.pullFlowUrl)
// Autoplay was prevented.
// Show a "Play" button so that user can start playback.
});
}
if(data.room.liveScope==3&&data.room.selfLock==0&&localStorage.uid!=sessionStorage.roomId){
$(".secret-face img").attr("src",'https://zhibocdn.yabolive.net/comm'+data.room.face.split('?')[0]+'?x-oss-process=image/resize,w_90')
$(".secret-rich-box").html('<img src="images/diamond.png" alt=""> '+data.room.tollPrice+'')
$(".secret-room").show()
// $(".secret-bg").attr("src",'https://zhibocdn.yabolive.net/comm'+data.room.face.split('?')[0]+'?x-oss-process=image/resize,w_634')
$(".secret-bg").hide()
setTimeout(function(){
$(".live-video").css("filter","blur(12px)")
$(".live-video").css("pointer-events","none")
},300)
$(".secret-rich-btn").unbind("click").on("click",function(){
if(localStorage.uid==undefined){
loginLayer()
return;
}
$.ajax({
url:$ip+'room/to/join/buy',
data:{
uid: localStorage.uid,
token: localStorage.token,
roomId: sessionStorage.roomId,
channelId:data.room.channelId,
pageID: localStorage.canvasCode,
},
success:function(data){
// console.log('进入付费房购买资格',data)
if(data.code==-100){
layer.msg(data.msg)
setTimeout(function() {
window.open("../reg/index.html")
}, 500);
return
}
if(data.code==1){
layer.msg("已付費,即將進入直播間")
setTimeout(function(){
window.location.reload()
},1000)
}else{
layer.msg(data.msg)
}
}
})
})
}
}
else{
$(".live-content-box-left-roombox").append("<img class='mc-out' src='images/mc-out.png'>")
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment