|
@@ -18,7 +18,11 @@
|
|
|
<div class="header-title">
|
|
|
<span class="title-id">TASK-{{ form_query.id }}</span>
|
|
|
<el-tooltip class="item" effect="dark" :content="form_query.name" placement="bottom">
|
|
|
- <span class="title-name">{{ form_query.name }}</span>
|
|
|
+ <span
|
|
|
+ v-clipboard:copy="form_query.name"
|
|
|
+ v-clipboard:success="copyName"
|
|
|
+ class="title-name"
|
|
|
+ >{{ form_query.name }}</span>
|
|
|
</el-tooltip>
|
|
|
</div>
|
|
|
<el-dropdown placement="bottom" @command="updateStatus">
|
|
@@ -273,6 +277,9 @@
|
|
|
</template>
|
|
|
<script>
|
|
|
const _ = require('lodash')
|
|
|
+import Vue from 'vue'
|
|
|
+import VueClipboard from 'vue-clipboard2'
|
|
|
+Vue.use(VueClipboard)
|
|
|
import {
|
|
|
taskGet,
|
|
|
configShowTaskEnum,
|
|
@@ -608,6 +615,9 @@ export default {
|
|
|
},
|
|
|
returnEmpty(val) {
|
|
|
return val || ''
|
|
|
+ },
|
|
|
+ copyName(name) { // 复制名字
|
|
|
+ this.$message({ message: '复制成功', type: 'success', duration: 1000, offset: 150 })
|
|
|
}
|
|
|
}
|
|
|
}
|
|
@@ -623,6 +633,9 @@ export default {
|
|
|
}
|
|
|
.main-header {
|
|
|
@include main-header;
|
|
|
+ .title-name {
|
|
|
+ cursor: pointer;
|
|
|
+ }
|
|
|
}
|
|
|
.main-header::after {
|
|
|
@include main-header-after;
|