图片
This commit is contained in:
@@ -292,6 +292,7 @@ export default {
|
||||
return arr.indexOf(item, 0) === index
|
||||
})
|
||||
},
|
||||
|
||||
nameAvatar(name) {
|
||||
return name?.split('')?.slice(-2) || '游客'
|
||||
},
|
||||
|
||||
@@ -66,6 +66,17 @@ export default {
|
||||
this.getList()
|
||||
},
|
||||
methods: {
|
||||
getList() {
|
||||
this.$instance.post(`/app/appzyvideoequipment/getAreaEquipment?areaId=${this.areaId}`).then((res) => {
|
||||
if (res?.data) {
|
||||
this.list = res.data.list
|
||||
this.count = res.data.count
|
||||
this.onlineRate = (this.count.online / this.count.sum).toFixed(2)
|
||||
this.offlineRate = (1 - this.onlineRate).toFixed(2)
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
getMonitors(nodeId, queryType = 0) {
|
||||
this.monitors = []
|
||||
this.$instance
|
||||
@@ -79,31 +90,26 @@ export default {
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
getMore(row) {
|
||||
this.nodes.push(row)
|
||||
this.getMonitors(row.nodeId, row.hasChild == 1 ? 0 : 1)
|
||||
},
|
||||
|
||||
isCurrent(index) {
|
||||
return index == Math.max(this.nodes?.length - 1, 0)
|
||||
},
|
||||
|
||||
gotoNode(node, index) {
|
||||
this.nodes.splice(index + 1)
|
||||
this.getMonitors(node.nodeId)
|
||||
},
|
||||
getList() {
|
||||
this.$instance.post(`/app/appzyvideoequipment/getAreaEquipment?areaId=${this.areaId}`).then((res) => {
|
||||
if (res?.data) {
|
||||
this.list = res.data.list
|
||||
this.count = res.data.count
|
||||
this.onlineRate = (this.count.online / this.count.sum).toFixed(2)
|
||||
this.offlineRate = (1 - this.onlineRate).toFixed(2)
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
areaSelect(e) {
|
||||
this.areaId = e
|
||||
this.getList()
|
||||
},
|
||||
|
||||
showMonitor(row) {
|
||||
if (row.deviceStatus != 1) return
|
||||
uni.navigateTo({ url: `./monitorDetail?id=${row.id}` })
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
<div class="datas" v-if="data.length">
|
||||
<div class="card" v-for="(item, index) in 3" :key="index" @click="toDetail(item)">
|
||||
<div class="cardTop">
|
||||
<img src="../../static/workOnline/池夏2.jpg" alt="" />
|
||||
<img src="../../static/workOnline/icon3@2x.png" alt="" />
|
||||
|
||||
<div class="rightTop">
|
||||
<div class="leftStaus">
|
||||
@@ -40,7 +40,7 @@
|
||||
<div class="cardConts">⾦秋穿上⽑⾐,漫步森林,在阳光下呼吸伸展,⾃在安逸的天⼈。也许是兰天名字的由来吧。</div>
|
||||
|
||||
<div class="cardImg">
|
||||
<img src="../../static/workOnline/池夏2.jpg" alt="" v-for="(items, i) in 4" :key="i" />
|
||||
<img src="../../static/workOnline/icon3@2x.png" alt="" v-for="(items, i) in 4" :key="i" />
|
||||
</div>
|
||||
|
||||
<div class="cardBot">
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
<div class="middle">
|
||||
<div class="cardTop">
|
||||
<img src="../../static/workOnline/池夏2.jpg" alt="" />
|
||||
<img src="../../static/workOnline/icon3@2x.png" alt="" />
|
||||
|
||||
<div class="rightTop">
|
||||
<div class="leftStaus">
|
||||
@@ -23,7 +23,7 @@
|
||||
<div class="cardConts">⾦秋穿上⽑⾐,漫步森林,在阳光下呼吸伸展,⾃在安逸的天⼈。也许是兰天名字的由来吧。</div>
|
||||
|
||||
<div class="cardImg">
|
||||
<img src="../../static/workOnline/池夏2.jpg" alt="" v-for="(items, i) in 4" :key="i" />
|
||||
<img src="../../static/workOnline/icon3@2x.png" alt="" v-for="(items, i) in 4" :key="i" />
|
||||
</div>
|
||||
|
||||
<div class="cardBot">
|
||||
@@ -107,7 +107,7 @@ export default {
|
||||
return this.$u.toast('请输入你的想法')
|
||||
}
|
||||
|
||||
this.$http
|
||||
this.$instance
|
||||
.post(`/app/appvillagediscussmessage/addOrUpdate`, {
|
||||
content: this.content,
|
||||
avatar: this.user.avatar,
|
||||
@@ -127,7 +127,7 @@ export default {
|
||||
},
|
||||
|
||||
like(id) {
|
||||
this.$http
|
||||
this.$instance
|
||||
.post(`/app/appvillagediscussmessage/suport?id=${id}&userId=${this.user.id}`)
|
||||
.then((res) => {
|
||||
this.$hideLoading()
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 249 KiB |
Reference in New Issue
Block a user