From d80a5794d029c8a5fe58a80464ab0e1ae097c87c Mon Sep 17 00:00:00 2001
From: feige <feige@qq.com>
Date: 星期二, 05 十二月 2023 21:52:03 +0800
Subject: [PATCH] 增加图像查看功能

---
 ruoyi-ui/src/views/pet/noteInfo.vue |   37 +++++++++++++++++++++++++++++++------
 1 files changed, 31 insertions(+), 6 deletions(-)

diff --git a/ruoyi-ui/src/views/pet/noteInfo.vue b/ruoyi-ui/src/views/pet/noteInfo.vue
index 47102e2..9d53ee6 100644
--- a/ruoyi-ui/src/views/pet/noteInfo.vue
+++ b/ruoyi-ui/src/views/pet/noteInfo.vue
@@ -33,6 +33,8 @@
         multiple
         :http-request="requestUpload"
         :file-list="fileList"
+        :disabled="!btn"
+        :class="{ hide: !btn }"
       >
         <div v-if="uploading" class="upload-status">姝e湪涓婁紶...</div>
         <i v-if="!uploading" slot="default" class="el-icon-plus"></i>
@@ -84,6 +86,8 @@
         :on-remove="handleRemoveFile"
         :http-request="requestUpload"
         :show-file-list="true"
+        :disabled="!btn"
+        :class="{ hide: !btn }"
       >
         <div v-if="uploading" class="upload-status">姝e湪涓婁紶...</div>
         <i v-if="!uploading" slot="default" class="el-icon-plus"></i>
@@ -156,7 +160,10 @@
     return {
       cdi:"榄呭疇澶囧繕鏈缁嗕俊鎭�",
       udi:"榄呭疇澶囧繕鏈俊鎭慨鏀�",
-      fot:[".jpg",".jif",".png"],
+      // 鏁版嵁鑼冨洿閫夐」
+      fot:['.bmp','.jpg','.jpeg','.png','.tif','.gif','.pcx','.tga','.exif','.fpx',
+        '.svg','.psd','.cdr','.pcd','.dxf','.ufo','.eps','.ai','.aw','.WMF','.webp','.apng'],
+      
       fileList:[
       ],
       fileListOther:[
@@ -224,13 +231,14 @@
       this.btn= jd
       this.dsb = !jd
       this.isShow=true
-      document.title = "淇敼璧勪骇璇︾粏淇℃伅";
-      this.$route.meta.title = "淇敼璧勪骇璇︾粏淇℃伅";//鍒楄〃鐨勫悕绉�
+      document.title = "淇敼榄呭疇澶囧繕褰曡缁嗕俊鎭�";
+      this.$route.meta.title = "淇敼榄呭疇澶囧繕褰曡缁嗕俊鎭�";//鍒楄〃鐨勫悕绉�
     }
     else{
-      document.title = "瀹跺涵璧勪骇璇︾粏淇℃伅";
-      this.$route.meta.title = "瀹跺涵璧勪骇璇︾粏淇℃伅";//鍒楄〃鐨勫悕绉�
+      document.title = "榄呭疇澶囧繕褰曡缁嗕俊鎭�";
+      this.$route.meta.title = "榄呭疇澶囧繕褰曡缁嗕俊鎭�";//鍒楄〃鐨勫悕绉�
       this.isShow=false
+      this.btn = false;
     }
 
     let _this = this
@@ -372,6 +380,20 @@
         else{
           _this.fileListOther.push({"name":response.data.fileName, "url":response.data.url})
         }
+        let ul = _this.fileList.map(function (elem){
+            return elem.url.replace(process.env.VUE_APP_BASE_TRUE_API,"")
+          }).join(",")
+          let uls = _this.fileListOther.map(function (elem){
+            return elem.url.replace(process.env.VUE_APP_BASE_TRUE_API,"")
+          }).join(",")
+          _this.formData.url = ul+","+uls
+          console.log(_this.formData.url)
+        //  alert(87)
+          updatenotePet(_this.formData).then(response => {
+            this.$modal.msgSuccess("鍥剧墖涓婁紶鎴愬姛");
+            // this.open = false;
+        
+          });
       })
 
     }
@@ -380,7 +402,7 @@
 }
 
 </script>
-<style>
+<style scoped>
 .mt
 {
   position: relative;
@@ -389,6 +411,9 @@
   display: block;
 
 }
+.hide /deep/ .el-upload--picture-card {
+  display: none;
+}
 .form{
   background:center/11% no-repeat url('../../assets/icons/form.png') ;
 }

--
Gitblit v1.9.1