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
18596d22
Commit
18596d22
authored
Dec 24, 2018
by
wangqinghua
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update
parent
f998bbbe
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
37 additions
and
5 deletions
+37
-5
network-detail.component.html
...etwork-check/network-detail/network-detail.component.html
+5
-2
network-detail.component.ts
.../network-check/network-detail/network-detail.component.ts
+32
-3
No files found.
src/main/webapp/app/overAll/network-check/network-detail/network-detail.component.html
View file @
18596d22
...
...
@@ -23,8 +23,8 @@
</div>
<div
class=
"tabset"
>
<div
class=
"tabset-btn"
>
<button
nz-button
nzType=
"default"
>
编辑
</button>
<button
nz-button
nzType=
"default"
>
删除
</button>
<button
(
click
)="
editBasicModal
()"
nz-button
nzType=
"default"
>
编辑
</button>
<button
(
click
)="
showDeleteConfirm
()"
nz-button
nzType=
"default"
>
删除
</button>
</div>
<div
class=
"releative"
>
<nz-tabset
class=
"tabs-smart "
>
...
...
@@ -193,3 +193,5 @@
</nz-tabset>
</div>
</div>
<!--添加网站-->
<smart-website
#
smartWebsite
(
done
)="
getwebList
()"
></smart-website>
\ No newline at end of file
src/main/webapp/app/overAll/network-check/network-detail/network-detail.component.ts
View file @
18596d22
import
{
Component
,
OnInit
,
OnChanges
,
ViewChild
,
ElementRef
}
from
'@angular/core'
;
import
{
OverAllService
}
from
'../../overAll.service'
;
import
{
ActivatedRoute
}
from
'@angular/router'
;
import
{
ActivatedRoute
,
Router
}
from
'@angular/router'
;
import
{
NzMessageService
}
from
'ng-zorro-antd'
;
import
{
DatePipe
}
from
'@angular/common'
;
import
{
WebsiteComponent
}
from
'../../../modal/website/website.component'
;
import
{
CommonService
}
from
'../../../shared/common/common.service'
;
@
Component
({
selector
:
'smart-network-detail'
,
...
...
@@ -28,6 +30,7 @@ import {DatePipe} from '@angular/common';
export
class
NetworkDetailComponent
implements
OnInit
,
OnChanges
{
@
ViewChild
(
'chartSpeedLeft'
)
chartSpeedLeft
:
ElementRef
;
@
ViewChild
(
'chartTimeLeft'
)
chartTimeLeft
:
ElementRef
;
@
ViewChild
(
'smartWebsite'
)
smartWebsite
:
WebsiteComponent
;
httptestid
;
//网站ID
webName
;
//网站名称
...
...
@@ -50,8 +53,8 @@ export class NetworkDetailComponent implements OnInit, OnChanges {
endTime
:
''
};
constructor
(
private
overAllSer
:
OverAllService
,
private
routerInfo
:
ActivatedRoute
,
private
message
:
NzMessageService
,
private
datePipe
:
DatePipe
)
{
constructor
(
private
overAllSer
:
OverAllService
,
private
routerInfo
:
ActivatedRoute
,
private
router
:
Router
,
private
message
:
NzMessageService
,
private
datePipe
:
DatePipe
,
private
commonSer
:
CommonService
)
{
}
ngOnInit
()
{
...
...
@@ -278,4 +281,30 @@ export class NetworkDetailComponent implements OnInit, OnChanges {
this
.
isSpinning
=
false
;
}
//编辑网站
editBasicModal
(){
this
.
smartWebsite
.
showEditModal
(
this
.
httptestid
);
}
//单个删除
showDeleteConfirm
(){
this
.
commonSer
.
confirmThing
(
"删除"
,
"确认要删除该网站监测吗"
,()
=>
{
let
arr
=
[];
arr
.
push
(
this
.
httptestid
);
const
data
=
{
ids
:
arr
};
this
.
overAllSer
.
deleteBatch
(
data
).
subscribe
(
(
res
)
=>
{
if
(
res
.
errCode
==
10000
)
{
this
.
message
.
success
(
'删除成功'
);
this
.
router
.
navigate
([
'app/main/networkCheck'
])
}
else
{
this
.
message
.
error
(
res
.
errMsg
);
}
}
);
});
}
}
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