添加告警导出

jc1.0
fanluyan 1 year ago
parent fdc1a31676
commit 2ad4f5dd68

@ -39,6 +39,13 @@
</el-form-item>
<el-form-item>
<el-button type="primary" @click="onSubmit"></el-button>
<el-button
type="primary"
icon="el-icon-document"
class="exportBtn"
@click="exportWarn"
>导出数据</el-button
>
</el-form-item>
</el-form>
</div>
@ -240,6 +247,21 @@ export default {
handleClose() {
this.dialogVisible = false;
},
//
exportWarn() {
this.formdata.starttime = this.$moment(this.formdata.starttime).format(
"YYYY-MM-DD HH:mm:ss"
);
this.formdata.endtime = this.$moment(this.formdata.endtime).format(
"YYYY-MM-DD HH:mm:ss"
);
window.location.href =
"/cac-api/warning/export?" +
"startTime=" +
this.formdata.starttime +
"&endTime=" +
this.formdata.endtime;
},
},
};
</script>

@ -68,7 +68,7 @@
<li>告警等级</li>
</ul>
<div class="marquee">
<ul class="scrollUl">
<ul class="scrollUl" v-if="tableData.length !== 0">
<li v-for="(item, index) in tableData" :key="index">
<span>{{ item.warnTime }}</span>
<span>{{ item.zsbName }}</span>
@ -83,6 +83,7 @@
>
</li>
</ul>
<div v-else class="empty">暂无告警</div>
</div>
</div>
<warnDialog ref="warnRef"></warnDialog>
@ -194,7 +195,7 @@ export default {
}
.cardContent {
margin-top: 10px;
height: 100%;
height: calc(100% - 54px);
.warntitle {
width: 100%;
@ -232,7 +233,7 @@ export default {
}
}
.marquee {
height: calc(100% - 80px);
height: calc(100% - 26px);
display: flex;
overflow: hidden;
margin-top: 2px;
@ -277,6 +278,13 @@ export default {
}
}
}
.empty {
text-align: center;
display: flex;
align-items: center;
justify-content: center;
width: 100%;
}
}
@keyframes scrollTop {

Loading…
Cancel
Save