Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
为 GitLab 提交贡献
登录/注册
切换导航
T
topology-ui
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
姜立玮
topology-ui
Commits
8524023c
提交
8524023c
authored
12月 07, 2022
作者:
姜立玮
🤼
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
修改代理
上级
2ca29564
变更
5
显示空白字符变更
内嵌
并排
正在显示
5 个修改的文件
包含
443 行增加
和
4 行删除
+443
-4
topology.html
public/topology.html
+433
-0
Images.vue
src/components/topology/modules/Images.vue
+2
-1
mainproxy.js
src/utils/mainproxy.js
+1
-0
request.js
src/utils/request.js
+6
-2
vue.config.js
vue.config.js
+1
-1
没有找到文件。
public/topology.html
0 → 100644
浏览文件 @
8524023c
<!DOCTYPE html>
<html
lang=
""
>
<head>
<meta
charset=
"utf-8"
>
<meta
http-equiv=
"X-UA-Compatible"
content=
"IE=edge"
>
<meta
name=
"viewport"
content=
"width=device-width,initial-scale=1"
>
<link
rel=
"icon"
href=
"topology/company.png"
>
<link
href=
"topology/icon/diode/iconfont.css"
rel=
"stylesheet"
>
<link
href=
"topology/icon/capacitance/iconfont.css"
rel=
"stylesheet"
>
<link
href=
"topology/icon/inductance/iconfont.css"
rel=
"stylesheet"
>
<link
href=
"topology/icon/resistance/iconfont.css"
rel=
"stylesheet"
>
<link
href=
"topology/icon/switch/iconfont.css"
rel=
"stylesheet"
>
<link
href=
"topology/icon/blade/iconfont.css"
rel=
"stylesheet"
>
<link
href=
"topology/icon/line/iconfont.css"
rel=
"stylesheet"
>
<link
href=
"topology/icon/contact/iconfont.css"
rel=
"stylesheet"
>
<link
href=
"topology/icon/fuse_breaker/iconfont.css"
rel=
"stylesheet"
>
<link
href=
"topology/icon/grounding/iconfont.css"
rel=
"stylesheet"
>
<link
href=
"topology/icon/transformer/iconfont.css"
rel=
"stylesheet"
>
<link
href=
"topology/css/font_1331132_h688rvffmbc.ttf"
>
<link
href=
"topology/css/font_1331132_qhyav2o6mp.css"
rel=
"stylesheet"
>
<link
href=
"topology/css/font_1331132_5lvbai88wkb.css"
rel=
"stylesheet"
>
<link
href=
"topology/css/font_2030495_3ziztwjjab6.css"
rel=
"stylesheet"
>
<link
href=
"topology/css/sgge.css"
rel=
"stylesheet"
>
<link
href=
"topology/css/eesymbols.css"
rel=
"stylesheet"
>
<title>
组态
</title>
<style>html
,
body
,
#app
{
height
:
100%
;
margin
:
0px
;
padding
:
0px
;
}
.chromeframe
{
margin
:
0.2em
0
;
background
:
#ccc
;
color
:
#000
;
padding
:
0.2em
0
;
}
#loader-wrapper
{
position
:
fixed
;
top
:
0
;
left
:
0
;
width
:
100%
;
height
:
100%
;
z-index
:
999999
;
}
#loader
{
display
:
block
;
position
:
relative
;
left
:
50%
;
top
:
50%
;
width
:
120px
;
height
:
120px
;
margin
:
-75px
0
0
-75px
;
border-radius
:
50%
;
border
:
3px
solid
transparent
;
/* COLOR 1 */
border-top-color
:
#FFF
;
-webkit-animation
:
spin
2s
linear
infinite
;
/* Chrome, Opera 15+, Safari 5+ */
-ms-animation
:
spin
2s
linear
infinite
;
/* Chrome, Opera 15+, Safari 5+ */
-moz-animation
:
spin
2s
linear
infinite
;
/* Chrome, Opera 15+, Safari 5+ */
-o-animation
:
spin
2s
linear
infinite
;
/* Chrome, Opera 15+, Safari 5+ */
animation
:
spin
2s
linear
infinite
;
/* Chrome, Firefox 16+, IE 10+, Opera */
z-index
:
1001
;
}
#loader
:before
{
content
:
""
;
position
:
absolute
;
top
:
5px
;
left
:
5px
;
right
:
5px
;
bottom
:
5px
;
border-radius
:
50%
;
border
:
3px
solid
transparent
;
/* COLOR 2 */
border-top-color
:
#FFF
;
-webkit-animation
:
spin
3s
linear
infinite
;
/* Chrome, Opera 15+, Safari 5+ */
-moz-animation
:
spin
3s
linear
infinite
;
/* Chrome, Opera 15+, Safari 5+ */
-o-animation
:
spin
3s
linear
infinite
;
/* Chrome, Opera 15+, Safari 5+ */
-ms-animation
:
spin
3s
linear
infinite
;
/* Chrome, Opera 15+, Safari 5+ */
animation
:
spin
3s
linear
infinite
;
/* Chrome, Firefox 16+, IE 10+, Opera */
}
#loader
:after
{
content
:
""
;
position
:
absolute
;
top
:
15px
;
left
:
15px
;
right
:
15px
;
bottom
:
15px
;
border-radius
:
50%
;
border
:
3px
solid
transparent
;
border-top-color
:
#FFF
;
/* COLOR 3 */
-moz-animation
:
spin
1.5s
linear
infinite
;
/* Chrome, Opera 15+, Safari 5+ */
-o-animation
:
spin
1.5s
linear
infinite
;
/* Chrome, Opera 15+, Safari 5+ */
-ms-animation
:
spin
1.5s
linear
infinite
;
/* Chrome, Opera 15+, Safari 5+ */
-webkit-animation
:
spin
1.5s
linear
infinite
;
/* Chrome, Opera 15+, Safari 5+ */
animation
:
spin
1.5s
linear
infinite
;
/* Chrome, Firefox 16+, IE 10+, Opera */
}
@-webkit-keyframes
spin
{
0
%
{
-webkit-transform
:
rotate
(
0deg
);
/* Chrome, Opera 15+, Safari 3.1+ */
-ms-transform
:
rotate
(
0deg
);
/* IE 9 */
transform
:
rotate
(
0deg
);
/* Firefox 16+, IE 10+, Opera */
}
100
%
{
-webkit-transform
:
rotate
(
360deg
);
/* Chrome, Opera 15+, Safari 3.1+ */
-ms-transform
:
rotate
(
360deg
);
/* IE 9 */
transform
:
rotate
(
360deg
);
/* Firefox 16+, IE 10+, Opera */
}
}
@keyframes
spin
{
0
%
{
-webkit-transform
:
rotate
(
0deg
);
/* Chrome, Opera 15+, Safari 3.1+ */
-ms-transform
:
rotate
(
0deg
);
/* IE 9 */
transform
:
rotate
(
0deg
);
/* Firefox 16+, IE 10+, Opera */
}
100
%
{
-webkit-transform
:
rotate
(
360deg
);
/* Chrome, Opera 15+, Safari 3.1+ */
-ms-transform
:
rotate
(
360deg
);
/* IE 9 */
transform
:
rotate
(
360deg
);
/* Firefox 16+, IE 10+, Opera */
}
}
#loader-wrapper
.loader-section
{
position
:
fixed
;
top
:
0
;
width
:
51%
;
height
:
100%
;
background
:
#49a9ee
;
/* Old browsers */
z-index
:
1000
;
-webkit-transform
:
translateX
(
0
);
/* Chrome, Opera 15+, Safari 3.1+ */
-ms-transform
:
translateX
(
0
);
/* IE 9 */
transform
:
translateX
(
0
);
/* Firefox 16+, IE 10+, Opera */
}
#loader-wrapper
.loader-section.section-left
{
left
:
0
;
}
#loader-wrapper
.loader-section.section-right
{
right
:
0
;
}
/* Loaded */
.loaded
#loader-wrapper
.loader-section.section-left
{
-webkit-transform
:
translateX
(
-100%
);
/* Chrome, Opera 15+, Safari 3.1+ */
-ms-transform
:
translateX
(
-100%
);
/* IE 9 */
transform
:
translateX
(
-100%
);
/* Firefox 16+, IE 10+, Opera */
-webkit-transition
:
all
0.7s
0.3s
cubic-bezier
(
0.645
,
0.045
,
0.355
,
1.000
);
transition
:
all
0.7s
0.3s
cubic-bezier
(
0.645
,
0.045
,
0.355
,
1.000
);
}
.loaded
#loader-wrapper
.loader-section.section-right
{
-webkit-transform
:
translateX
(
100%
);
/* Chrome, Opera 15+, Safari 3.1+ */
-ms-transform
:
translateX
(
100%
);
/* IE 9 */
transform
:
translateX
(
100%
);
/* Firefox 16+, IE 10+, Opera */
-webkit-transition
:
all
0.7s
0.3s
cubic-bezier
(
0.645
,
0.045
,
0.355
,
1.000
);
transition
:
all
0.7s
0.3s
cubic-bezier
(
0.645
,
0.045
,
0.355
,
1.000
);
}
.loaded
#loader
{
opacity
:
0
;
-webkit-transition
:
all
0.3s
ease-out
;
transition
:
all
0.3s
ease-out
;
}
.loaded
#loader-wrapper
{
visibility
:
hidden
;
-webkit-transform
:
translateY
(
-100%
);
/* Chrome, Opera 15+, Safari 3.1+ */
-ms-transform
:
translateY
(
-100%
);
/* IE 9 */
transform
:
translateY
(
-100%
);
/* Firefox 16+, IE 10+, Opera */
-webkit-transition
:
all
0.3s
1s
ease-out
;
transition
:
all
0.3s
1s
ease-out
;
}
/* JavaScript Turned Off */
.no-js
#loader-wrapper
{
display
:
none
;
}
.no-js
h1
{
color
:
#222222
;
}
#loader-wrapper
.load_title
{
font-family
:
'Open Sans'
;
color
:
#FFF
;
font-size
:
14px
;
width
:
100%
;
text-align
:
center
;
z-index
:
9999999999999
;
position
:
absolute
;
top
:
60%
;
opacity
:
1
;
line-height
:
30px
;
}
#loader-wrapper
.load_title
span
{
font-weight
:
normal
;
font-style
:
italic
;
font-size
:
14px
;
color
:
#FFF
;
opacity
:
0.5
;
}
</style>
<link
href=
"topology/css/chunk-libs.09af4a6b.css"
rel=
"stylesheet"
>
<link
href=
"topology/css/app.6e69a822.css"
rel=
"stylesheet"
>
</head>
<body>
<div
id=
"app"
>
<div
id=
"loader-wrapper"
>
<div
id=
"loader"
></div>
<div
class=
"loader-section section-left"
></div>
<div
class=
"loader-section section-right"
></div>
<div
class=
"load_title"
>
正在加载系统资源,请耐心等待
</div>
</div>
</div>
<script
src=
"topology/js/canvas2svg.js"
></script>
<script
src=
"topology/js/marked.min.js"
></script>
<script
src=
"topology/js/jszip.min.js"
></script>
<script
src=
"topology/js/echarts.min.js"
></script>
<script
src=
"topology/js/axios.min.js"
></script>
<script>
//window.location.origin
function
GetQueryString
(
name
)
{
var
reg
=
new
RegExp
(
"(^|&)"
+
name
+
"=([^&]*)(&|$)"
);
var
r
=
window
.
location
.
href
.
split
(
"="
);
if
(
r
!=
null
)
return
unescape
(
r
[
1
]);
return
null
;
}
function
request_topology
(
setterTag
,
setteeTag
)
{
let
params
=
{}
params
.
id
=
GetQueryString
(
"id"
);
params
.
setterTag
=
setterTag
;
params
.
setteeTag
=
setteeTag
;
axios
({
method
:
'get'
,
url
:
'/topology/params/show'
,
params
}).
then
(
res
=>
{
if
(
res
.
data
.
code
===
200
)
{
alert
(
res
.
data
.
msg
)
}
else
{
alert
(
res
.
data
.
msg
)
}
}).
catch
(
res
=>
{
alert
(
"执行失败,请检查配置!"
)
})
}
</script>
<script>
(
function
(
e
)
{
function
t
(
t
)
{
for
(
var
r
,
o
,
c
=
t
[
0
],
i
=
t
[
1
],
d
=
t
[
2
],
l
=
0
,
f
=
[];
l
<
c
.
length
;
l
++
)
o
=
c
[
l
],
Object
.
prototype
.
hasOwnProperty
.
call
(
a
,
o
)
&&
a
[
o
]
&&
f
.
push
(
a
[
o
][
0
]),
a
[
o
]
=
0
;
for
(
r
in
i
)
Object
.
prototype
.
hasOwnProperty
.
call
(
i
,
r
)
&&
(
e
[
r
]
=
i
[
r
]);
s
&&
s
(
t
);
while
(
f
.
length
)
f
.
shift
()();
return
u
.
push
.
apply
(
u
,
d
||
[]),
n
()
}
function
n
()
{
for
(
var
e
,
t
=
0
;
t
<
u
.
length
;
t
++
)
{
for
(
var
n
=
u
[
t
],
r
=
!
0
,
o
=
1
;
o
<
n
.
length
;
o
++
)
{
var
c
=
n
[
o
];
0
!==
a
[
c
]
&&
(
r
=
!
1
)
}
r
&&
(
u
.
splice
(
t
--
,
1
),
e
=
i
(
i
.
s
=
n
[
0
]))
}
return
e
}
var
r
=
{},
o
=
{
runtime
:
0
},
a
=
{
runtime
:
0
},
u
=
[];
function
c
(
e
)
{
return
i
.
p
+
"topology/js/"
+
({}[
e
]
||
e
)
+
"."
+
{
"chunk-02eb24ba"
:
"63ad49e7"
,
"chunk-1491a9b8"
:
"be763b4d"
,
"chunk-2bf75540"
:
"e5a375fd"
,
"chunk-4186cc52"
:
"d00ecd67"
,
"chunk-a2542904"
:
"13b2b034"
,
"chunk-8ea42a22"
:
"9702f2e6"
,
"chunk-aca192da"
:
"b29e135c"
,
"chunk-6be953dd"
:
"ab89585d"
}[
e
]
+
".js"
}
function
i
(
t
)
{
if
(
r
[
t
])
return
r
[
t
].
exports
;
var
n
=
r
[
t
]
=
{
i
:
t
,
l
:
!
1
,
exports
:
{}};
return
e
[
t
].
call
(
n
.
exports
,
n
,
n
.
exports
,
i
),
n
.
l
=
!
0
,
n
.
exports
}
i
.
e
=
function
(
e
)
{
var
t
=
[],
n
=
{
"chunk-1491a9b8"
:
1
,
"chunk-4186cc52"
:
1
,
"chunk-a2542904"
:
1
,
"chunk-6be953dd"
:
1
};
o
[
e
]
?
t
.
push
(
o
[
e
])
:
0
!==
o
[
e
]
&&
n
[
e
]
&&
t
.
push
(
o
[
e
]
=
new
Promise
((
function
(
t
,
n
)
{
for
(
var
r
=
"topology/css/"
+
({}[
e
]
||
e
)
+
"."
+
{
"chunk-02eb24ba"
:
"31d6cfe0"
,
"chunk-1491a9b8"
:
"da197b00"
,
"chunk-2bf75540"
:
"31d6cfe0"
,
"chunk-4186cc52"
:
"d0b05741"
,
"chunk-a2542904"
:
"ddd444f4"
,
"chunk-8ea42a22"
:
"31d6cfe0"
,
"chunk-aca192da"
:
"31d6cfe0"
,
"chunk-6be953dd"
:
"d8e2471b"
}[
e
]
+
".css"
,
a
=
i
.
p
+
r
,
u
=
document
.
getElementsByTagName
(
"link"
),
c
=
0
;
c
<
u
.
length
;
c
++
)
{
var
d
=
u
[
c
],
l
=
d
.
getAttribute
(
"data-href"
)
||
d
.
getAttribute
(
"href"
);
if
(
"stylesheet"
===
d
.
rel
&&
(
l
===
r
||
l
===
a
))
return
t
()
}
var
f
=
document
.
getElementsByTagName
(
"style"
);
for
(
c
=
0
;
c
<
f
.
length
;
c
++
)
{
d
=
f
[
c
],
l
=
d
.
getAttribute
(
"data-href"
);
if
(
l
===
r
||
l
===
a
)
return
t
()
}
var
s
=
document
.
createElement
(
"link"
);
s
.
rel
=
"stylesheet"
,
s
.
type
=
"text/css"
,
s
.
onload
=
t
,
s
.
onerror
=
function
(
t
)
{
var
r
=
t
&&
t
.
target
&&
t
.
target
.
src
||
a
,
u
=
new
Error
(
"Loading CSS chunk "
+
e
+
" failed.
\n
("
+
r
+
")"
);
u
.
code
=
"CSS_CHUNK_LOAD_FAILED"
,
u
.
request
=
r
,
delete
o
[
e
],
s
.
parentNode
.
removeChild
(
s
),
n
(
u
)
},
s
.
href
=
a
;
var
h
=
document
.
getElementsByTagName
(
"head"
)[
0
];
h
.
appendChild
(
s
)
})).
then
((
function
()
{
o
[
e
]
=
0
})));
var
r
=
a
[
e
];
if
(
0
!==
r
)
if
(
r
)
t
.
push
(
r
[
2
]);
else
{
var
u
=
new
Promise
((
function
(
t
,
n
)
{
r
=
a
[
e
]
=
[
t
,
n
]
}));
t
.
push
(
r
[
2
]
=
u
);
var
d
,
l
=
document
.
createElement
(
"script"
);
l
.
charset
=
"utf-8"
,
l
.
timeout
=
120
,
i
.
nc
&&
l
.
setAttribute
(
"nonce"
,
i
.
nc
),
l
.
src
=
c
(
e
);
var
f
=
new
Error
;
d
=
function
(
t
)
{
l
.
onerror
=
l
.
onload
=
null
,
clearTimeout
(
s
);
var
n
=
a
[
e
];
if
(
0
!==
n
)
{
if
(
n
)
{
var
r
=
t
&&
(
"load"
===
t
.
type
?
"missing"
:
t
.
type
),
o
=
t
&&
t
.
target
&&
t
.
target
.
src
;
f
.
message
=
"Loading chunk "
+
e
+
" failed.
\n
("
+
r
+
": "
+
o
+
")"
,
f
.
name
=
"ChunkLoadError"
,
f
.
type
=
r
,
f
.
request
=
o
,
n
[
1
](
f
)
}
a
[
e
]
=
void
0
}
};
var
s
=
setTimeout
((
function
()
{
d
({
type
:
"timeout"
,
target
:
l
})
}),
12
e4
);
l
.
onerror
=
l
.
onload
=
d
,
document
.
head
.
appendChild
(
l
)
}
return
Promise
.
all
(
t
)
},
i
.
m
=
e
,
i
.
c
=
r
,
i
.
d
=
function
(
e
,
t
,
n
)
{
i
.
o
(
e
,
t
)
||
Object
.
defineProperty
(
e
,
t
,
{
enumerable
:
!
0
,
get
:
n
})
},
i
.
r
=
function
(
e
)
{
"undefined"
!==
typeof
Symbol
&&
Symbol
.
toStringTag
&&
Object
.
defineProperty
(
e
,
Symbol
.
toStringTag
,
{
value
:
"Module"
}),
Object
.
defineProperty
(
e
,
"__esModule"
,
{
value
:
!
0
})
},
i
.
t
=
function
(
e
,
t
)
{
if
(
1
&
t
&&
(
e
=
i
(
e
)),
8
&
t
)
return
e
;
if
(
4
&
t
&&
"object"
===
typeof
e
&&
e
&&
e
.
__esModule
)
return
e
;
var
n
=
Object
.
create
(
null
);
if
(
i
.
r
(
n
),
Object
.
defineProperty
(
n
,
"default"
,
{
enumerable
:
!
0
,
value
:
e
}),
2
&
t
&&
"string"
!=
typeof
e
)
for
(
var
r
in
e
)
i
.
d
(
n
,
r
,
function
(
t
)
{
return
e
[
t
]
}.
bind
(
null
,
r
));
return
n
},
i
.
n
=
function
(
e
)
{
var
t
=
e
&&
e
.
__esModule
?
function
()
{
return
e
[
"default"
]
}
:
function
()
{
return
e
};
return
i
.
d
(
t
,
"a"
,
t
),
t
},
i
.
o
=
function
(
e
,
t
)
{
return
Object
.
prototype
.
hasOwnProperty
.
call
(
e
,
t
)
},
i
.
p
=
window
.
document
.
location
.
pathname
.
substring
(
0
,
window
.
document
.
location
.
pathname
.
indexOf
(
"/topology.html"
))
||
"/"
,
i
.
oe
=
function
(
e
)
{
throw
console
.
error
(
e
),
e
};
var
d
=
window
[
"webpackJsonp"
]
=
window
[
"webpackJsonp"
]
||
[],
l
=
d
.
push
.
bind
(
d
);
d
.
push
=
t
,
d
=
d
.
slice
();
for
(
var
f
=
0
;
f
<
d
.
length
;
f
++
)
t
(
d
[
f
]);
var
s
=
l
;
n
()
})([]);
</script>
<script
src=
"topology/js/chunk-elementUI.b676fb3c.js"
></script>
<script
src=
"topology/js/chunk-libs.2058ff8a.js"
></script>
<script
src=
"topology/js/app.b2481d9d.js"
></script>
</body>
</html>
\ No newline at end of file
src/components/topology/modules/Images.vue
浏览文件 @
8524023c
...
...
@@ -73,6 +73,7 @@
</
template
>
<
script
>
import
{
upload
,
deleteImages
,
list
}
from
"@/api/images.js"
;
import
{
mainProxy
}
from
'@/utils/mainproxy'
export
default
{
data
()
{
return
{
...
...
@@ -80,7 +81,7 @@ export default {
open
:
false
,
url
:
""
,
imageList
:
[],
baseapi
:
process
.
env
.
VUE_APP_BASE_API
,
baseapi
:
mainProxy
,
fit
:
"fill"
,
};
},
...
...
src/utils/mainproxy.js
0 → 100644
浏览文件 @
8524023c
export
const
mainProxy
=
window
.
document
.
location
.
pathname
.
substring
(
0
,
window
.
document
.
location
.
pathname
.
indexOf
(
"/topology.html"
))
||
"/"
\ No newline at end of file
src/utils/request.js
浏览文件 @
8524023c
...
...
@@ -2,12 +2,16 @@ import axios from 'axios'
import
errorCode
from
'@/utils/errorCode'
import
{
Notification
,
MessageBox
,
Message
}
from
'element-ui'
import
{
urlParse
}
from
'@/utils/ruoyi'
import
Vue
from
'vue'
import
{
mainProxy
}
from
'@/utils/mainproxy'
axios
.
defaults
.
headers
[
'Content-Type'
]
=
'application/json;charset=utf-8'
console
.
log
(
mainProxy
)
// 创建axios实例
const
service
=
axios
.
create
({
// axios中请求配置有baseURL选项,表示请求URL公共部分
baseURL
:
process
.
env
.
VUE_APP_BASE_API
,
// baseURL: process.env.VUE_APP_BASE_API,
baseURL
:
mainProxy
,
// 超时
timeout
:
10000
})
...
...
vue.config.js
浏览文件 @
8524023c
...
...
@@ -31,7 +31,7 @@ module.exports = {
proxy
:
{
// detail: https://cli.vuejs.org/config/#devserver-proxy
[
process
.
env
.
VUE_APP_BASE_API
]:
{
target
:
`http://localhost:7777`
,
target
:
'http://127.0.0.1:7777'
,
changeOrigin
:
true
,
pathRewrite
:
{
[
'^'
+
process
.
env
.
VUE_APP_BASE_API
]:
''
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论