feat:右侧弹出告警详情
parent
46bbbb9db7
commit
0a13e6fda2
|
@ -76,6 +76,7 @@
|
||||||
告警列表
|
告警列表
|
||||||
</title-component>
|
</title-component>
|
||||||
<warning-list-component class="margin-top-23" @getItem="showWaring"
|
<warning-list-component class="margin-top-23" @getItem="showWaring"
|
||||||
|
@changeClose="changeClose"
|
||||||
:data-list="dataList"></warning-list-component>
|
:data-list="dataList"></warning-list-component>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -5,6 +5,7 @@ import WarningListComponent from "@/components/warningList.component.vue"
|
||||||
import * as turf from '@turf/turf'
|
import * as turf from '@turf/turf'
|
||||||
import Mock from "mockjs"
|
import Mock from "mockjs"
|
||||||
import moment from "moment"
|
import moment from "moment"
|
||||||
|
|
||||||
import("@/assets/style/pageCommon.component.scss")
|
import("@/assets/style/pageCommon.component.scss")
|
||||||
|
|
||||||
|
|
||||||
|
@ -68,9 +69,11 @@ export default class HomeLeftComponent extends Vue {
|
||||||
id: 5
|
id: 5
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
|
|
||||||
get dataList() {
|
get dataList() {
|
||||||
return this.$store.state.eventList
|
return this.$store.state.eventList
|
||||||
}
|
}
|
||||||
|
|
||||||
setData(val, type) {
|
setData(val, type) {
|
||||||
if (type === 'typeName') {
|
if (type === 'typeName') {
|
||||||
const find = this.typeList.find(item => item.id == val) as any
|
const find = this.typeList.find(item => item.id == val) as any
|
||||||
|
@ -94,6 +97,7 @@ export default class HomeLeftComponent extends Vue {
|
||||||
levelClassIcon: 'level-2',
|
levelClassIcon: 'level-2',
|
||||||
time: '2023年3月12日 13:56:00',
|
time: '2023年3月12日 13:56:00',
|
||||||
address: '工厂厂房',
|
address: '工厂厂房',
|
||||||
|
equipment: '5号监测设备',
|
||||||
reporter: '李四',
|
reporter: '李四',
|
||||||
/*tableHeader:[
|
/*tableHeader:[
|
||||||
{
|
{
|
||||||
|
@ -136,6 +140,7 @@ export default class HomeLeftComponent extends Vue {
|
||||||
]*/
|
]*/
|
||||||
}, item))
|
}, item))
|
||||||
}
|
}
|
||||||
|
|
||||||
//点击告警信息
|
//点击告警信息
|
||||||
@Emit('getItem')
|
@Emit('getItem')
|
||||||
getItem(item) {
|
getItem(item) {
|
||||||
|
@ -157,9 +162,11 @@ export default class HomeLeftComponent extends Vue {
|
||||||
console.log(1)
|
console.log(1)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Emit('changeClose')
|
||||||
changeClose() {
|
changeClose() {
|
||||||
console.log(1)
|
console.log(1)
|
||||||
}
|
}
|
||||||
|
|
||||||
addManual() {
|
addManual() {
|
||||||
this.currentCompany = true
|
this.currentCompany = true
|
||||||
this.popObj = {
|
this.popObj = {
|
||||||
|
@ -180,6 +187,7 @@ export default class HomeLeftComponent extends Vue {
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
submitWaring() {
|
submitWaring() {
|
||||||
this.popObj.id = Mock.mock("@id");
|
this.popObj.id = Mock.mock("@id");
|
||||||
if (this.popObj.type === 'normal') {
|
if (this.popObj.type === 'normal') {
|
||||||
|
|
|
@ -108,7 +108,10 @@ export default class WarningDetailComponent extends Vue {
|
||||||
getHazardData(item){
|
getHazardData(item){
|
||||||
this.getHazard(item)
|
this.getHazard(item)
|
||||||
}
|
}
|
||||||
|
@Emit('changeClose')
|
||||||
|
changeClose(){
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
<!-- 运营管理-->
|
<!-- 运营管理-->
|
||||||
<ManageRightComponent v-if="currentNav === 'manage'" class="animate__animated animate__fadeInRight"></ManageRightComponent>
|
<ManageRightComponent v-if="currentNav === 'manage'" class="animate__animated animate__fadeInRight"></ManageRightComponent>
|
||||||
<!--告警详情-->
|
<!--告警详情-->
|
||||||
<WarningDetailComponent :info="info" v-if="waringRightShow && currentNav === 'home'" class="animate__animated animate__fadeInRight"></WarningDetailComponent>
|
<WarningDetailComponent @changeClose="changeClose" @changePoint="changePoint" :info="info" v-if="waringRightShow && currentNav === 'home'" class="animate__animated animate__fadeInRight"></WarningDetailComponent>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
|
@ -168,6 +168,14 @@ export default class OverViewComponent extends BaseComponent {
|
||||||
this.info = item
|
this.info = item
|
||||||
this.waringRightShow = true
|
this.waringRightShow = true
|
||||||
}
|
}
|
||||||
|
//定位坐标
|
||||||
|
changePoint(item){
|
||||||
|
this.addWarnning(item)
|
||||||
|
}
|
||||||
|
//关闭告警详情
|
||||||
|
changeClose(){
|
||||||
|
this.waringRightShow = false
|
||||||
|
}
|
||||||
//进入自由导览
|
//进入自由导览
|
||||||
async showView (){
|
async showView (){
|
||||||
this.toggleAllPanel();
|
this.toggleAllPanel();
|
||||||
|
|
Loading…
Reference in New Issue