Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
smart
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wangqinghua
smart
Commits
60d6f195
Commit
60d6f195
authored
Dec 17, 2018
by
wangqinghua
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
workService
parent
a9ed6126
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
134 additions
and
65 deletions
+134
-65
analysis-deal.component.html
...operation-work/analysis-deal/analysis-deal.component.html
+1
-1
analysis-event.component.html
...eration-work/analysis-event/analysis-event.component.html
+1
-1
analysis-status.component.html
...ation-work/analysis-status/analysis-status.component.html
+1
-1
resource-alarm.component.html
...app/analysis/resource-alarm/resource-alarm.component.html
+49
-20
resource-alarm.component.ts
...p/app/analysis/resource-alarm/resource-alarm.component.ts
+0
-0
resource-usabil.component.html
...p/analysis/resource-usabil/resource-usabil.component.html
+13
-34
resource-usabil.component.ts
...app/analysis/resource-usabil/resource-usabil.component.ts
+68
-7
app.main.module.ts
src/main/webapp/app/app.main.module.ts
+1
-1
No files found.
src/main/webapp/app/analysis/operation-work/analysis-deal/analysis-deal.component.html
View file @
60d6f195
<!--处理人统计-->
<!--处理人统计-->
<nz-spin
[
nzSpinning
]="
isLoading
"
>
<nz-spin>
<div
echarts
[
options
]="
chartOption
"
style=
"height: 400px;width: 100%"
></div>
<div
echarts
[
options
]="
chartOption
"
style=
"height: 400px;width: 100%"
></div>
</nz-spin>
</nz-spin>
...
...
src/main/webapp/app/analysis/operation-work/analysis-event/analysis-event.component.html
View file @
60d6f195
<!--事件分类统计-->
<!--事件分类统计-->
<nz-spin
[
nzSpinning
]="
isLoading
"
>
<nz-spin>
<div
echarts
[
options
]="
chartOption
"
style=
"height: 400px;width: 100%"
></div>
<div
echarts
[
options
]="
chartOption
"
style=
"height: 400px;width: 100%"
></div>
</nz-spin>
</nz-spin>
...
...
src/main/webapp/app/analysis/operation-work/analysis-status/analysis-status.component.html
View file @
60d6f195
<!--解决状态统计-->
<!--解决状态统计-->
<!--处理人统计-->
<!--处理人统计-->
<nz-spin
[
nzSpinning
]="
isLoading
"
>
<nz-spin>
<div
echarts
[
options
]="
chartOption
"
style=
"height: 400px;width: 100%"
></div>
<div
echarts
[
options
]="
chartOption
"
style=
"height: 400px;width: 100%"
></div>
</nz-spin>
</nz-spin>
...
...
src/main/webapp/app/analysis/resource-alarm/resource-alarm.component.html
View file @
60d6f195
...
@@ -56,12 +56,20 @@
...
@@ -56,12 +56,20 @@
></nz-date-picker>
></nz-date-picker>
</div>
</div>
</div>
</div>
<nz-spin
[
nzSpinning
]="
isLoading
"
>
<div
nz-row
nzGutter=
"4"
>
<div
echarts
[
options
]="
chartOption
"
style=
"height: 400px;width: 100%"
></div>
<div
nz-col
nzSpan=
"12"
>
</nz-spin>
<nz-spin
[
nzSpinning
]="
isLoading
"
>
<div
echarts
[
options
]="
chartTopOption
"
style=
"height: 400px;width: 100%"
></div>
</nz-spin>
</div>
<div
nz-col
nzSpan=
"12"
>
<nz-spin
[
nzSpinning
]="
isLoading
"
>
<div
echarts
[
options
]="
charTrendOption
"
style=
"height: 400px;width: 100%"
></div>
</nz-spin>
</div>
</div>
<h2>
常见问题TOP10
</h2>
<h2>
常见问题TOP10
</h2>
<nz-table
#
nzTable
[
nzData
]="
inList
"
[
nzLoading
]="
inLoading
"
[
nzFrontPagination
]="
false
"
[
nzTotal
]="
inTotalNum
"
<nz-table
#
nzTable
[
nzData
]="
commonList
"
>
[
nzPageIndex
]="
inPageNum
"
[
nzPageSize
]="
inPageCount
"
(
nzPageIndexChange
)="
inChnagePage
($
event
)"
>
<thead>
<thead>
<tr>
<tr>
<th
nzWidth=
"20%"
>
资源名称
</th>
<th
nzWidth=
"20%"
>
资源名称
</th>
...
@@ -72,20 +80,19 @@
...
@@ -72,20 +80,19 @@
</tr>
</tr>
</thead>
</thead>
<tbody>
<tbody>
<ng-container
*
ngFor=
"let item of
i
nList"
>
<ng-container
*
ngFor=
"let item of
commo
nList"
>
<tr
(
click
)="
getEcharts
(
item
.
itemid
)"
>
<tr>
<td>
{{item.
itemN
ame}}
</td>
<td>
{{item.
hostn
ame}}
</td>
<td>
{{item.
max | toUtil
}}
</td>
<td>
{{item.
groupname
}}
</td>
<td>
{{item.
min | toUtil
}}
</td>
<td>
{{item.
description
}}
</td>
<td>
{{item.
avg | toUtil
}}
</td>
<td>
{{item.
priority
}}
</td>
<td>
{{item.
avg | toUtil
}}
</td>
<td>
{{item.
count
}}
</td>
</tr>
</tr>
</ng-container>
</ng-container>
</tbody>
</tbody>
</nz-table>
</nz-table>
<h2>
统计报告
</h2>
<h2>
统计报告
</h2>
<nz-table
#
nzTable1
[
nzData
]="
outList
"
[
nzLoading
]="
outLoading
"
[
nzFrontPagination
]="
false
"
[
nzTotal
]="
outTotalNum
"
<nz-table
#
nzTable1
[
nzData
]="
reportList
"
>
[
nzPageIndex
]="
outPageNum
"
[
nzPageSize
]="
outPageCount
"
(
nzPageIndexChange
)="
outChnagePage
($
event
)"
>
<thead>
<thead>
<tr>
<tr>
<th
nzWidth=
"20%"
>
时间
</th>
<th
nzWidth=
"20%"
>
时间
</th>
...
@@ -95,15 +102,37 @@
...
@@ -95,15 +102,37 @@
</tr>
</tr>
</thead>
</thead>
<tbody>
<tbody>
<ng-container
*
ngFor=
"let data of outList"
>
<ng-container
*
ngFor=
"let data of reportList"
>
<tr
class=
"cursor"
(
click
)="
getEcharts
(
data
.
itemid
)"
>
<tr
>
<td>
{{data.itemName}}
</td>
<td>
{{data.dateTime}}
</td>
<td>
{{data.max | toUtil}}
</td>
<td>
{{data.countNumber}}
</td>
<td>
{{data.min | toUtil}}
</td>
<td>
<td>
{{data.avg | toUtil}}
</td>
<span
class=
"cursor"
(
click
)="
showWarnModal
()"
>
{{data.waring}}
</span>
</td>
<td>
<span
class=
"cursor"
(
click
)="
showErrorModal
()"
>
{{data.error}}
</span>
</td>
</tr>
</tr>
</ng-container>
</ng-container>
</tbody>
</tbody>
</nz-table>
</nz-table>
<nz-modal
[(
nzVisible
)]="
isVisiable
"
[
nzTitle
]="
title
"
[
nzFooter
]="
null
"
(
nzOnCancel
)="
handleCancel
()"
>
<nz-table
#
nzTable
[
nzData
]="
warnList
"
>
<thead>
<tr>
<th
nzShowSort
>
告警名称
</th>
<th>
告警时间
</th>
<th>
告警设备
</th>
</tr>
</thead>
<tbody>
<tr
*
ngFor=
"let data of warnList"
>
<td>
{{data.hostname}}
</td>
<td>
{{data.description}}
</td>
<td>
{{data.equipmentType}}
</td>
</tr>
</tbody>
</nz-table>
</nz-modal>
src/main/webapp/app/analysis/resource-alarm/resource-alarm.component.ts
View file @
60d6f195
This diff is collapsed.
Click to expand it.
src/main/webapp/app/analysis/resource-usabil/resource-usabil.component.html
View file @
60d6f195
...
@@ -21,19 +21,12 @@
...
@@ -21,19 +21,12 @@
</div>
</div>
<div
nz-row
[
nzGutter
]="
4
"
class=
"search-form"
>
<div
nz-row
[
nzGutter
]="
4
"
class=
"search-form"
>
<div
nz-col
nzSpan=
"3"
>
<div
nz-col
nzSpan=
"3"
>
<nz-select
style=
"width: 100%;"
nzPlaceHolder=
"选择分组"
[(
ngModel
)]="
obj
.
groupid
"
(
ngModelChange
)="
getList
()"
>
<nz-select
style=
"width: 100%;"
nzPlaceHolder=
"选择分组"
[(
ngModel
)]="
obj
.
groupid
"
>
<ng-container
*
ngFor=
"let item of groupList"
>
<ng-container
*
ngFor=
"let item of groupList"
>
<nz-option
nzLabel=
"{{item.name}}"
nzValue=
"{{item.groupid}}"
></nz-option>
<nz-option
nzLabel=
"{{item.name}}"
nzValue=
"{{item.groupid}}"
></nz-option>
</ng-container>
</ng-container>
</nz-select>
</nz-select>
</div>
</div>
<div
nz-col
nzSpan=
"3"
>
<nz-select
style=
"width: 100%;"
nzPlaceHolder=
"选择主机资源"
[(
ngModel
)]="
obj
.
hostid
"
(
ngModelChange
)="
getListIO
()"
>
<ng-container
*
ngFor=
"let item of hostList;"
>
<nz-option
nzLabel=
"{{item.name}}"
nzValue=
"{{item.hostid}}"
></nz-option>
</ng-container>
</nz-select>
</div>
<div
nz-col
nzSpan=
"7"
>
<div
nz-col
nzSpan=
"7"
>
<nz-radio-group
style=
"width: 100%;"
[(
ngModel
)]="
timeType
"
(
ngModelChange
)="
changeType
()"
[
nzButtonStyle
]="'
solid
'"
>
<nz-radio-group
style=
"width: 100%;"
[(
ngModel
)]="
timeType
"
(
ngModelChange
)="
changeType
()"
[
nzButtonStyle
]="'
solid
'"
>
<label
nz-radio-button
nzValue=
"1"
>
今天
</label>
<label
nz-radio-button
nzValue=
"1"
>
今天
</label>
...
@@ -57,28 +50,15 @@
...
@@ -57,28 +50,15 @@
></nz-date-picker>
></nz-date-picker>
</div>
</div>
</div>
</div>
<nz-spin
[
nzSpinning
]="
isLoading
"
>
<div
nz-row
nzGutter=
"4"
>
<div
echarts
[
options
]="
chartOption
"
style=
"height: 400px;width: 100%"
></div>
<div
nz-col
nzSpan=
"12"
>
</nz-spin>
<nz-spin>
<nz-table
#
nzTable
[
nzData
]="
eventList
"
[
nzLoading
]="
isLoading
"
>
<div
echarts
[
options
]="
chartTopOption
"
style=
"height: 400px;width: 100%"
></div>
<thead>
</nz-spin>
<tr>
</div>
<th
nzWidth=
"20%"
>
资源名称
</th>
<div
nz-col
nzSpan=
"12"
>
<th>
所在分组
</th>
<nz-spin>
<th>
告警名称
</th>
<div
echarts
[
options
]="
chartLastOption
"
style=
"height: 400px;width: 100%"
></div>
<th>
严重性
</th>
</nz-spin>
<th>
时间段内发生次数
</th>
</div>
</tr>
</div>
</thead>
<tbody>
<ng-container
*
ngFor=
"let item of eventList"
>
<tr
(
click
)="
getEcharts
(
item
.
itemid
)"
>
<td>
{{item.itemName}}
</td>
<td>
{{item.max | toUtil}}
</td>
<td>
{{item.min | toUtil}}
</td>
<td>
{{item.avg | toUtil}}
</td>
<td>
{{item.avg | toUtil}}
</td>
</tr>
</ng-container>
</tbody>
</nz-table>
\ No newline at end of file
src/main/webapp/app/analysis/resource-usabil/resource-usabil.component.ts
View file @
60d6f195
...
@@ -15,8 +15,11 @@ export class ResourceUsabilComponent implements OnInit {
...
@@ -15,8 +15,11 @@ export class ResourceUsabilComponent implements OnInit {
endTime
;
endTime
;
timeType
;
timeType
;
chartOption
;
chartTopOption
;
eventList
;
topList
;
chartLastOption
;
lastList
;
obj
=
{
obj
=
{
type
:
''
,
type
:
''
,
...
@@ -46,24 +49,81 @@ export class ResourceUsabilComponent implements OnInit {
...
@@ -46,24 +49,81 @@ export class ResourceUsabilComponent implements OnInit {
if
(
res
.
errCode
==
10000
)
{
if
(
res
.
errCode
==
10000
)
{
this
.
groupList
=
res
.
data
;
this
.
groupList
=
res
.
data
;
this
.
obj
.
groupid
=
this
.
groupList
[
0
].
groupid
+
''
;
this
.
obj
.
groupid
=
this
.
groupList
[
0
].
groupid
+
''
;
this
.
getEcharts
();
this
.
getTopEcharts
();
this
.
getLastEcharts
();
}
}
}
}
);
);
}
}
//获取图表
//获取
Top
图表
getEcharts
()
{
get
Top
Echarts
()
{
this
.
obj
.
type
=
'top'
;
this
.
obj
.
type
=
'top'
;
this
.
analysisSer
.
findFailureRate
(
this
.
obj
).
subscribe
(
this
.
analysisSer
.
findFailureRate
(
this
.
obj
).
subscribe
(
(
res
)
=>
{
(
res
)
=>
{
if
(
res
.
errCode
==
10000
){
if
(
res
.
errCode
==
10000
){
this
.
eventList
=
res
.
data
;
this
.
topList
=
res
.
data
;
this
.
setTopEcharts
();
}
}
}
}
);
);
}
}
//设置top图表
setTopEcharts
(){
this
.
chartTopOption
=
{
xAxis
:
{
type
:
'category'
,
data
:
this
.
topList
.
map
(
e
=>
{
return
e
.
operateStatusName
;
})
},
yAxis
:
{
type
:
'value'
},
series
:
[{
data
:
this
.
topList
.
map
(
e
=>
{
return
e
.
num
;
}),
type
:
'bar'
}]
};
}
//获取last图表
getLastEcharts
()
{
this
.
obj
.
type
=
'last'
;
this
.
analysisSer
.
findFailureRate
(
this
.
obj
).
subscribe
(
(
res
)
=>
{
if
(
res
.
errCode
==
10000
){
this
.
lastList
=
res
.
data
;
this
.
setLastEcharts
();
}
}
);
}
//设置last图表
setLastEcharts
(){
this
.
chartLastOption
=
{
xAxis
:
{
type
:
'category'
,
data
:
this
.
lastList
.
map
(
e
=>
{
return
e
.
operateStatusName
;
})
},
yAxis
:
{
type
:
'value'
},
series
:
[{
data
:
this
.
lastList
.
map
(
e
=>
{
return
e
.
num
;
}),
type
:
'bar'
}]
};
}
//时间改变
//时间改变
changeType
()
{
changeType
()
{
const
nowDate
=
new
Date
().
getTime
();
const
nowDate
=
new
Date
().
getTime
();
...
@@ -106,7 +166,8 @@ export class ResourceUsabilComponent implements OnInit {
...
@@ -106,7 +166,8 @@ export class ResourceUsabilComponent implements OnInit {
this
.
obj
.
startTime
=
this
.
datePipe
.
transform
(
this
.
startTime
,
'yyyy-MM-dd HH:mm:ss'
);
this
.
obj
.
startTime
=
this
.
datePipe
.
transform
(
this
.
startTime
,
'yyyy-MM-dd HH:mm:ss'
);
this
.
obj
.
endTime
=
this
.
datePipe
.
transform
(
this
.
endTime
,
'yyyy-MM-dd HH:mm:ss'
);
this
.
obj
.
endTime
=
this
.
datePipe
.
transform
(
this
.
endTime
,
'yyyy-MM-dd HH:mm:ss'
);
}
}
this
.
getEcharts
();
this
.
getLastEcharts
();
this
.
getTopEcharts
();
}
}
}
}
src/main/webapp/app/app.main.module.ts
View file @
60d6f195
...
@@ -180,7 +180,7 @@ import {AnalysisStatusComponent} from './analysis/operation-work/analysis-status
...
@@ -180,7 +180,7 @@ import {AnalysisStatusComponent} from './analysis/operation-work/analysis-status
LinkInventoryComponent
,
LinkInventoryComponent
,
AnalysisDealComponent
,
AnalysisDealComponent
,
AnalysisEventComponent
,
AnalysisEventComponent
,
AnalysisStatusComponent
AnalysisStatusComponent
,
],
],
providers
:[
providers
:[
OverAllService
,
OverAllService
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment