大喇叭

This commit is contained in:
liuye
2022-06-11 13:43:59 +08:00
parent 78a58bc5da
commit fca39122a8
5 changed files with 31 additions and 28 deletions

View File

@@ -108,11 +108,10 @@ export default {
},
setVolume() {
this.isShow = true
this.volume = this.info.volume * 10 || 10
this.volume = this.info.volume
},
confirmAdd() {
var volume = parseInt(this.volume/10)
this.$http.post(`/app/appdlbquipment/volumeControl?deviceId=${this.info.deviceId}&volume=${volume}`).then((res) => {
this.$http.post(`/app/appdlbquipment/volumeControl?deviceId=${this.info.deviceId}&volume=${this.volume}`).then((res) => {
if (res.code == 0) {
this.getDetail()
this.isShow = false

View File

@@ -17,7 +17,7 @@
</div>
<div class="right">
<div class="status">已下发</div>
<div class="cancel-btn" @click="cancel(item.id)" v-if="item.taskType == 1">撤销</div>
<div class="cancel-btn" @click.stop="cancel(item.id)" v-if="item.taskType == 1">撤销</div>
<div class="cancel-btn bg-AFD0FC" v-else>撤销</div>
</div>
</div>

View File

@@ -11,7 +11,9 @@
</div>
<div class="info">
<span>播放方式</span>
<span class="color-333">{{info.taskType == 1 ? '定时播放' : '立即播放'}}-{{ $dict.getLabel('dlbDyclingType', info.cyclingType) }}</span>
<span class="color-333">{{info.taskType == 1 ? '定时播放' : '立即播放'}}
<span v-if="info.taskType == 1 ">-{{ $dict.getLabel('dlbDyclingType', info.cyclingType) }}</span>
</span>
</div>
<div v-if="info.taskType == 1">
<div class="info" v-if="info.cyclingType != 1">
@@ -45,7 +47,7 @@
</div>
<div class="info">
<span>播发设备</span>
<span class="color-333" @click="toEquipmentList"><span style="color:#1174FE;">10</span>个设备<u-icon name="arrow-right" size="28" color="#999999" style="margin-left:8px;"></u-icon></span>
<span class="color-333" @click="toEquipmentList"><span style="color:#1174FE;" v-if="info.devices">{{info.devices.length}}</span>个设备<u-icon name="arrow-right" size="28" color="#999999" style="margin-left:8px;"></u-icon></span>
</div>
</div>
<div class="media-content">
@@ -58,7 +60,7 @@
</div>
</div>
</div>
<div class="btn" v-if="info.taskType">撤销任务</div>
<div class="btn" v-if="info.taskType" @click="cancel">撤销任务</div>
<u-popup v-model="isShow" mode="bottom">
<div class="audio">
<AiVideo :src="url" autoplay></AiVideo>
@@ -98,7 +100,7 @@ export default {
this.isShow = tru
},
toEquipmentList() {
uni.navigateTo({url: `./equipmentList`})
uni.navigateTo({url: `./equipmentList?id=${this.id}`})
},
getDetail() {
this.$http.post(`/app/appzyvideobroadcast/queryDetailById?id=${this.id}`).then(res => {

View File

@@ -1,22 +1,13 @@
<template>
<div class="equipmentList">
<p class="title">播发设备<span class="mini-title"><span style="color:#1174FE;">10</span>个设备</span></p>
<p class="title">播发设备<span class="mini-title"><span style="color:#1174FE;">{{info.devices.length}}</span>个设备</span></p>
<div class="record">
<div class="item">
<div class="item" v-for="(item, index) in info.devices" :key="index">
<img src="../img/lb@2x.png" alt="" class="voice-img">
<div class="info">
<div class="text">
<p>村头大喇叭</p>
<span>刘家河居委会</span>
</div>
</div>
</div>
<div class="item">
<img src="../img/lb@2x.png" alt="" class="voice-img">
<div class="info">
<div class="text">
<p>村头大喇叭</p>
<span>刘家河居委会</span>
<p>{{item.name}}</p>
<span>{{item.areaName}}</span>
</div>
</div>
</div>
@@ -29,17 +20,25 @@ export default {
name: "equipmentList",
data() {
return {
id: '',
info: {},
}
},
computed: { ...mapState(['user']) },
onLoad(option) {
this.areaId = this.user.areaId
this.areaName = this.user.areaName
this.id = option.id
this.getDetail()
},
methods: {
getDetail() {
this.$http.post(`/app/appzyvideobroadcast/queryDetailById?id=${this.id}`).then(res => {
if (res.code == 0) {
this.info = res.data
}
}).catch(() => {
uni.hideLoading()
})
},
}
}
</script>

View File

@@ -18,7 +18,7 @@
<p>{{ item.name ? item.name.split('.')[0] : '-' }}</p>
<div>{{ item.createUserName }}{{ item.createTime }}</div>
</div>
<div class="btn">发布</div>
<div class="btn" @click.stop="toAddBroadcast(item)">发布</div>
</div>
</div>
<div class="record-text" v-else>
@@ -27,7 +27,7 @@
<div>{{ item.name }}</div>
<p>{{ item.content }}</p>
</div>
<div class="btn">发布</div>
<div class="btn" @click.stop="toAddBroadcast(item)">发布</div>
</div>
</div>
<AiEmpty v-if="!list.length"></AiEmpty>
@@ -149,6 +149,9 @@ export default {
},
toDetail(item) {
uni.navigateTo({url: `./detail?id=${item.id}`})
},
toAddBroadcast(item) {
uni.navigateTo({ url: `../addPlay?mediaId=${item.id}&mediaName=${item.name}` })
}
},