Forráskód Böngészése

编辑插件-bug修改

lxh 1 éve
szülő
commit
0bbb53d2b1

+ 4 - 4
src/views/vent/performance/comment/DeviceModal.vue

@@ -24,8 +24,8 @@
       default: '',
     },
     editID: {
-      type: Number,
-      default: 0,
+      type: String,
+      default: '',
     },
   });
   //设置标题
@@ -52,7 +52,7 @@
         height: '500px',
         document: {
           title: '文档管理',
-          url: 'http://47.94.222.6:9050/ventanaly-sharefile/fileServer/onlyOffice/read?id=' + [[props.editID]], //id表示文件id,后端接口用这个id来加载文件
+          url: 'http://47.94.222.6:9999/ventanaly-sharefile/fileServer/onlyOffice/read?id=' + props.editID, //id表示文件id,后端接口用这个id来加载文件
           fileType: props.fileType == 'doc' ? 'docx' : props.fileType == 'xls' ? 'xlsx' : props.fileType == 'ppt' ? 'pptx' : props.fileType, //当文件类型为doc、xls、ppt时,对应用docx、xlsx、pptx否则会保存异常。
           key: '',
           lang: 'zh-CN',
@@ -66,7 +66,7 @@
         editorConfig: {
           lang: 'zh-CN',
           mode: 'edit', //view:只读且可复制内容,edit:可编辑
-          callbackUrl: 'http://47.94.222.6:9050/ventanaly-sharefile/fileServer/onlyOffice/read?id=' + [[props.editID]], //id表示文件id,后端接口用这个id来加载文件
+          callbackUrl: 'http://47.94.222.6:9999/ventanaly-sharefile/fileServer/onlyOffice/save?id=' + props.editID, //id表示文件id,后端接口用这个id来加载文件
           coEditing: {
             mode: 'fast',
             change: true,

+ 3 - 2
src/views/vent/performance/fileDetail/index.vue

@@ -31,9 +31,10 @@
         <div class="search">
           <a-input v-model:value="fileName" placeholder="请输入文件名称" />
           <a-button type="primary" preIcon="ant-design:search-outlined" @click="onSearch">查询</a-button>
-          <a-upload :before-upload="beforeUpload" :remove="handleRemove" :multiple="false" :file-list="fileList">
+          <a-button type="primary" style="float: right; margin-right: 20px" @click="openModal(true)">文件上传</a-button>
+          <!-- <a-upload :before-upload="beforeUpload" :remove="handleRemove" :multiple="false" :file-list="fileList">
             <a-button type="primary" preIcon="ant-design:cloud-upload-outlined">文件上传</a-button>
-          </a-upload>
+          </a-upload> -->
         </div>
         <div class="list">
           <div class="bd-t"></div>