Files
app-govern/pages/message/report.vue

66 lines
2.0 KiB
Vue
Raw Normal View History

2023-01-11 16:33:13 +08:00
<template>
2023-02-01 16:59:32 +08:00
<view class="content">
<uni-list :border="false">
2023-09-18 14:19:09 +08:00
<uni-list-item :show-badge="true" badgeType="error" isDot badge-text="未读" title="设备异常共4台"
note="2023-02-27 15:13:29" clickable @click="jump" />
<uni-list-item badgeType="error" isDot badge-text="未读" title="设备异常共1台" note="2023-02-14 15:10:29" clickable
@click="jump" />
<uni-list-item badgeType="error" isDot badge-text="未读" title="设备异常共4台" note="2023-02-10 15:10:29" clickable
@click="jump" />
2023-02-01 16:59:32 +08:00
</uni-list>
2023-02-07 17:59:54 +08:00
<uni-load-more status="nomore"></uni-load-more>
2023-02-01 16:59:32 +08:00
</view>
2023-01-11 16:33:13 +08:00
</template>
<script>
2023-09-18 15:55:34 +08:00
import list from "@/common/js/list";
2023-02-01 16:59:32 +08:00
export default {
2023-09-18 15:55:34 +08:00
mixins: [list],
data() {
2023-02-01 16:59:32 +08:00
return {
2023-09-18 15:55:34 +08:00
loading: true,
2023-02-01 16:59:32 +08:00
}
},
2023-09-18 15:55:34 +08:00
onShow() {
this.init()
2023-02-01 16:59:32 +08:00
},
methods: {
2023-09-18 15:55:34 +08:00
init() {
let dictData = this.$util.getDictData('app_event')
console.log(dictData)
this.store = this.DataSource('/cs-harmonic-boot/event/queryEventList')
this.store.params.type = 3
this.store.firstCallBack = (res) => {
this.store.data.forEach(item => {
item.title = item.equipmentName + dictData.find(item2 => item2.code === item.tag).name
})
console.log(this.store.data)
this.loading = false
}
this.store.reload()
},
jump(item) {
let str = JSON.stringify(item).replace(/%/g,'百分比')
uni.navigateTo({url: '/pages/message/transientDetail?detail=' + encodeURIComponent(str)})
},
2023-02-01 16:59:32 +08:00
}
}
2023-01-11 16:33:13 +08:00
</script>
2023-02-07 17:59:54 +08:00
<style lang="scss">
2023-02-09 08:50:01 +08:00
.content {
padding-top: 20rpx;
}
2023-02-07 17:59:54 +08:00
/deep/ .uni-list-item {
background-color: $uni-theme-white !important;
}
2023-02-27 14:56:08 +08:00
/deep/ .uni-badge {
background-color: unset !important;
2023-02-28 08:49:16 +08:00
color: #dd524d !important;
font-size: 28rpx !important;
2023-02-27 14:56:08 +08:00
}
2023-01-11 16:33:13 +08:00
</style>