Преглед изворни кода

支持同名文件同时上传

xiaohaizhao пре 9 месеци
родитељ
комит
c40f983b52
1 измењених фајлова са 1 додато и 1 уклоњено
  1. 1 1
      components/Yl_Upload/index.js

+ 1 - 1
components/Yl_Upload/index.js

@@ -74,7 +74,7 @@ Component({
                 "classname": "system.attachment.huawei.OBS",
                 "method": "getFileName",
                 "content": {
-                    "filename": file.name,
+                    "filename": file.name.concat(Date.now(), ".").concat(ext),
                     "filetype": ext,
                     "parentid": this.data.parentid
                 }