用户协议优化
This commit is contained in:
@@ -26,8 +26,8 @@ export default {
|
||||
this.init()
|
||||
},
|
||||
methods: {
|
||||
init() {
|
||||
let dictData = this.$util.getDictData('app_event')
|
||||
async init() {
|
||||
let dictData = await this.$util.getDictData('app_event')
|
||||
console.log(dictData)
|
||||
this.store = this.DataSource('/cs-harmonic-boot/event/queryEventList')
|
||||
this.store.params.type = 3
|
||||
|
||||
@@ -26,8 +26,8 @@ export default {
|
||||
this.init()
|
||||
},
|
||||
methods: {
|
||||
init() {
|
||||
let dictData = this.$util.getDictData('app_event')
|
||||
async init() {
|
||||
let dictData = await this.$util.getDictData('app_event')
|
||||
console.log(dictData)
|
||||
this.store = this.DataSource('/cs-harmonic-boot/event/queryEventList')
|
||||
this.store.params.type = 2
|
||||
|
||||
@@ -1,17 +1,60 @@
|
||||
<template>
|
||||
<view class="content">
|
||||
<uni-list :border="false">
|
||||
<uni-list-item show-badge badgeType="error" isDot badge-text="未读" title="发生稳态越限监测点10个" note="2023-02-03" clickable @click="jump" />
|
||||
<uni-list-item show-badge badgeType="error" isDot badge-text="未读" title="发生稳态越限监测点10个" note="2023-02-02" clickable @click="jump" />
|
||||
<uni-list-item show-badge badgeType="error" isDot badge-text="未读" title="发生稳态越限监测点10个" note="2023-02-01" clickable @click="jump" />
|
||||
<uni-list-item badgeType="error" isDot badge-text="未读" title="发生稳态越限监测点10个" note="2023-01-31" clickable @click="jump" />
|
||||
<uni-list-item badgeType="error" isDot badge-text="未读" title="发生稳态越限监测点10个" note="2023-01-30" clickable @click="jump" />
|
||||
<uni-list-item
|
||||
show-badge
|
||||
badgeType="error"
|
||||
isDot
|
||||
badge-text="未读"
|
||||
title="发生稳态越限监测点10个"
|
||||
note="2023-02-03"
|
||||
clickable
|
||||
@click="jump"
|
||||
/>
|
||||
<uni-list-item
|
||||
show-badge
|
||||
badgeType="error"
|
||||
isDot
|
||||
badge-text="未读"
|
||||
title="发生稳态越限监测点10个"
|
||||
note="2023-02-02"
|
||||
clickable
|
||||
@click="jump"
|
||||
/>
|
||||
<uni-list-item
|
||||
show-badge
|
||||
badgeType="error"
|
||||
isDot
|
||||
badge-text="未读"
|
||||
title="发生稳态越限监测点10个"
|
||||
note="2023-02-01"
|
||||
clickable
|
||||
@click="jump"
|
||||
/>
|
||||
<uni-list-item
|
||||
badgeType="error"
|
||||
isDot
|
||||
badge-text="未读"
|
||||
title="发生稳态越限监测点10个"
|
||||
note="2023-01-31"
|
||||
clickable
|
||||
@click="jump"
|
||||
/>
|
||||
<uni-list-item
|
||||
badgeType="error"
|
||||
isDot
|
||||
badge-text="未读"
|
||||
title="发生稳态越限监测点10个"
|
||||
note="2023-01-30"
|
||||
clickable
|
||||
@click="jump"
|
||||
/>
|
||||
</uni-list>
|
||||
<uni-load-more status="nomore"></uni-load-more>
|
||||
</view>
|
||||
</template>
|
||||
<script>
|
||||
import list from "@/common/js/list";
|
||||
import list from '@/common/js/list'
|
||||
|
||||
export default {
|
||||
mixins: [list],
|
||||
@@ -24,14 +67,14 @@ export default {
|
||||
this.init()
|
||||
},
|
||||
methods: {
|
||||
init() {
|
||||
let dictData = this.$util.getDictData('app_event')
|
||||
async init() {
|
||||
let dictData = await this.$util.getDictData('app_event')
|
||||
console.log(dictData)
|
||||
this.store = this.DataSource('/cs-harmonic-boot/event/queryEventList')
|
||||
this.store.params.type = 1
|
||||
this.store.firstCallBack = (res) => {
|
||||
this.store.data.forEach(item => {
|
||||
item.title = item.equipmentName + dictData.find(item2 => item2.code === item.tag).name
|
||||
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
|
||||
@@ -39,10 +82,10 @@ export default {
|
||||
this.store.reload()
|
||||
},
|
||||
jump(item) {
|
||||
let str = JSON.stringify(item).replace(/%/g,'百分比')
|
||||
uni.navigateTo({url: '/pages/message/transientDetail?detail=' + encodeURIComponent(str)})
|
||||
let str = JSON.stringify(item).replace(/%/g, '百分比')
|
||||
uni.navigateTo({ url: '/pages/message/transientDetail?detail=' + encodeURIComponent(str) })
|
||||
},
|
||||
}
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -51,7 +94,6 @@ export default {
|
||||
padding-top: 20rpx;
|
||||
}
|
||||
|
||||
|
||||
/deep/ .uni-list-item {
|
||||
background-color: $uni-theme-white !important;
|
||||
}
|
||||
|
||||
@@ -1,14 +1,19 @@
|
||||
<template>
|
||||
<Cn-page :loading="loading">
|
||||
<view class="content" slot="body">
|
||||
<uni-card :title="item.title" :extra="item.status === '1'?'':'未读'" :sub-title="item.startTime"
|
||||
@click="jump(item)"
|
||||
v-for="(item,index) in store.data" :key="index">
|
||||
<uni-card
|
||||
:title="item.title"
|
||||
:extra="item.status === '1' ? '' : '未读'"
|
||||
:sub-title="item.startTime"
|
||||
@click="jump(item)"
|
||||
v-for="(item, index) in store.data"
|
||||
:key="index"
|
||||
>
|
||||
<view class="term-list-bottom">
|
||||
<view class="term-list-bottom-item">
|
||||
{{ item.engineeringName + '' + item.projectName }}
|
||||
</view>
|
||||
<view class="term-list-bottom-item" v-for="(item2,textIndex) in item.dataSet" :key="textIndex">
|
||||
<view class="term-list-bottom-item" v-for="(item2, textIndex) in item.dataSet" :key="textIndex">
|
||||
{{ item2.showName + ':' + item2.value + (item2.unit || '') }}
|
||||
</view>
|
||||
</view>
|
||||
@@ -17,11 +22,10 @@
|
||||
<uni-load-more v-if="store.data && store.data.length > 0" :status="store.status"></uni-load-more>
|
||||
</view>
|
||||
</Cn-page>
|
||||
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import list from "@/common/js/list";
|
||||
import list from '@/common/js/list'
|
||||
|
||||
export default {
|
||||
mixins: [list],
|
||||
@@ -34,14 +38,14 @@ export default {
|
||||
this.init()
|
||||
},
|
||||
methods: {
|
||||
init() {
|
||||
let dictData = this.$util.getDictData('app_event')
|
||||
async init() {
|
||||
let dictData = await this.$util.getDictData('app_event')
|
||||
console.log(dictData)
|
||||
this.store = this.DataSource('/cs-harmonic-boot/event/queryEventList')
|
||||
this.store.params.type = 0
|
||||
this.store.firstCallBack = (res) => {
|
||||
this.store.data.forEach(item => {
|
||||
item.title = item.equipmentName + dictData.find(item2 => item2.code === item.tag).name
|
||||
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
|
||||
@@ -49,10 +53,10 @@ export default {
|
||||
this.store.reload()
|
||||
},
|
||||
jump(item) {
|
||||
let str = JSON.stringify(item).replace(/%/g,'百分比')
|
||||
uni.navigateTo({url: '/pages/message/transientDetail?detail=' + encodeURIComponent(str)})
|
||||
let str = JSON.stringify(item).replace(/%/g, '百分比')
|
||||
uni.navigateTo({ url: '/pages/message/transientDetail?detail=' + encodeURIComponent(str) })
|
||||
},
|
||||
}
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user