diff --git a/src/frontend/admin/src/components/naColOperation/index.vue b/src/frontend/admin/src/components/naColOperation/index.vue index 29a08091..6bfb9e71 100644 --- a/src/frontend/admin/src/components/naColOperation/index.vue +++ b/src/frontend/admin/src/components/naColOperation/index.vue @@ -18,8 +18,14 @@ size="small"> - {{ item.title }} + diff --git a/src/frontend/admin/src/views/sys/doc/list/index.vue b/src/frontend/admin/src/views/sys/doc/list/index.vue index afbf0e42..4a970a45 100644 --- a/src/frontend/admin/src/views/sys/doc/list/index.vue +++ b/src/frontend/admin/src/views/sys/doc/list/index.vue @@ -48,7 +48,7 @@
@@ -107,23 +107,30 @@ + width="180" /> @@ -232,7 +239,21 @@ export default { this.$refs.table.upData() }, - + async share(row) { + const textarea = document.createElement('textarea') + textarea.readOnly = 'readonly' + textarea.style.position = 'absolute' + textarea.style.left = '-9999px' + textarea.value = window.location.origin + `/guest/view-doc/${row.id}` + document.body.appendChild(textarea) + textarea.select() + textarea.setSelectionRange(0, textarea.value.length) + const result = document.execCommand('Copy') + if (result) { + this.$message.success(this.$t('文档链接已复制')) + } + document.body.removeChild(textarea) + }, //删除 async rowDel(row) { try {