From aed1ff699140de60131bf9cc1332c98063c66721 Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期五, 03 七月 2020 09:14:51 +0800
Subject: [PATCH] 2020-07-03

---
 src/tabviews/zshare/fileupload/index.jsx |   29 ++++++++++++++---------------
 1 files changed, 14 insertions(+), 15 deletions(-)

diff --git a/src/tabviews/zshare/fileupload/index.jsx b/src/tabviews/zshare/fileupload/index.jsx
index 99e0619..4f8f0a8 100644
--- a/src/tabviews/zshare/fileupload/index.jsx
+++ b/src/tabviews/zshare/fileupload/index.jsx
@@ -8,10 +8,10 @@
 import Utils from '@/utils/utils.js'
 import './index.scss'
 
-let Url = '/Upload'
-if (process.env.NODE_ENV === 'production') {
-  Url = document.location.origin + '/' + window.GLOB.service + 'zh-CN/Home/Upload'
-}
+// let Url = '/Upload'
+// if (process.env.NODE_ENV === 'production') {
+//   Url = document.location.origin + '/' + window.GLOB.service + 'zh-CN/Home/Upload'
+// }
 
 let service = ''
 if (process.env.NODE_ENV === 'production') {
@@ -28,7 +28,6 @@
   }
 
   state = {
-    baseUrl: Url,
     percent: 0,
     showprogress: false
   }
@@ -83,11 +82,11 @@
     })
   }
 
-  getExtraData = () => {
-    return {
-      RootPath: 'Content/images/upload/'
-    }
-  }
+  // getExtraData = () => {
+  //   return {
+  //     RootPath: 'Content/images/upload/'
+  //   }
+  // }
 
   shardupload = (params) => {
     let param = params.chunks.shift()
@@ -245,12 +244,12 @@
 
   render() {
     const { value, maxFile, fileType } = this.props
-    const { showprogress, percent, baseUrl } = this.state
+    const { showprogress, percent } = this.state
 
-    let uploadable = ''
+    let uploadable = 'fileupload-form-container '
 
     if (maxFile && maxFile > 0 && value && value.length >= maxFile) {
-      uploadable = 'limit-fileupload'
+      uploadable += 'limit-fileupload'
     }
 
     const props = {
@@ -258,12 +257,12 @@
       disabled: showprogress,
       listType: fileType,
       fileList: value,
-      action: baseUrl,
+      action: null,
       method: 'post',
       multiple: false,
       onChange: this.onChange,
       onRemove: this.onRemove,
-      data: this.getExtraData,
+      // data: this.getExtraData,
       beforeUpload: this.beforeUpload,
       className: uploadable
     }

--
Gitblit v1.8.0