diff --git a/package.json b/package.json index 72f160e..b43d785 100644 --- a/package.json +++ b/package.json @@ -44,6 +44,7 @@ "splitpanes": "2.4.1", "vant": "^2.13.9", "vue": "2.6.12", + "vue-clipboard2": "^0.3.3", "vue-count-to": "1.0.13", "vue-cropper": "0.5.5", "vue-router": "3.4.9", diff --git a/src/assets/images/app/copy.png b/src/assets/images/app/copy.png new file mode 100644 index 0000000..8de33ce Binary files /dev/null and b/src/assets/images/app/copy.png differ diff --git a/src/main.js b/src/main.js index 95200ba..3b67d8c 100644 --- a/src/main.js +++ b/src/main.js @@ -36,6 +36,7 @@ import ImagePreview from "@/components/ImagePreview" import DictTag from '@/components/DictTag' // 字典数据组件 import DictData from '@/components/DictData' +import VueClipboard from 'vue-clipboard2' // Vant 引用 import Vant from 'vant'; import 'vant/lib/index.css'; @@ -65,6 +66,7 @@ Vue.component('ImagePreview', ImagePreview) Vue.use(Vant) Vue.use(directive) Vue.use(plugins) +Vue.use(VueClipboard) DictData.install() /** diff --git a/src/views/app/project/list.vue b/src/views/app/project/list.vue index cc43b73..dad80fd 100644 --- a/src/views/app/project/list.vue +++ b/src/views/app/project/list.vue @@ -17,12 +17,13 @@
-
+
+
-
{{item.dkbm}}
-
+

{{item.dkbm}}

+
-
+
{{item.dkmc}}
{{item.scmjm}}
@@ -117,6 +118,13 @@ this.surveyStatus = '调查状态'; this.queryParams.surveyStatus = ''; }, + onCopy (e) { + this.$message.success("内容已复制到剪切板!") + }, +// 复制失败时的回调函数 + onError (e) { + this.$message.error("抱歉,复制失败!") + }, /** 删除按钮操作 */ handleDelete(row) { const fids = row.fid || this.ids @@ -177,6 +185,11 @@ text-overflow: ellipsis; white-space: nowrap; padding-right: 20px; + display: flex; + align-items: center; + img{ + margin-left: 5px; + } } .describe{ font-size: 14px; diff --git a/src/views/app/project/operate_edit.vue b/src/views/app/project/operate_edit.vue index ea7d8be..ecf2d8f 100644 --- a/src/views/app/project/operate_edit.vue +++ b/src/views/app/project/operate_edit.vue @@ -178,6 +178,7 @@ this.form.sfqdht = '1'; this.form.surveyStatusText = '已调查'; this.form.surveyStatus = '2'; + this.form.jymj = 0; }) } // getInfoByImportCode(response.data.importCode).then((res) => {