From 3e7914ac910d705a19a9c4bb96f769080e342a0e Mon Sep 17 00:00:00 2001 From: lb Date: Tue, 17 Oct 2023 17:02:33 +0800 Subject: [PATCH] update ui --- src/assets/icons/svg/icon-upload.svg | 14 +++ src/components/DialogForm/index.vue | 10 +- .../equipment/components/AssetsUpload.vue | 26 ++-- .../equipment/components/EquipmentAssets.vue | 32 ----- .../equipment/components/EquipmentPics.vue | 111 ------------------ src/views/core/base/equipment/index.vue | 28 ++--- src/views/core/base/equipmentType/index.vue | 2 - .../equipmentStatusAndParams/index.vue | 8 +- .../qualityStatistics/graphPage.vue | 1 + 9 files changed, 57 insertions(+), 175 deletions(-) create mode 100644 src/assets/icons/svg/icon-upload.svg delete mode 100644 src/views/core/base/equipment/components/EquipmentAssets.vue delete mode 100644 src/views/core/base/equipment/components/EquipmentPics.vue diff --git a/src/assets/icons/svg/icon-upload.svg b/src/assets/icons/svg/icon-upload.svg new file mode 100644 index 00000000..7c679b07 --- /dev/null +++ b/src/assets/icons/svg/icon-upload.svg @@ -0,0 +1,14 @@ + + + 上传 + + + + + + + + + + + \ No newline at end of file diff --git a/src/components/DialogForm/index.vue b/src/components/DialogForm/index.vue index e19db936..b0d57759 100644 --- a/src/components/DialogForm/index.vue +++ b/src/components/DialogForm/index.vue @@ -83,6 +83,9 @@ :on-success="handleUploadSuccess" v-bind="col.bind"> + 上传文件
@@ -133,7 +136,6 @@ const uploadedFile = { }, methods: { handleDelete() { - console.log('emit delete event') this.$emit('delete', this.file); }, }, @@ -220,7 +222,6 @@ export default { watch: { rows: { handler() { - console.log('watch triggered!'); this.$nextTick(() => { this.handleOptions('watch'); }); @@ -231,6 +232,7 @@ export default { dataForm: { handler(val) { this.form = JSON.parse(JSON.stringify(val)); + this.form.files = this.form.files ?? []; }, deep: true, immediate: true, @@ -368,7 +370,9 @@ export default { }, handleDeleteFile(file) { - this.form.files = this.form.files.filter(item => item.fileUrl != file.fileUrl); + this.form.files = this.form.files.filter( + (item) => item.fileUrl != file.fileUrl + ); this.$emit('update', this.form); }, }, diff --git a/src/views/core/base/equipment/components/AssetsUpload.vue b/src/views/core/base/equipment/components/AssetsUpload.vue index c6d410e5..2d7f84ab 100644 --- a/src/views/core/base/equipment/components/AssetsUpload.vue +++ b/src/views/core/base/equipment/components/AssetsUpload.vue @@ -18,9 +18,16 @@ 预览
--> -
+
- - - - - diff --git a/src/views/core/base/equipment/components/EquipmentPics.vue b/src/views/core/base/equipment/components/EquipmentPics.vue deleted file mode 100644 index 9c4b1f92..00000000 --- a/src/views/core/base/equipment/components/EquipmentPics.vue +++ /dev/null @@ -1,111 +0,0 @@ - - - - - - - diff --git a/src/views/core/base/equipment/index.vue b/src/views/core/base/equipment/index.vue index 16c881d8..ae2b9ced 100644 --- a/src/views/core/base/equipment/index.vue +++ b/src/views/core/base/equipment/index.vue @@ -105,9 +105,6 @@