Newer
Older
import {Component, OnInit, ViewChild, ElementRef} from '@angular/core';
import {AlarmService} from '../alarm.service';
import {NzMessageService} from 'ng-zorro-antd';
import {SendLogComponent} from '../modal/send-log/send-log.component';
import {WarnListComponent} from '../../modal/warn-list/warn-list.component';
selector: 'smart-now-alarm',
templateUrl: './now-alarm.component.html',
styles: [
`
.tag-warn{
padding: 5px;
}
.tag-warn span{
border: 1px solid #ccc;
margin-right: 10px;
display: inline-block;
margin-bottom: 10px;
padding: 2px 4px;
border-radius: 4px;
}
:host ::ng-deep .tag-warn .ant-tag{
margin-right: 0px;
}
loading = false;
pageCount = pageSize;
pageNum = 1;
totalNum;
constructor(public alarmSer: AlarmService, public message: NzMessageService,
public overAllSer:OverAllService) {
getType(){
this.overAllSer.findHostWarningCount().subscribe(
(res)=>{
if(res.errCode == 10000){
this.warnCountList = res.data;
}else{
this.message.info(res.errMsg);
}
}
)
}
change(e){
this.pageNum = e;
}
//打开modal
showModal(data){
this.sendLog.showModal(data);
}