From aa0481c047a57977d23ea2e1e2015866c9d4b201 Mon Sep 17 00:00:00 2001
From: yz3456 <2753272399@qq.com>
Date: 星期一, 25 三月 2024 23:59:15 +0800
Subject: [PATCH] 完善了一些家庭会议模块1

---
 ruoyi-ui/src/views/pet/index.vue |   35 +++++++++++++++++++++++++----------
 1 files changed, 25 insertions(+), 10 deletions(-)

diff --git a/ruoyi-ui/src/views/pet/index.vue b/ruoyi-ui/src/views/pet/index.vue
index 4f97874..547de62 100644
--- a/ruoyi-ui/src/views/pet/index.vue
+++ b/ruoyi-ui/src/views/pet/index.vue
@@ -322,6 +322,10 @@
 
     </el-dialog>
 
+    <el-dialog  :visible.sync="dialogVisible">
+      <img w-full :src="dialogImageUrl"    style="width: 100%; height: 100%" alt="Preview Image" />
+    </el-dialog>
+
   </div>
 </template>
 
@@ -332,7 +336,7 @@
 
 
 //鍦╯ystem/note/index.js涓鍏ユ帴鍙e嚱鏁�
-import {listPet,enload, getPetInfo, delPet,addPet, uploadPic} from "@/api/pet/index";
+import {listPet,enload, getPetInfo, delPet,addPet, uploadPic1} from "@/api/pet/index";
 export default {
   name: "Role",
   dicts: ['sys_normal_disable'],
@@ -363,13 +367,16 @@
       menuNodeAll: false,
       deptExpand: true,
       deptNodeAll: false,
+
+      dialogImageUrl: '',
+      dialogVisible: false,
       // 鏃ユ湡鑼冨洿
       dateRange: [],
       // 鏁版嵁鑼冨洿閫夐」
       // 鏁版嵁鑼冨洿閫夐」
       fot:['.bmp','.jpg','.jpeg','.png','.tif','.gif','.pcx','.tga','.exif','.fpx',
         '.svg','.psd','.cdr','.pcd','.dxf','.ufo','.eps','.ai','.aw','.WMF','.webp','.apng'],
-      
+
       fileList1:[ ],
       fileList2:[ ],
       fileListOther:[ ],
@@ -713,16 +720,24 @@
             addPet(this.formDat).then(response => {
               this.$modal.msgSuccess("鏂板鎴愬姛");
               this.open = false;
+              // 娓呯┖formDat瀵硅薄鐨勬暟鎹�
+              Object.keys(this.formDat).forEach(key => {
+                this.formDat[key] = '';
+              });
+              for(let i = 0; i <= this.fileList1.length; i++)
+              {
+                this.handleRemove(this.fileList1[0]);
+              }
+              for(let i = 0; i < this.fileListOther.length; i++){
+                this.handleRemoveFile(this.fileListOther[0]);
+              }
+              // this.handleRemove(this.fileList[0]);
+              // this.handleRemoveFile(this.fileListOther[0]);
               this.getList();
             });
           }
         });
-      // 娓呯┖formDat瀵硅薄鐨勬暟鎹�
-      Object.keys(this.formDat).forEach(key => {
-        this.formDat[key] = '';
-      });
-      this.handleRemove(this.fileList[0]);
-      this.handleRemoveFile(this.fileListOther[0]);
+
     },
     requestUpload(params)
     {
@@ -732,7 +747,7 @@
       formData.append('uploadFile', file);
       let _this = this
 
-      uploadPic(formData).then(response => {
+      uploadPic1(formData).then(response => {
         let pth = response.data.originalFilename.substr(response.data.originalFilename.length-4, response.data.originalFilename.length)
         _this.fileList1.push({name:response.data.fileName, url:response.data.url})
         // _this.fileList2.push({name:response.data.fileName, url:response.data.url})
@@ -748,7 +763,7 @@
       formData.append('uploadFile', file);
       let _this = this
 
-      uploadPic(formData).then(response => {
+      uploadPic1(formData).then(response => {
         let pth = response.data.originalFilename.substr(response.data.originalFilename.length-4, response.data.originalFilename.length)
         // _this.fileList1.push({name:response.data.fileName, url:response.data.url})
         _this.fileList2.push({name:response.data.fileName, url:response.data.url})

--
Gitblit v1.9.1