|
@@ -11596,6 +11596,22 @@ U.MD.D.I.downloadFile = function (cid, s, task, t, uid, type, text, loading, spa
|
|
|
if (uploadedCount === total) finalizeUpload();
|
|
|
return;
|
|
|
}
|
|
|
+ // 如果 dataURL 已经是链接(http, https, //, oss, cloud, cocorobo)就不上传
|
|
|
+ if (
|
|
|
+ typeof fileObj.dataURL === "string" &&
|
|
|
+ (
|
|
|
+ /^https?:\/\//.test(fileObj.dataURL) ||
|
|
|
+ /^\/\//.test(fileObj.dataURL) ||
|
|
|
+ fileObj.dataURL.startsWith('oss://') ||
|
|
|
+ fileObj.dataURL.startsWith('cloud://') ||
|
|
|
+ fileObj.dataURL.indexOf('.cocorobo.cn/') > -1
|
|
|
+ )
|
|
|
+ ) {
|
|
|
+ // 已经是链接,不上传,直接计数
|
|
|
+ uploadedCount++;
|
|
|
+ if (uploadedCount === total) finalizeUpload();
|
|
|
+ return;
|
|
|
+ }
|
|
|
// 是 base64 字符串转 File
|
|
|
if (typeof fileObj.dataURL === "string") {
|
|
|
let filename = fileObj.name || ('file_' + key);
|