Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
api-gateway
Overview
Overview
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
API
api-gateway
Commits
f1ad9990
Commit
f1ad9990
authored
Sep 06, 2019
by
damodmg
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加分布式限流在列表
parent
ef5c8b0c
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
12 additions
and
6 deletions
+12
-6
index.html
dist/index.html
+2
-2
app.2c457a9381aa15186173d1c7fd4cf7f4.css
dist/static/css/app.2c457a9381aa15186173d1c7fd4cf7f4.css
+0
-0
4.708117be04c0644c10c0.js
dist/static/js/4.708117be04c0644c10c0.js
+2
-2
manifest.b90c9ba8897ae6d21a51.js
dist/static/js/manifest.b90c9ba8897ae6d21a51.js
+0
-2
manifest.c79a13333675abfa1c43.js
dist/static/js/manifest.c79a13333675abfa1c43.js
+2
-0
fluid-rule.vue
src/components/plug/fluid-rule.vue
+6
-0
No files found.
dist/index.html
View file @
f1ad9990
<!DOCTYPE html>
<html><head><meta
charset=
utf-8
><link
rel=
"shortcut icon"
href=
./favicon.ico
><title>
API网关管理平台
</title><link
href=
./static/css/app.7704df90a4766ac1c217cae23a64a458.css
rel=
stylesheet
></head><body
style=
"min-width: 1400px;"
><div
id=
app
></div><script
src=
//web-1251519181.file.myqcloud.com/lib/vue/2.6.6/vue.min.js
></script><script
src=
//web-1251519181.file.myqcloud.com/lib/vue-router/3.0.2/vue-router.min.js
></script><script
src=
//web-1251519181.file.myqcloud.com/lib/vuex/3.1.0/vuex.min.js
></script><script
src=
//web-1251519181.file.myqcloud.com/components/img-preview.2.0.00.js
></script><script>
// Raven.config('https://3715a345910d4c768e7a1ec14619c2d5@sentry.io/1413672').install();
</script><script
src=
//web-1251519181.file.myqcloud.com/components/input.2.0.15.js
></script><script
src=
//web-1251519181.file.myqcloud.com/components/delete.2.0.01.js
></script><script
type=
text/javascript
src=
./static/js/manifest.b90c9ba8897ae6d21a51.js
></script><script
type=
text/javascript
src=
./static/js/vendor.adc34c81686691b8a2e7.js
></script><script
type=
text/javascript
src=
./static/js/app.eb7a92daf8e200957259.js
></script></body></html>
\ No newline at end of file
<!DOCTYPE html>
<html><head><meta
charset=
utf-8
><link
rel=
"shortcut icon"
href=
./favicon.ico
><title>
API网关管理平台
</title><link
href=
./static/css/app.2c457a9381aa15186173d1c7fd4cf7f4.css
rel=
stylesheet
></head><body
style=
"min-width: 1400px;"
><div
id=
app
></div><script
src=
//web-1251519181.file.myqcloud.com/lib/vue/2.6.6/vue.min.js
></script><script
src=
//web-1251519181.file.myqcloud.com/lib/vue-router/3.0.2/vue-router.min.js
></script><script
src=
//web-1251519181.file.myqcloud.com/lib/vuex/3.1.0/vuex.min.js
></script><script
src=
//web-1251519181.file.myqcloud.com/components/img-preview.2.0.00.js
></script><script>
// Raven.config('https://3715a345910d4c768e7a1ec14619c2d5@sentry.io/1413672').install();
</script><script
src=
//web-1251519181.file.myqcloud.com/components/input.2.0.15.js
></script><script
src=
//web-1251519181.file.myqcloud.com/components/delete.2.0.01.js
></script><script
type=
text/javascript
src=
./static/js/manifest.c79a13333675abfa1c43.js
></script><script
type=
text/javascript
src=
./static/js/vendor.adc34c81686691b8a2e7.js
></script><script
type=
text/javascript
src=
./static/js/app.eb7a92daf8e200957259.js
></script></body></html>
\ No newline at end of file
dist/static/css/app.
7704df90a4766ac1c217cae23a64a458
.css
→
dist/static/css/app.
2c457a9381aa15186173d1c7fd4cf7f4
.css
View file @
f1ad9990
This source diff could not be displayed because it is too large. You can
view the blob
instead.
dist/static/js/4.
091de7fadbabb3b3a37a
.js
→
dist/static/js/4.
708117be04c0644c10c0
.js
View file @
f1ad9990
webpackJsonp
([
4
],{
"0amw"
:
function
(
e
,
t
){},
"8PC5"
:
function
(
e
,
t
){
e
.
exports
=
"data:image/png;base64,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"
},
F6GH
:
function
(
e
,
t
){},
"JN/y"
:
function
(
e
,
t
,
a
){
"use strict"
;
Object
.
defineProperty
(
t
,
"__esModule"
,{
value
:
!
0
});
var
r
=
a
(
"bOdI"
),
n
=
a
.
n
(
r
),
o
=
a
(
"BO1k"
),
i
=
a
.
n
(
o
),
s
=
a
(
"319J"
),
l
=
a
(
"P9l9"
),
c
=
a
(
"PEkr"
),
d
=
{
props
:{
ruleId
:{
type
:
String
,
default
:
function
(){
return
""
}},
sceneCode
:{
type
:
String
,
default
:
function
(){
return
""
}}},
data
:
function
(){
return
{
dialogVisible
:
!
0
,
projectList
:[],
groupList
:[],
apiList
:[],
form
:{
rangeType
:
0
,
rangeInfo
:
""
,
projectId
:
""
,
projectName
:
""
,
groupId
:
""
,
groupName
:
""
,
interfaceId
:
""
,
interfaceName
:
""
,
ruleContent
:
""
,
grade
:
1
,
count
:
""
,
strategy
:
0
,
distFlag
:
!
1
,
enableFlag
:
!
1
},
rule
:{
projectId
:[{
required
:
!
0
,
message
:
"请选择项目"
,
trigger
:
"change"
}],
groupId
:[{
required
:
!
0
,
message
:
"请选择分组"
,
trigger
:
"change"
}],
interfaceId
:[{
required
:
!
0
,
message
:
"请选择接口"
,
trigger
:
"change"
}],
count
:[{
required
:
!
0
,
message
:
"请选择阈值"
,
trigger
:
"blur"
},{
validator
:
function
(
e
,
t
,
a
){
/^
(
0
|
\
+
?[
1
-
9
][
0
-
9
]
*
)
$
/
.
test
(
t
)?
a
():
a
(
new
Error
(
"阈值必须输入正整数"
))},
trigger
:
"blur"
}]}}},
created
:
function
(){
this
.
dialogVisible
=!
0
,
this
.
getProjectList
(),
this
.
ruleId
&&
this
.
getInfo
()},
methods
:{
getInfo
:
function
(){
var
e
=
this
,
t
=
this
,
a
=
{
ruleId
:
this
.
ruleId
};
Object
(
l
.
a
)(
"/gateway-manage//rule/ratelimiter/detail"
,
a
).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?(
e
.
form
.
rangeType
=
t
.
data
.
result
.
rangeType
,
0
===
e
.
form
.
rangeType
?
e
.
getGroupList
():
1
===
e
.
form
.
rangeType
?
e
.
getGroupList
():
2
===
e
.
form
.
rangeType
&&
(
e
.
getApiList
(),
e
.
getGroupList
()),
e
.
form
.
projectId
=
t
.
data
.
result
.
projectId
,
e
.
form
.
interfaceId
=
t
.
data
.
result
.
interfaceId
,
e
.
form
.
groupId
=
t
.
data
.
result
.
groupId
,
e
.
form
.
grade
=
t
.
data
.
result
.
grade
,
e
.
form
.
count
=
t
.
data
.
result
.
count
,
e
.
form
.
strategy
=
t
.
data
.
result
.
strategy
,
e
.
form
.
distFlag
=
1
===
t
.
data
.
result
.
distFlag
,
e
.
form
.
enableFlag
=
1
===
t
.
data
.
result
.
enableFlag
):
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
t
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
getProjectList
:
function
(){
var
e
=
this
,
t
=
this
;
Object
(
l
.
a
)(
"/gateway-manage/plugin/interface/tree"
,{}).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?
t
.
data
.
result
?
e
.
projectList
=
t
.
data
.
result
:
e
.
projectList
=
[]:
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
t
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
getGroupList
:
function
(){
var
e
=
this
,
t
=
this
;
this
.
form
.
groupId
=
""
,
this
.
form
.
interfaceId
=
""
;
var
a
=
{
type
:
0
,
id
:
this
.
form
.
projectId
};
Object
(
l
.
a
)(
"/gateway-manage/plugin/interface/tree"
,
a
).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?
t
.
data
.
result
?
e
.
groupList
=
t
.
data
.
result
:
e
.
groupList
=
[]:
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
t
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
getApiList
:
function
(){
var
e
=
this
,
t
=
this
;
this
.
form
.
interfaceId
=
""
;
var
a
=
{
type
:
1
,
id
:
this
.
form
.
groupId
};
Object
(
l
.
a
)(
"/gateway-manage/plugin/interface/tree"
,
a
).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?
t
.
data
.
result
?
e
.
apiList
=
t
.
data
.
result
:
e
.
apiList
=
[]:
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
t
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
submitForm
:
function
(
e
){
var
t
=
this
;
this
.
$refs
[
e
].
validate
(
function
(
e
){
if
(
!
e
)
return
!
1
;
0
===
t
.
form
.
rangeType
?(
t
.
form
.
projectName
=
t
.
projectList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
projectId
}).
name
,
t
.
form
.
ruleContent
=
t
.
form
.
projectName
,
t
.
form
.
rangeInfo
=
t
.
form
.
projectId
):
1
===
t
.
form
.
rangeType
?(
t
.
form
.
projectName
=
t
.
projectList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
projectId
}).
name
,
t
.
form
.
groupName
=
t
.
groupList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
groupId
}).
name
,
t
.
form
.
ruleContent
=
t
.
form
.
projectName
+
"-"
+
t
.
form
.
groupName
,
t
.
form
.
rangeInfo
=
t
.
form
.
groupId
):
2
===
t
.
form
.
rangeType
&&
(
t
.
form
.
projectName
=
t
.
projectList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
projectId
}).
name
,
t
.
form
.
groupName
=
t
.
groupList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
groupId
}).
name
,
t
.
form
.
interfaceName
=
t
.
apiList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
interfaceId
}).
name
,
t
.
form
.
ruleContent
=
t
.
form
.
projectName
+
"-"
+
t
.
form
.
groupName
+
"-"
+
t
.
form
.
interfaceName
,
t
.
form
.
rangeInfo
=
t
.
form
.
interfaceId
);
var
a
=
{
sceneCode
:
t
.
sceneCode
,
rangeType
:
t
.
form
.
rangeType
,
rangeInfo
:
t
.
form
.
rangeInfo
,
ruleContent
:
t
.
form
.
ruleContent
,
grade
:
t
.
form
.
grade
,
count
:
t
.
form
.
count
,
strategy
:
t
.
form
.
strategy
,
distFlag
:
t
.
form
.
distFlag
?
1
:
0
,
enableFlag
:
t
.
form
.
enableFlag
?
1
:
0
};
t
.
ruleId
&&
(
a
.
rateLimiterId
=
t
.
ruleId
),
Object
(
l
.
a
)(
"/gateway-manage//rule/ratelimiter/save"
,
a
).
then
(
function
(
e
){
"0000"
==
e
.
data
.
code
?(
t
.
dialogVisible
=!
1
,
t
.
$emit
(
"getList"
),
t
.
$emit
(
"cancelAdd"
)):
t
.
$message
.
error
(
e
.
data
.
message
)})})},
close
:
function
(
e
){
this
.
$refs
[
e
].
resetFields
(),
this
.
$emit
(
"cancelAdd"
)}}},
u
=
{
render
:
function
(){
var
e
=
this
,
t
=
e
.
$createElement
,
a
=
e
.
_self
.
_c
||
t
;
return
a
(
"el-dialog"
,{
attrs
:{
title
:
e
.
ruleId
?
"编辑流控规则"
:
"新建流控规则"
,
visible
:
e
.
dialogVisible
,
width
:
"400px"
},
on
:{
"update:visible"
:
function
(
t
){
e
.
dialogVisible
=
t
},
close
:
function
(
t
){
return
e
.
close
(
"form"
)}}},[
a
(
"div"
,{
staticClass
:
"dialog-body"
},[
a
(
"el-form"
,{
ref
:
"form"
,
staticClass
:
"demo-ruleForm"
,
attrs
:{
model
:
e
.
form
,
rules
:
e
.
rule
,
"label-width"
:
"100px"
,
"label-position"
:
"right"
}},[
a
(
"el-form-item"
,{
attrs
:{
label
:
"流控范围"
,
prop
:
"rangeType"
}},[[
a
(
"el-radio"
,{
attrs
:{
label
:
0
},
model
:{
value
:
e
.
form
.
rangeType
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"rangeType"
,
t
)},
expression
:
"form.rangeType"
}},[
e
.
_v
(
"项目"
)]),
e
.
_v
(
" "
),
a
(
"el-radio"
,{
attrs
:{
label
:
1
},
model
:{
value
:
e
.
form
.
rangeType
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"rangeType"
,
t
)},
expression
:
"form.rangeType"
}},[
e
.
_v
(
"分组"
)]),
e
.
_v
(
" "
),
a
(
"el-radio"
,{
attrs
:{
label
:
2
},
model
:{
value
:
e
.
form
.
rangeType
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"rangeType"
,
t
)},
expression
:
"form.rangeType"
}},[
e
.
_v
(
"接口"
)])]],
2
),
e
.
_v
(
" "
),
a
(
"el-form-item"
,{
attrs
:{
label
:
"流控内容"
,
prop
:
"projectId"
}},[
a
(
"el-select"
,{
attrs
:{
placeholder
:
"请选择项目"
},
on
:{
change
:
e
.
getGroupList
},
model
:{
value
:
e
.
form
.
projectId
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"projectId"
,
t
)},
expression
:
"form.projectId"
}},
e
.
_l
(
e
.
projectList
,
function
(
e
){
return
a
(
"el-option"
,{
key
:
e
.
id
,
attrs
:{
label
:
e
.
name
,
value
:
e
.
id
}})}),
1
)],
1
),
e
.
_v
(
" "
),
0
!==
e
.
form
.
rangeType
?
a
(
"el-form-item"
,{
attrs
:{
prop
:
"groupId"
}},[
a
(
"el-select"
,{
attrs
:{
placeholder
:
"请选择分组"
,
disabled
:
""
===
e
.
form
.
projectId
},
on
:{
change
:
e
.
getApiList
},
model
:{
value
:
e
.
form
.
groupId
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"groupId"
,
t
)},
expression
:
"form.groupId"
}},
e
.
_l
(
e
.
groupList
,
function
(
e
){
return
a
(
"el-option"
,{
key
:
e
.
id
,
attrs
:{
label
:
e
.
name
,
value
:
e
.
id
}})}),
1
)],
1
):
e
.
_e
(),
e
.
_v
(
" "
),
2
===
e
.
form
.
rangeType
?
a
(
"el-form-item"
,{
attrs
:{
prop
:
"interfaceId"
}},[
a
(
"el-select"
,{
attrs
:{
placeholder
:
"请选择接口"
,
disabled
:
""
===
e
.
form
.
groupId
},
model
:{
value
:
e
.
form
.
interfaceId
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"interfaceId"
,
t
)},
expression
:
"form.interfaceId"
}},
e
.
_l
(
e
.
apiList
,
function
(
e
){
return
a
(
"el-option"
,{
key
:
e
.
id
,
attrs
:{
label
:
e
.
name
,
value
:
e
.
id
}})}),
1
)],
1
):
e
.
_e
(),
e
.
_v
(
" "
),
a
(
"el-form-item"
,{
attrs
:{
label
:
"阈值类型"
,
prop
:
"grade"
}},[[
a
(
"el-radio"
,{
attrs
:{
label
:
1
},
model
:{
value
:
e
.
form
.
grade
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"grade"
,
t
)},
expression
:
"form.grade"
}},[
e
.
_v
(
"QPS"
)])]],
2
),
e
.
_v
(
" "
),
a
(
"el-form-item"
,{
attrs
:{
label
:
"阈值"
,
prop
:
"count"
}},[
a
(
"el-input"
,{
staticClass
:
"w-220"
,
attrs
:{
placeholder
:
"请输入阈值"
},
model
:{
value
:
e
.
form
.
count
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"count"
,
t
)},
expression
:
"form.count"
}})],
1
),
e
.
_v
(
" "
),
a
(
"el-form-item"
,{
attrs
:{
label
:
"流控方式"
,
prop
:
"rangeType"
}},[[
a
(
"el-radio"
,{
attrs
:{
label
:
0
},
model
:{
value
:
e
.
form
.
strategy
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"strategy"
,
t
)},
expression
:
"form.strategy"
}},[
e
.
_v
(
"快速失败"
)])]],
2
),
e
.
_v
(
" "
),
a
(
"el-form-item"
,{
attrs
:{
label
:
"分布式限流"
,
prop
:
"count"
}},[
a
(
"el-switch"
,{
model
:{
value
:
e
.
form
.
distFlag
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"distFlag"
,
t
)},
expression
:
"form.distFlag"
}})],
1
),
e
.
_v
(
" "
),
a
(
"el-form-item"
,{
attrs
:{
label
:
"是否开启"
,
prop
:
"count"
}},[
a
(
"el-switch"
,{
model
:{
value
:
e
.
form
.
enableFlag
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"enableFlag"
,
t
)},
expression
:
"form.enableFlag"
}})],
1
)],
1
)],
1
),
e
.
_v
(
" "
),
a
(
"div"
,{
staticClass
:
"dialog-footer"
,
attrs
:{
slot
:
"footer"
},
slot
:
"footer"
},[
a
(
"el-button"
,{
on
:{
click
:
function
(
t
){
return
e
.
close
(
"form"
)}}},[
e
.
_v
(
"取消"
)]),
e
.
_v
(
" "
),
a
(
"el-button"
,{
attrs
:{
type
:
"primary"
},
on
:{
click
:
function
(
t
){
return
e
.
submitForm
(
"form"
)}}},[
e
.
_v
(
"确定"
)])],
1
)])},
staticRenderFns
:[]};
var
g
=
a
(
"VU/8"
)(
d
,
u
,
!
1
,
function
(
e
){
a
(
"0amw"
)},
"data-v-7928b793"
,
null
).
exports
,
m
=
{
props
:{
ruleId
:{
type
:
String
,
default
:
function
(){
return
""
}},
alarmType
:{
type
:
Number
,
default
:
function
(){
return
0
}},
sceneCode
:{
type
:
String
,
default
:
function
(){
return
""
}}},
data
:
function
(){
return
{
dialogVisible
:
!
0
,
tableData
:[],
total
:
0
,
currentPage
:
1
,
pageSize
:
5
}},
created
:
function
(){
this
.
dialogVisible
=!
0
,
this
.
getList
()},
methods
:{
handleCurrentChange
:
function
(
e
){
this
.
currentPage
=
e
,
this
.
getList
()},
getList
:
function
(){
var
e
=
this
,
t
=
{
ruleId
:
this
.
ruleId
,
sceneCode
:
this
.
sceneCode
,
alarmType
:
this
.
alarmType
,
currentPage
:
this
.
currentPage
,
pageSize
:
this
.
pageSize
},
a
=
this
;
Object
(
l
.
a
)(
"/gateway-manage/rule/alarm/log"
,
t
).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?
t
.
data
.
result
.
result
.
length
?(
e
.
tableData
=
t
.
data
.
result
.
result
,
e
.
total
=
t
.
data
.
result
.
totalCount
):(
e
.
tableData
=
[],
e
.
total
=
0
):
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
a
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
close
:
function
(){
this
.
dialogVisible
=!
1
,
this
.
$emit
(
"cancelLog"
)}}},
f
=
{
render
:
function
(){
var
e
=
this
,
t
=
e
.
$createElement
,
a
=
e
.
_self
.
_c
||
t
;
return
a
(
"el-dialog"
,{
attrs
:{
title
:
1
===
e
.
alarmType
?
"流控日志"
:
"熔断日志"
,
visible
:
e
.
dialogVisible
,
width
:
"600px"
},
on
:{
"update:visible"
:
function
(
t
){
e
.
dialogVisible
=
t
},
close
:
e
.
close
}},[
a
(
"div"
,{
staticClass
:
"dialog-body"
},[
a
(
"el-table"
,{
staticClass
:
"dialog-table"
,
staticStyle
:{
width
:
"100%"
},
attrs
:{
data
:
e
.
tableData
}},[
a
(
"el-table-column"
,{
attrs
:{
prop
:
"rangeType"
,
label
:
1
===
e
.
alarmType
?
"流控范围"
:
"熔断范围"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
0
===
t
.
row
.
rangeType
?
a
(
"div"
,[
e
.
_v
(
"项目"
)]):
e
.
_e
(),
e
.
_v
(
" "
),
1
===
t
.
row
.
rangeType
?
a
(
"div"
,[
e
.
_v
(
"分组"
)]):
e
.
_e
(),
e
.
_v
(
" "
),
2
===
t
.
row
.
rangeType
?
a
(
"div"
,[
e
.
_v
(
"接口"
)]):
e
.
_e
()]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"ruleContent"
,
label
:
1
===
e
.
alarmType
?
"流控内容"
:
"熔断内容"
}}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"updateTime"
,
label
:
"发生时间"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
a
(
"div"
,{
staticClass
:
"color-606266 line-18"
},[
e
.
_v
(
e
.
_s
(
e
.
_f
(
"timeStampToYmd"
)(
t
.
row
.
updateTime
)))]),
e
.
_v
(
" "
),
a
(
"div"
,{
staticClass
:
"color-606266 line-18"
},[
e
.
_v
(
e
.
_s
(
e
.
_f
(
"timeStampToHms"
)(
t
.
row
.
updateTime
)))])]}}])})],
1
),
e
.
_v
(
" "
),
e
.
total
>
0
?
a
(
"div"
,{
staticClass
:
"page-content"
},[
a
(
"el-pagination"
,{
attrs
:{
small
:
""
,
"current-page"
:
e
.
currentPage
,
"page-size"
:
e
.
pageSize
,
layout
:
"prev, pager, next"
,
total
:
e
.
total
},
on
:{
"current-change"
:
e
.
handleCurrentChange
,
"update:currentPage"
:
function
(
t
){
e
.
currentPage
=
t
},
"update:current-page"
:
function
(
t
){
e
.
currentPage
=
t
}}})],
1
):
e
.
_e
()],
1
)])},
staticRenderFns
:[]};
var
p
=
a
(
"VU/8"
)(
m
,
f
,
!
1
,
function
(
e
){
a
(
"JQyN"
)},
"data-v-118a596f"
,
null
).
exports
,
h
=
{
props
:{
tableData
:{
type
:
Array
,
default
:
function
(){
return
[]}},
sceneCode
:{
type
:
String
,
default
:
function
(){
return
""
}}},
components
:{
newRule
:
g
,
ahshLog
:
p
},
data
:
function
(){
return
{
showRuleDialog
:
!
1
,
ruleId
:
""
,
showDialog
:
""
,
alarmType
:
1
}},
methods
:{
deleteList
:
function
(
e
){
var
t
=
this
,
a
=
this
,
r
=
{
rateLimiterId
:
e
.
rateLimiterId
};
Object
(
l
.
a
)(
"/gateway-manage/rule/ratelimiter/del"
,
r
).
then
(
function
(
e
){
"0000"
==
e
.
data
.
code
?
t
.
getList
():
t
.
$message
.
error
(
e
.
data
.
message
)}).
catch
(
function
(
e
){
a
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
getList
:
function
(){
this
.
$emit
(
"getList"
)},
changeFlag
:
function
(
e
){
var
t
=
this
,
a
=
{
enableFlag
:
e
.
enableFlag
?
1
:
0
,
rateLimiterId
:
e
.
rateLimiterId
};
Object
(
l
.
a
)(
"/gateway-manage/rule/ratelimiter/enable"
,
a
).
then
(
function
(
a
){
"0000"
==
a
.
data
.
code
?
t
.
$emit
(
"getList"
):(
e
.
enableFlag
=!
e
.
enableFlag
,
t
.
$message
.
error
(
a
.
data
.
message
))})},
edit
:
function
(
e
){
this
.
ruleId
=
e
.
rateLimiterId
,
this
.
showRuleDialog
=!
0
},
cancelAdd
:
function
(){
this
.
showRuleDialog
=!
1
},
seeLog
:
function
(
e
){
this
.
ruleId
=
e
.
rateLimiterId
,
this
.
showDialog
=!
0
},
cancelLog
:
function
(){
this
.
showDialog
=!
1
}}},
v
=
{
render
:
function
(){
var
e
=
this
,
t
=
e
.
$createElement
,
a
=
e
.
_self
.
_c
||
t
;
return
a
(
"div"
,{
staticStyle
:{
"margin-top"
:
"20px"
}},[
a
(
"div"
,{
staticClass
:
"table-content"
},[
a
(
"el-table"
,{
directives
:[{
name
:
"loading"
,
rawName
:
"v-loading"
,
value
:
e
.
loading
,
expression
:
"loading"
}],
staticStyle
:{
width
:
"100%"
},
attrs
:{
data
:
e
.
tableData
,
"tooltip-effect"
:
"dark"
,
height
:
e
.
tableHeight
}},[
a
(
"el-table-column"
,{
attrs
:{
label
:
"流控ID"
,
prop
:
"ruleCode"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
a
(
"span"
,[
e
.
_v
(
e
.
_s
(
t
.
row
.
ruleCode
))]),
e
.
_v
(
" "
),
1
===
t
.
row
.
editeFlag
?
a
(
"span"
,{
staticClass
:
"sign-design"
},[
e
.
_v
(
"未发布"
)]):
e
.
_e
()]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"rangeType"
,
label
:
"流控范围"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
0
===
t
.
row
.
rangeType
?
a
(
"p"
,[
e
.
_v
(
"项目"
)]):
e
.
_e
(),
e
.
_v
(
" "
),
1
===
t
.
row
.
rangeType
?
a
(
"p"
,[
e
.
_v
(
"分组"
)]):
e
.
_e
(),
e
.
_v
(
" "
),
2
===
t
.
row
.
rangeType
?
a
(
"p"
,[
e
.
_v
(
"接口"
)]):
e
.
_e
()]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"ruleContent"
,
label
:
"流控内容"
}}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"grade"
,
label
:
"阈值类型"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
1
===
t
.
row
.
grade
?
a
(
"p"
,[
e
.
_v
(
"QPS"
)]):
e
.
_e
()]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"count"
,
label
:
"阈值"
}}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"strategy"
,
label
:
"流控方式"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
0
===
t
.
row
.
strategy
?
a
(
"p"
,[
e
.
_v
(
"快速失败"
)]):
e
.
_e
()]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"enableFlag"
,
label
:
"开启状态"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
a
(
"el-switch"
,{
on
:{
change
:
function
(
a
){
return
e
.
changeFlag
(
t
.
row
)}},
model
:{
value
:
t
.
row
.
enableFlag
,
callback
:
function
(
a
){
e
.
$set
(
t
.
row
,
"enableFlag"
,
a
)},
expression
:
"scope.row.enableFlag"
}})]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
label
:
"操作"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
a
(
"el-button"
,{
attrs
:{
type
:
"text"
},
on
:{
click
:
function
(
a
){
return
e
.
edit
(
t
.
row
)}}},[
e
.
_v
(
"编辑"
)]),
e
.
_v
(
" "
),
a
(
"dm-delete"
,{
attrs
:{
tips
:
"确定要删除该数据吗?"
},
on
:{
confirm
:
function
(
a
){
return
e
.
deleteList
(
t
.
row
)}}},[
a
(
"el-button"
,{
attrs
:{
type
:
"text"
}},[
e
.
_v
(
"删除"
)])],
1
),
e
.
_v
(
" "
),
a
(
"el-button"
,{
attrs
:{
type
:
"text"
},
on
:{
click
:
function
(
a
){
return
e
.
seeLog
(
t
.
row
)}}},[
e
.
_v
(
"日志"
)])]}}])})],
1
)],
1
),
e
.
_v
(
" "
),
e
.
showRuleDialog
?
a
(
"newRule"
,{
attrs
:{
sceneCode
:
e
.
sceneCode
,
ruleId
:
e
.
ruleId
},
on
:{
cancelAdd
:
e
.
cancelAdd
,
getList
:
e
.
getList
}}):
e
.
_e
(),
e
.
_v
(
" "
),
e
.
showDialog
?
a
(
"ahshLog"
,{
attrs
:{
alarmType
:
e
.
alarmType
,
sceneCode
:
e
.
sceneCode
,
ruleId
:
e
.
ruleId
},
on
:{
cancelLog
:
e
.
cancelLog
}}):
e
.
_e
()],
1
)},
staticRenderFns
:[]};
var
b
=
a
(
"VU/8"
)(
h
,
v
,
!
1
,
function
(
e
){
a
(
"QSX3"
)},
"data-v-4e8f1a54"
,
null
).
exports
,
y
=
{
props
:{
degradeId
:{
type
:
String
,
default
:
function
(){
return
""
}},
sceneCode
:{
type
:
String
,
default
:
function
(){
return
""
}}},
data
:
function
(){
return
{
dialogVisible
:
!
0
,
projectList
:[],
groupList
:[],
apiList
:[],
form
:{
rangeType
:
0
,
rangeInfo
:
""
,
ruleContent
:
""
,
projectId
:
""
,
projectName
:
""
,
groupId
:
""
,
groupName
:
""
,
interfaceId
:
""
,
interfaceName
:
""
,
grade
:
1
,
count
:
""
,
timeWindow
:
""
,
enableFlag
:
!
1
},
rule
:{
projectId
:[{
required
:
!
0
,
message
:
"请选择项目"
,
trigger
:
"change"
}],
groupId
:[{
required
:
!
0
,
message
:
"请选择分组"
,
trigger
:
"change"
}],
interfaceId
:[{
required
:
!
0
,
message
:
"请选择接口"
,
trigger
:
"change"
}],
count
:[{
required
:
!
0
,
message
:
"请输入异常比例"
,
trigger
:
"blur"
},{
validator
:
function
(
e
,
t
,
a
){
/^
[
0
-
1
]{
1
}([.]([
0
-
9
]){
2
})?
$
/
.
test
(
t
)?
a
():
a
(
new
Error
(
"请输入0-1且小数不超过两位的数字"
))},
trigger
:
"blur"
}],
timeWindow
:[{
required
:
!
0
,
message
:
"请输入时间窗口"
,
trigger
:
"blur"
},{
validator
:
function
(
e
,
t
,
a
){
/^
(
0
|
\
+
?[
1
-
9
][
0
-
9
]
*
)
$
/
.
test
(
t
)?
a
():
a
(
new
Error
(
"时间必须输入正整数"
))},
trigger
:
"blur"
}]}}},
created
:
function
(){
this
.
dialogVisible
=!
0
,
this
.
getProjectList
(),
this
.
degradeId
&&
this
.
getInfo
()},
methods
:{
getInfo
:
function
(){
var
e
=
this
,
t
=
this
,
a
=
{
ruleId
:
this
.
degradeId
};
Object
(
l
.
a
)(
"/gateway-manage/rule/degrade/detail"
,
a
).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?(
e
.
form
.
rangeType
=
t
.
data
.
result
.
rangeType
,
0
===
e
.
form
.
rangeType
?
e
.
getGroupList
():
1
===
e
.
form
.
rangeType
?
e
.
getGroupList
():
2
===
e
.
form
.
rangeType
&&
(
e
.
getApiList
(),
e
.
getGroupList
()),
e
.
form
.
projectId
=
t
.
data
.
result
.
projectId
,
e
.
form
.
interfaceId
=
t
.
data
.
result
.
interfaceId
,
e
.
form
.
groupId
=
t
.
data
.
result
.
groupId
,
e
.
form
.
grade
=
t
.
data
.
result
.
grade
,
e
.
form
.
count
=
t
.
data
.
result
.
count
,
e
.
form
.
timeWindow
=
t
.
data
.
result
.
timeWindow
,
e
.
form
.
enableFlag
=
1
===
t
.
data
.
result
.
enableFlag
):
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
t
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
getProjectList
:
function
(){
var
e
=
this
,
t
=
this
;
Object
(
l
.
a
)(
"/gateway-manage/plugin/interface/tree"
,{}).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?
t
.
data
.
result
?
e
.
projectList
=
t
.
data
.
result
:
e
.
projectList
=
[]:
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
t
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
getGroupList
:
function
(){
var
e
=
this
,
t
=
this
;
this
.
form
.
groupId
=
""
,
this
.
form
.
interfaceId
=
""
;
var
a
=
{
type
:
0
,
id
:
this
.
form
.
projectId
};
Object
(
l
.
a
)(
"/gateway-manage/plugin/interface/tree"
,
a
).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?
t
.
data
.
result
?
e
.
groupList
=
t
.
data
.
result
:
e
.
groupList
=
[]:
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
t
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
getApiList
:
function
(){
var
e
=
this
,
t
=
this
;
this
.
form
.
interfaceId
=
""
;
var
a
=
{
type
:
1
,
id
:
this
.
form
.
groupId
};
Object
(
l
.
a
)(
"/gateway-manage/plugin/interface/tree"
,
a
).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?
t
.
data
.
result
?
e
.
apiList
=
t
.
data
.
result
:
e
.
apiList
=
[]:
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
t
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
submitForm
:
function
(
e
){
var
t
=
this
,
a
=
this
;
this
.
$refs
[
e
].
validate
(
function
(
e
){
if
(
!
e
)
return
!
1
;
0
===
t
.
form
.
rangeType
?(
t
.
form
.
projectName
=
t
.
projectList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
projectId
}).
name
,
t
.
form
.
ruleContent
=
t
.
form
.
projectName
,
t
.
form
.
rangeInfo
=
t
.
form
.
projectId
):
1
===
t
.
form
.
rangeType
?(
t
.
form
.
projectName
=
t
.
projectList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
projectId
}).
name
,
t
.
form
.
groupName
=
t
.
groupList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
groupId
}).
name
,
t
.
form
.
ruleContent
=
t
.
form
.
projectName
+
"-"
+
t
.
form
.
groupName
,
t
.
form
.
rangeInfo
=
t
.
form
.
groupId
):
2
===
t
.
form
.
rangeType
&&
(
t
.
form
.
projectName
=
t
.
projectList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
projectId
}).
name
,
t
.
form
.
groupName
=
t
.
groupList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
groupId
}).
name
,
t
.
form
.
interfaceName
=
t
.
apiList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
interfaceId
}).
name
,
t
.
form
.
ruleContent
=
t
.
form
.
projectName
+
"-"
+
t
.
form
.
groupName
+
"-"
+
t
.
form
.
interfaceName
,
t
.
form
.
rangeInfo
=
t
.
form
.
interfaceId
);
var
r
=
{
sceneCode
:
t
.
sceneCode
,
rangeType
:
t
.
form
.
rangeType
,
rangeInfo
:
t
.
form
.
rangeInfo
,
ruleContent
:
t
.
form
.
ruleContent
,
grade
:
t
.
form
.
grade
,
count
:
t
.
form
.
count
,
timeWindow
:
t
.
form
.
timeWindow
,
enableFlag
:
t
.
form
.
enableFlag
?
1
:
0
};
t
.
degradeId
&&
(
r
.
degradeId
=
t
.
degradeId
),
Object
(
l
.
a
)(
"/gateway-manage/rule/degrade/save"
,
r
).
then
(
function
(
e
){
"0000"
==
e
.
data
.
code
?(
t
.
dialogVisible
=!
1
,
t
.
$emit
(
"cancelAddFlus"
),
t
.
$emit
(
"getList"
)):
t
.
$message
.
error
(
e
.
data
.
message
)}).
catch
(
function
(
e
){
a
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})})},
close
:
function
(
e
){
this
.
$refs
[
e
].
resetFields
(),
this
.
$emit
(
"cancelAddFlus"
)}}},
I
=
{
render
:
function
(){
var
e
=
this
,
t
=
e
.
$createElement
,
a
=
e
.
_self
.
_c
||
t
;
return
a
(
"el-dialog"
,{
attrs
:{
title
:
e
.
degradeId
?
"编辑熔断规则"
:
"新建熔断规则"
,
visible
:
e
.
dialogVisible
,
width
:
"400px"
},
on
:{
"update:visible"
:
function
(
t
){
e
.
dialogVisible
=
t
},
close
:
function
(
t
){
return
e
.
close
(
"form"
)}}},[
a
(
"div"
,{
staticClass
:
"dialog-body"
},[
a
(
"el-form"
,{
ref
:
"form"
,
staticClass
:
"demo-ruleForm"
,
attrs
:{
model
:
e
.
form
,
rules
:
e
.
rule
,
"label-width"
:
"100px"
,
"label-position"
:
"right"
}},[
a
(
"el-form-item"
,{
attrs
:{
label
:
"熔断范围"
,
prop
:
"rangeType"
}},[[
a
(
"el-radio"
,{
attrs
:{
label
:
0
},
model
:{
value
:
e
.
form
.
rangeType
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"rangeType"
,
t
)},
expression
:
"form.rangeType"
}},[
e
.
_v
(
"项目"
)]),
e
.
_v
(
" "
),
a
(
"el-radio"
,{
attrs
:{
label
:
1
},
model
:{
value
:
e
.
form
.
rangeType
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"rangeType"
,
t
)},
expression
:
"form.rangeType"
}},[
e
.
_v
(
"分组"
)]),
e
.
_v
(
" "
),
a
(
"el-radio"
,{
attrs
:{
label
:
2
},
model
:{
value
:
e
.
form
.
rangeType
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"rangeType"
,
t
)},
expression
:
"form.rangeType"
}},[
e
.
_v
(
"接口"
)])]],
2
),
e
.
_v
(
" "
),
a
(
"el-form-item"
,{
attrs
:{
label
:
"熔断内容"
,
prop
:
"projectId"
}},[
a
(
"el-select"
,{
attrs
:{
placeholder
:
"请选择项目"
},
on
:{
change
:
e
.
getGroupList
},
model
:{
value
:
e
.
form
.
projectId
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"projectId"
,
t
)},
expression
:
"form.projectId"
}},
e
.
_l
(
e
.
projectList
,
function
(
e
){
return
a
(
"el-option"
,{
key
:
e
.
id
,
attrs
:{
label
:
e
.
name
,
value
:
e
.
id
}})}),
1
)],
1
),
e
.
_v
(
" "
),
0
!==
e
.
form
.
rangeType
?
a
(
"el-form-item"
,{
attrs
:{
prop
:
"groupId"
}},[
a
(
"el-select"
,{
attrs
:{
placeholder
:
"请选择分组"
,
disabled
:
""
===
e
.
form
.
projectId
},
on
:{
change
:
e
.
getApiList
},
model
:{
value
:
e
.
form
.
groupId
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"groupId"
,
t
)},
expression
:
"form.groupId"
}},
e
.
_l
(
e
.
groupList
,
function
(
e
){
return
a
(
"el-option"
,{
key
:
e
.
id
,
attrs
:{
label
:
e
.
name
,
value
:
e
.
id
}})}),
1
)],
1
):
e
.
_e
(),
e
.
_v
(
" "
),
2
===
e
.
form
.
rangeType
?
a
(
"el-form-item"
,{
attrs
:{
prop
:
"interfaceId"
}},[
a
(
"el-select"
,{
attrs
:{
placeholder
:
"请选择接口"
,
disabled
:
""
===
e
.
form
.
groupId
},
model
:{
value
:
e
.
form
.
interfaceId
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"interfaceId"
,
t
)},
expression
:
"form.interfaceId"
}},
e
.
_l
(
e
.
apiList
,
function
(
e
){
return
a
(
"el-option"
,{
key
:
e
.
id
,
attrs
:{
label
:
e
.
name
,
value
:
e
.
id
}})}),
1
)],
1
):
e
.
_e
(),
e
.
_v
(
" "
),
a
(
"el-form-item"
,{
attrs
:{
label
:
"阈值类型"
,
prop
:
"grade"
}},[[
a
(
"el-radio"
,{
attrs
:{
label
:
1
},
model
:{
value
:
e
.
form
.
grade
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"grade"
,
t
)},
expression
:
"form.grade"
}},[
e
.
_v
(
"异常比例"
)])]],
2
),
e
.
_v
(
" "
),
a
(
"el-form-item"
,{
attrs
:{
label
:
"异常比例"
,
prop
:
"count"
}},[
a
(
"el-input"
,{
staticClass
:
"w-220"
,
attrs
:{
placeholder
:
"请输入异常比例"
},
model
:{
value
:
e
.
form
.
count
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"count"
,
t
)},
expression
:
"form.count"
}})],
1
),
e
.
_v
(
" "
),
a
(
"el-form-item"
,{
attrs
:{
label
:
"时间窗口"
,
prop
:
"timeWindow"
}},[
a
(
"el-input"
,{
staticClass
:
"w-220"
,
attrs
:{
placeholder
:
"请输入时间窗口"
},
model
:{
value
:
e
.
form
.
timeWindow
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"timeWindow"
,
t
)},
expression
:
"form.timeWindow"
}},[
a
(
"template"
,{
slot
:
"append"
},[
e
.
_v
(
"
\
n 秒
\
n "
)])],
2
)],
1
),
e
.
_v
(
" "
),
a
(
"el-form-item"
,{
attrs
:{
label
:
"是否开启"
,
prop
:
"enableFlag"
}},[
a
(
"el-switch"
,{
model
:{
value
:
e
.
form
.
enableFlag
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"enableFlag"
,
t
)},
expression
:
"form.enableFlag"
}})],
1
)],
1
)],
1
),
e
.
_v
(
" "
),
a
(
"div"
,{
staticClass
:
"dialog-footer"
,
attrs
:{
slot
:
"footer"
},
slot
:
"footer"
},[
a
(
"el-button"
,{
on
:{
click
:
function
(
t
){
return
e
.
close
(
"form"
)}}},[
e
.
_v
(
"取消"
)]),
e
.
_v
(
" "
),
a
(
"el-button"
,{
attrs
:{
type
:
"primary"
},
on
:{
click
:
function
(
t
){
return
e
.
submitForm
(
"form"
)}}},[
e
.
_v
(
"确定"
)])],
1
)])},
staticRenderFns
:[]};
var
w
=
a
(
"VU/8"
)(
y
,
I
,
!
1
,
function
(
e
){
a
(
"F6GH"
)},
"data-v-55b9c3d1"
,
null
).
exports
,
L
=
{
props
:{
tableData
:{
type
:
Array
,
default
:
function
(){
return
[]}},
sceneCode
:{
type
:
String
,
default
:
function
(){
return
""
}}},
data
:
function
(){
return
{
showFlusDialog
:
!
1
,
showDialog
:
!
1
,
alarmType
:
2
}},
methods
:{
deleteList
:
function
(
e
){
var
t
=
this
,
a
=
this
,
r
=
{
degradeId
:
e
.
degradeId
};
Object
(
l
.
a
)(
"/gateway-manage/rule/degrade/del"
,
r
).
then
(
function
(
e
){
"0000"
==
e
.
data
.
code
?
t
.
getList
():
t
.
$message
.
error
(
e
.
data
.
message
)}).
catch
(
function
(
e
){
a
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
getList
:
function
(){
this
.
$emit
(
"getList"
)},
edit
:
function
(
e
){
this
.
degradeId
=
e
.
degradeId
,
this
.
showFlusDialog
=!
0
},
cancelAddFlus
:
function
(){
this
.
showFlusDialog
=!
1
},
changeFlag
:
function
(
e
){
var
t
=
this
,
a
=
this
,
r
=
{
enableFlag
:
e
.
enableFlag
?
1
:
0
,
degradeId
:
e
.
degradeId
};
Object
(
l
.
a
)(
"/gateway-manage/rule/degrade/enable"
,
r
).
then
(
function
(
a
){
"0000"
==
a
.
data
.
code
?
t
.
$emit
(
"getList"
):(
e
.
enableFlag
=!
e
.
enableFlag
,
t
.
$message
.
error
(
a
.
data
.
message
))}).
catch
(
function
(
e
){
a
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
seeLog
:
function
(
e
){
this
.
ruleId
=
e
.
degradeId
,
this
.
showDialog
=!
0
},
cancelLog
:
function
(){
this
.
showDialog
=!
1
}},
components
:{
newSet
:
w
,
ahshLog
:
p
}},
C
=
{
render
:
function
(){
var
e
=
this
,
t
=
e
.
$createElement
,
a
=
e
.
_self
.
_c
||
t
;
return
a
(
"div"
,{
staticStyle
:{
"margin-top"
:
"20px"
}},[
a
(
"div"
,{
staticClass
:
"table-content"
},[
a
(
"el-table"
,{
directives
:[{
name
:
"loading"
,
rawName
:
"v-loading"
,
value
:
e
.
loading
,
expression
:
"loading"
}],
staticStyle
:{
width
:
"100%"
},
attrs
:{
data
:
e
.
tableData
,
"tooltip-effect"
:
"dark"
,
height
:
e
.
tableHeight
}},[
a
(
"el-table-column"
,{
attrs
:{
label
:
"熔断ID"
,
prop
:
"ruleCode"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
a
(
"span"
,[
e
.
_v
(
e
.
_s
(
t
.
row
.
ruleCode
))]),
e
.
_v
(
" "
),
1
===
t
.
row
.
editeFlag
?
a
(
"span"
,{
staticClass
:
"sign-design"
},[
e
.
_v
(
"未发布"
)]):
e
.
_e
()]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"rangeType"
,
label
:
"熔断范围"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
0
===
t
.
row
.
rangeType
?
a
(
"p"
,[
e
.
_v
(
"项目"
)]):
e
.
_e
(),
e
.
_v
(
" "
),
1
===
t
.
row
.
rangeType
?
a
(
"p"
,[
e
.
_v
(
"分组"
)]):
e
.
_e
(),
e
.
_v
(
" "
),
2
===
t
.
row
.
rangeType
?
a
(
"p"
,[
e
.
_v
(
"接口"
)]):
e
.
_e
(),
e
.
_v
(
" "
),
3
===
t
.
row
.
rangeType
?
a
(
"p"
,[
e
.
_v
(
"其他"
)]):
e
.
_e
()]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"ruleContent"
,
label
:
"熔断内容"
}}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"grade"
,
label
:
"阈值类型"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
1
===
t
.
row
.
grade
?
a
(
"p"
,[
e
.
_v
(
"异常比例"
)]):
e
.
_e
()]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"count"
,
label
:
"阈值"
}}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"timeWindow"
,
label
:
"时间窗口"
}}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"enableFlag"
,
label
:
"开启状态"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
a
(
"el-switch"
,{
on
:{
change
:
function
(
a
){
return
e
.
changeFlag
(
t
.
row
)}},
model
:{
value
:
t
.
row
.
enableFlag
,
callback
:
function
(
a
){
e
.
$set
(
t
.
row
,
"enableFlag"
,
a
)},
expression
:
"scope.row.enableFlag"
}})]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
label
:
"操作"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
a
(
"el-button"
,{
attrs
:{
type
:
"text"
},
on
:{
click
:
function
(
a
){
return
e
.
edit
(
t
.
row
)}}},[
e
.
_v
(
"编辑"
)]),
e
.
_v
(
" "
),
a
(
"dm-delete"
,{
attrs
:{
tips
:
"确定要删除该数据吗?"
},
on
:{
confirm
:
function
(
a
){
return
e
.
deleteList
(
t
.
row
)}}},[
a
(
"el-button"
,{
attrs
:{
type
:
"text"
}},[
e
.
_v
(
"删除"
)])],
1
),
e
.
_v
(
" "
),
a
(
"el-button"
,{
attrs
:{
type
:
"text"
},
on
:{
click
:
function
(
a
){
return
e
.
seeLog
(
t
.
row
)}}},[
e
.
_v
(
"日志"
)])]}}])})],
1
)],
1
),
e
.
_v
(
" "
),
e
.
showFlusDialog
?
a
(
"newSet"
,{
attrs
:{
sceneCode
:
e
.
sceneCode
,
degradeId
:
e
.
degradeId
},
on
:{
cancelAddFlus
:
e
.
cancelAddFlus
,
getList
:
e
.
getList
}}):
e
.
_e
(),
e
.
_v
(
" "
),
e
.
showDialog
?
a
(
"ahshLog"
,{
attrs
:{
sceneCode
:
e
.
sceneCode
,
ruleId
:
e
.
ruleId
,
alarmType
:
e
.
alarmType
},
on
:{
cancelLog
:
e
.
cancelLog
}}):
e
.
_e
()],
1
)},
staticRenderFns
:[]};
var
_
=
a
(
"VU/8"
)(
L
,
C
,
!
1
,
function
(
e
){
a
(
"RV9G"
)},
"data-v-5d6ec933"
,
null
).
exports
,
F
=
{
props
:{
alarmType
:{
type
:
Number
,
default
:
function
(){
return
0
}},
sceneCode
:{
type
:
String
,
default
:
function
(){
return
""
}}},
data
:
function
(){
return
{
dialogVisible
:
!
0
,
tableData
:[],
total
:
0
,
currentPage
:
1
,
pageSize
:
5
}},
created
:
function
(){
this
.
dialogVisible
=!
0
,
this
.
getList
()},
methods
:{
handleCurrentChange
:
function
(
e
){
this
.
currentPage
=
e
,
this
.
getList
()},
getList
:
function
(){
var
e
=
this
,
t
=
{
sceneCode
:
this
.
sceneCode
,
alarmType
:
this
.
alarmType
,
currentPage
:
this
.
currentPage
,
pageSize
:
this
.
pageSize
},
a
=
this
;
Object
(
l
.
a
)(
"/gateway-manage/rule/alarm/log"
,
t
).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?
t
.
data
.
result
.
result
.
length
?(
e
.
tableData
=
t
.
data
.
result
.
result
,
e
.
total
=
t
.
data
.
result
.
totalCount
):(
e
.
tableData
=
[],
e
.
total
=
0
):
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
a
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
close
:
function
(){
this
.
dialogVisible
=!
1
,
this
.
$emit
(
"cancelLog"
)}}},
j
=
{
render
:
function
(){
var
e
=
this
,
t
=
e
.
$createElement
,
a
=
e
.
_self
.
_c
||
t
;
return
a
(
"el-dialog"
,{
attrs
:{
title
:
"日志"
,
visible
:
e
.
dialogVisible
,
width
:
"600px"
},
on
:{
"update:visible"
:
function
(
t
){
e
.
dialogVisible
=
t
},
close
:
e
.
close
}},[
a
(
"div"
,{
staticClass
:
"dialog-body"
},[
a
(
"el-table"
,{
staticClass
:
"dialog-table"
,
staticStyle
:{
width
:
"100%"
},
attrs
:{
data
:
e
.
tableData
}},[
a
(
"el-table-column"
,{
attrs
:{
prop
:
"enableFlag"
,
label
:
"告警类型"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
a
(
"el-switch"
,{
on
:{
change
:
function
(
a
){
return
e
.
changeFlag
(
t
.
row
)}},
model
:{
value
:
t
.
row
.
enableFlag
,
callback
:
function
(
a
){
e
.
$set
(
t
.
row
,
"enableFlag"
,
a
)},
expression
:
"scope.row.enableFlag"
}})]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"enableFlag"
,
label
:
"告警内容"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
a
(
"el-switch"
,{
on
:{
change
:
function
(
a
){
return
e
.
changeFlag
(
t
.
row
)}},
model
:{
value
:
t
.
row
.
enableFlag
,
callback
:
function
(
a
){
e
.
$set
(
t
.
row
,
"enableFlag"
,
a
)},
expression
:
"scope.row.enableFlag"
}})]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"updateTime"
,
label
:
"发生时间"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
a
(
"div"
,{
staticClass
:
"color-606266 line-18"
},[
e
.
_v
(
e
.
_s
(
e
.
_f
(
"timeStampToYmd"
)(
t
.
row
.
updateTime
)))]),
e
.
_v
(
" "
),
a
(
"div"
,{
staticClass
:
"color-606266 line-18"
},[
e
.
_v
(
e
.
_s
(
e
.
_f
(
"timeStampToHms"
)(
t
.
row
.
updateTime
)))])]}}])})],
1
),
e
.
_v
(
" "
),
e
.
total
>
0
?
a
(
"div"
,{
staticClass
:
"page-content"
},[
a
(
"el-pagination"
,{
attrs
:{
small
:
""
,
"current-page"
:
e
.
currentPage
,
"page-size"
:
e
.
pageSize
,
layout
:
"prev, pager, next"
,
total
:
e
.
total
},
on
:{
"current-change"
:
e
.
handleCurrentChange
,
"update:currentPage"
:
function
(
t
){
e
.
currentPage
=
t
},
"update:current-page"
:
function
(
t
){
e
.
currentPage
=
t
}}})],
1
):
e
.
_e
()],
1
)])},
staticRenderFns
:[]};
var
A
=
a
(
"VU/8"
)(
F
,
j
,
!
1
,
function
(
e
){
a
(
"PbPA"
)},
"data-v-238c15d7"
,
null
).
exports
,
D
=
{
props
:{
tableData
:{
type
:
Array
,
default
:
function
(){
return
[]}},
sceneCode
:{
type
:
String
,
default
:
function
(){
return
""
}}},
data
:
function
(){
return
{
showDialog
:
!
1
,
refash
:
!
1
}},
methods
:{
handleChange
:
function
(
e
){
this
.
$emit
(
"changeFlag"
,
e
)},
seeLog
:
function
(
e
){
this
.
ruleId
=
e
.
sceneCode
,
this
.
alarmType
=
e
.
alarmType
,
this
.
showDialog
=!
0
},
cancelLog
:
function
(){
this
.
showDialog
=!
1
},
editItemm
:
function
(
e
){
var
t
=
this
,
a
=
this
;
if
(
this
.
refash
=!
this
.
refash
,
e
.
editStatus
=!
e
.
editStatus
,
!
e
.
editStatus
){
var
r
=
{
alarmType
:
e
.
alarmType
,
alarmInfo
:
e
.
alarmInfo
,
sceneCode
:
this
.
sceneCode
};
Object
(
l
.
a
)(
"/gateway-manage/rule/alarm/edit"
,
r
).
then
(
function
(
a
){
"0000"
==
a
.
data
.
code
?(
t
.
$emit
(
"getList"
),
t
.
$message
.
success
(
"保存成功"
)):(
e
.
editStatus
=!
e
.
editStatus
,
t
.
$message
.
error
(
a
.
data
.
message
))}).
catch
(
function
(
e
){
a
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})}}},
components
:{
alarmLog
:
A
}},
S
=
{
render
:
function
(){
var
e
=
this
,
t
=
e
.
$createElement
,
r
=
e
.
_self
.
_c
||
t
;
return
r
(
"div"
,{
staticStyle
:{
"margin-top"
:
"20px"
}},[
r
(
"div"
,{
staticClass
:
"list-content"
},
e
.
_l
(
e
.
tableData
,
function
(
t
,
n
){
return
r
(
"div"
,{
key
:
n
,
staticClass
:
"list-item"
},[
r
(
"div"
,{
staticClass
:
"item-top"
},[
1
===
t
.
alarmType
?
r
(
"img"
,{
attrs
:{
src
:
a
(
"vgET"
),
alt
:
""
}}):
e
.
_e
(),
e
.
_v
(
" "
),
2
===
t
.
alarmType
?
r
(
"img"
,{
attrs
:{
src
:
a
(
"8PC5"
),
alt
:
""
}}):
e
.
_e
(),
e
.
_v
(
" "
),
r
(
"div"
,{
staticClass
:
"item-info"
},[
r
(
"p"
,{
staticClass
:
"info-type"
},[
e
.
_v
(
e
.
_s
(
1
===
t
.
alarmType
?
"流控告警"
:
"熔断告警"
))]),
e
.
_v
(
" "
),
r
(
"p"
,{
staticClass
:
"name"
},[
e
.
_v
(
"Webhook通知地址"
)]),
e
.
_v
(
" "
),
r
(
"div"
,{
staticClass
:
"address"
},[
t
.
editStatus
?
r
(
"el-input"
,{
staticStyle
:{
width
:
"368px"
},
attrs
:{
type
:
"textarea"
,
placeholder
:
"请输入内容"
},
model
:{
value
:
t
.
alarmInfo
,
callback
:
function
(
a
){
e
.
$set
(
t
,
"alarmInfo"
,
a
)},
expression
:
"item.alarmInfo"
}}):
r
(
"p"
,[
e
.
_v
(
e
.
_s
(
t
.
alarmInfo
))])],
1
)])]),
e
.
_v
(
" "
),
r
(
"div"
,{
staticClass
:
"item-bottom"
},[
r
(
"div"
,[
r
(
"p"
,{
on
:{
click
:
function
(
a
){
return
e
.
editItemm
(
t
)}}},[
e
.
_v
(
e
.
_s
(
t
.
editStatus
?
"保存"
:
"编辑"
)
+
"Webhook通知地址"
)]),
e
.
_v
(
" "
),
r
(
"p"
,{
on
:{
click
:
function
(
a
){
return
e
.
seeLog
(
t
)}}},[
e
.
_v
(
"日志"
)])]),
e
.
_v
(
" "
),
r
(
"span"
,{
staticStyle
:{
display
:
"none"
}},[
e
.
_v
(
e
.
_s
(
e
.
refash
))]),
e
.
_v
(
" "
),
r
(
"el-switch"
,{
on
:{
change
:
function
(
a
){
return
e
.
handleChange
(
t
)}},
model
:{
value
:
t
.
enableFlag
,
callback
:
function
(
a
){
e
.
$set
(
t
,
"enableFlag"
,
a
)},
expression
:
"item.enableFlag"
}})],
1
)])}),
0
),
e
.
_v
(
" "
),
e
.
showDialog
?
r
(
"alarmLog"
,{
attrs
:{
alarmType
:
e
.
alarmType
,
sceneCode
:
e
.
sceneCode
},
on
:{
cancelLog
:
e
.
cancelLog
}}):
e
.
_e
()],
1
)},
staticRenderFns
:[]};
var
T
=
a
(
"VU/8"
)(
D
,
S
,
!
1
,
function
(
e
){
a
(
"o4sL"
)},
"data-v-2b8f96fb"
,
null
).
exports
,
k
=
{
name
:
"envManage"
,
components
:{
navBread
:
s
.
a
,
selectEnv
:
c
.
a
,
fluidList
:
b
,
fusingList
:
_
,
warnSet
:
T
,
newRule
:
g
,
newSet
:
w
},
data
:
function
(){
return
{
navPath
:[{
name
:
"插件管理"
,
path
:
"/pluginManage"
},{
name
:
"AHSH"
,
path
:
"/pluginManage"
}],
activeName
:
"first"
,
search
:
""
,
showdialog
:
!
1
,
pluginId
:
""
,
sceneCode
:
""
,
pluginType
:
0
,
projectList
:[],
projectId
:
""
,
groupList
:[],
groupId
:
""
,
total
:
0
,
currentPage
:
1
,
pageSize
:
20
,
pageSizes
:[
20
,
40
,
60
,
80
],
tableData
:[],
loading
:
!
1
,
showRuleDialog
:
!
1
,
showFlusDialog
:
!
1
,
publishNum
:
0
}},
created
:
function
(){
this
.
pluginId
=
this
.
$route
.
query
.
pluginId
,
this
.
sceneCode
=
this
.
$route
.
query
.
sceneCode
,
this
.
getProjectList
(),
this
.
getList
(),
this
.
getUpdateStatus
()},
methods
:{
handleClick
:
function
(
e
,
t
){
this
.
getList
(),
this
.
getUpdateStatus
()},
goEnvList
:
function
(){
this
.
showdialog
=!
0
,
this
.
pluginId
=
this
.
pluginId
},
closeDialog
:
function
(){
this
.
showdialog
=!
1
},
handleSizeChange
:
function
(
e
){
this
.
pageSize
=
e
,
this
.
getList
()},
handleCurrentChange
:
function
(
e
){
this
.
currentPage
=
e
,
this
.
getList
()},
getChange
:
function
(){
this
.
groupId
=
""
,
this
.
currentPage
=
1
,
this
.
getGroupList
(),
this
.
getList
()},
getSearchList
:
function
(){
"first"
!==
this
.
activeName
&&
"second"
!==
this
.
activeName
||
(
this
.
currentPage
=
1
,
this
.
getGroupList
(),
this
.
getList
())},
getList
:
function
(){
var
e
=
this
,
t
=
""
,
a
=
{};
"first"
===
this
.
activeName
?(
t
=
"/gateway-manage/rule/ratelimiter/list"
,
a
=
{
projectId
:
this
.
projectId
?
this
.
projectId
:
null
,
groupId
:
this
.
groupId
?
this
.
groupId
:
null
,
search
:
this
.
search
?
this
.
search
:
null
,
sceneCode
:
this
.
sceneCode
,
currentPage
:
this
.
currentPage
,
pageSize
:
this
.
pageSize
}):
"second"
===
this
.
activeName
?(
t
=
"/gateway-manage/rule/degrade/list"
,
a
=
{
projectId
:
this
.
projectId
?
this
.
projectId
:
null
,
groupId
:
this
.
groupId
?
this
.
groupId
:
null
,
search
:
this
.
search
?
this
.
search
:
null
,
sceneCode
:
this
.
sceneCode
,
currentPage
:
this
.
currentPage
,
pageSize
:
this
.
pageSize
}):
"third"
===
this
.
activeName
&&
(
t
=
"/gateway-manage/rule/alarm/list"
,
a
=
{
sceneCode
:
this
.
sceneCode
}),
this
.
tableData
=
[],
this
.
loading
=!
0
;
var
r
=
this
;
Object
(
l
.
a
)(
t
,
a
).
then
(
function
(
t
){
if
(
"0000"
==
t
.
data
.
code
){
if
(
"first"
===
e
.
activeName
){
t
.
data
.
result
.
result
?(
e
.
tableData
=
t
.
data
.
result
.
result
,
e
.
total
=
t
.
data
.
result
.
totalCount
):(
e
.
total
=
0
,
e
.
tableData
=
[]);
var
a
=!
0
,
r
=!
1
,
n
=
void
0
;
try
{
for
(
var
o
,
s
=
i
()(
e
.
tableData
);
!
(
a
=
(
o
=
s
.
next
()).
done
);
a
=!
0
){
var
l
=
o
.
value
;
l
.
enableFlag
=
1
===
l
.
enableFlag
}}
catch
(
e
){
r
=!
0
,
n
=
e
}
finally
{
try
{
!
a
&&
s
.
return
&&
s
.
return
()}
finally
{
if
(
r
)
throw
n
}}}
else
if
(
"second"
===
e
.
activeName
){
t
.
data
.
result
.
result
?(
e
.
tableData
=
t
.
data
.
result
.
result
,
e
.
total
=
t
.
data
.
result
.
totalCount
):(
e
.
total
=
0
,
e
.
tableData
=
[]);
var
c
=!
0
,
d
=!
1
,
u
=
void
0
;
try
{
for
(
var
g
,
m
=
i
()(
e
.
tableData
);
!
(
c
=
(
g
=
m
.
next
()).
done
);
c
=!
0
){
var
f
=
g
.
value
;
f
.
enableFlag
=
1
===
f
.
enableFlag
}}
catch
(
e
){
d
=!
0
,
u
=
e
}
finally
{
try
{
!
c
&&
m
.
return
&&
m
.
return
()}
finally
{
if
(
d
)
throw
u
}}}
else
if
(
"third"
===
e
.
activeName
){
t
.
data
.
result
?
e
.
tableData
=
t
.
data
.
result
:
e
.
tableData
=
[];
var
p
=!
0
,
h
=!
1
,
v
=
void
0
;
try
{
for
(
var
b
,
y
=
i
()(
e
.
tableData
);
!
(
p
=
(
b
=
y
.
next
()).
done
);
p
=!
0
){
var
I
=
b
.
value
;
I
.
enableFlag
=
1
===
I
.
enableFlag
,
I
.
editStatus
=!
1
}}
catch
(
e
){
h
=!
0
,
v
=
e
}
finally
{
try
{
!
p
&&
y
.
return
&&
y
.
return
()}
finally
{
if
(
h
)
throw
v
}}}
e
.
loading
=!
1
}
else
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
r
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
changeFlag
:
function
(
e
){
var
t
=
this
,
a
=
this
,
r
=
{
alarmType
:
e
.
alarmType
,
enableFlag
:
e
.
enableFlag
?
1
:
0
,
sceneCode
:
this
.
sceneCode
};
Object
(
l
.
a
)(
"/gateway-manage/rule/alarm/enable"
,
r
).
then
(
function
(
a
){
"0000"
==
a
.
data
.
code
?
t
.
getList
():(
e
.
enableFlag
=!
e
.
enableFlag
,
t
.
$message
.
error
(
a
.
data
.
message
))}).
catch
(
function
(
e
){
a
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
getProjectList
:
function
(){
var
e
=
this
,
t
=
this
;
Object
(
l
.
a
)(
"/gateway-manage/plugin/interface/tree"
,{}).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?
t
.
data
.
result
?
e
.
projectList
=
t
.
data
.
result
:
e
.
projectList
=
[]:
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
t
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
getGroupList
:
function
(){
var
e
=
this
,
t
=
this
,
a
=
{
type
:
0
,
id
:
this
.
projectId
};
Object
(
l
.
a
)(
"/gateway-manage/plugin/interface/tree"
,
a
).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?
t
.
data
.
result
?
e
.
groupList
=
t
.
data
.
result
:
e
.
groupList
=
[]:
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
t
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
addFluid
:
function
(){
this
.
showRuleDialog
=!
0
},
cancelAdd
:
function
(){
this
.
showRuleDialog
=!
1
},
addFusing
:
function
(){
this
.
showFlusDialog
=!
0
},
cancelAddFlus
:
function
(){
this
.
showFlusDialog
=!
1
},
publish
:
function
(){
var
e
=
this
,
t
=
{
sceneCode
:
this
.
sceneCode
},
a
=
""
;
"first"
===
this
.
activeName
?
a
=
"/gateway-manage/rule/ratelimiter/publish"
:
"second"
===
this
.
activeName
&&
(
a
=
"/gateway-manage/rule/degrade/publish"
);
var
r
=
this
;
this
.
$confirm
(
"确定要发布吗?"
,
"提示"
,{
confirmButtonText
:
"确定"
,
cancelButtonText
:
"取消"
,
type
:
"warning"
}).
then
(
function
(){
Object
(
l
.
a
)(
a
,
t
).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?(
e
.
getList
(),
e
.
getUpdateStatus
()):
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
r
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})}).
catch
(
function
(){
e
.
$message
({
type
:
"info"
,
message
:
"已取消发布"
})})},
getUpdateStatus
:
function
(
e
){
var
t
=
this
,
a
=
{
sceneCode
:
e
||
this
.
sceneCode
},
r
=
""
;
r
=
"first"
===
this
.
activeName
?
"/gateway-manage/rule/ratelimiter/has/edit"
:
"/gateway-manage/rule/degrade/has/edit"
,
Object
(
l
.
a
)(
r
,
a
).
then
(
function
(
e
){
"0000"
==
e
.
data
.
code
?
t
.
publishNum
=
e
.
data
.
result
:
t
.
$message
.
error
(
e
.
data
.
message
)})}},
watch
:
n
()({
$route
:{
handler
:
function
(
e
,
t
){},
deep
:
!
0
}},
"$route"
,
function
(
e
,
t
){
this
.
pluginId
=
this
.
$route
.
query
.
pluginId
,
this
.
sceneCode
=
this
.
$route
.
query
.
sceneCode
,
this
.
getList
(),
this
.
getUpdateStatus
()})},
N
=
{
render
:
function
(){
var
e
=
this
,
t
=
e
.
$createElement
,
a
=
e
.
_self
.
_c
||
t
;
return
a
(
"div"
,{
staticClass
:
"api-body-content border-box"
},[
a
(
"div"
,{
staticClass
:
"common-nav"
},[
a
(
"nav-bread"
,{
attrs
:{
navPath
:
e
.
navPath
}}),
e
.
_v
(
" "
),
a
(
"div"
,{
staticClass
:
"change-env"
,
on
:{
click
:
e
.
goEnvList
}},[
a
(
"span"
,[
e
.
_v
(
"切换环境"
)]),
a
(
"i"
,{
staticClass
:
"iconfont iconicon-qihuan"
,
on
:{
click
:
function
(
t
){
return
e
.
goEnvList
(
e
.
item
)}}})])],
1
),
e
.
_v
(
" "
),
a
(
"div"
,{
staticClass
:
"api-body-main common-body-main border-box"
},[
a
(
"div"
,{
staticClass
:
"api-main-content border-box"
},[
a
(
"div"
,{
staticClass
:
"env-tab-wrap"
},[
a
(
"el-tabs"
,{
on
:{
"tab-click"
:
e
.
handleClick
},
model
:{
value
:
e
.
activeName
,
callback
:
function
(
t
){
e
.
activeName
=
t
},
expression
:
"activeName"
}},[
"third"
!==
e
.
activeName
?
a
(
"div"
,{
staticClass
:
"search-box"
},[
a
(
"div"
,{
staticClass
:
"left"
},[
a
(
"el-input"
,{
staticClass
:
"w-320"
,
attrs
:{
placeholder
:
"first"
===
e
.
activeName
?
"请输入接口名称/流控ID"
:
"请输入接口名称/熔断ID"
,
"prefix-icon"
:
"el-icon-search"
,
clearable
:
""
},
on
:{
clear
:
function
(
t
){
return
e
.
getSearchList
()}},
nativeOn
:{
keyup
:
function
(
t
){
return
!
t
.
type
.
indexOf
(
"key"
)
&&
e
.
_k
(
t
.
keyCode
,
"enter"
,
13
,
t
.
key
,
"Enter"
)?
null
:
e
.
getSearchList
()}},
model
:{
value
:
e
.
search
,
callback
:
function
(
t
){
e
.
search
=
t
},
expression
:
"search"
}}),
e
.
_v
(
" "
),
a
(
"el-select"
,{
staticClass
:
"w-140 marginLeft10"
,
staticStyle
:{
display
:
"inline-block"
},
attrs
:{
placeholder
:
"请选择项目"
,
size
:
"small"
,
clearable
:
""
},
on
:{
change
:
e
.
getChange
},
model
:{
value
:
e
.
projectId
,
callback
:
function
(
t
){
e
.
projectId
=
t
},
expression
:
"projectId"
}},
e
.
_l
(
e
.
projectList
,
function
(
e
){
return
a
(
"el-option"
,{
key
:
e
.
id
,
attrs
:{
label
:
e
.
name
,
value
:
e
.
id
}})}),
1
),
e
.
_v
(
" "
),
a
(
"el-select"
,{
staticClass
:
"w-140 marginLeft10"
,
staticStyle
:{
display
:
"inline-block"
},
attrs
:{
placeholder
:
"请选择分组"
,
size
:
"small"
,
clearable
:
""
,
disabled
:
""
===
e
.
projectId
},
on
:{
change
:
e
.
getSearchList
},
model
:{
value
:
e
.
groupId
,
callback
:
function
(
t
){
e
.
groupId
=
t
},
expression
:
"groupId"
}},
e
.
_l
(
e
.
groupList
,
function
(
e
){
return
a
(
"el-option"
,{
key
:
e
.
id
,
attrs
:{
label
:
e
.
name
,
value
:
e
.
id
}})}),
1
)],
1
),
e
.
_v
(
" "
),
a
(
"div"
,[
"first"
===
e
.
activeName
?
a
(
"el-button"
,{
attrs
:{
type
:
"primary"
},
on
:{
click
:
e
.
addFluid
}},[
e
.
_v
(
"新建流控规则"
)]):
e
.
_e
(),
e
.
_v
(
" "
),
"second"
===
e
.
activeName
?
a
(
"el-button"
,{
attrs
:{
type
:
"primary"
},
on
:{
click
:
e
.
addFusing
}},[
e
.
_v
(
"新建熔断规则"
)]):
e
.
_e
(),
e
.
_v
(
" "
),
a
(
"el-button"
,{
attrs
:{
type
:
"primary"
,
disabled
:
e
.
publishNum
<=
0
},
on
:{
click
:
e
.
publish
}},[
e
.
_v
(
e
.
_s
(
e
.
publishNum
>
0
?
"待发布("
+
e
.
publishNum
+
")"
:
"发布"
))])],
1
)]):
e
.
_e
(),
e
.
_v
(
" "
),
a
(
"el-tab-pane"
,{
attrs
:{
label
:
"流控规则"
,
name
:
"first"
}},[
"first"
===
e
.
activeName
?
a
(
"fluidList"
,{
directives
:[{
name
:
"loading"
,
rawName
:
"v-loading"
,
value
:
e
.
loading
,
expression
:
"loading"
}],
attrs
:{
tableData
:
e
.
tableData
,
sceneCode
:
e
.
sceneCode
},
on
:{
getList
:
e
.
getList
}}):
e
.
_e
()],
1
),
e
.
_v
(
" "
),
a
(
"el-tab-pane"
,{
attrs
:{
label
:
"熔断规则"
,
name
:
"second"
}},[
"second"
===
e
.
activeName
?
a
(
"fusingList"
,{
directives
:[{
name
:
"loading"
,
rawName
:
"v-loading"
,
value
:
e
.
loading
,
expression
:
"loading"
}],
attrs
:{
tableData
:
e
.
tableData
,
sceneCode
:
e
.
sceneCode
},
on
:{
getList
:
e
.
getList
}}):
e
.
_e
()],
1
),
e
.
_v
(
" "
),
a
(
"el-tab-pane"
,{
attrs
:{
label
:
"告警配置"
,
name
:
"third"
}},[
"third"
===
e
.
activeName
?
a
(
"warnSet"
,{
directives
:[{
name
:
"loading"
,
rawName
:
"v-loading"
,
value
:
e
.
loading
,
expression
:
"loading"
}],
attrs
:{
tableData
:
e
.
tableData
,
sceneCode
:
e
.
sceneCode
},
on
:{
getList
:
e
.
getList
,
changeFlag
:
e
.
changeFlag
}}):
e
.
_e
()],
1
)],
1
),
e
.
_v
(
" "
),
0
===
e
.
total
||
"first"
!==
e
.
activeName
&&
"second"
!==
e
.
activeName
?
e
.
_e
():
a
(
"div"
,{
staticStyle
:{
"text-align"
:
"right"
,
"margin-top"
:
"20px"
}},[
a
(
"el-pagination"
,{
attrs
:{
background
:
""
,
"current-page"
:
e
.
currentPage
,
"page-sizes"
:
e
.
pageSizes
,
"page-size"
:
e
.
pageSize
,
layout
:
"total, sizes, prev, pager, next"
,
total
:
e
.
total
},
on
:{
"size-change"
:
e
.
handleSizeChange
,
"current-change"
:
e
.
handleCurrentChange
}})],
1
)],
1
)])]),
e
.
_v
(
" "
),
e
.
showdialog
?
a
(
"selectEnv"
,{
attrs
:{
pluginId
:
e
.
pluginId
,
pluginType
:
e
.
pluginType
},
on
:{
closeDialog
:
e
.
closeDialog
}}):
e
.
_e
(),
e
.
_v
(
" "
),
e
.
showRuleDialog
?
a
(
"newRule"
,{
attrs
:{
sceneCode
:
e
.
sceneCode
},
on
:{
cancelAdd
:
e
.
cancelAdd
,
getList
:
e
.
getList
}}):
e
.
_e
(),
e
.
_v
(
" "
),
e
.
showFlusDialog
?
a
(
"newSet"
,{
attrs
:{
sceneCode
:
e
.
sceneCode
},
on
:{
cancelAddFlus
:
e
.
cancelAddFlus
,
getList
:
e
.
getList
}}):
e
.
_e
()],
1
)},
staticRenderFns
:[]};
var
x
=
a
(
"VU/8"
)(
k
,
N
,
!
1
,
function
(
e
){
a
(
"sAf0"
)},
"data-v-c24c625a"
,
null
);
t
.
default
=
x
.
exports
},
JQyN
:
function
(
e
,
t
){},
PbPA
:
function
(
e
,
t
){},
QSX3
:
function
(
e
,
t
){},
RV9G
:
function
(
e
,
t
){},
o4sL
:
function
(
e
,
t
){},
sAf0
:
function
(
e
,
t
){},
vgET
:
function
(
e
,
t
){
e
.
exports
=
"data:image/png;base64,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"
}});
\ No newline at end of file
webpackJsonp
([
4
],{
"0amw"
:
function
(
e
,
t
){},
"8PC5"
:
function
(
e
,
t
){
e
.
exports
=
"data:image/png;base64,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"
},
F6GH
:
function
(
e
,
t
){},
"JN/y"
:
function
(
e
,
t
,
a
){
"use strict"
;
Object
.
defineProperty
(
t
,
"__esModule"
,{
value
:
!
0
});
var
r
=
a
(
"bOdI"
),
n
=
a
.
n
(
r
),
o
=
a
(
"BO1k"
),
s
=
a
.
n
(
o
),
i
=
a
(
"319J"
),
l
=
a
(
"P9l9"
),
c
=
a
(
"PEkr"
),
d
=
{
props
:{
ruleId
:{
type
:
String
,
default
:
function
(){
return
""
}},
sceneCode
:{
type
:
String
,
default
:
function
(){
return
""
}}},
data
:
function
(){
return
{
dialogVisible
:
!
0
,
projectList
:[],
groupList
:[],
apiList
:[],
form
:{
rangeType
:
0
,
rangeInfo
:
""
,
projectId
:
""
,
projectName
:
""
,
groupId
:
""
,
groupName
:
""
,
interfaceId
:
""
,
interfaceName
:
""
,
ruleContent
:
""
,
grade
:
1
,
count
:
""
,
strategy
:
0
,
distFlag
:
!
1
,
enableFlag
:
!
1
},
rule
:{
projectId
:[{
required
:
!
0
,
message
:
"请选择项目"
,
trigger
:
"change"
}],
groupId
:[{
required
:
!
0
,
message
:
"请选择分组"
,
trigger
:
"change"
}],
interfaceId
:[{
required
:
!
0
,
message
:
"请选择接口"
,
trigger
:
"change"
}],
count
:[{
required
:
!
0
,
message
:
"请选择阈值"
,
trigger
:
"blur"
},{
validator
:
function
(
e
,
t
,
a
){
/^
(
0
|
\
+
?[
1
-
9
][
0
-
9
]
*
)
$
/
.
test
(
t
)?
a
():
a
(
new
Error
(
"阈值必须输入正整数"
))},
trigger
:
"blur"
}]}}},
created
:
function
(){
this
.
dialogVisible
=!
0
,
this
.
getProjectList
(),
this
.
ruleId
&&
this
.
getInfo
()},
methods
:{
getInfo
:
function
(){
var
e
=
this
,
t
=
this
,
a
=
{
ruleId
:
this
.
ruleId
};
Object
(
l
.
a
)(
"/gateway-manage//rule/ratelimiter/detail"
,
a
).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?(
e
.
form
.
rangeType
=
t
.
data
.
result
.
rangeType
,
0
===
e
.
form
.
rangeType
?
e
.
getGroupList
():
1
===
e
.
form
.
rangeType
?
e
.
getGroupList
():
2
===
e
.
form
.
rangeType
&&
(
e
.
getApiList
(),
e
.
getGroupList
()),
e
.
form
.
projectId
=
t
.
data
.
result
.
projectId
,
e
.
form
.
interfaceId
=
t
.
data
.
result
.
interfaceId
,
e
.
form
.
groupId
=
t
.
data
.
result
.
groupId
,
e
.
form
.
grade
=
t
.
data
.
result
.
grade
,
e
.
form
.
count
=
t
.
data
.
result
.
count
,
e
.
form
.
strategy
=
t
.
data
.
result
.
strategy
,
e
.
form
.
distFlag
=
1
===
t
.
data
.
result
.
distFlag
,
e
.
form
.
enableFlag
=
1
===
t
.
data
.
result
.
enableFlag
):
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
t
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
getProjectList
:
function
(){
var
e
=
this
,
t
=
this
;
Object
(
l
.
a
)(
"/gateway-manage/plugin/interface/tree"
,{}).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?
t
.
data
.
result
?
e
.
projectList
=
t
.
data
.
result
:
e
.
projectList
=
[]:
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
t
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
getGroupList
:
function
(){
var
e
=
this
,
t
=
this
;
this
.
form
.
groupId
=
""
,
this
.
form
.
interfaceId
=
""
;
var
a
=
{
type
:
0
,
id
:
this
.
form
.
projectId
};
Object
(
l
.
a
)(
"/gateway-manage/plugin/interface/tree"
,
a
).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?
t
.
data
.
result
?
e
.
groupList
=
t
.
data
.
result
:
e
.
groupList
=
[]:
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
t
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
getApiList
:
function
(){
var
e
=
this
,
t
=
this
;
this
.
form
.
interfaceId
=
""
;
var
a
=
{
type
:
1
,
id
:
this
.
form
.
groupId
};
Object
(
l
.
a
)(
"/gateway-manage/plugin/interface/tree"
,
a
).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?
t
.
data
.
result
?
e
.
apiList
=
t
.
data
.
result
:
e
.
apiList
=
[]:
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
t
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
submitForm
:
function
(
e
){
var
t
=
this
;
this
.
$refs
[
e
].
validate
(
function
(
e
){
if
(
!
e
)
return
!
1
;
0
===
t
.
form
.
rangeType
?(
t
.
form
.
projectName
=
t
.
projectList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
projectId
}).
name
,
t
.
form
.
ruleContent
=
t
.
form
.
projectName
,
t
.
form
.
rangeInfo
=
t
.
form
.
projectId
):
1
===
t
.
form
.
rangeType
?(
t
.
form
.
projectName
=
t
.
projectList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
projectId
}).
name
,
t
.
form
.
groupName
=
t
.
groupList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
groupId
}).
name
,
t
.
form
.
ruleContent
=
t
.
form
.
projectName
+
"-"
+
t
.
form
.
groupName
,
t
.
form
.
rangeInfo
=
t
.
form
.
groupId
):
2
===
t
.
form
.
rangeType
&&
(
t
.
form
.
projectName
=
t
.
projectList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
projectId
}).
name
,
t
.
form
.
groupName
=
t
.
groupList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
groupId
}).
name
,
t
.
form
.
interfaceName
=
t
.
apiList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
interfaceId
}).
name
,
t
.
form
.
ruleContent
=
t
.
form
.
projectName
+
"-"
+
t
.
form
.
groupName
+
"-"
+
t
.
form
.
interfaceName
,
t
.
form
.
rangeInfo
=
t
.
form
.
interfaceId
);
var
a
=
{
sceneCode
:
t
.
sceneCode
,
rangeType
:
t
.
form
.
rangeType
,
rangeInfo
:
t
.
form
.
rangeInfo
,
ruleContent
:
t
.
form
.
ruleContent
,
grade
:
t
.
form
.
grade
,
count
:
t
.
form
.
count
,
strategy
:
t
.
form
.
strategy
,
distFlag
:
t
.
form
.
distFlag
?
1
:
0
,
enableFlag
:
t
.
form
.
enableFlag
?
1
:
0
};
t
.
ruleId
&&
(
a
.
rateLimiterId
=
t
.
ruleId
),
Object
(
l
.
a
)(
"/gateway-manage//rule/ratelimiter/save"
,
a
).
then
(
function
(
e
){
"0000"
==
e
.
data
.
code
?(
t
.
dialogVisible
=!
1
,
t
.
$emit
(
"getList"
),
t
.
$emit
(
"cancelAdd"
)):
t
.
$message
.
error
(
e
.
data
.
message
)})})},
close
:
function
(
e
){
this
.
$refs
[
e
].
resetFields
(),
this
.
$emit
(
"cancelAdd"
)}}},
u
=
{
render
:
function
(){
var
e
=
this
,
t
=
e
.
$createElement
,
a
=
e
.
_self
.
_c
||
t
;
return
a
(
"el-dialog"
,{
attrs
:{
title
:
e
.
ruleId
?
"编辑流控规则"
:
"新建流控规则"
,
visible
:
e
.
dialogVisible
,
width
:
"400px"
},
on
:{
"update:visible"
:
function
(
t
){
e
.
dialogVisible
=
t
},
close
:
function
(
t
){
return
e
.
close
(
"form"
)}}},[
a
(
"div"
,{
staticClass
:
"dialog-body"
},[
a
(
"el-form"
,{
ref
:
"form"
,
staticClass
:
"demo-ruleForm"
,
attrs
:{
model
:
e
.
form
,
rules
:
e
.
rule
,
"label-width"
:
"100px"
,
"label-position"
:
"right"
}},[
a
(
"el-form-item"
,{
attrs
:{
label
:
"流控范围"
,
prop
:
"rangeType"
}},[[
a
(
"el-radio"
,{
attrs
:{
label
:
0
},
model
:{
value
:
e
.
form
.
rangeType
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"rangeType"
,
t
)},
expression
:
"form.rangeType"
}},[
e
.
_v
(
"项目"
)]),
e
.
_v
(
" "
),
a
(
"el-radio"
,{
attrs
:{
label
:
1
},
model
:{
value
:
e
.
form
.
rangeType
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"rangeType"
,
t
)},
expression
:
"form.rangeType"
}},[
e
.
_v
(
"分组"
)]),
e
.
_v
(
" "
),
a
(
"el-radio"
,{
attrs
:{
label
:
2
},
model
:{
value
:
e
.
form
.
rangeType
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"rangeType"
,
t
)},
expression
:
"form.rangeType"
}},[
e
.
_v
(
"接口"
)])]],
2
),
e
.
_v
(
" "
),
a
(
"el-form-item"
,{
attrs
:{
label
:
"流控内容"
,
prop
:
"projectId"
}},[
a
(
"el-select"
,{
attrs
:{
placeholder
:
"请选择项目"
},
on
:{
change
:
e
.
getGroupList
},
model
:{
value
:
e
.
form
.
projectId
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"projectId"
,
t
)},
expression
:
"form.projectId"
}},
e
.
_l
(
e
.
projectList
,
function
(
e
){
return
a
(
"el-option"
,{
key
:
e
.
id
,
attrs
:{
label
:
e
.
name
,
value
:
e
.
id
}})}),
1
)],
1
),
e
.
_v
(
" "
),
0
!==
e
.
form
.
rangeType
?
a
(
"el-form-item"
,{
attrs
:{
prop
:
"groupId"
}},[
a
(
"el-select"
,{
attrs
:{
placeholder
:
"请选择分组"
,
disabled
:
""
===
e
.
form
.
projectId
},
on
:{
change
:
e
.
getApiList
},
model
:{
value
:
e
.
form
.
groupId
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"groupId"
,
t
)},
expression
:
"form.groupId"
}},
e
.
_l
(
e
.
groupList
,
function
(
e
){
return
a
(
"el-option"
,{
key
:
e
.
id
,
attrs
:{
label
:
e
.
name
,
value
:
e
.
id
}})}),
1
)],
1
):
e
.
_e
(),
e
.
_v
(
" "
),
2
===
e
.
form
.
rangeType
?
a
(
"el-form-item"
,{
attrs
:{
prop
:
"interfaceId"
}},[
a
(
"el-select"
,{
attrs
:{
placeholder
:
"请选择接口"
,
disabled
:
""
===
e
.
form
.
groupId
},
model
:{
value
:
e
.
form
.
interfaceId
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"interfaceId"
,
t
)},
expression
:
"form.interfaceId"
}},
e
.
_l
(
e
.
apiList
,
function
(
e
){
return
a
(
"el-option"
,{
key
:
e
.
id
,
attrs
:{
label
:
e
.
name
,
value
:
e
.
id
}})}),
1
)],
1
):
e
.
_e
(),
e
.
_v
(
" "
),
a
(
"el-form-item"
,{
attrs
:{
label
:
"阈值类型"
,
prop
:
"grade"
}},[[
a
(
"el-radio"
,{
attrs
:{
label
:
1
},
model
:{
value
:
e
.
form
.
grade
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"grade"
,
t
)},
expression
:
"form.grade"
}},[
e
.
_v
(
"QPS"
)])]],
2
),
e
.
_v
(
" "
),
a
(
"el-form-item"
,{
attrs
:{
label
:
"阈值"
,
prop
:
"count"
}},[
a
(
"el-input"
,{
staticClass
:
"w-220"
,
attrs
:{
placeholder
:
"请输入阈值"
},
model
:{
value
:
e
.
form
.
count
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"count"
,
t
)},
expression
:
"form.count"
}})],
1
),
e
.
_v
(
" "
),
a
(
"el-form-item"
,{
attrs
:{
label
:
"流控方式"
,
prop
:
"rangeType"
}},[[
a
(
"el-radio"
,{
attrs
:{
label
:
0
},
model
:{
value
:
e
.
form
.
strategy
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"strategy"
,
t
)},
expression
:
"form.strategy"
}},[
e
.
_v
(
"快速失败"
)])]],
2
),
e
.
_v
(
" "
),
a
(
"el-form-item"
,{
attrs
:{
label
:
"分布式限流"
,
prop
:
"count"
}},[
a
(
"el-switch"
,{
model
:{
value
:
e
.
form
.
distFlag
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"distFlag"
,
t
)},
expression
:
"form.distFlag"
}})],
1
),
e
.
_v
(
" "
),
a
(
"el-form-item"
,{
attrs
:{
label
:
"是否开启"
,
prop
:
"count"
}},[
a
(
"el-switch"
,{
model
:{
value
:
e
.
form
.
enableFlag
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"enableFlag"
,
t
)},
expression
:
"form.enableFlag"
}})],
1
)],
1
)],
1
),
e
.
_v
(
" "
),
a
(
"div"
,{
staticClass
:
"dialog-footer"
,
attrs
:{
slot
:
"footer"
},
slot
:
"footer"
},[
a
(
"el-button"
,{
on
:{
click
:
function
(
t
){
return
e
.
close
(
"form"
)}}},[
e
.
_v
(
"取消"
)]),
e
.
_v
(
" "
),
a
(
"el-button"
,{
attrs
:{
type
:
"primary"
},
on
:{
click
:
function
(
t
){
return
e
.
submitForm
(
"form"
)}}},[
e
.
_v
(
"确定"
)])],
1
)])},
staticRenderFns
:[]};
var
g
=
a
(
"VU/8"
)(
d
,
u
,
!
1
,
function
(
e
){
a
(
"0amw"
)},
"data-v-7928b793"
,
null
).
exports
,
m
=
{
props
:{
ruleId
:{
type
:
String
,
default
:
function
(){
return
""
}},
alarmType
:{
type
:
Number
,
default
:
function
(){
return
0
}},
sceneCode
:{
type
:
String
,
default
:
function
(){
return
""
}}},
data
:
function
(){
return
{
dialogVisible
:
!
0
,
tableData
:[],
total
:
0
,
currentPage
:
1
,
pageSize
:
5
}},
created
:
function
(){
this
.
dialogVisible
=!
0
,
this
.
getList
()},
methods
:{
handleCurrentChange
:
function
(
e
){
this
.
currentPage
=
e
,
this
.
getList
()},
getList
:
function
(){
var
e
=
this
,
t
=
{
ruleId
:
this
.
ruleId
,
sceneCode
:
this
.
sceneCode
,
alarmType
:
this
.
alarmType
,
currentPage
:
this
.
currentPage
,
pageSize
:
this
.
pageSize
},
a
=
this
;
Object
(
l
.
a
)(
"/gateway-manage/rule/alarm/log"
,
t
).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?
t
.
data
.
result
.
result
.
length
?(
e
.
tableData
=
t
.
data
.
result
.
result
,
e
.
total
=
t
.
data
.
result
.
totalCount
):(
e
.
tableData
=
[],
e
.
total
=
0
):
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
a
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
close
:
function
(){
this
.
dialogVisible
=!
1
,
this
.
$emit
(
"cancelLog"
)}}},
f
=
{
render
:
function
(){
var
e
=
this
,
t
=
e
.
$createElement
,
a
=
e
.
_self
.
_c
||
t
;
return
a
(
"el-dialog"
,{
attrs
:{
title
:
1
===
e
.
alarmType
?
"流控日志"
:
"熔断日志"
,
visible
:
e
.
dialogVisible
,
width
:
"600px"
},
on
:{
"update:visible"
:
function
(
t
){
e
.
dialogVisible
=
t
},
close
:
e
.
close
}},[
a
(
"div"
,{
staticClass
:
"dialog-body"
},[
a
(
"el-table"
,{
staticClass
:
"dialog-table"
,
staticStyle
:{
width
:
"100%"
},
attrs
:{
data
:
e
.
tableData
}},[
a
(
"el-table-column"
,{
attrs
:{
prop
:
"rangeType"
,
label
:
1
===
e
.
alarmType
?
"流控范围"
:
"熔断范围"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
0
===
t
.
row
.
rangeType
?
a
(
"div"
,[
e
.
_v
(
"项目"
)]):
e
.
_e
(),
e
.
_v
(
" "
),
1
===
t
.
row
.
rangeType
?
a
(
"div"
,[
e
.
_v
(
"分组"
)]):
e
.
_e
(),
e
.
_v
(
" "
),
2
===
t
.
row
.
rangeType
?
a
(
"div"
,[
e
.
_v
(
"接口"
)]):
e
.
_e
()]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"ruleContent"
,
label
:
1
===
e
.
alarmType
?
"流控内容"
:
"熔断内容"
}}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"updateTime"
,
label
:
"发生时间"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
a
(
"div"
,{
staticClass
:
"color-606266 line-18"
},[
e
.
_v
(
e
.
_s
(
e
.
_f
(
"timeStampToYmd"
)(
t
.
row
.
updateTime
)))]),
e
.
_v
(
" "
),
a
(
"div"
,{
staticClass
:
"color-606266 line-18"
},[
e
.
_v
(
e
.
_s
(
e
.
_f
(
"timeStampToHms"
)(
t
.
row
.
updateTime
)))])]}}])})],
1
),
e
.
_v
(
" "
),
e
.
total
>
0
?
a
(
"div"
,{
staticClass
:
"page-content"
},[
a
(
"el-pagination"
,{
attrs
:{
small
:
""
,
"current-page"
:
e
.
currentPage
,
"page-size"
:
e
.
pageSize
,
layout
:
"prev, pager, next"
,
total
:
e
.
total
},
on
:{
"current-change"
:
e
.
handleCurrentChange
,
"update:currentPage"
:
function
(
t
){
e
.
currentPage
=
t
},
"update:current-page"
:
function
(
t
){
e
.
currentPage
=
t
}}})],
1
):
e
.
_e
()],
1
)])},
staticRenderFns
:[]};
var
p
=
a
(
"VU/8"
)(
m
,
f
,
!
1
,
function
(
e
){
a
(
"JQyN"
)},
"data-v-118a596f"
,
null
).
exports
,
h
=
{
props
:{
tableData
:{
type
:
Array
,
default
:
function
(){
return
[]}},
sceneCode
:{
type
:
String
,
default
:
function
(){
return
""
}}},
components
:{
newRule
:
g
,
ahshLog
:
p
},
data
:
function
(){
return
{
showRuleDialog
:
!
1
,
ruleId
:
""
,
showDialog
:
""
,
alarmType
:
1
}},
methods
:{
deleteList
:
function
(
e
){
var
t
=
this
,
a
=
this
,
r
=
{
rateLimiterId
:
e
.
rateLimiterId
};
Object
(
l
.
a
)(
"/gateway-manage/rule/ratelimiter/del"
,
r
).
then
(
function
(
e
){
"0000"
==
e
.
data
.
code
?
t
.
getList
():
t
.
$message
.
error
(
e
.
data
.
message
)}).
catch
(
function
(
e
){
a
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
getList
:
function
(){
this
.
$emit
(
"getList"
)},
changeFlag
:
function
(
e
){
var
t
=
this
,
a
=
{
enableFlag
:
e
.
enableFlag
?
1
:
0
,
rateLimiterId
:
e
.
rateLimiterId
};
Object
(
l
.
a
)(
"/gateway-manage/rule/ratelimiter/enable"
,
a
).
then
(
function
(
a
){
"0000"
==
a
.
data
.
code
?
t
.
$emit
(
"getList"
):(
e
.
enableFlag
=!
e
.
enableFlag
,
t
.
$message
.
error
(
a
.
data
.
message
))})},
edit
:
function
(
e
){
this
.
ruleId
=
e
.
rateLimiterId
,
this
.
showRuleDialog
=!
0
},
cancelAdd
:
function
(){
this
.
showRuleDialog
=!
1
},
seeLog
:
function
(
e
){
this
.
ruleId
=
e
.
rateLimiterId
,
this
.
showDialog
=!
0
},
cancelLog
:
function
(){
this
.
showDialog
=!
1
}}},
v
=
{
render
:
function
(){
var
e
=
this
,
t
=
e
.
$createElement
,
a
=
e
.
_self
.
_c
||
t
;
return
a
(
"div"
,{
staticStyle
:{
"margin-top"
:
"20px"
}},[
a
(
"div"
,{
staticClass
:
"table-content"
},[
a
(
"el-table"
,{
directives
:[{
name
:
"loading"
,
rawName
:
"v-loading"
,
value
:
e
.
loading
,
expression
:
"loading"
}],
staticStyle
:{
width
:
"100%"
},
attrs
:{
data
:
e
.
tableData
,
"tooltip-effect"
:
"dark"
,
height
:
e
.
tableHeight
}},[
a
(
"el-table-column"
,{
attrs
:{
label
:
"流控ID"
,
prop
:
"ruleCode"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
a
(
"span"
,[
e
.
_v
(
e
.
_s
(
t
.
row
.
ruleCode
))]),
e
.
_v
(
" "
),
1
===
t
.
row
.
editeFlag
?
a
(
"span"
,{
staticClass
:
"sign-design"
},[
e
.
_v
(
"未发布"
)]):
e
.
_e
()]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"rangeType"
,
label
:
"流控范围"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
0
===
t
.
row
.
rangeType
?
a
(
"p"
,[
e
.
_v
(
"项目"
)]):
e
.
_e
(),
e
.
_v
(
" "
),
1
===
t
.
row
.
rangeType
?
a
(
"p"
,[
e
.
_v
(
"分组"
)]):
e
.
_e
(),
e
.
_v
(
" "
),
2
===
t
.
row
.
rangeType
?
a
(
"p"
,[
e
.
_v
(
"接口"
)]):
e
.
_e
()]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"ruleContent"
,
label
:
"流控内容"
}}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"grade"
,
label
:
"阈值类型"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
1
===
t
.
row
.
grade
?
a
(
"p"
,[
e
.
_v
(
"QPS"
)]):
e
.
_e
()]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"count"
,
label
:
"阈值"
}}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"strategy"
,
label
:
"流控方式"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
0
===
t
.
row
.
strategy
?
a
(
"p"
,[
e
.
_v
(
"快速失败"
)]):
e
.
_e
()]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"grade"
,
label
:
"分布式限流"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
1
===
t
.
row
.
distFlag
?
a
(
"p"
,[
e
.
_v
(
"是"
)]):
e
.
_e
(),
e
.
_v
(
" "
),
0
===
t
.
row
.
distFlag
?
a
(
"p"
,[
e
.
_v
(
"否"
)]):
e
.
_e
()]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"enableFlag"
,
label
:
"开启状态"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
a
(
"el-switch"
,{
on
:{
change
:
function
(
a
){
return
e
.
changeFlag
(
t
.
row
)}},
model
:{
value
:
t
.
row
.
enableFlag
,
callback
:
function
(
a
){
e
.
$set
(
t
.
row
,
"enableFlag"
,
a
)},
expression
:
"scope.row.enableFlag"
}})]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
label
:
"操作"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
a
(
"el-button"
,{
attrs
:{
type
:
"text"
},
on
:{
click
:
function
(
a
){
return
e
.
edit
(
t
.
row
)}}},[
e
.
_v
(
"编辑"
)]),
e
.
_v
(
" "
),
a
(
"dm-delete"
,{
attrs
:{
tips
:
"确定要删除该数据吗?"
},
on
:{
confirm
:
function
(
a
){
return
e
.
deleteList
(
t
.
row
)}}},[
a
(
"el-button"
,{
attrs
:{
type
:
"text"
}},[
e
.
_v
(
"删除"
)])],
1
),
e
.
_v
(
" "
),
a
(
"el-button"
,{
attrs
:{
type
:
"text"
},
on
:{
click
:
function
(
a
){
return
e
.
seeLog
(
t
.
row
)}}},[
e
.
_v
(
"日志"
)])]}}])})],
1
)],
1
),
e
.
_v
(
" "
),
e
.
showRuleDialog
?
a
(
"newRule"
,{
attrs
:{
sceneCode
:
e
.
sceneCode
,
ruleId
:
e
.
ruleId
},
on
:{
cancelAdd
:
e
.
cancelAdd
,
getList
:
e
.
getList
}}):
e
.
_e
(),
e
.
_v
(
" "
),
e
.
showDialog
?
a
(
"ahshLog"
,{
attrs
:{
alarmType
:
e
.
alarmType
,
sceneCode
:
e
.
sceneCode
,
ruleId
:
e
.
ruleId
},
on
:{
cancelLog
:
e
.
cancelLog
}}):
e
.
_e
()],
1
)},
staticRenderFns
:[]};
var
b
=
a
(
"VU/8"
)(
h
,
v
,
!
1
,
function
(
e
){
a
(
"LmEw"
)},
"data-v-fa7cb46e"
,
null
).
exports
,
y
=
{
props
:{
degradeId
:{
type
:
String
,
default
:
function
(){
return
""
}},
sceneCode
:{
type
:
String
,
default
:
function
(){
return
""
}}},
data
:
function
(){
return
{
dialogVisible
:
!
0
,
projectList
:[],
groupList
:[],
apiList
:[],
form
:{
rangeType
:
0
,
rangeInfo
:
""
,
ruleContent
:
""
,
projectId
:
""
,
projectName
:
""
,
groupId
:
""
,
groupName
:
""
,
interfaceId
:
""
,
interfaceName
:
""
,
grade
:
1
,
count
:
""
,
timeWindow
:
""
,
enableFlag
:
!
1
},
rule
:{
projectId
:[{
required
:
!
0
,
message
:
"请选择项目"
,
trigger
:
"change"
}],
groupId
:[{
required
:
!
0
,
message
:
"请选择分组"
,
trigger
:
"change"
}],
interfaceId
:[{
required
:
!
0
,
message
:
"请选择接口"
,
trigger
:
"change"
}],
count
:[{
required
:
!
0
,
message
:
"请输入异常比例"
,
trigger
:
"blur"
},{
validator
:
function
(
e
,
t
,
a
){
/^
[
0
-
1
]{
1
}([.]([
0
-
9
]){
2
})?
$
/
.
test
(
t
)?
a
():
a
(
new
Error
(
"请输入0-1且小数不超过两位的数字"
))},
trigger
:
"blur"
}],
timeWindow
:[{
required
:
!
0
,
message
:
"请输入时间窗口"
,
trigger
:
"blur"
},{
validator
:
function
(
e
,
t
,
a
){
/^
(
0
|
\
+
?[
1
-
9
][
0
-
9
]
*
)
$
/
.
test
(
t
)?
a
():
a
(
new
Error
(
"时间必须输入正整数"
))},
trigger
:
"blur"
}]}}},
created
:
function
(){
this
.
dialogVisible
=!
0
,
this
.
getProjectList
(),
this
.
degradeId
&&
this
.
getInfo
()},
methods
:{
getInfo
:
function
(){
var
e
=
this
,
t
=
this
,
a
=
{
ruleId
:
this
.
degradeId
};
Object
(
l
.
a
)(
"/gateway-manage/rule/degrade/detail"
,
a
).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?(
e
.
form
.
rangeType
=
t
.
data
.
result
.
rangeType
,
0
===
e
.
form
.
rangeType
?
e
.
getGroupList
():
1
===
e
.
form
.
rangeType
?
e
.
getGroupList
():
2
===
e
.
form
.
rangeType
&&
(
e
.
getApiList
(),
e
.
getGroupList
()),
e
.
form
.
projectId
=
t
.
data
.
result
.
projectId
,
e
.
form
.
interfaceId
=
t
.
data
.
result
.
interfaceId
,
e
.
form
.
groupId
=
t
.
data
.
result
.
groupId
,
e
.
form
.
grade
=
t
.
data
.
result
.
grade
,
e
.
form
.
count
=
t
.
data
.
result
.
count
,
e
.
form
.
timeWindow
=
t
.
data
.
result
.
timeWindow
,
e
.
form
.
enableFlag
=
1
===
t
.
data
.
result
.
enableFlag
):
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
t
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
getProjectList
:
function
(){
var
e
=
this
,
t
=
this
;
Object
(
l
.
a
)(
"/gateway-manage/plugin/interface/tree"
,{}).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?
t
.
data
.
result
?
e
.
projectList
=
t
.
data
.
result
:
e
.
projectList
=
[]:
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
t
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
getGroupList
:
function
(){
var
e
=
this
,
t
=
this
;
this
.
form
.
groupId
=
""
,
this
.
form
.
interfaceId
=
""
;
var
a
=
{
type
:
0
,
id
:
this
.
form
.
projectId
};
Object
(
l
.
a
)(
"/gateway-manage/plugin/interface/tree"
,
a
).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?
t
.
data
.
result
?
e
.
groupList
=
t
.
data
.
result
:
e
.
groupList
=
[]:
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
t
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
getApiList
:
function
(){
var
e
=
this
,
t
=
this
;
this
.
form
.
interfaceId
=
""
;
var
a
=
{
type
:
1
,
id
:
this
.
form
.
groupId
};
Object
(
l
.
a
)(
"/gateway-manage/plugin/interface/tree"
,
a
).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?
t
.
data
.
result
?
e
.
apiList
=
t
.
data
.
result
:
e
.
apiList
=
[]:
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
t
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
submitForm
:
function
(
e
){
var
t
=
this
,
a
=
this
;
this
.
$refs
[
e
].
validate
(
function
(
e
){
if
(
!
e
)
return
!
1
;
0
===
t
.
form
.
rangeType
?(
t
.
form
.
projectName
=
t
.
projectList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
projectId
}).
name
,
t
.
form
.
ruleContent
=
t
.
form
.
projectName
,
t
.
form
.
rangeInfo
=
t
.
form
.
projectId
):
1
===
t
.
form
.
rangeType
?(
t
.
form
.
projectName
=
t
.
projectList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
projectId
}).
name
,
t
.
form
.
groupName
=
t
.
groupList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
groupId
}).
name
,
t
.
form
.
ruleContent
=
t
.
form
.
projectName
+
"-"
+
t
.
form
.
groupName
,
t
.
form
.
rangeInfo
=
t
.
form
.
groupId
):
2
===
t
.
form
.
rangeType
&&
(
t
.
form
.
projectName
=
t
.
projectList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
projectId
}).
name
,
t
.
form
.
groupName
=
t
.
groupList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
groupId
}).
name
,
t
.
form
.
interfaceName
=
t
.
apiList
.
find
(
function
(
e
){
return
e
.
id
===
t
.
form
.
interfaceId
}).
name
,
t
.
form
.
ruleContent
=
t
.
form
.
projectName
+
"-"
+
t
.
form
.
groupName
+
"-"
+
t
.
form
.
interfaceName
,
t
.
form
.
rangeInfo
=
t
.
form
.
interfaceId
);
var
r
=
{
sceneCode
:
t
.
sceneCode
,
rangeType
:
t
.
form
.
rangeType
,
rangeInfo
:
t
.
form
.
rangeInfo
,
ruleContent
:
t
.
form
.
ruleContent
,
grade
:
t
.
form
.
grade
,
count
:
t
.
form
.
count
,
timeWindow
:
t
.
form
.
timeWindow
,
enableFlag
:
t
.
form
.
enableFlag
?
1
:
0
};
t
.
degradeId
&&
(
r
.
degradeId
=
t
.
degradeId
),
Object
(
l
.
a
)(
"/gateway-manage/rule/degrade/save"
,
r
).
then
(
function
(
e
){
"0000"
==
e
.
data
.
code
?(
t
.
dialogVisible
=!
1
,
t
.
$emit
(
"cancelAddFlus"
),
t
.
$emit
(
"getList"
)):
t
.
$message
.
error
(
e
.
data
.
message
)}).
catch
(
function
(
e
){
a
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})})},
close
:
function
(
e
){
this
.
$refs
[
e
].
resetFields
(),
this
.
$emit
(
"cancelAddFlus"
)}}},
I
=
{
render
:
function
(){
var
e
=
this
,
t
=
e
.
$createElement
,
a
=
e
.
_self
.
_c
||
t
;
return
a
(
"el-dialog"
,{
attrs
:{
title
:
e
.
degradeId
?
"编辑熔断规则"
:
"新建熔断规则"
,
visible
:
e
.
dialogVisible
,
width
:
"400px"
},
on
:{
"update:visible"
:
function
(
t
){
e
.
dialogVisible
=
t
},
close
:
function
(
t
){
return
e
.
close
(
"form"
)}}},[
a
(
"div"
,{
staticClass
:
"dialog-body"
},[
a
(
"el-form"
,{
ref
:
"form"
,
staticClass
:
"demo-ruleForm"
,
attrs
:{
model
:
e
.
form
,
rules
:
e
.
rule
,
"label-width"
:
"100px"
,
"label-position"
:
"right"
}},[
a
(
"el-form-item"
,{
attrs
:{
label
:
"熔断范围"
,
prop
:
"rangeType"
}},[[
a
(
"el-radio"
,{
attrs
:{
label
:
0
},
model
:{
value
:
e
.
form
.
rangeType
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"rangeType"
,
t
)},
expression
:
"form.rangeType"
}},[
e
.
_v
(
"项目"
)]),
e
.
_v
(
" "
),
a
(
"el-radio"
,{
attrs
:{
label
:
1
},
model
:{
value
:
e
.
form
.
rangeType
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"rangeType"
,
t
)},
expression
:
"form.rangeType"
}},[
e
.
_v
(
"分组"
)]),
e
.
_v
(
" "
),
a
(
"el-radio"
,{
attrs
:{
label
:
2
},
model
:{
value
:
e
.
form
.
rangeType
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"rangeType"
,
t
)},
expression
:
"form.rangeType"
}},[
e
.
_v
(
"接口"
)])]],
2
),
e
.
_v
(
" "
),
a
(
"el-form-item"
,{
attrs
:{
label
:
"熔断内容"
,
prop
:
"projectId"
}},[
a
(
"el-select"
,{
attrs
:{
placeholder
:
"请选择项目"
},
on
:{
change
:
e
.
getGroupList
},
model
:{
value
:
e
.
form
.
projectId
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"projectId"
,
t
)},
expression
:
"form.projectId"
}},
e
.
_l
(
e
.
projectList
,
function
(
e
){
return
a
(
"el-option"
,{
key
:
e
.
id
,
attrs
:{
label
:
e
.
name
,
value
:
e
.
id
}})}),
1
)],
1
),
e
.
_v
(
" "
),
0
!==
e
.
form
.
rangeType
?
a
(
"el-form-item"
,{
attrs
:{
prop
:
"groupId"
}},[
a
(
"el-select"
,{
attrs
:{
placeholder
:
"请选择分组"
,
disabled
:
""
===
e
.
form
.
projectId
},
on
:{
change
:
e
.
getApiList
},
model
:{
value
:
e
.
form
.
groupId
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"groupId"
,
t
)},
expression
:
"form.groupId"
}},
e
.
_l
(
e
.
groupList
,
function
(
e
){
return
a
(
"el-option"
,{
key
:
e
.
id
,
attrs
:{
label
:
e
.
name
,
value
:
e
.
id
}})}),
1
)],
1
):
e
.
_e
(),
e
.
_v
(
" "
),
2
===
e
.
form
.
rangeType
?
a
(
"el-form-item"
,{
attrs
:{
prop
:
"interfaceId"
}},[
a
(
"el-select"
,{
attrs
:{
placeholder
:
"请选择接口"
,
disabled
:
""
===
e
.
form
.
groupId
},
model
:{
value
:
e
.
form
.
interfaceId
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"interfaceId"
,
t
)},
expression
:
"form.interfaceId"
}},
e
.
_l
(
e
.
apiList
,
function
(
e
){
return
a
(
"el-option"
,{
key
:
e
.
id
,
attrs
:{
label
:
e
.
name
,
value
:
e
.
id
}})}),
1
)],
1
):
e
.
_e
(),
e
.
_v
(
" "
),
a
(
"el-form-item"
,{
attrs
:{
label
:
"阈值类型"
,
prop
:
"grade"
}},[[
a
(
"el-radio"
,{
attrs
:{
label
:
1
},
model
:{
value
:
e
.
form
.
grade
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"grade"
,
t
)},
expression
:
"form.grade"
}},[
e
.
_v
(
"异常比例"
)])]],
2
),
e
.
_v
(
" "
),
a
(
"el-form-item"
,{
attrs
:{
label
:
"异常比例"
,
prop
:
"count"
}},[
a
(
"el-input"
,{
staticClass
:
"w-220"
,
attrs
:{
placeholder
:
"请输入异常比例"
},
model
:{
value
:
e
.
form
.
count
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"count"
,
t
)},
expression
:
"form.count"
}})],
1
),
e
.
_v
(
" "
),
a
(
"el-form-item"
,{
attrs
:{
label
:
"时间窗口"
,
prop
:
"timeWindow"
}},[
a
(
"el-input"
,{
staticClass
:
"w-220"
,
attrs
:{
placeholder
:
"请输入时间窗口"
},
model
:{
value
:
e
.
form
.
timeWindow
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"timeWindow"
,
t
)},
expression
:
"form.timeWindow"
}},[
a
(
"template"
,{
slot
:
"append"
},[
e
.
_v
(
"
\
n 秒
\
n "
)])],
2
)],
1
),
e
.
_v
(
" "
),
a
(
"el-form-item"
,{
attrs
:{
label
:
"是否开启"
,
prop
:
"enableFlag"
}},[
a
(
"el-switch"
,{
model
:{
value
:
e
.
form
.
enableFlag
,
callback
:
function
(
t
){
e
.
$set
(
e
.
form
,
"enableFlag"
,
t
)},
expression
:
"form.enableFlag"
}})],
1
)],
1
)],
1
),
e
.
_v
(
" "
),
a
(
"div"
,{
staticClass
:
"dialog-footer"
,
attrs
:{
slot
:
"footer"
},
slot
:
"footer"
},[
a
(
"el-button"
,{
on
:{
click
:
function
(
t
){
return
e
.
close
(
"form"
)}}},[
e
.
_v
(
"取消"
)]),
e
.
_v
(
" "
),
a
(
"el-button"
,{
attrs
:{
type
:
"primary"
},
on
:{
click
:
function
(
t
){
return
e
.
submitForm
(
"form"
)}}},[
e
.
_v
(
"确定"
)])],
1
)])},
staticRenderFns
:[]};
var
w
=
a
(
"VU/8"
)(
y
,
I
,
!
1
,
function
(
e
){
a
(
"F6GH"
)},
"data-v-55b9c3d1"
,
null
).
exports
,
L
=
{
props
:{
tableData
:{
type
:
Array
,
default
:
function
(){
return
[]}},
sceneCode
:{
type
:
String
,
default
:
function
(){
return
""
}}},
data
:
function
(){
return
{
showFlusDialog
:
!
1
,
showDialog
:
!
1
,
alarmType
:
2
}},
methods
:{
deleteList
:
function
(
e
){
var
t
=
this
,
a
=
this
,
r
=
{
degradeId
:
e
.
degradeId
};
Object
(
l
.
a
)(
"/gateway-manage/rule/degrade/del"
,
r
).
then
(
function
(
e
){
"0000"
==
e
.
data
.
code
?
t
.
getList
():
t
.
$message
.
error
(
e
.
data
.
message
)}).
catch
(
function
(
e
){
a
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
getList
:
function
(){
this
.
$emit
(
"getList"
)},
edit
:
function
(
e
){
this
.
degradeId
=
e
.
degradeId
,
this
.
showFlusDialog
=!
0
},
cancelAddFlus
:
function
(){
this
.
showFlusDialog
=!
1
},
changeFlag
:
function
(
e
){
var
t
=
this
,
a
=
this
,
r
=
{
enableFlag
:
e
.
enableFlag
?
1
:
0
,
degradeId
:
e
.
degradeId
};
Object
(
l
.
a
)(
"/gateway-manage/rule/degrade/enable"
,
r
).
then
(
function
(
a
){
"0000"
==
a
.
data
.
code
?
t
.
$emit
(
"getList"
):(
e
.
enableFlag
=!
e
.
enableFlag
,
t
.
$message
.
error
(
a
.
data
.
message
))}).
catch
(
function
(
e
){
a
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
seeLog
:
function
(
e
){
this
.
ruleId
=
e
.
degradeId
,
this
.
showDialog
=!
0
},
cancelLog
:
function
(){
this
.
showDialog
=!
1
}},
components
:{
newSet
:
w
,
ahshLog
:
p
}},
C
=
{
render
:
function
(){
var
e
=
this
,
t
=
e
.
$createElement
,
a
=
e
.
_self
.
_c
||
t
;
return
a
(
"div"
,{
staticStyle
:{
"margin-top"
:
"20px"
}},[
a
(
"div"
,{
staticClass
:
"table-content"
},[
a
(
"el-table"
,{
directives
:[{
name
:
"loading"
,
rawName
:
"v-loading"
,
value
:
e
.
loading
,
expression
:
"loading"
}],
staticStyle
:{
width
:
"100%"
},
attrs
:{
data
:
e
.
tableData
,
"tooltip-effect"
:
"dark"
,
height
:
e
.
tableHeight
}},[
a
(
"el-table-column"
,{
attrs
:{
label
:
"熔断ID"
,
prop
:
"ruleCode"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
a
(
"span"
,[
e
.
_v
(
e
.
_s
(
t
.
row
.
ruleCode
))]),
e
.
_v
(
" "
),
1
===
t
.
row
.
editeFlag
?
a
(
"span"
,{
staticClass
:
"sign-design"
},[
e
.
_v
(
"未发布"
)]):
e
.
_e
()]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"rangeType"
,
label
:
"熔断范围"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
0
===
t
.
row
.
rangeType
?
a
(
"p"
,[
e
.
_v
(
"项目"
)]):
e
.
_e
(),
e
.
_v
(
" "
),
1
===
t
.
row
.
rangeType
?
a
(
"p"
,[
e
.
_v
(
"分组"
)]):
e
.
_e
(),
e
.
_v
(
" "
),
2
===
t
.
row
.
rangeType
?
a
(
"p"
,[
e
.
_v
(
"接口"
)]):
e
.
_e
(),
e
.
_v
(
" "
),
3
===
t
.
row
.
rangeType
?
a
(
"p"
,[
e
.
_v
(
"其他"
)]):
e
.
_e
()]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"ruleContent"
,
label
:
"熔断内容"
}}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"grade"
,
label
:
"阈值类型"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
1
===
t
.
row
.
grade
?
a
(
"p"
,[
e
.
_v
(
"异常比例"
)]):
e
.
_e
()]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"count"
,
label
:
"阈值"
}}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"timeWindow"
,
label
:
"时间窗口"
}}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"enableFlag"
,
label
:
"开启状态"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
a
(
"el-switch"
,{
on
:{
change
:
function
(
a
){
return
e
.
changeFlag
(
t
.
row
)}},
model
:{
value
:
t
.
row
.
enableFlag
,
callback
:
function
(
a
){
e
.
$set
(
t
.
row
,
"enableFlag"
,
a
)},
expression
:
"scope.row.enableFlag"
}})]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
label
:
"操作"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
a
(
"el-button"
,{
attrs
:{
type
:
"text"
},
on
:{
click
:
function
(
a
){
return
e
.
edit
(
t
.
row
)}}},[
e
.
_v
(
"编辑"
)]),
e
.
_v
(
" "
),
a
(
"dm-delete"
,{
attrs
:{
tips
:
"确定要删除该数据吗?"
},
on
:{
confirm
:
function
(
a
){
return
e
.
deleteList
(
t
.
row
)}}},[
a
(
"el-button"
,{
attrs
:{
type
:
"text"
}},[
e
.
_v
(
"删除"
)])],
1
),
e
.
_v
(
" "
),
a
(
"el-button"
,{
attrs
:{
type
:
"text"
},
on
:{
click
:
function
(
a
){
return
e
.
seeLog
(
t
.
row
)}}},[
e
.
_v
(
"日志"
)])]}}])})],
1
)],
1
),
e
.
_v
(
" "
),
e
.
showFlusDialog
?
a
(
"newSet"
,{
attrs
:{
sceneCode
:
e
.
sceneCode
,
degradeId
:
e
.
degradeId
},
on
:{
cancelAddFlus
:
e
.
cancelAddFlus
,
getList
:
e
.
getList
}}):
e
.
_e
(),
e
.
_v
(
" "
),
e
.
showDialog
?
a
(
"ahshLog"
,{
attrs
:{
sceneCode
:
e
.
sceneCode
,
ruleId
:
e
.
ruleId
,
alarmType
:
e
.
alarmType
},
on
:{
cancelLog
:
e
.
cancelLog
}}):
e
.
_e
()],
1
)},
staticRenderFns
:[]};
var
_
=
a
(
"VU/8"
)(
L
,
C
,
!
1
,
function
(
e
){
a
(
"RV9G"
)},
"data-v-5d6ec933"
,
null
).
exports
,
F
=
{
props
:{
alarmType
:{
type
:
Number
,
default
:
function
(){
return
0
}},
sceneCode
:{
type
:
String
,
default
:
function
(){
return
""
}}},
data
:
function
(){
return
{
dialogVisible
:
!
0
,
tableData
:[],
total
:
0
,
currentPage
:
1
,
pageSize
:
5
}},
created
:
function
(){
this
.
dialogVisible
=!
0
,
this
.
getList
()},
methods
:{
handleCurrentChange
:
function
(
e
){
this
.
currentPage
=
e
,
this
.
getList
()},
getList
:
function
(){
var
e
=
this
,
t
=
{
sceneCode
:
this
.
sceneCode
,
alarmType
:
this
.
alarmType
,
currentPage
:
this
.
currentPage
,
pageSize
:
this
.
pageSize
},
a
=
this
;
Object
(
l
.
a
)(
"/gateway-manage/rule/alarm/log"
,
t
).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?
t
.
data
.
result
.
result
.
length
?(
e
.
tableData
=
t
.
data
.
result
.
result
,
e
.
total
=
t
.
data
.
result
.
totalCount
):(
e
.
tableData
=
[],
e
.
total
=
0
):
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
a
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
close
:
function
(){
this
.
dialogVisible
=!
1
,
this
.
$emit
(
"cancelLog"
)}}},
j
=
{
render
:
function
(){
var
e
=
this
,
t
=
e
.
$createElement
,
a
=
e
.
_self
.
_c
||
t
;
return
a
(
"el-dialog"
,{
attrs
:{
title
:
"日志"
,
visible
:
e
.
dialogVisible
,
width
:
"600px"
},
on
:{
"update:visible"
:
function
(
t
){
e
.
dialogVisible
=
t
},
close
:
e
.
close
}},[
a
(
"div"
,{
staticClass
:
"dialog-body"
},[
a
(
"el-table"
,{
staticClass
:
"dialog-table"
,
staticStyle
:{
width
:
"100%"
},
attrs
:{
data
:
e
.
tableData
}},[
a
(
"el-table-column"
,{
attrs
:{
prop
:
"enableFlag"
,
label
:
"告警类型"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
a
(
"el-switch"
,{
on
:{
change
:
function
(
a
){
return
e
.
changeFlag
(
t
.
row
)}},
model
:{
value
:
t
.
row
.
enableFlag
,
callback
:
function
(
a
){
e
.
$set
(
t
.
row
,
"enableFlag"
,
a
)},
expression
:
"scope.row.enableFlag"
}})]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"enableFlag"
,
label
:
"告警内容"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
a
(
"el-switch"
,{
on
:{
change
:
function
(
a
){
return
e
.
changeFlag
(
t
.
row
)}},
model
:{
value
:
t
.
row
.
enableFlag
,
callback
:
function
(
a
){
e
.
$set
(
t
.
row
,
"enableFlag"
,
a
)},
expression
:
"scope.row.enableFlag"
}})]}}])}),
e
.
_v
(
" "
),
a
(
"el-table-column"
,{
attrs
:{
prop
:
"updateTime"
,
label
:
"发生时间"
},
scopedSlots
:
e
.
_u
([{
key
:
"default"
,
fn
:
function
(
t
){
return
[
a
(
"div"
,{
staticClass
:
"color-606266 line-18"
},[
e
.
_v
(
e
.
_s
(
e
.
_f
(
"timeStampToYmd"
)(
t
.
row
.
updateTime
)))]),
e
.
_v
(
" "
),
a
(
"div"
,{
staticClass
:
"color-606266 line-18"
},[
e
.
_v
(
e
.
_s
(
e
.
_f
(
"timeStampToHms"
)(
t
.
row
.
updateTime
)))])]}}])})],
1
),
e
.
_v
(
" "
),
e
.
total
>
0
?
a
(
"div"
,{
staticClass
:
"page-content"
},[
a
(
"el-pagination"
,{
attrs
:{
small
:
""
,
"current-page"
:
e
.
currentPage
,
"page-size"
:
e
.
pageSize
,
layout
:
"prev, pager, next"
,
total
:
e
.
total
},
on
:{
"current-change"
:
e
.
handleCurrentChange
,
"update:currentPage"
:
function
(
t
){
e
.
currentPage
=
t
},
"update:current-page"
:
function
(
t
){
e
.
currentPage
=
t
}}})],
1
):
e
.
_e
()],
1
)])},
staticRenderFns
:[]};
var
A
=
a
(
"VU/8"
)(
F
,
j
,
!
1
,
function
(
e
){
a
(
"PbPA"
)},
"data-v-238c15d7"
,
null
).
exports
,
D
=
{
props
:{
tableData
:{
type
:
Array
,
default
:
function
(){
return
[]}},
sceneCode
:{
type
:
String
,
default
:
function
(){
return
""
}}},
data
:
function
(){
return
{
showDialog
:
!
1
,
refash
:
!
1
}},
methods
:{
handleChange
:
function
(
e
){
this
.
$emit
(
"changeFlag"
,
e
)},
seeLog
:
function
(
e
){
this
.
ruleId
=
e
.
sceneCode
,
this
.
alarmType
=
e
.
alarmType
,
this
.
showDialog
=!
0
},
cancelLog
:
function
(){
this
.
showDialog
=!
1
},
editItemm
:
function
(
e
){
var
t
=
this
,
a
=
this
;
if
(
this
.
refash
=!
this
.
refash
,
e
.
editStatus
=!
e
.
editStatus
,
!
e
.
editStatus
){
var
r
=
{
alarmType
:
e
.
alarmType
,
alarmInfo
:
e
.
alarmInfo
,
sceneCode
:
this
.
sceneCode
};
Object
(
l
.
a
)(
"/gateway-manage/rule/alarm/edit"
,
r
).
then
(
function
(
a
){
"0000"
==
a
.
data
.
code
?(
t
.
$emit
(
"getList"
),
t
.
$message
.
success
(
"保存成功"
)):(
e
.
editStatus
=!
e
.
editStatus
,
t
.
$message
.
error
(
a
.
data
.
message
))}).
catch
(
function
(
e
){
a
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})}}},
components
:{
alarmLog
:
A
}},
S
=
{
render
:
function
(){
var
e
=
this
,
t
=
e
.
$createElement
,
r
=
e
.
_self
.
_c
||
t
;
return
r
(
"div"
,{
staticStyle
:{
"margin-top"
:
"20px"
}},[
r
(
"div"
,{
staticClass
:
"list-content"
},
e
.
_l
(
e
.
tableData
,
function
(
t
,
n
){
return
r
(
"div"
,{
key
:
n
,
staticClass
:
"list-item"
},[
r
(
"div"
,{
staticClass
:
"item-top"
},[
1
===
t
.
alarmType
?
r
(
"img"
,{
attrs
:{
src
:
a
(
"vgET"
),
alt
:
""
}}):
e
.
_e
(),
e
.
_v
(
" "
),
2
===
t
.
alarmType
?
r
(
"img"
,{
attrs
:{
src
:
a
(
"8PC5"
),
alt
:
""
}}):
e
.
_e
(),
e
.
_v
(
" "
),
r
(
"div"
,{
staticClass
:
"item-info"
},[
r
(
"p"
,{
staticClass
:
"info-type"
},[
e
.
_v
(
e
.
_s
(
1
===
t
.
alarmType
?
"流控告警"
:
"熔断告警"
))]),
e
.
_v
(
" "
),
r
(
"p"
,{
staticClass
:
"name"
},[
e
.
_v
(
"Webhook通知地址"
)]),
e
.
_v
(
" "
),
r
(
"div"
,{
staticClass
:
"address"
},[
t
.
editStatus
?
r
(
"el-input"
,{
staticStyle
:{
width
:
"368px"
},
attrs
:{
type
:
"textarea"
,
placeholder
:
"请输入内容"
},
model
:{
value
:
t
.
alarmInfo
,
callback
:
function
(
a
){
e
.
$set
(
t
,
"alarmInfo"
,
a
)},
expression
:
"item.alarmInfo"
}}):
r
(
"p"
,[
e
.
_v
(
e
.
_s
(
t
.
alarmInfo
))])],
1
)])]),
e
.
_v
(
" "
),
r
(
"div"
,{
staticClass
:
"item-bottom"
},[
r
(
"div"
,[
r
(
"p"
,{
on
:{
click
:
function
(
a
){
return
e
.
editItemm
(
t
)}}},[
e
.
_v
(
e
.
_s
(
t
.
editStatus
?
"保存"
:
"编辑"
)
+
"Webhook通知地址"
)]),
e
.
_v
(
" "
),
r
(
"p"
,{
on
:{
click
:
function
(
a
){
return
e
.
seeLog
(
t
)}}},[
e
.
_v
(
"日志"
)])]),
e
.
_v
(
" "
),
r
(
"span"
,{
staticStyle
:{
display
:
"none"
}},[
e
.
_v
(
e
.
_s
(
e
.
refash
))]),
e
.
_v
(
" "
),
r
(
"el-switch"
,{
on
:{
change
:
function
(
a
){
return
e
.
handleChange
(
t
)}},
model
:{
value
:
t
.
enableFlag
,
callback
:
function
(
a
){
e
.
$set
(
t
,
"enableFlag"
,
a
)},
expression
:
"item.enableFlag"
}})],
1
)])}),
0
),
e
.
_v
(
" "
),
e
.
showDialog
?
r
(
"alarmLog"
,{
attrs
:{
alarmType
:
e
.
alarmType
,
sceneCode
:
e
.
sceneCode
},
on
:{
cancelLog
:
e
.
cancelLog
}}):
e
.
_e
()],
1
)},
staticRenderFns
:[]};
var
T
=
a
(
"VU/8"
)(
D
,
S
,
!
1
,
function
(
e
){
a
(
"o4sL"
)},
"data-v-2b8f96fb"
,
null
).
exports
,
k
=
{
name
:
"envManage"
,
components
:{
navBread
:
i
.
a
,
selectEnv
:
c
.
a
,
fluidList
:
b
,
fusingList
:
_
,
warnSet
:
T
,
newRule
:
g
,
newSet
:
w
},
data
:
function
(){
return
{
navPath
:[{
name
:
"插件管理"
,
path
:
"/pluginManage"
},{
name
:
"AHSH"
,
path
:
"/pluginManage"
}],
activeName
:
"first"
,
search
:
""
,
showdialog
:
!
1
,
pluginId
:
""
,
sceneCode
:
""
,
pluginType
:
0
,
projectList
:[],
projectId
:
""
,
groupList
:[],
groupId
:
""
,
total
:
0
,
currentPage
:
1
,
pageSize
:
20
,
pageSizes
:[
20
,
40
,
60
,
80
],
tableData
:[],
loading
:
!
1
,
showRuleDialog
:
!
1
,
showFlusDialog
:
!
1
,
publishNum
:
0
}},
created
:
function
(){
this
.
pluginId
=
this
.
$route
.
query
.
pluginId
,
this
.
sceneCode
=
this
.
$route
.
query
.
sceneCode
,
this
.
getProjectList
(),
this
.
getList
(),
this
.
getUpdateStatus
()},
methods
:{
handleClick
:
function
(
e
,
t
){
this
.
getList
(),
this
.
getUpdateStatus
()},
goEnvList
:
function
(){
this
.
showdialog
=!
0
,
this
.
pluginId
=
this
.
pluginId
},
closeDialog
:
function
(){
this
.
showdialog
=!
1
},
handleSizeChange
:
function
(
e
){
this
.
pageSize
=
e
,
this
.
getList
()},
handleCurrentChange
:
function
(
e
){
this
.
currentPage
=
e
,
this
.
getList
()},
getChange
:
function
(){
this
.
groupId
=
""
,
this
.
currentPage
=
1
,
this
.
getGroupList
(),
this
.
getList
()},
getSearchList
:
function
(){
"first"
!==
this
.
activeName
&&
"second"
!==
this
.
activeName
||
(
this
.
currentPage
=
1
,
this
.
getGroupList
(),
this
.
getList
())},
getList
:
function
(){
var
e
=
this
,
t
=
""
,
a
=
{};
"first"
===
this
.
activeName
?(
t
=
"/gateway-manage/rule/ratelimiter/list"
,
a
=
{
projectId
:
this
.
projectId
?
this
.
projectId
:
null
,
groupId
:
this
.
groupId
?
this
.
groupId
:
null
,
search
:
this
.
search
?
this
.
search
:
null
,
sceneCode
:
this
.
sceneCode
,
currentPage
:
this
.
currentPage
,
pageSize
:
this
.
pageSize
}):
"second"
===
this
.
activeName
?(
t
=
"/gateway-manage/rule/degrade/list"
,
a
=
{
projectId
:
this
.
projectId
?
this
.
projectId
:
null
,
groupId
:
this
.
groupId
?
this
.
groupId
:
null
,
search
:
this
.
search
?
this
.
search
:
null
,
sceneCode
:
this
.
sceneCode
,
currentPage
:
this
.
currentPage
,
pageSize
:
this
.
pageSize
}):
"third"
===
this
.
activeName
&&
(
t
=
"/gateway-manage/rule/alarm/list"
,
a
=
{
sceneCode
:
this
.
sceneCode
}),
this
.
tableData
=
[],
this
.
loading
=!
0
;
var
r
=
this
;
Object
(
l
.
a
)(
t
,
a
).
then
(
function
(
t
){
if
(
"0000"
==
t
.
data
.
code
){
if
(
"first"
===
e
.
activeName
){
t
.
data
.
result
.
result
?(
e
.
tableData
=
t
.
data
.
result
.
result
,
e
.
total
=
t
.
data
.
result
.
totalCount
):(
e
.
total
=
0
,
e
.
tableData
=
[]);
var
a
=!
0
,
r
=!
1
,
n
=
void
0
;
try
{
for
(
var
o
,
i
=
s
()(
e
.
tableData
);
!
(
a
=
(
o
=
i
.
next
()).
done
);
a
=!
0
){
var
l
=
o
.
value
;
l
.
enableFlag
=
1
===
l
.
enableFlag
}}
catch
(
e
){
r
=!
0
,
n
=
e
}
finally
{
try
{
!
a
&&
i
.
return
&&
i
.
return
()}
finally
{
if
(
r
)
throw
n
}}}
else
if
(
"second"
===
e
.
activeName
){
t
.
data
.
result
.
result
?(
e
.
tableData
=
t
.
data
.
result
.
result
,
e
.
total
=
t
.
data
.
result
.
totalCount
):(
e
.
total
=
0
,
e
.
tableData
=
[]);
var
c
=!
0
,
d
=!
1
,
u
=
void
0
;
try
{
for
(
var
g
,
m
=
s
()(
e
.
tableData
);
!
(
c
=
(
g
=
m
.
next
()).
done
);
c
=!
0
){
var
f
=
g
.
value
;
f
.
enableFlag
=
1
===
f
.
enableFlag
}}
catch
(
e
){
d
=!
0
,
u
=
e
}
finally
{
try
{
!
c
&&
m
.
return
&&
m
.
return
()}
finally
{
if
(
d
)
throw
u
}}}
else
if
(
"third"
===
e
.
activeName
){
t
.
data
.
result
?
e
.
tableData
=
t
.
data
.
result
:
e
.
tableData
=
[];
var
p
=!
0
,
h
=!
1
,
v
=
void
0
;
try
{
for
(
var
b
,
y
=
s
()(
e
.
tableData
);
!
(
p
=
(
b
=
y
.
next
()).
done
);
p
=!
0
){
var
I
=
b
.
value
;
I
.
enableFlag
=
1
===
I
.
enableFlag
,
I
.
editStatus
=!
1
}}
catch
(
e
){
h
=!
0
,
v
=
e
}
finally
{
try
{
!
p
&&
y
.
return
&&
y
.
return
()}
finally
{
if
(
h
)
throw
v
}}}
e
.
loading
=!
1
}
else
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
r
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
changeFlag
:
function
(
e
){
var
t
=
this
,
a
=
this
,
r
=
{
alarmType
:
e
.
alarmType
,
enableFlag
:
e
.
enableFlag
?
1
:
0
,
sceneCode
:
this
.
sceneCode
};
Object
(
l
.
a
)(
"/gateway-manage/rule/alarm/enable"
,
r
).
then
(
function
(
a
){
"0000"
==
a
.
data
.
code
?
t
.
getList
():(
e
.
enableFlag
=!
e
.
enableFlag
,
t
.
$message
.
error
(
a
.
data
.
message
))}).
catch
(
function
(
e
){
a
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
getProjectList
:
function
(){
var
e
=
this
,
t
=
this
;
Object
(
l
.
a
)(
"/gateway-manage/plugin/interface/tree"
,{}).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?
t
.
data
.
result
?
e
.
projectList
=
t
.
data
.
result
:
e
.
projectList
=
[]:
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
t
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
getGroupList
:
function
(){
var
e
=
this
,
t
=
this
,
a
=
{
type
:
0
,
id
:
this
.
projectId
};
Object
(
l
.
a
)(
"/gateway-manage/plugin/interface/tree"
,
a
).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?
t
.
data
.
result
?
e
.
groupList
=
t
.
data
.
result
:
e
.
groupList
=
[]:
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
t
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})},
addFluid
:
function
(){
this
.
showRuleDialog
=!
0
},
cancelAdd
:
function
(){
this
.
showRuleDialog
=!
1
},
addFusing
:
function
(){
this
.
showFlusDialog
=!
0
},
cancelAddFlus
:
function
(){
this
.
showFlusDialog
=!
1
},
publish
:
function
(){
var
e
=
this
,
t
=
{
sceneCode
:
this
.
sceneCode
},
a
=
""
;
"first"
===
this
.
activeName
?
a
=
"/gateway-manage/rule/ratelimiter/publish"
:
"second"
===
this
.
activeName
&&
(
a
=
"/gateway-manage/rule/degrade/publish"
);
var
r
=
this
;
this
.
$confirm
(
"确定要发布吗?"
,
"提示"
,{
confirmButtonText
:
"确定"
,
cancelButtonText
:
"取消"
,
type
:
"warning"
}).
then
(
function
(){
Object
(
l
.
a
)(
a
,
t
).
then
(
function
(
t
){
"0000"
==
t
.
data
.
code
?(
e
.
getList
(),
e
.
getUpdateStatus
()):
e
.
$message
.
error
(
t
.
data
.
message
)}).
catch
(
function
(
e
){
r
.
$message
.
error
({
duration
:
1
e3
,
message
:
e
.
message
})})}).
catch
(
function
(){
e
.
$message
({
type
:
"info"
,
message
:
"已取消发布"
})})},
getUpdateStatus
:
function
(
e
){
var
t
=
this
,
a
=
{
sceneCode
:
e
||
this
.
sceneCode
},
r
=
""
;
r
=
"first"
===
this
.
activeName
?
"/gateway-manage/rule/ratelimiter/has/edit"
:
"/gateway-manage/rule/degrade/has/edit"
,
Object
(
l
.
a
)(
r
,
a
).
then
(
function
(
e
){
"0000"
==
e
.
data
.
code
?
t
.
publishNum
=
e
.
data
.
result
:
t
.
$message
.
error
(
e
.
data
.
message
)})}},
watch
:
n
()({
$route
:{
handler
:
function
(
e
,
t
){},
deep
:
!
0
}},
"$route"
,
function
(
e
,
t
){
this
.
pluginId
=
this
.
$route
.
query
.
pluginId
,
this
.
sceneCode
=
this
.
$route
.
query
.
sceneCode
,
this
.
getList
(),
this
.
getUpdateStatus
()})},
N
=
{
render
:
function
(){
var
e
=
this
,
t
=
e
.
$createElement
,
a
=
e
.
_self
.
_c
||
t
;
return
a
(
"div"
,{
staticClass
:
"api-body-content border-box"
},[
a
(
"div"
,{
staticClass
:
"common-nav"
},[
a
(
"nav-bread"
,{
attrs
:{
navPath
:
e
.
navPath
}}),
e
.
_v
(
" "
),
a
(
"div"
,{
staticClass
:
"change-env"
,
on
:{
click
:
e
.
goEnvList
}},[
a
(
"span"
,[
e
.
_v
(
"切换环境"
)]),
a
(
"i"
,{
staticClass
:
"iconfont iconicon-qihuan"
,
on
:{
click
:
function
(
t
){
return
e
.
goEnvList
(
e
.
item
)}}})])],
1
),
e
.
_v
(
" "
),
a
(
"div"
,{
staticClass
:
"api-body-main common-body-main border-box"
},[
a
(
"div"
,{
staticClass
:
"api-main-content border-box"
},[
a
(
"div"
,{
staticClass
:
"env-tab-wrap"
},[
a
(
"el-tabs"
,{
on
:{
"tab-click"
:
e
.
handleClick
},
model
:{
value
:
e
.
activeName
,
callback
:
function
(
t
){
e
.
activeName
=
t
},
expression
:
"activeName"
}},[
"third"
!==
e
.
activeName
?
a
(
"div"
,{
staticClass
:
"search-box"
},[
a
(
"div"
,{
staticClass
:
"left"
},[
a
(
"el-input"
,{
staticClass
:
"w-320"
,
attrs
:{
placeholder
:
"first"
===
e
.
activeName
?
"请输入接口名称/流控ID"
:
"请输入接口名称/熔断ID"
,
"prefix-icon"
:
"el-icon-search"
,
clearable
:
""
},
on
:{
clear
:
function
(
t
){
return
e
.
getSearchList
()}},
nativeOn
:{
keyup
:
function
(
t
){
return
!
t
.
type
.
indexOf
(
"key"
)
&&
e
.
_k
(
t
.
keyCode
,
"enter"
,
13
,
t
.
key
,
"Enter"
)?
null
:
e
.
getSearchList
()}},
model
:{
value
:
e
.
search
,
callback
:
function
(
t
){
e
.
search
=
t
},
expression
:
"search"
}}),
e
.
_v
(
" "
),
a
(
"el-select"
,{
staticClass
:
"w-140 marginLeft10"
,
staticStyle
:{
display
:
"inline-block"
},
attrs
:{
placeholder
:
"请选择项目"
,
size
:
"small"
,
clearable
:
""
},
on
:{
change
:
e
.
getChange
},
model
:{
value
:
e
.
projectId
,
callback
:
function
(
t
){
e
.
projectId
=
t
},
expression
:
"projectId"
}},
e
.
_l
(
e
.
projectList
,
function
(
e
){
return
a
(
"el-option"
,{
key
:
e
.
id
,
attrs
:{
label
:
e
.
name
,
value
:
e
.
id
}})}),
1
),
e
.
_v
(
" "
),
a
(
"el-select"
,{
staticClass
:
"w-140 marginLeft10"
,
staticStyle
:{
display
:
"inline-block"
},
attrs
:{
placeholder
:
"请选择分组"
,
size
:
"small"
,
clearable
:
""
,
disabled
:
""
===
e
.
projectId
},
on
:{
change
:
e
.
getSearchList
},
model
:{
value
:
e
.
groupId
,
callback
:
function
(
t
){
e
.
groupId
=
t
},
expression
:
"groupId"
}},
e
.
_l
(
e
.
groupList
,
function
(
e
){
return
a
(
"el-option"
,{
key
:
e
.
id
,
attrs
:{
label
:
e
.
name
,
value
:
e
.
id
}})}),
1
)],
1
),
e
.
_v
(
" "
),
a
(
"div"
,[
"first"
===
e
.
activeName
?
a
(
"el-button"
,{
attrs
:{
type
:
"primary"
},
on
:{
click
:
e
.
addFluid
}},[
e
.
_v
(
"新建流控规则"
)]):
e
.
_e
(),
e
.
_v
(
" "
),
"second"
===
e
.
activeName
?
a
(
"el-button"
,{
attrs
:{
type
:
"primary"
},
on
:{
click
:
e
.
addFusing
}},[
e
.
_v
(
"新建熔断规则"
)]):
e
.
_e
(),
e
.
_v
(
" "
),
a
(
"el-button"
,{
attrs
:{
type
:
"primary"
,
disabled
:
e
.
publishNum
<=
0
},
on
:{
click
:
e
.
publish
}},[
e
.
_v
(
e
.
_s
(
e
.
publishNum
>
0
?
"待发布("
+
e
.
publishNum
+
")"
:
"发布"
))])],
1
)]):
e
.
_e
(),
e
.
_v
(
" "
),
a
(
"el-tab-pane"
,{
attrs
:{
label
:
"流控规则"
,
name
:
"first"
}},[
"first"
===
e
.
activeName
?
a
(
"fluidList"
,{
directives
:[{
name
:
"loading"
,
rawName
:
"v-loading"
,
value
:
e
.
loading
,
expression
:
"loading"
}],
attrs
:{
tableData
:
e
.
tableData
,
sceneCode
:
e
.
sceneCode
},
on
:{
getList
:
e
.
getList
}}):
e
.
_e
()],
1
),
e
.
_v
(
" "
),
a
(
"el-tab-pane"
,{
attrs
:{
label
:
"熔断规则"
,
name
:
"second"
}},[
"second"
===
e
.
activeName
?
a
(
"fusingList"
,{
directives
:[{
name
:
"loading"
,
rawName
:
"v-loading"
,
value
:
e
.
loading
,
expression
:
"loading"
}],
attrs
:{
tableData
:
e
.
tableData
,
sceneCode
:
e
.
sceneCode
},
on
:{
getList
:
e
.
getList
}}):
e
.
_e
()],
1
),
e
.
_v
(
" "
),
a
(
"el-tab-pane"
,{
attrs
:{
label
:
"告警配置"
,
name
:
"third"
}},[
"third"
===
e
.
activeName
?
a
(
"warnSet"
,{
directives
:[{
name
:
"loading"
,
rawName
:
"v-loading"
,
value
:
e
.
loading
,
expression
:
"loading"
}],
attrs
:{
tableData
:
e
.
tableData
,
sceneCode
:
e
.
sceneCode
},
on
:{
getList
:
e
.
getList
,
changeFlag
:
e
.
changeFlag
}}):
e
.
_e
()],
1
)],
1
),
e
.
_v
(
" "
),
0
===
e
.
total
||
"first"
!==
e
.
activeName
&&
"second"
!==
e
.
activeName
?
e
.
_e
():
a
(
"div"
,{
staticStyle
:{
"text-align"
:
"right"
,
"margin-top"
:
"20px"
}},[
a
(
"el-pagination"
,{
attrs
:{
background
:
""
,
"current-page"
:
e
.
currentPage
,
"page-sizes"
:
e
.
pageSizes
,
"page-size"
:
e
.
pageSize
,
layout
:
"total, sizes, prev, pager, next"
,
total
:
e
.
total
},
on
:{
"size-change"
:
e
.
handleSizeChange
,
"current-change"
:
e
.
handleCurrentChange
}})],
1
)],
1
)])]),
e
.
_v
(
" "
),
e
.
showdialog
?
a
(
"selectEnv"
,{
attrs
:{
pluginId
:
e
.
pluginId
,
pluginType
:
e
.
pluginType
},
on
:{
closeDialog
:
e
.
closeDialog
}}):
e
.
_e
(),
e
.
_v
(
" "
),
e
.
showRuleDialog
?
a
(
"newRule"
,{
attrs
:{
sceneCode
:
e
.
sceneCode
},
on
:{
cancelAdd
:
e
.
cancelAdd
,
getList
:
e
.
getList
}}):
e
.
_e
(),
e
.
_v
(
" "
),
e
.
showFlusDialog
?
a
(
"newSet"
,{
attrs
:{
sceneCode
:
e
.
sceneCode
},
on
:{
cancelAddFlus
:
e
.
cancelAddFlus
,
getList
:
e
.
getList
}}):
e
.
_e
()],
1
)},
staticRenderFns
:[]};
var
x
=
a
(
"VU/8"
)(
k
,
N
,
!
1
,
function
(
e
){
a
(
"sAf0"
)},
"data-v-c24c625a"
,
null
);
t
.
default
=
x
.
exports
},
JQyN
:
function
(
e
,
t
){},
LmEw
:
function
(
e
,
t
){},
PbPA
:
function
(
e
,
t
){},
RV9G
:
function
(
e
,
t
){},
o4sL
:
function
(
e
,
t
){},
sAf0
:
function
(
e
,
t
){},
vgET
:
function
(
e
,
t
){
e
.
exports
=
"data:image/png;base64,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"
}});
\ No newline at end of file
dist/static/js/manifest.b90c9ba8897ae6d21a51.js
deleted
100644 → 0
View file @
ef5c8b0c
!
function
(
e
){
var
n
=
window
.
webpackJsonp
;
window
.
webpackJsonp
=
function
(
r
,
c
,
o
){
for
(
var
f
,
d
,
b
,
i
=
0
,
u
=
[];
i
<
r
.
length
;
i
++
)
d
=
r
[
i
],
a
[
d
]
&&
u
.
push
(
a
[
d
][
0
]),
a
[
d
]
=
0
;
for
(
f
in
c
)
Object
.
prototype
.
hasOwnProperty
.
call
(
c
,
f
)
&&
(
e
[
f
]
=
c
[
f
]);
for
(
n
&&
n
(
r
,
c
,
o
);
u
.
length
;)
u
.
shift
()();
if
(
o
)
for
(
i
=
0
;
i
<
o
.
length
;
i
++
)
b
=
t
(
t
.
s
=
o
[
i
]);
return
b
};
var
r
=
{},
a
=
{
23
:
0
};
function
t
(
n
){
if
(
r
[
n
])
return
r
[
n
].
exports
;
var
a
=
r
[
n
]
=
{
i
:
n
,
l
:
!
1
,
exports
:{}};
return
e
[
n
].
call
(
a
.
exports
,
a
,
a
.
exports
,
t
),
a
.
l
=!
0
,
a
.
exports
}
t
.
e
=
function
(
e
){
var
n
=
a
[
e
];
if
(
0
===
n
)
return
new
Promise
(
function
(
e
){
e
()});
if
(
n
)
return
n
[
2
];
var
r
=
new
Promise
(
function
(
r
,
t
){
n
=
a
[
e
]
=
[
r
,
t
]});
n
[
2
]
=
r
;
var
c
=
document
.
getElementsByTagName
(
"head"
)[
0
],
o
=
document
.
createElement
(
"script"
);
o
.
type
=
"text/javascript"
,
o
.
charset
=
"utf-8"
,
o
.
async
=!
0
,
o
.
timeout
=
12
e4
,
t
.
nc
&&
o
.
setAttribute
(
"nonce"
,
t
.
nc
),
o
.
src
=
t
.
p
+
"static/js/"
+
e
+
"."
+
{
0
:
"90184a99cbf200fc5420"
,
1
:
"490562478be660678b4c"
,
2
:
"aba954d032af31777ca2"
,
3
:
"891b203d9fe7a8561dfd"
,
4
:
"091de7fadbabb3b3a37a"
,
5
:
"326fb42830c68b115dac"
,
6
:
"f4c9cb7fb0fea566317f"
,
7
:
"a1935be11e77d5f2c5b4"
,
8
:
"8121d39547813d60ebc0"
,
9
:
"b3deccff7d55a154a299"
,
10
:
"0fa1f876e10fcdf5c8bc"
,
11
:
"722834da6c9a43c2cd06"
,
12
:
"67847cd5371b700c9f72"
,
13
:
"28aedb2f2a8862416b38"
,
14
:
"87bbee3da6a929830283"
,
15
:
"2854ebb8d89f105b01a8"
,
16
:
"ed20f73ba065fa5cfb56"
,
17
:
"7654e050c5e95259b1af"
,
18
:
"37321ffca9347a60b988"
,
19
:
"76545794ef370769a689"
,
20
:
"1e2a9dda654bf5adc16a"
}[
e
]
+
".js"
;
var
f
=
setTimeout
(
d
,
12
e4
);
function
d
(){
o
.
onerror
=
o
.
onload
=
null
,
clearTimeout
(
f
);
var
n
=
a
[
e
];
0
!==
n
&&
(
n
&&
n
[
1
](
new
Error
(
"Loading chunk "
+
e
+
" failed."
)),
a
[
e
]
=
void
0
)}
return
o
.
onerror
=
o
.
onload
=
d
,
c
.
appendChild
(
o
),
r
},
t
.
m
=
e
,
t
.
c
=
r
,
t
.
d
=
function
(
e
,
n
,
r
){
t
.
o
(
e
,
n
)
||
Object
.
defineProperty
(
e
,
n
,{
configurable
:
!
1
,
enumerable
:
!
0
,
get
:
r
})},
t
.
n
=
function
(
e
){
var
n
=
e
&&
e
.
__esModule
?
function
(){
return
e
.
default
}:
function
(){
return
e
};
return
t
.
d
(
n
,
"a"
,
n
),
n
},
t
.
o
=
function
(
e
,
n
){
return
Object
.
prototype
.
hasOwnProperty
.
call
(
e
,
n
)},
t
.
p
=
"./"
,
t
.
oe
=
function
(
e
){
throw
console
.
error
(
e
),
e
}}([]);
\ No newline at end of file
dist/static/js/manifest.c79a13333675abfa1c43.js
0 → 100644
View file @
f1ad9990
!
function
(
e
){
var
n
=
window
.
webpackJsonp
;
window
.
webpackJsonp
=
function
(
r
,
c
,
o
){
for
(
var
f
,
d
,
i
,
u
=
0
,
b
=
[];
u
<
r
.
length
;
u
++
)
d
=
r
[
u
],
t
[
d
]
&&
b
.
push
(
t
[
d
][
0
]),
t
[
d
]
=
0
;
for
(
f
in
c
)
Object
.
prototype
.
hasOwnProperty
.
call
(
c
,
f
)
&&
(
e
[
f
]
=
c
[
f
]);
for
(
n
&&
n
(
r
,
c
,
o
);
b
.
length
;)
b
.
shift
()();
if
(
o
)
for
(
u
=
0
;
u
<
o
.
length
;
u
++
)
i
=
a
(
a
.
s
=
o
[
u
]);
return
i
};
var
r
=
{},
t
=
{
23
:
0
};
function
a
(
n
){
if
(
r
[
n
])
return
r
[
n
].
exports
;
var
t
=
r
[
n
]
=
{
i
:
n
,
l
:
!
1
,
exports
:{}};
return
e
[
n
].
call
(
t
.
exports
,
t
,
t
.
exports
,
a
),
t
.
l
=!
0
,
t
.
exports
}
a
.
e
=
function
(
e
){
var
n
=
t
[
e
];
if
(
0
===
n
)
return
new
Promise
(
function
(
e
){
e
()});
if
(
n
)
return
n
[
2
];
var
r
=
new
Promise
(
function
(
r
,
a
){
n
=
t
[
e
]
=
[
r
,
a
]});
n
[
2
]
=
r
;
var
c
=
document
.
getElementsByTagName
(
"head"
)[
0
],
o
=
document
.
createElement
(
"script"
);
o
.
type
=
"text/javascript"
,
o
.
charset
=
"utf-8"
,
o
.
async
=!
0
,
o
.
timeout
=
12
e4
,
a
.
nc
&&
o
.
setAttribute
(
"nonce"
,
a
.
nc
),
o
.
src
=
a
.
p
+
"static/js/"
+
e
+
"."
+
{
0
:
"90184a99cbf200fc5420"
,
1
:
"490562478be660678b4c"
,
2
:
"aba954d032af31777ca2"
,
3
:
"891b203d9fe7a8561dfd"
,
4
:
"708117be04c0644c10c0"
,
5
:
"326fb42830c68b115dac"
,
6
:
"f4c9cb7fb0fea566317f"
,
7
:
"a1935be11e77d5f2c5b4"
,
8
:
"8121d39547813d60ebc0"
,
9
:
"b3deccff7d55a154a299"
,
10
:
"0fa1f876e10fcdf5c8bc"
,
11
:
"722834da6c9a43c2cd06"
,
12
:
"67847cd5371b700c9f72"
,
13
:
"28aedb2f2a8862416b38"
,
14
:
"87bbee3da6a929830283"
,
15
:
"2854ebb8d89f105b01a8"
,
16
:
"ed20f73ba065fa5cfb56"
,
17
:
"7654e050c5e95259b1af"
,
18
:
"37321ffca9347a60b988"
,
19
:
"76545794ef370769a689"
,
20
:
"1e2a9dda654bf5adc16a"
}[
e
]
+
".js"
;
var
f
=
setTimeout
(
d
,
12
e4
);
function
d
(){
o
.
onerror
=
o
.
onload
=
null
,
clearTimeout
(
f
);
var
n
=
t
[
e
];
0
!==
n
&&
(
n
&&
n
[
1
](
new
Error
(
"Loading chunk "
+
e
+
" failed."
)),
t
[
e
]
=
void
0
)}
return
o
.
onerror
=
o
.
onload
=
d
,
c
.
appendChild
(
o
),
r
},
a
.
m
=
e
,
a
.
c
=
r
,
a
.
d
=
function
(
e
,
n
,
r
){
a
.
o
(
e
,
n
)
||
Object
.
defineProperty
(
e
,
n
,{
configurable
:
!
1
,
enumerable
:
!
0
,
get
:
r
})},
a
.
n
=
function
(
e
){
var
n
=
e
&&
e
.
__esModule
?
function
(){
return
e
.
default
}:
function
(){
return
e
};
return
a
.
d
(
n
,
"a"
,
n
),
n
},
a
.
o
=
function
(
e
,
n
){
return
Object
.
prototype
.
hasOwnProperty
.
call
(
e
,
n
)},
a
.
p
=
"./"
,
a
.
oe
=
function
(
e
){
throw
console
.
error
(
e
),
e
}}([]);
\ No newline at end of file
src/components/plug/fluid-rule.vue
View file @
f1ad9990
...
...
@@ -27,6 +27,12 @@
<p
v-if=
"scope.row.strategy === 0"
>
快速失败
</p>
</
template
>
</el-table-column>
<el-table-column
prop=
"grade"
label=
"分布式限流"
>
<
template
slot-scope=
"scope"
>
<p
v-if=
"scope.row.distFlag === 1"
>
是
</p>
<p
v-if=
"scope.row.distFlag === 0"
>
否
</p>
</
template
>
</el-table-column>
<el-table-column
prop=
"enableFlag"
label=
"开启状态"
>
<
template
slot-scope=
"scope"
>
<el-switch
v-model=
"scope.row.enableFlag"
@
change=
"changeFlag(scope.row)"
>
</el-switch>
...
...
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