Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
qa-platform-ui
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
QA
qa-platform-ui
Commits
4d7e8596
Commit
4d7e8596
authored
May 18, 2021
by
黎博
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
新增清除数据,修改新增jira相关
parent
39b07fea
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
92 additions
and
20 deletions
+92
-20
effect.js
src/api/effect.js
+8
-0
index.js
src/router/index.js
+6
-1
ClearCache.vue
src/views/effect/ClearCache.vue
+15
-13
ClearData.vue
src/views/effect/ClearData.vue
+44
-0
menu.json
src/views/layout/leftAside/menu.json
+19
-6
No files found.
src/api/effect.js
View file @
4d7e8596
...
...
@@ -55,3 +55,11 @@ export function clearCache(queryInfo) {
params
:
queryInfo
})
}
export
function
clearData
(
dataInfo
)
{
return
request
({
url
:
'
/cleardata
'
,
method
:
'
get
'
,
params
:
dataInfo
})
}
src/router/index.js
View file @
4d7e8596
...
...
@@ -17,6 +17,7 @@ import LoginWhiteList from '../views/effect/LoginWhiteList'
import
JiraNotify
from
'
../views/jira/Notify
'
import
RiskControl
from
'
../views/vcc/RiskControl
'
import
ClearCache
from
'
../views/effect/ClearCache
'
import
ClearData
from
'
../views/effect/ClearData
'
Vue
.
use
(
Router
)
...
...
@@ -81,7 +82,7 @@ const router = new Router({
component
:
LoginWhiteList
},
{
'
path
'
:
'
/
effect/
jira/notify
'
,
'
path
'
:
'
/jira/notify
'
,
component
:
JiraNotify
},
{
...
...
@@ -91,6 +92,10 @@ const router = new Router({
{
'
path
'
:
'
/effect/clearcache
'
,
component
:
ClearCache
},
{
'
path
'
:
'
/effect/cleardata
'
,
component
:
ClearData
}
]
}
...
...
src/views/effect/ClearCache.vue
View file @
4d7e8596
<
template
>
<div>
<el-table
:data=
"cacheList"
border
style=
"width: 100%"
>
<el-table-column
type=
"index"
width=
"50"
></el-table-column>
<el-table-column
prop=
"name"
label=
"描述"
width=
"180"
>
</el-table-column>
<el-table-column
prop=
"url"
label=
"地址"
width=
"500"
>
</el-table-column>
<el-table-column
label=
"操作"
>
<slot
slot-scope=
"scope"
>
<el-button
type=
"primary"
@
click=
"clearCache(scope.row)"
>
清除缓存
</el-button>
</slot>
</el-table-column>
</el-table>
<el-card>
<el-table
:data=
"cacheList"
border
style=
"width: 100%"
>
<el-table-column
type=
"index"
width=
"50"
></el-table-column>
<el-table-column
prop=
"name"
label=
"描述"
width=
"180"
>
</el-table-column>
<el-table-column
prop=
"url"
label=
"地址"
width=
"500"
>
</el-table-column>
<el-table-column
label=
"操作"
>
<slot
slot-scope=
"scope"
>
<el-button
type=
"primary"
@
click=
"clearCache(scope.row)"
>
清除缓存
</el-button>
</slot>
</el-table-column>
</el-table>
<!--
<div
class=
"result"
>
清除结果:
{{
clearResult
}}
</div>
-->
<!--
<div
class=
"result"
>
清除结果:
{{
clearResult
}}
</div>
-->
</el-card>
</div>
</
template
>
...
...
src/views/effect/ClearData.vue
0 → 100644
View file @
4d7e8596
<
template
>
<div>
<!--
<p>
羊小咩相关数据清除
</p>
-->
<el-card>
手机号:
<el-input
v-model=
"clearParams.phoneNo"
placeholder=
"请输入手机号"
maxlength=
"11"
></el-input>
<el-button
type=
"primary"
icon=
"el-icon-brush"
@
click=
"clearYxmData"
>
清除数据
</el-button>
</el-card>
</div>
</
template
>
<
script
>
import
{
clearData
}
from
'
@/api/effect
'
export
default
{
data
()
{
return
{
clearParams
:
{
phoneNo
:
''
,
namespace
:
window
.
sessionStorage
.
getItem
(
'
env
'
)
}
}
},
methods
:
{
clearYxmData
()
{
clearData
(
this
.
clearParams
).
then
((
resp
)
=>
{
if
(
resp
.
data
.
data
===
true
)
{
this
.
$message
.
success
(
'
数据清除成功!
'
)
}
else
{
return
this
.
$message
.
error
(
'
数据清除失败!
'
)
}
}).
catch
((
error
)
=>
{
console
.
log
(
error
)
return
this
.
$message
.
error
(
'
数据清除失败,请检查环境或是否正确!
'
)
})
}
}
}
</
script
>
<
style
lang=
"less"
scoped
>
.el-input {
width: 200px;
margin-right: 20px;
}
</
style
>
src/views/layout/leftAside/menu.json
View file @
4d7e8596
...
...
@@ -88,17 +88,30 @@
},
{
"id"
:
4
,
"title"
:
"jira-钉钉通知"
,
"icon"
:
"el-icon-ice-tea"
,
"path"
:
"/effect/jira/notify"
},
{
"id"
:
5
,
"title"
:
"缓存清理"
,
"icon"
:
"el-icon-milk-tea"
,
"path"
:
"/effect/clearcache"
},
{
"id"
:
5
,
"title"
:
"数据清理"
,
"icon"
:
"el-icon-water-cup"
,
"path"
:
"/effect/cleardata"
}
]
},
{
"id"
:
6
,
"title"
:
"Jira相关"
,
"icon"
:
"el-icon-hot-water"
,
"child"
:
[
{
"id"
:
1
,
"title"
:
"jira-钉钉通知"
,
"icon"
:
"el-icon-ice-tea"
,
"path"
:
"/jira/notify"
}
]
}
]
}
\ No newline at end of file
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