pull/25/head
ruibaby 2019-06-21 23:17:00 +08:00
parent fcf427d9fa
commit eb7ceab7e6
2 changed files with 35 additions and 12 deletions

View File

@ -91,11 +91,11 @@
<a-list-item-meta :description="attachment.path"> <a-list-item-meta :description="attachment.path">
<span slot="title"> <span slot="title">
普通链接 普通链接
<a href="javascript:void(0);"> <a
<a-icon href="javascript:void(0);"
type="copy"
@click="handleCopyNormalLink" @click="handleCopyNormalLink"
/> >
<a-icon type="copy" />
</a> </a>
</span> </span>
</a-list-item-meta> </a-list-item-meta>
@ -105,11 +105,11 @@
<span slot="description">![{{ attachment.name }}]({{ attachment.path }})</span> <span slot="description">![{{ attachment.name }}]({{ attachment.path }})</span>
<span slot="title"> <span slot="title">
Markdown 格式 Markdown 格式
<a href="javascript:void(0);"> <a
<a-icon href="javascript:void(0);"
type="copy"
@click="handleCopyMarkdownLink" @click="handleCopyMarkdownLink"
/> >
<a-icon type="copy" />
</a> </a>
</span> </span>
</a-list-item-meta> </a-list-item-meta>
@ -118,7 +118,7 @@
</a-skeleton> </a-skeleton>
</a-col> </a-col>
</a-row> </a-row>
<a-divider class="divider-transparent"/> <a-divider class="divider-transparent" />
<div class="bottom-control"> <div class="bottom-control">
<a-popconfirm <a-popconfirm
title="你确定要添加到图库?" title="你确定要添加到图库?"

View File

@ -4,10 +4,18 @@
<a-col :span="24"> <a-col :span="24">
<a-card :bordered="false"> <a-card :bordered="false">
<a-card <a-card
title="环境信息"
:bordered="false" :bordered="false"
class="environment-info" class="environment-info"
> >
<template slot="title">
环境信息
<a
href="javascript:void(0);"
@click="handleCopyEnvironments"
>
<a-icon type="copy" />
</a>
</template>
<a-popconfirm <a-popconfirm
slot="extra" slot="extra"
placement="left" placement="left"
@ -202,6 +210,21 @@ export default {
.finally(() => { .finally(() => {
this.updating = false this.updating = false
}) })
},
handleCopyEnvironments() {
const text = `Server 版本:${this.environments.version}
Admin 版本${this.adminVersion}
数据库${this.environments.database}
运行模式${this.environments.mode}`
this.$copyText(text)
.then(message => {
console.log('copy', message)
this.$message.success('复制成功!')
})
.catch(err => {
console.log('copy.err', err)
this.$message.error('复制失败!')
})
} }
} }
} }