yz3456
2024-05-10 fa3615d2dcad3eb020a7ac59581546a6560e37ae
ruoyi-ui/src/views/note/memo.vue
@@ -130,24 +130,25 @@
          </template>
          <i v-if="true" slot="default" class="el-icon-plus"></i>
          <div slot="file" slot-scope="{file}">
            <!-- 添加video元素用于显示视频 -->
            <video
              v-if="file.url.includes('.mp4')"
              class="el-upload-list__item-thumbnail"
              :src="file.url"
              style="width: 147px; height: 147px"
              fit="cover"
                 style="width: 147px; height: 147px"
              fit="fill"
            ></video>
            <img v-else
                 class="el-upload-list__item-thumbnail"
                 :src="file.url"
                 src="../../assets/images/deviceLis.png"
                 alt=""
                 style="width: 100%; height: 100%"
                 style="width: 147px; height: 147px"
                 fit="cover">
            <span class="el-upload-list__item-actions">
                 <span class="el-upload-list__item-name">{{ file.name }}</span>
                 <span class="el-upload-list__item-name">{{file.name}}</span>
                      <span
                        class="el-upload-list__item-preview"
                        @click="handleFileCardPreview(file)"
@@ -168,17 +169,21 @@
                        <i class="el-icon-delete"></i>
                      </span>
                </span>
               <!-- <div style="height: 50px;">
                {{file.name}}
                </div> -->
            <!-- <div style="position:absolute; z-index:2; left:0px; top:70%">{{file.name}}</div> -->
          </div>
        </el-upload>
<el-button
                style="margin-left: 10px"
                size="small"
                type="success"
                @click="fileUpload"
              >上传到服务器</el-button>
        <el-button
          style="margin-left: 10px;"
          size="small"
          type="success"
          @click="fileUpload"
        >上传到服务器</el-button>
        </el-form>
      </el-col>
@@ -283,7 +288,7 @@
              ></video>
              <img v-else
                   class="el-upload-list__item-thumbnail"
                   :src="file.url"
                   src="../../assets/images/deviceLis.png"
                   alt=""
                   style="width: 100%; height: 100%"
                   fit="cover">
@@ -502,6 +507,8 @@
       _this.formDat.url = _this.formDat.url+","+response.fileNames
       _this.$modal.msgSuccess("文件上传成功!");
         })
            // const cid = this.$route.params && this.$route.params.id;
            // this.getList(2007,cid);
    },
    // 查看文件