Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
phsl
/
admin
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Unverified
Commit
7b7ce96c
authored
Jan 04, 2025
by
芋道源码
Committed by
Gitee
Jan 04, 2025
Browse files
Options
Browse Files
Download
Plain Diff
!631 【功能完善】文件列表: 添加复制链接功能
Merge pull request !631 from jinmh/master
parents
e508da7f
74b62bf0
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
0 deletions
+14
-0
src/views/infra/file/index.vue
+14
-0
No files found.
src/views/infra/file/index.vue
View file @
7b7ce96c
...
...
@@ -97,6 +97,13 @@
<
template
#
default=
"scope"
>
<el-button
link
type=
"primary"
@
click=
"copyToClipboard(scope.row.url)"
>
复制链接
</el-button>
<el-button
link
type=
"danger"
@
click=
"handleDelete(scope.row.id)"
v-hasPermi=
"['infra:file:delete']"
...
...
@@ -172,6 +179,13 @@ const openForm = () => {
formRef
.
value
.
open
()
}
/** 复制到剪贴板方法 */
const
copyToClipboard
=
(
text
:
string
)
=>
{
navigator
.
clipboard
.
writeText
(
text
).
then
(()
=>
{
message
.
success
(
'复制成功'
)
})
}
/** 删除按钮操作 */
const
handleDelete
=
async
(
id
:
number
)
=>
{
try
{
...
...
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