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
50514109
Commit
50514109
authored
Jun 06, 2019
by
wangqinghua
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
服务器
parent
e921b293
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
25 additions
and
21 deletions
+25
-21
app.service.ts
src/main/webapp/app/app.service.ts
+1
-1
home.component.ts
src/main/webapp/app/home/home.component.ts
+4
-2
navbar.component.html
src/main/webapp/app/layouts/navbar/navbar.component.html
+5
-5
ne-topology.component.html
...pp/app/netTopology/ne-topology/ne-topology.component.html
+1
-1
ne-topology.component.ts
...bapp/app/netTopology/ne-topology/ne-topology.component.ts
+2
-1
jtopo-editor.js
src/main/webapp/content/javascript/jtopo/js/jtopo-editor.js
+7
-11
white.scss
src/main/webapp/content/scss/white.scss
+5
-0
No files found.
src/main/webapp/app/app.service.ts
View file @
50514109
...
...
@@ -4,7 +4,7 @@ import {BehaviorSubject, Subscription} from 'rxjs';
@
Injectable
()
export
class
AppService
{
private
themeSource
:
BehaviorSubject
<
string
>
=
new
BehaviorSubject
(
'
dark
'
);
private
themeSource
:
BehaviorSubject
<
string
>
=
new
BehaviorSubject
(
'
white
'
);
public
theme
=
this
.
themeSource
.
asObservable
();
public
setTheme
(
value
:
string
){
...
...
src/main/webapp/app/home/home.component.ts
View file @
50514109
...
...
@@ -158,8 +158,10 @@ export class HomeComponent implements OnInit, AfterViewInit {
);
this
.
layoutSer
.
findItemStatisticsByGroupid
(
this
.
obj
.
leftGroupId
).
subscribe
(
(
res
)
=>
{
this
.
leftTwoData
=
res
.
data
;
this
.
setLeftTwo
(
res
.
data
);
if
(
res
){
this
.
leftTwoData
=
res
.
data
;
this
.
setLeftTwo
(
res
.
data
);
}
}
);
}
...
...
src/main/webapp/app/layouts/navbar/navbar.component.html
View file @
50514109
...
...
@@ -11,11 +11,11 @@
</span>
</div>
<div
nz-col
[
nzSpan
]="
12
"
style=
"text-align: right"
>
<!-- <nz-select style="width: 150px;margin-right: 20px" [(ngModel)]="theme" (ngModelChange)="changeTheme()">--
>
<!-- <ng-container *ngFor="let item of themeList">--
>
<!-- <nz-option [nzValue]="item.value" [nzLabel]="item.label"></nz-option>--
>
<!-- </ng-container>--
>
<!-- </nz-select>--
>
<nz-select
style=
"width: 150px;margin-right: 20px"
[(
ngModel
)]="
theme
"
(
ngModelChange
)="
changeTheme
()"
>
<ng-container
*
ngFor=
"let item of themeList"
>
<nz-option
[
nzValue
]="
item
.
value
"
[
nzLabel
]="
item
.
label
"
></nz-option
>
</ng-container
>
</nz-select
>
<nz-dropdown
[
nzTrigger
]="'
click
'"
>
<a
nz-dropdown
>
{{user.loginName}}
<i
class=
"anticon anticon-down"
></i>
</a>
...
...
src/main/webapp/app/netTopology/ne-topology/ne-topology.component.html
View file @
50514109
...
...
@@ -37,7 +37,7 @@
<div
nz-row
class=
"layui-layout layui-layout-admin header-bar"
>
<div
nz-col
nzSpan=
"12"
class=
"layui-header "
>
<ng-container
*
ngIf=
"editType == '只读模式'"
>
<nz-select
style=
"width: 200px;"
nzPlaceHolder=
"选择背景色"
[(
ngModel
)]="
backgroundColor
"
(
ngModelChange
)="
changeColor
()"
>
<nz-select
style=
"width: 200px;"
nzPlaceHolder=
"选择背景色
123
"
[(
ngModel
)]="
backgroundColor
"
(
ngModelChange
)="
changeColor
()"
>
<nz-option
nzLabel=
"深蓝"
nzValue=
"#3d76ab"
></nz-option>
<nz-option
nzLabel=
"白色"
nzValue=
"#ffffff"
></nz-option>
<nz-option
nzLabel=
"淡绿"
nzValue=
"#cadf91"
></nz-option>
...
...
src/main/webapp/app/netTopology/ne-topology/ne-topology.component.ts
View file @
50514109
...
...
@@ -135,8 +135,9 @@ export class NeTopologyComponent implements OnInit, DoCheck, AfterViewInit, OnDe
}
ngAfterViewInit
()
{
const
canvasWidth
=
this
.
topologyBody
.
nativeElement
.
clientWidth
;
const
canvasWidth
=
this
.
topologyBody
.
nativeElement
.
clientWidth
-
200
;
const
canvasHeight
=
this
.
topologyBody
.
nativeElement
.
clientHeight
;
console
.
log
(
canvasWidth
,
canvasHeight
)
let
myCanvas
=
this
.
topologyCanvas
.
nativeElement
;
let
context
=
myCanvas
.
getContext
(
'2d'
);
let
ratio
=
this
.
getPixelRatio
(
context
);
...
...
src/main/webapp/content/javascript/jtopo/js/jtopo-editor.js
View file @
50514109
...
...
@@ -171,8 +171,8 @@ function TopologyEditor() {
eagleEyeVsibleDefault
:
false
,
// 是否显示鹰眼对象
// Node属性
nodeAlpha
:
1
,
// 节点透明度,取值范围[0-1]
nodeStrokeColor
:
'
22,124,255
'
,
// 节点描边的颜色
nodeFillColor
:
'
22,124,255
'
,
// 节点填充颜色
nodeStrokeColor
:
'
177,209,239
'
,
// 节点描边的颜色
nodeFillColor
:
'
177,209,239
'
,
// 节点填充颜色
nodeShadow
:
false
,
// 节点是否显示阴影
nodeShadowColor
:
'rgba(0,0,0,0.5)'
,
// 节点阴影的颜色
nodeFont
:
'18px Consolas'
,
// 节点字体
...
...
@@ -189,8 +189,8 @@ function TopologyEditor() {
linkFillColor
:
'177,209,239'
,
linkShadow
:
false
,
// 是否显示连线阴影
linkShadowColor
:
'rgba(0,0,0,0.5)'
,
linkFont
:
'
25
px Consolas'
,
// 节点字体
linkFontColor
:
'
red
'
,
// 连线文字颜色,如"255,255,0"
linkFont
:
'
18
px Consolas'
,
// 节点字体
linkFontColor
:
'
177,209,239
'
,
// 连线文字颜色,如"255,255,0"
linkArrowsRadius
:
0
,
// 线条箭头半径
linkDefaultWidth
:
1
,
// 连线宽度
linkOffsetGap
:
80
,
// 折线拐角处的长度
...
...
@@ -515,8 +515,9 @@ TopologyEditor.prototype.init = function (topologyGuid, backImg, topologyJson,ca
this
.
topologyGuid
=
topologyGuid
// 创建jTopo舞台屏幕对象
var
canvas
=
document
.
getElementById
(
'topology-canvas'
);
// canvas.width = canvasWidth;
// canvas.height = canvasHeight;
console
.
log
(
canvasWidth
,
canvasHeight
)
canvas
.
width
=
canvasWidth
;
canvas
.
height
=
canvasHeight
;
// 加载空白的编辑器
if
(
topologyJson
===
'-1'
)
{
this
.
stage
=
new
JTopo
.
Stage
(
canvas
)
// 定义舞台对象
...
...
@@ -542,11 +543,6 @@ TopologyEditor.prototype.init = function (topologyGuid, backImg, topologyJson,ca
this
.
link
=
null
var
self
=
this
// 模拟告警
if
(
editor
.
utils
.
getAllNodes
().
length
>
0
){
debugger
editor
.
utils
.
getAllNodes
()[
0
].
alarm
=
"告警"
;
}
// 初始化菜单
...
...
src/main/webapp/content/scss/white.scss
View file @
50514109
.white
{
.ant-layout-header
{
background-color
:
#fff
;
border-bottom
:
1px
solid
#eeeeee
;
}
//自己写的
//主机详情
.host-item-title
{
...
...
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