Commit 905a5786 by 程智春

直播2.0

parent b909156b
...@@ -36,5 +36,17 @@ export default { ...@@ -36,5 +36,17 @@ export default {
//获取服务器时间戳 //获取服务器时间戳
queryServerTimeNow(){ queryServerTimeNow(){
return requestGET(`${process.env.OLSHOP_URL}/liveBroadcastInfo/getServerTimeNow`) return requestGET(`${process.env.OLSHOP_URL}/liveBroadcastInfo/getServerTimeNow`)
},
// 根据号码查询主播创建直播权限状态
queryLivePermissions(options){
return requestPOST(`${process.env.OLSHOP_URL}/liveAnchor/getAuthorityByPhone`,options)
},
//申请直播权限
applyAuthority(options){
return requestPOST(`${process.env.OLSHOP_URL}/liveAnchor/applyAuthority`,options)
},
// 添加申请主播结果通知订阅消息
addLiveResultMsg(options){
return requestPOST(`${process.env.OLSHOP_URL}/broadcastReminderRecord/addLiveAnchorByCustomer`,options)
} }
} }
\ No newline at end of file
<template>
<div class="replay">
</div>
</template>
<script>
export default {
}
</script>
<style lang="scss" scoped>
</style>
\ No newline at end of file
...@@ -447,6 +447,7 @@ export default { ...@@ -447,6 +447,7 @@ export default {
overflow: hidden; overflow: hidden;
bottom: 0; bottom: 0;
right: -30px; right: -30px;
pointer-events: none;
.img { .img {
position: absolute; position: absolute;
bottom: 0; bottom: 0;
......
...@@ -51,6 +51,9 @@ export default { ...@@ -51,6 +51,9 @@ export default {
watch: { watch: {
updateGoods() { updateGoods() {
console.log(this.goodsList,'---------------------------------46goodsList') console.log(this.goodsList,'---------------------------------46goodsList')
this.goodsList.forEach((item,index) => {
this.$set(this.goodsList[index],'minPrice',Number(item.minPrice).toFixed(2))
})
console.log(this.firstCom,'this.firstCom----------') console.log(this.firstCom,'this.firstCom----------')
if (this.firstCom == true) { if (this.firstCom == true) {
this.list = []; this.list = [];
......
...@@ -83,7 +83,7 @@ export default { ...@@ -83,7 +83,7 @@ export default {
updateGoods(){ updateGoods(){
this.list=this.goodsList; this.list=this.goodsList;
this.list.forEach((item, index) => { this.list.forEach((item, index) => {
item.minPrice = Number(item.minPrice); item.minPrice = Number(item.minPrice).toFixed(2);
}); });
}, },
}, },
......
...@@ -312,7 +312,7 @@ export default { ...@@ -312,7 +312,7 @@ export default {
let params = '' let params = ''
if(querys.length > midNum){ if(querys.length > midNum){
if(querys[midNum + 2]){ if(querys[midNum + 2]){
params += `&spokesmanGroupId=${querys[midNum - 1]}&spokesmanShopId=${midNum}&spokesmanRelId=${midNum+1}&userId=${querys[midNum+2]}` params += `&spokesmanGroupId=${querys[midNum - 1]}&spokesmanShopId=${querys[midNum]}&spokesmanRelId=${query[midNum+1]}&userId=${querys[midNum+2]}`
}else{ }else{
params += `&spokesmanGroupId=${querys[midNum - 1]}&spokesmanShopId=${querys[midNum]}&spokesmanRelId=${querys[midNum+1]}` params += `&spokesmanGroupId=${querys[midNum - 1]}&spokesmanShopId=${querys[midNum]}&spokesmanRelId=${querys[midNum+1]}`
} }
......
...@@ -19,6 +19,7 @@ ...@@ -19,6 +19,7 @@
@statechange="statechange" @statechange="statechange"
@error="binderror" @error="binderror"
@netstatus="bindnetstatus" @netstatus="bindnetstatus"
v-if="refreshLive"
/> />
<image class="bg-img" v-if="isBgImg" :src="liveInfo.coverUrl" mode="aspectFill" alt=""></image> <image class="bg-img" v-if="isBgImg" :src="liveInfo.coverUrl" mode="aspectFill" alt=""></image>
<div class="content" :style="{'padding-top':navHeight +'px'}"> <div class="content" :style="{'padding-top':navHeight +'px'}">
...@@ -160,7 +161,7 @@ export default { ...@@ -160,7 +161,7 @@ export default {
clear:'HD', clear:'HD',
devicePosition : 'front', //前置或者后置 back => 后置 devicePosition : 'front', //前置或者后置 back => 后置
enableMic: true, //麦克风是否开启 enableMic: true, //麦克风是否开启
remoteMirror:'disable', //镜像 remoteMirror:'enable', //镜像
userInfo : null, userInfo : null,
...@@ -219,7 +220,11 @@ export default { ...@@ -219,7 +220,11 @@ export default {
isDetailControlLock : true, isDetailControlLock : true,
mirror : false, mirror : true,
refreshLive : true
} }
}, },
filter(){ filter(){
...@@ -282,6 +287,7 @@ export default { ...@@ -282,6 +287,7 @@ export default {
this.isTimeFirstReq = true; this.isTimeFirstReq = true;
this.overOrStop = 1; this.overOrStop = 1;
this.isDetailLock = true; this.isDetailLock = true;
this.refreshLive = true;
this.online = 0 //在线 this.online = 0 //在线
this.look = 0 //观看 this.look = 0 //观看
...@@ -350,7 +356,12 @@ export default { ...@@ -350,7 +356,12 @@ export default {
if(type == 'record'){ if(type == 'record'){
if (!res.authSetting["scope.record"]) { if (!res.authSetting["scope.record"]) {
this.refreshLive = false;
this.openConfirm(type); this.openConfirm(type);
}else{
this.refreshLive = true;
this.pusher = wx.createLivePusherContext('pusher');
this.pusher.startPreview()
} }
}else if(type == 'camera'){ }else if(type == 'camera'){
if (!res.authSetting["scope.camera"]) { if (!res.authSetting["scope.camera"]) {
...@@ -1076,13 +1087,13 @@ export default { ...@@ -1076,13 +1087,13 @@ export default {
top: 0; top: 0;
left: 0; left: 0;
width: 39px; width: 39px;
height: 12px; height: 16px;
color: white; color: white;
background-color: #FF4240; background-color: #FF4240;
border-bottom-right-radius: 2px; border-bottom-right-radius: 2px;
font-size: 11px; font-size: 11px;
text-align: center; text-align: center;
line-height: 12px; line-height: 16px;
} }
.item-top{ .item-top{
height: 78px; height: 78px;
......
...@@ -72,6 +72,15 @@ ...@@ -72,6 +72,15 @@
@error="error" @error="error"
@statechange="changes" @statechange="changes"
/> />
<!-- <video
style="width:100%;height:100vh;"
src="http://vjs.zencdn.net/v/oceans.mp4"
autoplay
:show-fullscreen-btn="false"
/> -->
<!-- object-fit="fillCrop" --> <!-- object-fit="fillCrop" -->
<!-- orientation="horizontal" --> <!-- orientation="horizontal" -->
</div> </div>
......
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 to comment